4 Modbus protocol description
28
4.9 Error messages
4.9.1 Modbus error codes
No response by
the paperless
recorder
In the event of the following errors, the slave will not respond:
• Baud rate and/or data format of Master (PC or notebook) and Slave
(paperless recorder) are not compatible.
• The device address of the paperless recorder does not comply with that
contained in the protocol.
• The checksum (CRC16) is not correct.
• The instruction from the Master is incomplete or over-defined.
• The number of words to be read is zero.
In these cases the data request should be transmitted again once the timeout
time (2s)
has elapsed.
Error codes If the data request of the master has been received by the paperless recorder
without transmission errors but could not be processed, the paperless
recorder will respond with an error code.
The following error codes can be occur:
• 01 Invalid error code
• 02 Invalid address or number of words or bits to be read or written is too
large
• 03 Value not within the admissible range
• 08 Value wirte-protected
Response in the
event of an
error
0x80 is used to set the function code to its OR status, i.e. the MSB (most
significant bit) is set to 1.
Example Data request:
Response:
Respons is error code 08 because address 0x1257 is write-protected.
Slave
address
Function
XX OR 80h
Error code Checksum
CRC16
1 byte 1 byte 1 byte 2 byte
01 06 1257 0001 FCA2
01 86 08 43A6