...
Each of the responses starts with a single byte (uint8
) indicating the length of its payload (len
) followed by that many bytes of payload. The payload consists of the raw Modbus response as sent by the Slave Device followed by 3 additional bytes: the first register/coil as uint16
(big endian) and the number of registers/coils as uint8
taken from the executed command. The following tables visualise the message structure. See the Examples Section for some sample data messages explained down to the individual bytes. We also provide a Reference decoder in JavaScript that can read the format.
...