SMAX MODBUS®
8.3 Using the 06 Write Single Register function code
EXAMPLE 1
Operating parameters [0003 hex]
to the Slave having the node address 1: we need to set the scaling function
(
= 1) and the increasing counting when the sensor moves in
the direction shown by the arrow in Figure 1 (
set is 00 01 hex (= 0000 0000 0000 0001 in binary notation: bit 0
= 0; the remaining bits are not used,
therefore their value is 0).
Request PDU
(in hexadecimal notation)
[01][06][00][03][00][01][B8][0A]
where:
[01] = Slave address
[06] =
function code
[00][03] = address of the register (
Operating parameters [0003 hex]
register 4)
[00][01] = value to be set in the register
[B8][0A] = CRC
Response PDU
(in hexadecimal notation)
[01][06][00][03][00][01][B8][0A]
where:
[01] = Slave address
[06] =
function code
[00][03] = address of the register (
Operating parameters [0003 hex]
register 4)
[00][01] = value set in the register
[B8][0A] = CRC
The value 00 01 hex is set, i.e. 0000 0000 0000 0001 in binary notation: bit 0
= 0; the remaining bits are not
used, therefore their value is 0.
MAN SMAX MB E 1.2
Programming examples
79 of 84