0% found this document useful (0 votes)
2 views41 pages

Timer and Counter Notes

The document describes the functionality and parameters of On-delay timers and counters in PLC programming, including timer file names, preset values, and accumulator values. It outlines the operation of timers and counters through ladder logic with specific rung descriptions and timing diagrams. Additionally, it explains the behavior of done bits, overflow, and underflow conditions for both timer and counter operations.

Uploaded by

dynamiclashersop
Copyright
© All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
2 views41 pages

Timer and Counter Notes

The document describes the functionality and parameters of On-delay timers and counters in PLC programming, including timer file names, preset values, and accumulator values. It outlines the operation of timers and counters through ladder logic with specific rung descriptions and timing diagrams. Additionally, it explains the behavior of done bits, overflow, and underflow conditions for both timer and counter operations.

Uploaded by

dynamiclashersop
Copyright
© All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd

In the above On-delay timer instruction, there are totally

four parameter,
TIMER: T4:0 – Timer File name (Timer T4:0, T4:1, T4:2…)
TIMER BASE – How the time need to count, in Seconds,
Milli Seconds…
PRESET – Limit value of Timer-Up to how much it should
count
ACCUMULATOR – Running Value of the timer when it is in
ON condition.
Program Description
ON delay timer purpose is to delaying the ON time,
Example : After the turning ON of main switch, Air Conditioner takes nearly 5s to
15s to turn ON.
RUNG 0000
Start and Stop Switch is to turn ON/OFF the timer.

RUNG 0001
When start switch is pressed, Timer Enable bit (T4:0/EN) is turned
ON to show the status of TIMER ON/OFF condition

RUNG 0002
When start switch is pressed, along with the timer enable bit timer
timing bit also turned ON to show the status of timer’s accumulator
(T4:0/ACC)value is currently in running state.

RUNG 0003
When start switch is pressed, timer starts running from zero to
preset valve, timer’s done bit is turned ON when accumulator value
reached preset value.
Timing Diagram
COUNTER C5

In the above picture, there are totally three parameter,


COUNTER: C5:0 – Counter File name (counter C5:0, C5:1,
C5:2…)
PRESET –PRE: Limit value of COUNT-Up to how much it
should count
ACCUMULATOR –ACC: Running Value of counter when
condition turn ON.
From the data file, along with
preset and accumulator, we have
few more bits,

CU: Count up Bit-whenever the


counter is enable makes this bit to
go ON.

DN: Done Bit-When accumulator


value reached preset value, done
bit turns to ON.

OV: Over Flow Bit-When


accumulator value reached the
UA-Update Accumulator Value- limit value (32767),it rolls back to -
Only used when high speed 32767 for the upcoming counter
counters are used in the program. operation, Overflow bit turns ON,
CD & UN-Used for down Counter in this condition.
Function.
Rung 000 – Having condition input I:0/0 which gives input to counter to perform
counter function.
Rung 0001 – Having Counter CU Bit which enable only when counter is in function or
When input to the counter turns ON.
Counter Done Bit (C5:0/DN)

When accumulator value reaches the Preset, Counter


Done bit (CU5:0/DN) turns ON.
Done bits remains in the ON condition, even though
accumulator value runs beyond Preset.
Counter OverFlow Bit (C5:0/OV)
accumulator value overflows when accumulator value reaches 32767 in Allen
Bradley PLC Programming.
When we turn ON the I:0/0 for the 32768 time, accumulator value rolls back
to -32768 and start counting from -32767 to [Link] Overflow bit
turns ON when this condition happen (Rung 003).
Timing Diagram for Up Counter:-
COUNTER: C5:0 – Counter File name (TimerC5:0,
C5:1,C5:2…)

PRESET – PRE : Limit value of COUNT-Up to how


much it should count

ACCUMULATOR – ACC : Running Value of counter


when condition turn ON.
CD: Countdown Bit-whenever the counter is
enable makes this bit to go ON.

DN: Done Bit-When accumulator value equals


preset value, done bit turns to ON.

UN: Counter Underflow – When accumulator


value reached the limit value (-32767),it rolls
back to +32767 for the upcoming counter
operation, underflow bit turns ON, in this
condition.
UA – Update Accumulator Value-Only used when
high speed counters are used in the program.

CU & OV – Used for Up Counter Function.


Rung 0000
Having condition input I:0/0 which gives input to counter to perform counter down
function.

Rung 0001
Having Counter CD Bit which enable only when counter is in function or when input
to the counter turns ON and accumulator value counted down.

Rung 0002
Counter done bit turns on when accumulator value equals preset value.
Counter Count Down Bit (C5:0/CD):
In the below Ladder logic,
Rung 0000
Having condition input I:0/0 which gives input to counter to perform counter function.
Rung 0001
Having Counter CD Bit which enable only when counter is in function or when input to
the counter turns ON and accumulator value counted down.
Rung 0000
Having condition input I:0/0 which gives input to counter to perform counter
function. Accumulator value goes to negative if I:0/0 goes ON for 6th time in
the below case,
Counter Under Flow Bit (C5:0/UN):
In the Below Ladder Logic,
Counter accumulator value under flows when accumulator value reaches -32767 in
Allen Bradley PLC Programming.
In the below ladder Logic,
When we turn ON the I:0/0 ,accumulator value rolls back to 32768 and start counting
down from 32767 to -[Link] underflow bit turns ON when this condition happen
(Rung 003).
Timing Diagram for Down Counter:-

Preset =2
Accumulator = 6
Counter Elements

Word 0 CU CD DN OV UN UA Reserved
Word 1 PRESET VALUE
Word 2 ACCUMULATOR VALUE

You might also like