The TRON Developer Hub

Welcome to the TRON developer hub. You'll find comprehensive guides and documentation to help you start working with TRON as quickly as possible, as well as support if you get stuck. Let's jump right in!

Tronweb.contract()

Recent Posts

Archive

Tags

Getting Started

Introduction

The TRON network natively supports decentralized exchanges. A decentralized exchange consists of multiple trading pairs. A trading pair (Exchange) is an Exchange Market between token and token, or between token and TRX. Any account can create a trading pair between any tokens, even if the same pair already exists in the TRON network. Trading and price fluctuations of the trading pairs follow the Bancor Protocol. The TRON network stipulates the weights of the two tokens in all trading pairs are equal, so the ratio of their balance is the price between them. For example, let's say a trading pair contains two tokens, ABC and DEF. ABC has a balance of 10 million and DEF has a balance of 1 million. Since their weights are equal, 10 ABC = 1 DEF — that is, the price of ABC to DEF is 10ABC/DEF.

Tronscan Dex

The Dex page is listed on the Tronscan site. The site lists the various TRC token exchanges, most recent exchange price, change percentage, and TradingView chart. Below the TradingView chart are

Chart Settings

Settings Button

Scales: Set the y-axis scaling for viewing the exchange rate data. Default setting is Auto Scale, which is a Linear Scale, but Percentage can be toggled if you wish to view the exchange rate percentage change. Another common view is Log Scale. Log scaling allows the user to view all changes in an asset's history with relatively equal weighting on the same chart. Otherwise, in a linear chart, large moves in the exchange ratio may hide the variation in other areas.

Trading TRC Token/TRX Pairs

Purchasing a TRC token from the DEX using TRX is simple when using the UI. First, log in to your Tronscan wallet. The Buy button will turn green, while the Sell button turns orange. Enter the amount of TRC tokens you wish to purchase in the BUY prompt, and the TRX Estimated Cost automatically populates. Clicking on the BUY button triggers a purchase, which then broadcasts the purchase to the TRON network.

Buy ERC Token

Selling a TRC token back for TRX is a simple as well. Simply enter the amount of the TRC token you wish to sell, and click on the SELL button, which then broadcasts the transaction to the TRON network.