7-17
Section
Data Movement Instructions
417
During stack operation, the value of the stack 1 exceeds the
length of the stack.
EQ:
ON when the content of S is zero; otherwise OFF.
7-17-7
DATA COLLECT – COLL(81)
SBs
: Source base word
IR, SR, AR, DM, HR, TC, LR
C
: Control word (BCD)
IR, SR, AR, DM, HR, TC, LR, #
Ladder Symbols
Operand Data Areas
D
: Destination word
IR, SR, AR, DM, HR, TC, LR
COLL(81)
SBs
C
D
@COLL(81)
SBs
C
D
C must be BCD.
DM 6144 to DM 6655 cannot be used for D.
COLL(81) can be used for data collection, an FIFO stack operation, or an LIFO
stack operation depending on the content of the control word, C.
When bits 12 to 15 of C=0 to 7, COLL(81) is used for data collection. The entire
contents of C specifies an offset, Of (0000 to 2047 in BCD).
When the execution condition is OFF, COLL(81) is not executed. When the
execution condition is ON, COLL(81) copies the content of SBs + Of to D, i.e., Of
is added to SBs to determine the source word.
Note
1. SBs and SBs+Of must be in the same data area.
2. IR 000 to IR 019 or IR 000 to IR 049 is treated as a different memory area
from IR 200 to IR 255 for the source data area. The entire source data area
must be within one or the other of these areas. An error will occur if words
from both areas are included.
Example
The following example shows how to use COLL(81) to copy the content of
DM 0000+Of to LR 00. The content of 200 is #0005, so the content of DM 0005
(DM 0000 + 5) is copied to LR 00 when IR 00001 is ON.
@COLL(81)
DM 0000
200
LR 00
00001
Address
Instruction
Operands
00000
LD
00001
00001
@DIST(80)
DM
0000
200
LR
00
F
LR 00
0 0 F
0
DM 0000
0 0 0
F
DM 0005
0 0 F
5
200
0 0 0
FIFO Stack Operation
When bits 12 to 15 of C=9, COLL(81) can be used for an FIFO stack operation.
The other 3 digits of C specify the number of words in the stack (000 to 999, in
BCD). The content of SBs is the stack pointer.
Limitations
Description
Data Collection
Содержание SRM1 - PROGRAMING 02-2001
Страница 1: ...Programmable Controllers Cat No W353 E1 06 SYSMAC CPM1 CPM1A CPM2A CPM2C SRM1 V2 PROGRAMMING MANUAL ...
Страница 2: ...CPM1 CPM1A CPM2A CPM2C SRM1 V2 Programmable Controllers Programming Manual Revised February 2008 ...
Страница 3: ...iv ...
Страница 5: ...vi ...
Страница 9: ...x ...
Страница 15: ...xvi ...