Siemens Simatic S7 Series Manual page 60

Hide thumbs Also See for Simatic S7 Series:
Table of Contents

Advertisement

Count Up/Down Counter..
(CTUD) Example .
The.Count Up/Down Counter (CTUD).counts.up.by.one.each.
time.the.count.up.(CU).input.transitions.from.off.to.on.and.
counts.down.by.one.each.time.the.count.down.(CD).input.
transitions.from.off.to.on..When.the.accumulated.count.equals.
the.preset.value.(PV),.the.counter.bit.turns.on..When.the.reset.
input.(R).turns.on.or.when.a.Reset.instruction.is.executed,.the.
accumulated.count.resets.to.zero.and.the.counter.bit.turns.off.
If.the.count.reaches.the.maximum.positive.value.(32,767),.
the.next.count.up.input.sets.the.accumulated.count.to.the.
maximum.negative.value.(-32,767)..Similarly,.if.the.count.
reaches.the.maximum.negative.value,.the.next.down.count.
sets.the.accumulated.count.to.the.maximum.positive.value.
Counters.are.common.instructions.used.for.counting.a.wide
variety.of.events.such.as.parts.manufactured.or.packed,.items.
processed,.machine.operations,.etc..For.example,.a.counter.
might.be.used.to.keep.track.of.the.items.in.an.inventory.
storage.area.
In.the.following.example,.Count.Up/down.Counter.(CTUD).C48.
is.reset.to.zero.when.contact.I0.2.closes..This.could.be.event.
could.be.triggered.automatically.or.manually.to.indicate.that.the.
associated.storage.location.is.empty.
When.contact.I0.0.closes,.the.counter.counts.up.by...This.
could.be.triggered.by.a.proximity.switch.sensing.that.an.item.
has.been.placed.in.the.storage.location.
When.contact.I0..closes,.the.counter.counts.down.by...This.
could.be.triggered.by.a.proximity.switch.sensing.that.an.item.
has.been.removed.from.the.storage.location.
I0.0
I0.1
I0.2
C48
59
C48
CU
CTUD
CD
R
+150
PV
Q0.1

Hide quick links:

Advertisement

Table of Contents
loading

Table of Contents