Modbus TCP/UDP

Modbus connection parameters

  • Byte Order:
  • Bit Order:
  • Single value write only:
    • This option switches between multiple write class and single write class
  • Max wait time
    • Specifies max wait time to receive value – the time for which will DataTalk wait for response from PLC adjust this according to your network speed and PLC capatabilities

FC5 “Force Single Coil” & FC6 “Preset Single Register” X FC15 “Force Multiple Coil” & FC16 “Preset Multiple Registers”

Address mapping

In our system, we use a short or symbolic addressing format to simplify working with Modbus registers. For example:

  • H:0 refers to Modbus address 40001
  • H:1 = 40002, H:7 = 40008, etc.
TypeModicon Address RangeAccessShort Address PrefixExample
Discrete Outputs (Coils)00001–09999Read / WriteO: (Output)O:0 → 00001
Discrete Inputs10001–19999Read-onlyI: (Input)I:0 → 10001
Input Registers30001–39999Read-onlyR: (Register/Input)R:0 → 30001
Holding Registers40001–49999Read / WriteH: (Holding)H:0 → 40001

Batch optimization

Batch optimization means grouping multiple tags into a single Modbus request instead of reading or writing them one by one. This improves performance by reducing the number of requests, lowering communication overhead, and making data exchange faster.

  • Max tag count – the maximum number of tags that can be grouped into one request.
  • Max wait time [ms] – maximum time the system will wait to collect tags before sending the batch.

In short: larger batches = fewer requests and better efficiency, but possibly slightly slower response for individual tags.