How to Program Timers

How to Program Timers

 Skills you’ll gain: The basics, features, and programming environment of our MapleLogic PLC programming software.

Software Required

Hardware Required

What is a Timer?

PLC Timers are internal PLC instructions that can be used to delay input and output signals in the PLC program. They measure the amount of time elapsed following an event. There are four main types of PLC timers: an on-delay timer, off-delay timer and a retentive on and off delay timer.

Maple Logic has five kinds of timers.

TON (Timer On Delay – Up Counter)

A TON instruction counts the preset value (t) and when the accumulated value reaches the preset value (t), The timer device (S) will be set.

If X0.0 is ON, the TON instruction counts up to 5sec (5000ms), and when it reaches 5sec (5000ms), T1.0 and Y0.1 turn ON.

If X0.1 is ON the TON instruction is disabled (reset) and T1.0 (accumulated value) is cleared.

TOFF (Timer Off Delay – Down Counter)

A TOFF instruction decrements the preset value (t) and the accumulated value reaches 0 seconds, the timer device (S) will be turned OFF.

If X0.2 is ON, T2.0 and Y0.2 turn ON.

When X0.2 is OFF, the TOFF decrements the preset value from 5sec(5000ms) to 0 sec and when it reaches 0sec, T2.0 and Y0.2 turn OFF.

When X0.3 is ON and X0.2 is OFF and the accumulated value is counting down, T2.0 (accumulated value) will reset to 0 and turn OFF.

TMR (Retentive ON Timer – Up Counter)

A TMR instruction counts the preset value (t) and when the accumulated value reaches the preset value (t), the timer device (S) will turn ON.

When X0.4 is ON, the TMR instruction counts up to 10sec (10000ms). When it reaches 10sec (10000ms), T3.0 and Y0.3 turn ON.

Even if X0.4 is disabled, the TMR instruction retains its accumulated value.

When X0.4 is enabled again, it will continue the count.

If X0.5 is ON, the accumulated value is cleared.

TMON (Retentive Off Timer – Down Counter)

A TMON instruction counts downward from the preset value (t) and the accumulated value reaches 0, the timer device (S) will turn OFF.

If X0.6 is ON, T4.0 and Y0.4 are turned ON and the TMON instruction decrements the preset value from 5sec (5000ms) to 0sec. When it reaches 0 sec, T4.0 and Y0.4 turn OFF.

Even if X0.6 is disabled, the TMON instruction counts downward to 0.

If X0.7 is ON, T4.0 resets to 0.

TRTG (Non Retentive Off Timer – Down Counter)

A TRTG instruction counts downward from the preset value (t) and the accumulated value reaches the preset value (t) the timer device (S) will turn OFF.

If X0.8 is ON, T5.0 and Y0.5 turn ON and the TRTG instruction decrements the preset value from 5sec (5000ms) to 0sec.

When it reaches 0sec, T5.0 and Y0.5 turn OFF.

Even if X0.8 is disabled (OFF), the TRTG instruction keeps decrementing the preset value.

When X0.8 is ON again, the TRTG instruction counts downward from 5sec (5000ms) again.

If X0.9 is ON, T5.0 resets to 0.

Sample Project

The project shown above was designed for the specific hardware mentioned at the beginning of the tutorial and is intended to provide you guidance when programming your unit. If you are using models other than the ones specified in this sample project, similar steps can be duplicated within your own project.

Download MapleLogic Sample Project

Resources & Documentation

Maple PLC/MapleLogic Resources

More Tutorials Sample Projects

See our Support Center for a complete list of Quick Start and Installation Guides

Scroll to Top