User guide
50 MDX-ETHERNET User Guide
www.leroy-somer.com Issue : a
13.6.2 Data access
Data access using Modbus TCP/IP takes the form of a request for data by the master,
followed by a response from the slave indicating either success (response), or failure
(exception response) as shown in Figure 13-2. If no response is received this indicates
that the message has not been received or the node is unable to reply.
Figure 13-2 Modbus TCP/IP- request, response, exception
MBAP and PDU message structure
The following tables document the structure of the MBAP and PDU, specifically the
functions of each data byte within the overall message structure.
Table 13.5 MBAP
Table 13.6 PDU
Byte Description
0 Transaction identifier MSB
1 Transaction identifier LSB
2 Protocol identifier MSB
3 Protocol identifier LSB
4 Length MSB
5 Length LSB
6 Unit identifier
PDU Consist of
Request Function code, 1 byte
Function data, > 1 byte
Response Function code, 1 byte
Response data, > 1 byte
Exception
Response
Error code, 1 byte
Exception code, 1 byte
Function
Code
Function Data
Function
Code
Response Data
Function
Code
Exception Data
PDU (Request)
PDU (Exception Response)
PDU (Response)