3. Instructions
Sample program
When CIO 0.00 is ON in the following example, SWRIT(640) writes the data in D100 to the specified
word in the stack starting at D0. In this case, the stack pointer indicates D7 and the offset value is 3, so
the data in D4 is overwritten. SWRIT(640) does not change the pointer.
0.00
SWRIT
D0
&3
D100
Stack
pointer
Last word
in stack
Stack
pointer
Last word
in stack
562
D0
PLC memory address of
last word in the stack
D1
D2
Stack pointer
D3
D4
B
D5
3
D6
D7
D8
D9
D0
PLC memory address of
last word in the stack
D1
D2
Stack pointer
D3
D4
A
D5
D6
D7
D8
D9
PLC memory
address
(Overwrite)
D100
The stack pointer position remains
unchanged after the data is written.
CS/CJ/NSJ Series Instructions Reference Manual (W474)
A
Need help?
Do you have a question about the CJ - INSTRUCTIONS REFERENCE MANUAL 07-2009 and is the answer not in the manual?
Questions and answers