Reversible Counter - Cntr(12) - Omron SYSMAC C20P Operation Manual

Sysmac programmable controllers
Hide thumbs Also See for SYSMAC C20P:
Table of Contents

Advertisement

Timer and Counter Instructions
5–11–5 Reversible Counter – CNTR(12)
Limitations
Description
0000 TIM 01
CNT 02
TIM 01
0001
CNT 00
In the following example, CNT 01 counts the number of times the 1-second
clock pulse bit (1902) goes from OFF to ON. Here again, 0000 is used to
control when CNT is operating.
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.
0000
1902
0001
CNT 01
Note
The shorter clock pulses may not produce accurate timers because their
short ON times may not be read accurately for longer scan times. In particu-
lar the 0.02-second and 0.1-second clock pulses should not be used to cre-
ate timers with CNT.
Ladder Symbol
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
II
CNTR(12)
N
DI
SV
R
Section 5–11
TIM
5.0 s
0100
CP
CNT 02
#0100
R
0200
CP
CNT 01
#0700
R
0202
Definer Values
N: TC number
# (00 through 47)
Operand Data Areas
SV: Set value (word, BCD)
IR, HR, #
67

Hide quick links:

Advertisement

Table of Contents
loading

This manual is also suitable for:

Sysmac c28pSysmac c40pSysmac c60p

Table of Contents