Omron C60K Video Game Controller User Manual


 
!
93
As the SV for CNT 01 is 700, the completion flag for CNT 02 turns ON when
1 second x 700 times, or 10 minutes and 40 seconds have expired. This
would result in 0202 being turned ON.
CP
R
CNT 01
#0700
0000 1902
0001
CNT 01
0202
Address Instruction Operands
0000 LD 0000
0001 AND 1902
0002 LD NOT 0001
0003 CNT 01
# 0700
0004 LD CNT 01
0005 OUT 0202
Caution The shorter clock pulses may not produce accurate timers because their short
ON times may not be read accurately for longer cycle times. In particular the
0.02-second and 0.1-second clock pulses should not be used to create timers
with CNT.
5-11-5 REVERSIBLE COUNTER – CNTR(12)
N: TC number
# (00 through 47)
Ladder Symbol
Definer Values
SV: Set value (word, BCD)
IR, HR, #
Operand Data Areas
II
DI
CNTR(12)
N
SV
R
Each TC number can be used as the definer in only one timer or counter in-
struction.
The CNTR(12) is a reversible, up-down circular counter, i.e., it is used to
count between zero and SV according to changes in two execution condi-
tions, those in the increment input (II) and those in the decrement input (DI).
The present value (PV) will be incremented by one whenever CNTR(12) is
executed with an ON execution condition for II and the execution condition
was OFF for II for the last execution. The present value (PV) will be decre-
mented by one whenever CNTR(12) is executed with an ON execution condi-
tion for DI and the execution condition was OFF for DI for the last execution.
If OFF to ON changes have occurred in both II and DI since the last execu-
tion, the PV will not be changed.
If the execution conditions have not changed or has changed from ON to
OFF for both II and DI, the PV of CNT will not be changed.
When decremented from 0000, the present value is set to SV and the com-
pletion flag is turned ON until the PV is decremented again. When incre-
mented past the SV, the PV is set to 0000 and the completion flag is turned
ON until the PV is incremented again.
Limitations
Description
Timer and Counter Instructions Section 5-11