Omron SYSMAC CS/CJ Series Programming Manual page 275

Table of Contents

Advertisement

Index Registers
,IR2
,IR1+
ON
The FOR-NEXT loop starts timers T0000 through T0099 by repeating
the loop 100 times while incrementing the contents of IR0 (timer number/
PV address), IR1 (Completion Flag address), IR2 (Work bit address),
and D00000 (SV address).
254
The 11-instruction subroutine on the left is equivalent to the 200-instruction
subroutine on the right.
Puts the PLC memory
MOVRW
address of T0000's
T0000
PV in IR0.
IR0
MO
VR
Puts the PLC memory
address of T0000's
T0000
Completion Flag in IR1.
IR1
Puts the PLC memory
MO
VR
address of W00000
W00000
in IR2.
IR2
MO
V
Writes &100 in D00000.
&100
D00000
Jumps the FOR-NEXT
JMP
loop if the pointers above
&1
haven't been set.
Repeats the FOR-NEXT
FOR
loop 100 times.
&100
If the Work bit addressed in
TIM
IR2 is OFF, TIM starts the tim-
er with the timer PV ad
,IR
O+
dressed in IR0+ and the SV
@D00000
addressed in D00000.
If the Completion Flag addressed in
IR1 is ON, OUT turns ON the Work
,IR2+
bit addressed in IR2.
++
Increments the content of D00000.
(The next address containing an SV.)
D00000
NEXT
JME
&1
Section 6-2
W000
00
T0000
W000
01
T0001
W000
W006
03
T0099
TIM
0000
D00100
W000
00
TIM
0001
D00101
01
TIM
0099
D00109
W006
03

Advertisement

Table of Contents
loading

Table of Contents