11 - 251 11 - 251
MELSEC-Q
11 INSTRUCTIONS AND FUNCTIONS
• The special function module's buffer memory contains 16 bits (one word) per one
address and reading/writing operations between the PLC CPU and intelligent
functional module are performed with the FROM/TO instructions.
When reading/writing from the special function module's buffer memory to the QD51
(-R24) or vice versa, the operation is performed in units of 8 bits (one byte) per one
address.
The addresses (hexadecimal) to specify in the QD51 (-R24) are obtained by the
following conversion from addresses for the FROM/TO instructions.
Specified address (hexadecimal) = convert {(address for the FROM/TO instruction 2)} into a hexadecimal number
and add (the starting address of each module)
Example : When specifying address 1 of the FROM/TO instructions (the preset value
of CH.1) of the type AD61 high-speed counter module.
Specified
address 82
H
FROM/TO instruction
address 0
×
2, 1
H
×
2
starting
address 80
H
=
+
See the user's manual for the intelligent functional module for the starting address of
each intelligent functional module.
• Assign values to %(3) and %(4) ( %(6) and %(7) in case of a format 2 control
table, %(7) and %(8) in case of a format 3 control table) in the following manner.
D!
H!
L!
H$
L$
to
• • • •
• • • •
The specified address calculated using the formula above
Used as work area.
100 H!=INT(D!/65536!)
110 L!=D!-H! 65536!
120 H$=RIGHT$(”0000”+HEX$(H!),4)
130 L$=RIGHT$(”0000”+HEX$(L!),4)
In case of a format 2 control table
140 %(3)=VAL(”&H”+L$)
150 %(4)=VAL(”&H”+H$)
to
• • • •
• • • •
%(6)=VAL(”&H”+L$)
%(7)=VAL(”&H”+H$)