Mitsubishi QD51 Programming Manual page 478

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

Advertisement

11 INSTRUCTIONS AND FUNCTIONS
(Address)
11 - 308
• Assign values to %(3) and %(4) ( %(6) and %(7) in case of a format 2 control
table) in the following manner.
D!
• • •
Address seen from the communication module
H!
L!
Used as work areas.
• • • •
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 to be written> in the following manner.
Example : When writing data to buffer memory addresses 1 to 3 of an AD61 module
whose I/O addresses are from X/Y40 to X/Y5F.
1) If an input element is specified as an integer variable/array, the data is stored as
follows:
PCRD TBL%( ), SD%( )
Number of bytes to be written • • • • 6 bytes
Starting address • • • • • • • • • • • •
Module number • • • • • • • • • • • • •
Buffer memory viewed
from the PLC CPU
(Address)
23
45
H
1
(H)
(L)
00
12
H
2
(L)
(H)
00
18
H
3
(H)
(L)
2) If an input element is specified as a character variable or character array variable
name:
Number of bytes to be written • • • • 6 bytes
Starting address • • • • • • • • • • • •
Module number • • • • • • • • • • • • •
Buffer memory viewed
from the PLC CPU
(Address)
45
23
H
H
1
(H)
(L)
12
00
H
H
2
(L)
(H)
00
18
H
H
3
(H)
(L)
• • • •
%(6)=VAL("&H"+L$)
• • • •
%(7)=VAL("&H"+H$)
Specify
82
H
05
H
Buffer memory viewed
from the BASIC program
(Address)
82
45
(L)
H
H
H
83
23
(H)
H
H
84
12
(L)
H
H
H
85
00
(H)
H
H
86
18
(L)
H
H
H
87
00
(H)
H
H
PCRD TBL%( ), SD%( )
Buffer memory viewed
from the BASIC program
82
45
(L)
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
In case of a format 2 control table
Storage status
of data written
SD%(0)
23
(H)
45
H
SD%(1)
00
(H)
12
H
SD%(2)
00
(H)
18
H
Specify
82
H
05
H
Storage status
of data written
1st
2nd
3rd
character
character
character
SD $
45
23
12
H
H
H
MELSEC-Q
(L)
H
(L)
H
(L)
H
4th
5th
6th
character
character
character
00
18
00
H
H
H
11 - 308

Advertisement

Table of Contents
loading

This manual is also suitable for:

Ad51h-s3Qd51-r24A1sd51s

Table of Contents