How to Use Solo-chain

<h1 align="center">How to Use Solo-chain</h1>
<p align="center" class="version">Version 0.1</p>

1. Installation

Solo-chain is an Ontology single-node private-net. It generates a block every six seconds.

You can view the source code in GitHub and download the release version from here.

2. Introduction

main UI
  1. The function of "reboot" is to restart the private-net and clear the existing data. And the function of "stop" is to stop the private-net.
  2. The default port of RPC server is 20336. For Restful server, the port is 20334. For websocket server, it is 20335.
  3. The height of blockchain will increase by one every six seconds. Gas price can be changed in the setting. Gas limit is a fixed number, 20000.
  4. In the account page, we have 5 accounts at first and the ONT and ONG in each account can be transferred. The ONG can be obtained by redeeming ONG.
block page
  1. The block page displays all blocks that contain transactions.
transaction page
  1. The transaction page displays transactions. It includes two types, deploy and invoke. You can see transaction details by clicking "Detail".
event page
  1. The event page displays all events that are invoked by "notify" in the smart contract.
page of smart contract
  1. The page of smart contract displays all smart contracts that has been deployed in the blockchain.
    At initialization, the blockchain will deploy several native contract by default.
logs page
  1. The log page displays all log of test node at runtime.

3. Solo-chain demo

Step1 - Start solo-chain

step 1

Step2 - Transfer and redeem ONG

2.1 Transfer ONT to another account

transfer

2.2 redeem ONG

redeem

Step 3 - Write a smart contract with SmartX

You can refer to this document for how to write a smart contract with SmartX.

Step 4 - Transfer 1000 ONG to Cyano wallet for deploying smart contracts.

4.1 Install Cyano wallet in Chrome, open it and create a new account.

cyano wallet

4.2 Create a new account and get public address

new account
public address

4.3 Transfer ONG to the new account by solo-chain

transfer ONG
balance
最后编辑于
©著作权归作者所有,转载或内容合作请联系作者
【社区内容提示】社区部分内容疑似由AI辅助生成,浏览时请结合常识与多方信息审慎甄别。
平台声明:文章内容(如有图片或视频亦包括在内)由作者上传并发布,文章内容仅代表作者本人观点,简书系信息发布平台,仅提供信息存储服务。

相关阅读更多精彩内容

  • rljs by sennchi Timeline of History Part One The Cognitiv...
    sennchi阅读 12,172评论 0 10
  • 我们为什么没办法收拾 物质过度泛滥 现在的社会就是不断出现新物品的环境,如今社会的制造业过于发达,网购以及电商的告...
    taomas阅读 6,934评论 1 3
  • 那时,妈妈带着我生活在一个名叫“虎啸村”的地方,我是进城懂事后才知道这个名字的,以前都只知道叫“沙坝嘴”。...
    涛涛宝宝阅读 1,661评论 0 0
  • 啊超喜欢的电影!陈柏霖那时候真帅啊! 惠珍拍他的球,写他的名字的时候。 年少的时候都会骑单车。
    菠00阅读 1,589评论 0 0

友情链接更多精彩内容