Back to FBD reference

Counters

CTD

Count-down counter

The CTD block decrements an internal counter on rising edges of CD. In the current implementation, R returns the counter to PV.

Typical FBD symbol

CD
R
CTD
Q
Typical FBD symbol for CTD

Inputs

NameTypeRequiredDescription
CDBOOLYesCount-down input. Rising edges are counted.
RBOOLYesReset that returns the counter to PV.

Outputs

NameTypeRequiredDescription
QBOOLYesTRUE when count has reached 0 or below.

Parameters

NameTypeRequiredDefaultDescription
PVnumberNo1Starting count value.

Stateful

Yes, the block keeps internal state between scans.

Behavior rule

Counts CD edges down from PV to 0; when R = TRUE returns the counter to PV; Q = TRUE when count reaches 0 or below.

Practical use

  • counting down remaining parts or operations.

What to watch

  • Confusing reset with zeroing: in the current logic, R returns CTD to PV.

Related blocks