- 48 -
EXAMPLE 2
Multiple commands reading for registers (command 3, h03 hexadecimal).
Assuming that we wish to read the gross weight value (e.g.: 4000) and net weight value (e.g.: 3000),
reading from address 40008 to address 40011 must be performed by sending the following string:
h01 h03 h00 h07 h00 h04 hF5 hC8
The instrument will respond with the string:
h01 h03 h08 h00 h00 h0F hA0 h00 h00 h0B hB8 h12 h73
Query field name
hex
Response field name
hex
Instrument address
h01
Instrument address
h01
Function
h03
Function
h03
Address of the first register H
h00
Byte count
h08
Address of the first register L
h07
Datum 1 H
h00
Number of registers H
h00
Datum 1 L
h00
Number of registers L
h04
Datum 2 H
h0F
CRC16 L
hF5
Datum 2 L
hA0
CRC16 H
hC8
Datum 3 H
h00
Datum 3 L
h00
Datum 4 H
h0B
Datum 4 L
hB8
CRC16 L
h12
CRC16 H
h73
For additional examples regarding the generation of correct control characters (CRC16) refer to the
manual
Modicon PI-MBUS-300.