4 - 6 4 - 6
MELSEC-Q
4 MODBUS
R
STANDARD FUNCTIONS
4.3.1 Read coils (FC: 01)
Reads the statuses (ON/OFF) of one or more coils.
Number of accessible devices with one message
1 to 2000 points
(1) Request message format (Master Slave)
Head coil number
Data
Read points
(H)
(L)
(H)
(L)
Function code
Function code
(0000
H
to FFFF
H
)
(01
H
)
(0001
H
to 07D0
H
)
(2) Response message format (Slave Master)
(When completed normally)
Data
Function code
Function code
Device data
1
Device data
n
(Number of read bytes n)
(Device data 1 to n)
Device data 1
b0
b1
b2
b3
b4
b5
b6
b7
Device data n
0 : OFF
1 : ON
The read coil statuses are stored in order from low-order to high-order bits.
When the number of read points is not a multiple of 8, the excess bits turn to 0.
Bit device storage
order
(01
H
)
Number of
read bytes
n
(When completed with an error)
Data
Function code
Function code
(81
H
)
Exception
code*
: When completed with an error, the exception code and error code are stored
into the buffer memory.
Refer to Section 11.3 for the storage location, confirmation method and more
details.