Fieldbus control through the embedded fieldbus interface (EFB) 455
Modbus function codes
The table below shows the Modbus function codes supported by the embedded
fieldbus interface.
Code Function name Description
01h Read Coils Reads the 0/1 status of coils (0X references).
02h Read Discrete Inputs Reads the 0/1 status of discrete inputs (1X
references).
03h Read Holding Registers Reads the binary contents of holding registers (4X
references).
05h Write Single Coil Forces a single coil (0X reference) to 0 or 1.
06h Write Single Register Writes a single holding register (4X reference).
08h Diagnostics Provides a series of tests for checking the
communication, or for checking various internal error
conditions.
Supported subcodes:
• 00h Return Query Data: Echo/loopback test.
• 01h Restart Comm Option: Restarts and initializes
the EFB, clears communications event counters.
• 04h Force Listen Only Mode
• 0Ah Clear Counters and Diagnostic Register
• 0Bh Return Bus Message Count
• 0Ch Return Bus Comm. Error Count
• 0Dh Return Bus Exception Error Count
• 0Eh Return Slave Message Count
• 0Fh Return Slave No Response Count
• 10h Return Slave NAK (negative acknowledge)
Count
• 11h Return Slave Busy Count
• 12h Return Bus Character Overrun Count
• 14h Clear Overrun Counter and Flag
0Bh Get Comm Event
Counter
Returns a status word and an event count.
0Fh Write Multiple Coils Forces a sequence of coils (0X references) to 0 or 1.
10h Write Multiple Registers Writes the contents of a contiguous block of holding
registers (4X references).
16h Mask Write Register Modifies the contents of a 4X register using a
combination of an AND mask, an OR mask, and the
register’s current contents.
17h Read/Write Multiple
Registers
Writes the contents of a contiguous block of 4X
registers, then reads the contents of another group of
registers (the same or different than those written) in
a server device.