(N) Operation via communication and its settings
34
• Read data / write data
The value read from the device is stored for reading. The value to be written to the device is stored for writing.
The data is arranged differently between reading/writing in bit units (subcommand: H0001) and reading/writing in word units
(subcommand: H0000).
• In bit units (subcommand: H0001)
Each device is specified in 4 bits. The data is sent from the upper bit for the device with the first device No. and the
subsequent devices in order. The ON state is denoted as 1 and the OFF state is denoted as 0.
(Example) ON/OFF state of five devices starting from M10
• In word units (subcommand: H0000)
When bit devices are used as word data, each device is specified in one bit. The data is stored from the lower byte (bit
0 to bit 7) to the upper byte (bit 8 to bit 15).
(Example) ON/OFF state of 32 devices starting from M16
When word devices are used, one word is specified in 16 bits as follows. The data is stored from the lower byte (bit 0 to
bit 7) to the upper byte (bit 8 to bit 15).
The user should switch the values in the upper and lower bytes in the response data for reading.
The user should switch the write values in the upper and lower bytes to store them in the request data for writing.
H0A H00 H00
H90
H05 H00 H10 H10 H10
M14 ON
M13 OFF
M12 ON
M11 OFF
M10 ON
Device
code
Number
of
devices
Data
"0" is shown when the number
of points is an odd number.
Head
device
H10 H00 H00
H90
H02 H00 H12 HAB HCD H34
0 0 0 1 0 0 1 0 1 0 1 0 1 0 1 1 1 1 0 0
b11 b10 b9 b8
b7 b6 b5 b4 b3 b2 b1 b0
1 1 0 1 0 0 1 1 0 1 0 0
b9 b8
b7 b6 b5 b4 b3 b2 b1 b0
b15 b14 b13 b12
b11 b10
b15 b14 b13 b12
1
2
A
B
C
D
3
4
0 OFF
1 ON
M23 to M16
M31 to M24
M39 to M32
M47 to M40
"02" is shown for the number of devices because the
word device is specified in 16-bit units.
Number
of
devices
Data
Data
First
device
Device
code