Down Counter; Up/Down Counter - Siemens SIMATIC S7-200 System Manual

Hide thumbs Also See for SIMATIC S7-200:
Table of Contents

Advertisement

IEC 1131-3 Instructions

Down Counter

L
A
D
CD
F
LD
B
PV
D
221
222 224
Note
Since there is one current value for each counter, do not assign the same number
to more than one counter. (Up Counters, Down Counters, and Up/Down Counters
access the same current value.)
Inputs/Outputs
CD, LD (LAD)
Power Flow
CD, LD (FBD)
I, Q, M, SM, V, S, L, T, C, Power Flow
PV (LAD, FBD)
VW, IW, QW, MW, SMW, LW, SW, AIW, AC, Constant, *VD, *AC,
*LD
Q (LAD & FBD)
I, Q, M, SM, V, S, L
CV (LAD & FBD)
VW, IW, QW, MW, SW, LW, AC, *VD, *AC, *LD
Cxxx
Constant

Up/Down Counter

L
A
D
CD
CU
F
R
B
D
LD
PV
221
222
10-16
The Down Counter function block counts down from the
Cxxx
preset value (PV) on the rising edges of the Count Down
CTD
(CD) input. When the current value (CV) is equal to zero,
the counter output bit (Q) turns on. The counter resets
and loads the current value (CV) with the preset value
Q
(PV) when the load input (LD) is enabled. The Down
CV
Counter stops counting when it reaches zero.
226
Operands
The Up/Down Counter function block counts up or down
Cxxx
from the preset value on the rising edges of the Count Up
CTUD
(CU) or Count Down (CD) input. When the current value
(CV) is equal to preset, the output (QU) turns on. When
the current value (CV) is equal to zero, the output (QD)
turns on. The counter loads the current value (CV) with
QU
the preset value (PV) when the load (LD) input is
QD
enabled. Similarly, the counter resets and loads the
CV
current value (CV) with zero when the reset (R) is
enabled. The counter stops counting when it reaches
preset or zero.
224
226
S7-200 Programmable Controller System Manual
Data Types
BOOL
BOOL
INT
BOOL
INT
CTD
A5E00066097-02

Hide quick links:

Advertisement

Table of Contents
loading

Table of Contents