Read Coils (Modbus function 1)
Read Only
Returns one byte of data.
The bit positions 7 - 0, represent the exception state of the corresponding
channel or structure. (It doesnt represent the actual state
of any relay)
If a bit is set (1), the channel corresponding to the bits
position in the byte has detected an exception, i.e. the measurement
falls outside the parameters defined in its structure.
Example 1.
Read Coils (Modbus function 1)
Format-
[node address][01h][register start(2 bytes)][number of coils(2 bytes)][crc(2
bytes)]
Read coil data (8 coils = 1 byte)
[05][01][0000][0008][3C48]
Coil data returned (1 byte)
Format-
[node address][01h][number of bytes][coil data][crc(2 bytes)]
[05][01][01][18][50B2]
In the above
example the coil data returned tells us that channels 4 and 5 (having
their corresponding bits set) have detected an exception.
|