Ethereum Common

The packages contains two launch files: erc20.launch and signer.launch. The last one is included in Robonomics Liability.

Below is the description for erc20 node which contains utils for convenient work with Ethereum accounts and XRT token.

ROS Parameters

~web3_http_provider

Web3 HTTP provider address. The type is string, defaults to http://127.0.0.1:8545

~erc20_token

ERC20 token to work with. Type is string, defaults to xrt.3.robonomics.eth

~factory_contract

The name of the liability factory. The type is string, defaults to factory.3.robonomics.eth

~ens_contract

The checksumed address of ENS registry. The type is string, defaults to ""

~keyfile

Path to keyfile. The type is string, defaults to "". Required parameter

~keyfile_password_file

Path to a file with password for the keyfile. The type is string, defaults to "". Required parameter

Published topics

/eth/event/transfer (ethereum_common/TransferEvent)

The event ethereum_common/TransferEvent is emitted after the transfer of tokens was made

/eth/event/approval (ethereum_common/ApprovalEvent)

The event ethereum_common/ApprovalEvent is emitted after the approval of tokens was made

Services

/eth/accounts (ethereum_common/Accounts)

List of available Ethereum accounts. See Accounts.srv

/eth/account_eth_balance (ethereum_common/AccountBalance)

Returns the balance of the given address in Wei. See AccountBalance.srv

/eth/eth_balance (ethereum_common/Balance)

Returns the balance of the default address. See Balance.srv

/eth/current_block (ethereum_common/BlockNumber)

Returns current block number. See BlockNumber.srv

/eth/transfer (ethereum_common/Transfer)

Transfers tokens from the default account to a given one. See Transfer.srv

/eth/transfer_from (ethereum_common/TransferFrom)

Transfers tokens from a given account to another one. See TransferFrom.srv

/eth/approve (ethereum_common/Approve)

Approves tokens from the default account to a given one. See Approve.srv

/eth/account_xrt_balance (ethereum_common/AccountBalance)

Returns the XRT balance of a given account. See AccountBalance.srv

/eth/xrt_balance (ethereum_common/Balance)

Return the XRT balance of the default account. See Balance.srv

/eth/account_xrt_allowance (ethereum_common/AccountToAddressAllowance)

Returns how much one account is allowed to spend from another account. See AccountToAddressAllowance.srv

/eth/xrt_allowance (ethereum_common/Allowance)

Returns how much the Factory is allowed to spend from the default account. See Allowance.srv