35
11. Modbus TCP server
11. 4. List of Modbus functions supported11. 5. “Read Holding Registers” (3) function
This Modbus request is used to read the values of a number (No. of Points) of adjacent words starting at the address indicated (Starting
Address). The values read are restored one after another, at the end of the response (First Point Data Last Point Data).
Request format:
Response format:
Exception response format:
Code
(decimal)
Modbus name Description Size of data
3 = 16#03 Read Holding Registers Read N output words 63 words max.
6 = 16#06 Write Single Register Write one output word -
16 = 16#10 Write Multiple Registers Write N output words 61 words max.
23 = 16#17 Read/Write Multiple Registers Read/write N words 20/20 words max.
43 = 16#2B Read Device Identification Identification -
Byte Meaning
0 Function Code = 16#03
1 Starting Address Hi
2 Starting Address Lo
3 No. of Points Hi (0)
4 No. of Points Lo (1 - 125)
Byte Meaning
0 Function Code = 16#03
1 Byte Count (B = 2 × No. of Points)
2 First Point Data Hi
3 First Point Data Lo
… ………………………
B Las t Point Data Hi
B+1 Last Point Data Lo
Byte Meaning With the VW3A3310d Ethernet card
0 Function Code = 16#83
1 Exception Code
01 (Illegal Function)
02 (Illegal Data Address)
03 (Illegal Data Value)
04 (Illegal Response Length)