- 46 -
RESPONSE
Address
Function
No. bytes
1st register
2nd register
2 byte
A
0x03
0x04
0x0064
0x00C8
CRC
Tot. byte = 3+2*No. re2
where: No. registers .. number of Modbus registers to write beginning from the address no. 1
No. byte ........ number of bytes of the following data
FUNCTION 16: Preset multiple registers (WRITE MULTIPLE REGISTERS)
QUERY
Address
Function 1st reg. add. No. reg. No. bytes Val.reg.1 Val.reg.2
2 byte
A
0x10
0x0000
0x0002
0x04
0x0000
0x0000
CRC
Tot. byte = 7+2*No. re2
RESPONSE
Address
Function
1st reg. address
No. reg.
2 byte
A
0x10
0x0000
0x0002
CRC
Tot. byte = 8
where: No. registers .. number of Modbus registers to read beginning from the address no. 1
No. byte ........ number of bytes of the following data
Val.reg.1 ....... contents of the register beginning from the first
The response contains the number of registers modified beginning from the address no. 1.
COMMUNICATION ERROR MANAGEMENT
The communication strings are controlled by way of the CRC (Cyclical Redundancy Check).
In case of communication error the slave will not respond with any string. The master must consider
a time-out for reception of the answer. If it does not receive an answer it deduces that there has
been a communication error.
In the case of the string received correctly but not executable, the slave responds with an
EXCEPTIONAL RESPONSE. The "Function" field is transmitted with the msb at 1.
EXCEPTIONAL RESPONSE
Address
Function
Code
2 byte
A
Funct + 0x80
CRC
CODE
DESCRIPTION
1
ILLEGAL FUNCTION (the function is not valid or is not supported)
2
ILLEGAL DATA ADDRESS (the specified data address is not available)
3
ILLEGAL DATA VALUE (the data received has an invalid value)