Modsak Manual v3.15 - 3.3. Reading and writing registers

Download manual: PDF HTML

3.3. Reading and writing registers

You can read from or write to defined registers by selecting them in the Register Table and clicking the Read or Write button. Modsak will read values from the slave and display them in the register table, or write the values displayed in the register table to the slave.

Modsak uses the address range of the register to choose which Modbus command to use, as shown in the following table:

Table 6. Register read/write implementation

Address range Read command Write command
Holding register 3 Read Holding Registers 16 Write Multiple Registers*
Input register 4 Read Input Registers -
Coil 1 Read Coils 15 Write Multiple Coils*
Discrete input 2 Read Discrete Inputs -

* If the Use Single-Write Functions option has been selected, 6 Write Single Register will be used instead of 16 Write Multiple Registers and 5 Write Single Coil will be used instead of 15 Write Multiple Coils.

If a register appears in more than one address range (i.e. is overlaid), then Modsak will use the first (in the above table) address range that it appears in.

If more than one Modbus request is needed to perform the read or write, Modsak will delay each request except the first by the configured Request Delay .