ProSoft Technology MVI56E-MNETR User Manual

Page 130

Advertising
background image

MVI56E-MNETR ♦ ControlLogix Platform

Reference

Modbus TCP/IP Interface Module with Reduced Data Block

User Manual


Page 130 of 153

ProSoft Technology, Inc.

August 31, 2009

ƒ If the server receives the request, but detects a communication error (parity,

LRC, CRC, ...), no response is returned. The Client program will eventually
process a timeout condition for the request.

ƒ If the server receives the request without a communication error, but cannot

handle it (for example, if the request is to read a non-existent output or
register), the server will return an exception response informing the Client of
the nature of the error.

The exception response message has two fields that differentiate it from a
normal response:

Function Code Field: In a normal response, the server echoes the function
code of the original request in the function code field of the response. All function
codes have a most-significant bit (MSB) of 0 (their values are all below 80
hexadecimal). In an exception response, the server sets the MSB of the function
code to 1. This makes the function code value in an exception response exactly
80 hexadecimal higher than the value would be for a normal response.

With the function code's MSB set, the Client's application program can recognize
the exception response and can examine the data field for the exception code.

Data Field: In a normal response, the server may return data or statistics in the
data field (any information that was requested in the request). In an exception
response, the server returns an exception code in the data field. This defines the
server condition that caused the exception.

The following table shows an example of a Client request and server exception
response.

Request

Response

Field Name

(Hex)

Field Name

(Hex)

Function 01

Function 81

Starting Address Hi

04

Exception Code

02

Starting Address Lo

A1

Quantity of Outputs Hi

00

Quantity of Outputs Lo 01

In this example, the Client addresses a request to server device. The function
code (01) is for a Read Output Status operation. It requests the status of the
output at address 1245 (04A1 hex). Note that only that one output is to be read,
as specified by the number of outputs field (0001).

If the output address is non-existent in the server device, the server will return
the exception response with the exception code shown (02). This specifies an
illegal data address for the Server.

Advertising
This manual is related to the following products: