14
…5
MODBUS FUNCTIONS
5.6
Write Multiple Registers – Function Code 16
5.6.1
Write Multiple Registers Query
This message is used to change the contents of up to eight holding registers at a
time. When used with slave address zero (broadcast mode) all slave controllers
load the selected registers with the contents specified.
Note. To write to a register, its offset address (one less than the register
number) must be used, e.g. to write to register 25, the offset address 24 (18H)
is transmitted.
Example. Write the value 500 to the register address 25 (proportional band 1 –
heat) and the value 100 to the register address 26 (integral action time) in slave 01.
Register
Register
Number of
Byte
Address
Function
Start
Start
Registers
Count
Offset High
Offset Low
01
10
00
18
00
02
04
Holding
Holding
Holding
Holding
Error Check
Register 24
Register 24
Register 25
Register 25
Field
(CRC16)
High
Low
High
Low
01
F4
00
64
B2
E0
5.6.2
Write Multiple Registers Response
The Write Multiple Registers Response confirms slave identification, function code,
starting register address and quantity only.
Example
Register
Register
Number of
Error
Address
Function
Start Offset
Start Offset
Registers
Check
(CRC-16)
High
Low
Field
01
10
00
18
00
02
C1
CF