20 • vacon
modbus
Tel.+358 (0)201 2121 • Fax +358 (0)201 212 205
6
read the diagnostic status of the slave; to write to designated coils or registers; or to allow loading,
recording, or verifying the program within the slave.
When the slave responds to the master, it uses the function code field to indicate either a normal (er-
ror-free) response or that some kind of error occurred (called an exception response). For a normal
response, the slave simply echoes the original function code. For an exception response, the slave
returns a code that is equivalent to the original function code with its most significant bit set to a logic
1.
The data field is constructed using sets of two hexadecimal digits, in the range of 00 to FF hexadeci-
mal. These can be made from a pair of ASCII characters, or from one RTU character, according to the
network's serial transmission mode.
The data field of messages sent from a master to slave devices contains additional information which
the slave must use to take the action defined by the function code. This can include items like discrete
and register addresses, the quantity of items to be handled, and the count of actual data bytes in the
field.
If no error occurs, the data field of a response from a slave to a master contains the data requested. If
an error occurs, the field contains an exception code that the master application can use to determine
the next action to be taken.
Two kinds of checksum are used for standard Modbus networks. The error checking field contents
depend upon the transmission method that is being used.