Series Programmable Controllers
Programming Manual - Basic & Applied Instruction Edition
Related devices (to specify counting direction) [32-bit counter]
When an auxiliary relay for switching the counting direction is set to ON, the counter executes down-counting,
and when set to OFF, the counter executes up-counting.
Functions and operation examples
1. General type and latched (battery backed) type 16-bit up counters
• The valid set range of 16-bit binary up counter is from K1 to K32767 (decimal constant).
K0 provides the same operation as K1, and the output contact turns on at the first counting.
• In general type counters, the counter value is cleared when the PLC turns off. In latch type counters,
however, the counter value just before power failure is stored (backed up by the battery); The counter
value in the subsequent operations can be added to the last counter value.
• Every time the coil C0 is driven by the counting input X011, the current value of the counter increases.
When a coil instruction is executed 10 times, the output contact turns on.
After that, the current value of the counter does not change even if the counting input X011 turns on after
When the RST input X010 turns ON and then RST instruction is executed, the current value of the counter
is reset to "0" and the output contact returns.
• The counter set value can be set by a constant (K) as shown above, or indirectly specified by a data
register number. For example, when D10 is specified and the contents of D10 are "123", it is equivalent to
• If data beyond the set value is written to the current value register by MOV instruction, etc., the OUT coil
turns ON and the current value register becomes the set value when the next counting input is received.
• For latched (battery backed) type counters, the current value, output contact operation and reset status are
backed up against power failure.
PLCs, latched type counters are backed up by the EEPROM built into the PLC.
Set value (constant)
It can be specified
PLCs, latched type counters are backed up by the battery built into the PLC.
→ For details on backup methods against power failure, refer to Section 2.6.
4 Devices in Detail
4.6 Counter [C]