User guide

Chapter 5
626
External Device Setup Manual
- FC7 Read exception status -Reading of exception status (Bit 0 to 7 of HR400001)
5. Exception code
The following table describes the exception codes that are sent upon an abnormal response.
Normal response
Byte 7 FC (Function code) = 06 (HEX)
Byte 8-9 Reference No.
Byte 10-11 Write data
Abnormal response
Byte 7 FC (Function code)=86 (HEX)
Byte 8 Exception code 01 or 02
Example
Writing to HR400001. The write value is 1234 (HEX).
06 00 00 12 34 => 06 00 00 12 34
Request
Byte 7 FC (Function code)=07 (HEX)
Normal response
Byte 7 FC (Function code)=07 (HEX)
Byte 8 Value of exception status
Abnormal response
Byte 7 FC (Function code)= 87 (HEX)
Byte 8 Exception code 01 or 02
Communication example
Reading of exception status. The read value is 34 (HEX).
07 => 07 34
The Read exception status function reads the data from the device holding special status information using the
Modbus TCP protocol. Since the MICRO/I or Touch does not have special registers, the exception status is read
by bit 0 to 7 of HR400001.
Exception
code
Name Description
01 ILLEGAL FUNCTION Indicates that a function code that is not defined by the Modbus TCP protocol
or a function code that is not supported by the MICRO/I or Touch is desig-
nated.
02 ILLEGAL DATA ADDRESS The address information included in the data is invalid. For example, when
reading the number of read words starting from the starting reference No. for
the read, this exception code is sent if the data exceeds the maximum address
of the device.
03 ILLEGAL DATA VALUE The value of the data is invalid. This exception code is also sent when the
number of data is invalid.