730 likes | 2.62k Views
Chapter 6 Programming PLC Timers and Counters.
E N D
Chapter 6Programming PLC Timers and Counters Timer and Counter Instructions • Timer Instructions • Timer Instruction Words • Timer On-Delay (TON) Instructions • Timer Off-Delay (TOF) Instructions • Retentive Timer (RTO) Instructions • Reset (RES) Instructions • Special Applications • Counter Instructions • Counter Instruction Words • Count Up (CTU) Instructions • Count Down (CTD) Instructions
PLCs provide a cost-effective alternative to using individual hardwired timers and counters because the smallest PLCs (nanos and micros) already contain 10 or more timers and counters.
Timer instructions contain three words, with word “0” containing three bits that can be used in the program of a PLC.
Timers following on-delay (TON) instructions begin timing when the logic preceding the instruction on a rung changes from false to true.
A PLC with a programmed timer using timer on-delay (TON) instructions can be used to replace hardwired on-delay timers.
Timers following off-delay (TOF) instructions start timing when the logic preceding the instruction on a rung changes from true to false.
Off-delay timers are used in applications that require a load to remain energized after the input has been removed.
Retentive timers begin timing when the logic preceding the instruction on a rung changes from false to true. Retentive timers retain their accumulated value until reset.
Free running timers are continuously timing because the XIO instruction preceding the timer is always true.
Timers are cascaded by having the DN bit of timer #0 activate timer #1. The only limit to the number of cascaded timers is the size of the memory in the PLC.
Cascaded timers are used to start equipment sequentially, such as when starting three conveyors with a 10 sec delay between the start of each conveyor.
Counter instructions contain three words. The bits and words of counter instructions have addresses that can be used in the program of a PLC.
Count up (CTU) instructions increase the accumulated value incrementally on each false to true transition of the logic preceding the instruction.
Counters are used in applications that require items or products to be counted.
A CTD instruction counts down on every false to true transition of the logic preceding the instruction and shares the same status bits, preset values, and accumulated values as the corresponding CTU instruction.
CTU and CTD instructions can be used to keep track of the cars entering and exiting a parking lot.