What Token Standards Are Explained With WiFi, USB, and Tezos
On the internet, you definitely saw things like “ERC-20”, “BEP-2 token”, or “FA2 NFT” referring to token standards. Why do tokens need those standards? What do those acronyms mean? How are they created?
We’ll try to answer all those questions using routine objects like WiFi switches and USB ports.
Why do we need token standards? Here’s WiFi to explain
Bob wants to turn off WiFi. To do that, he clicks on the WiFi icon and then moves the toggle.
The network is off, Bob is happy. But what does that do behind the scenes? The device’s OS ordered the system controller to disconnect the WiFi chip. So, Bob could actually do the same: directly command the controller to power off the WiFi chip.
Bob doesn’t care who produced his WiFi chip: Broadcom, Intel, Asus, or TP-Link. Bob doesn’t even have to know the internal commands of the chip or its architecture. It just actuates by clicking on the WiFi icon because the manufacturer made it pursuant to a common standard. OS developers made it so that moving the toggle causes the system to power it off. The creators of chips, in their turn, made their chips in such a way as to discontinue the power supply upon receiving the power-off command. Thanks to that, it only takes two clicks to turn off WiFi. Otherwise, Bob would have to read the manual and learn console commands.
So, what about tokens?
Roughly speaking, tokens are smart contracts or code executed by the virtual machine of blockchain.
OS developers and WiFi chip manufacturers try to make every chip understand the commands of any operating system without forcing the user to revert to the console. Just like that, token and dApp developers try to make every smart contract understand the commands of any blockchain application. To achieve that, they agree on the standards and then use them in their new development.
A token standard is a set of functions that the token’s contract must include. Basic standards like FA1.2, ERC-20, and BEP2 have the function Transfer to transfer tokens and the function Approve to allow one to transfer a certain amount of tokens, as well as View to browse the balance. Wallet developers make it so that when you press Send the wallet goes to the Transfer function. If the token developer names the function otherwise, the wallet won’t be able to use the token.
Over time, the functions of the basic standard become outdated or insufficient to work with new tasks. Thus, the good old rectangular Type-A USB will soon replace Type-C USB: it’s easier to put it in the socket, it transfers audio and video signals, and supports fast charging.
It’s the same in the blockchain. Transfer and Approve are not enough for DeFi, NFT, and GameFi. They required the developers to create new standards like FA2 on Tezos and ERC-721 on Ethereum. As gaming and metaverse projects evolve, new standards supporting more functions may and will emerge.
Must there be new token standards?
There are reasons for that. Hangzhou brought about timelock primitive to Tezos along with new view functions and global constants. To use them to their full potential, developers must agree on how to do it and reflect their agreement in the standard. It’s imperative that they do it, otherwise, Bob will have to read manuals and use the console.
Aside from that, a new token standard may implement other functions like transfer_and_call to notify the owner of a token transfer, zk-channels for anonymous transactions, expirable tokens for advanced DeFi mechanics, and many other things.
One of the new standard use cases is TZIP-17 or a preliminary signature of a transaction. It can simplify Tezos for new users: a contract creator signs the transaction and pays for gas in advance so that the user could send tokens for free. It’s good for GameFi to keep newbies away from gas fees, transaction confirmations, and other potentially unlikeable things.
Subscribe and never miss updates from the world of Tezos: