This repository contains the IOTA and Ethereum smart contract implementation of collaborative mapping. The collaborative mapping is a demonstration of how IOTA's smart contracts with the asynchronous requests between chains provide partition tolerance.
For testing Ethereum smart contracst, you can use Remix IDE. Remix is totally online and you don't need to install anything. You can deploy and test the smart contract on the IDE.
If you have own your private network. You can deploy the smart contract on your own network.
Multiple robots can register on the smart contract. After mapping the area they must submit the created map to the smart contract. By calling the getGlobalMap
everyone can receive the merged maps.
NOTE: IOTA 2.0 is heavily under development and in every version APIs chaing alot. The given instruction might not work with newer versions.
You will need at least two wasp
node connected to one or multiple goshimmer
nodes. Each of the controllerswarm
and agentswarm
smart contracts should be deployed on two different chain. These chains should be created by two disjoint wasp
committies. Also the committe members should be connected to two disjoint goshimmer
nodes.
For setting up everything on your local network:
- You should bring up a
goshimmer
network. You can use the script provided ingoshimmer
github repository. You need at least twogoshimmer
nodes. - In this script, you should also enable
faucet
andtxstream
plugins for thegoshimmer
nodes. You should change thedockercompose
file in thepeer_replica
.
--node.enablePlugins=bootstrap,"webAPIToolsEndpoint",faucet,txstream
- Then you should setup at least two
wasp
nodes. You can use this link. Just make sure that you bring it up in the same network that is created bygoshimmer
script, so thewasp
node you create can communicate withgoshimmer
ones. - By using
wasp-cli
you should create a new chain and deploy the smart contract. For creating the new chain and a tutorial on how you can deploy smart contracts you can follow the instructions given here. - For compiling the smart contract, you should clone the
wasp
repository. It is tested withv0.2.2
. - Then you should copy the
controllerswarm
andagentswarm
folders tocontracts/swarm
folder of the repository. And follow the instructions.