Modbus MFU Option Card Installation Manual
44 of 76
Publication PUB091-003-00_0119
7.3 Function Code Support
Details of the Request and Reply formats for messages can be found in the Modbus Application
Protocol Specification V1.1b3, found at http://www.modbus.org. The following table lists the function
codes supported by the Modbus Module.
Function
Code
Modbus Name
Addressing
01
Read Output Coil Status
Discrete
02
Read Input Status
Discrete
03
Read Holding Registers
Register
04
Read Input Registers
Register
05
Force Single Coil
Discrete
06
Preset Single Register
Register
07
Read Exception Status
08
Loopback Diagnostic Test
15
Force Multiple Coils
Discrete
16
Preset Multiple Registers
Register
17
Report Slave ID
Exception Response
Code
Meaning
01
Illegal function code or incorrect message length
02
Illegal data address (Register or discrete address invalid)
03
Illegal data value
06
Busy
To read data the function code to use will depend on whether the data is to be read as single bits or as
16 bit registers. For example, code 01 reads data as discrete bits, whereas code 03 reads the data as
registers. In many cases Discrete and Register access reads the SAME data.
Code 01 - Read Coils
This is
used to read discrete (bit) data from the data base to obtain
information about the status of the output coils (commands).
Code 02 - Read Input Status Requests
This is
used to read discrete (bit) data from the data base to obtain
information about the actuator current status such as open or closed
positions achieved.
Code 03 - Read Holding Register Requests
All the data in the MFU can be read using function code 03. Discrete
data is mapped into registers that are available for this command.
Code 04 - Read Input Register Requests
Actuator position and torque registers, plus the status bits are
accessible with function code 04.