Mitsubishi QD51 Programming Manual page 380

Logic controller
Hide thumbs Also See for QD51:
Table of Contents

Advertisement

11 INSTRUCTIONS AND FUNCTIONS
11 - 210
• Assign values to %(3) and %(4) ( %(6) and %(7) in case of a format 2
control table) in the following manner.
D!
• • • • • • •
Address viewed from the communication module
H!
L!
• • • • • •
Used as a work area.
H$
L$
to
100 H!=INT(D!/65536!)
110 L!=D!-H!*65536!
120 H$=RIGHT$("0000"+HEX$ (H!))
130 L$=RIGHT$("0000"+HEX$ (L!))
140 %(3)=VAL("&H+L$)
150 %(4)=VAL("&H+H$)
to
• Data is stored in <storage area for data read> in the following manner.
Example: When reading data in buffer memory addresses 1 to 3 from an AD61
module whose I/O addresses are from X/Y40 to X/Y5F.
1) If an input element is specified as a positive variable/array, the data is stored
as follows:
PCRD TBL%( ), RD%( )
Number of bytes to be read • • • • 6 bytes
Starting address • • • • • • • • • • •
Module number • • • • • • • • • • • •
Buffer memory viewed
from the PLC CPU
(Address)
23
45
H
H
1
(H)
(L)
00
12
H
H
2
(H)
(L)
00
18
H
H
3
(H)
(L)
In case of a format 2 control table
• • • • • • •
%(6)=VAL("&H+L$)
• • • • • • •
%(7)=VAL("&H+H$)
82
Specify
H
05
H
Buffer memory viewed
from the BASIC program
(Address)
45
(L)
82
H
H
83
23
(H)
H
H
84
12
(L)
H
H
85
00
(H)
H
H
86
18
(L)
H
H
87
00
(H)
H
H
MELSEC-Q
Storage status
of data read
RD%(0)
23
(H)
45
(L)
H
H
RD%(1)
00
(H)
12
(L)
H
H
00
(H)
18
(L)
RD%(2)
H
H
11 - 210

Advertisement

Table of Contents
loading

This manual is also suitable for:

Ad51h-s3Qd51-r24A1sd51s

Table of Contents