Skip to content

Common fields ​

These fields are used by Write, Read and Wait Until, and by If and While with a register condition.

FieldMeaning
channel"A" (default) or "B": which channel's connection to use. See Concepts › 9. Two channels
functionFunction code, see each command
address / end_address / countAddress range, up to 123 registers
formatValue format
max_msResponse time limit in milliseconds, 0–600000. 0 or omitted means no limit. If the device responds but takes longer, the step FAILs

In addition, every step can be disabled with "disabled": true (written outside the command):

json
{ "read": { "address": "0x0A00", "expected": 8 }, "disabled": true }

A disabled step does not run, shows SKIP (disabled), and is struck through on screen. Disabling an If, Repeat or While skips the whole block. On screen, select a step and press Ctrl+/ to toggle it.

Common field settings

On screen, max_ms is the Max response field.

Example ​

Step 2 has a 500 ms response limit (answer ≤ 500 ms); step 3 is disabled and shows SKIP.

Common fields example result

Download the sample script ​

Sample script

Before running it, start a Slave window on 127.0.0.1:502 and click Listen, then open the script with Open JSON in Script mode and click Run. See How to use the examples.

Roach Modbus Tool by Mr.Roach