Scripts

See Usage to read about how to use these scripts together.

tolk_server.py

modbus_tcp_slave.py

json_rpc_client.py

Send JSON-RPC requests.

Usage:
json_rpc_client read_coils <starting-address> <quantity> [–slave-id=<nr> –socket=<path>] json_rpc_client read_discrete_inputs <starting-address> <quantity> [–slave-id=<nr> –socket=<path>] json_rpc_client read_holding_registers <starting-address> <quantity> [–slave-id=<nr> –socket=<path>] json_rpc_client read_input_registers <starting-address> <quantity> [–slave-id=<nr> –socket=<path>] json_rpc_client write_single_coil <address> <value> [–slave-id=<nr> –socket=<path>] json_rpc_client write_single_register <address> <value> [–slave-id=<nr> –socket=<path>] json_rpc_client write_multiple_coils <starting_address> <values> [–slave-id=<nr> –socket=<path>] json_rpc_client write_multiple_registers <starting_address> <values> [–slave-id=<nr> –socket=<path>]
Options:
-h –help Show this screen. -s –slave-id=<nr> Id of slave [default: 1]. –socket=</tmp/tolk.sock> Location of Tolk’s socket [default: /tmp/tolk.sock].