LadderLogicOnline

Learn › Instructions

RTO: Retentive Timer On

An RTO times like a TON while its rung is true, but it doesn't forget when the rung goes false. Its accumulated time is kept until a RES instruction clears it, so it can add up time across many starts and stops.

How an RTO behaves

An RTO writes to a TIMER tag, with the usual PRE, ACC, EN, TT and DN members (see the TON lesson for what each one means).

Once DN is on, it stays on, even if the rung goes false, until you reset the timer. That's a big difference from a TON, where DN always drops out with the rung.

A timeline

An RTO named RunT with a 10.0 second preset, timing how long a pump has run. The pump runs in three bursts, and an operator presses Reset at the end.

TimeRung (Pump)ACCENTTDN
0 s (pump on)true0 s110
4 s (pump off)false4 s000
9 s (pump on)true4 s110
13 s (pump off)false8 s000
20 s (pump on)true8 s110
22 strue10 s101
25 s (pump off)false10 s001
30 s (Reset pressed)false0 s000

A TON on the same rung would never have finished: none of the three bursts lasted 10 seconds on its own. The RTO added them together and reached its preset 2 seconds into the third run.

A maintenance reminder

The textbook use for an RTO is tracking run time for maintenance. Here, a conveyor needs inspecting after a set amount of running. The RTO totals up run time, a lamp comes on when it's due, and a maintenance button resets it.

 |   Conveyor                                        |
 |----] [------------------------------[RTO  RunT  PRE 60.0s]--|
 |                                                  |
 |   RunT.DN                               Service   |
 |----] [------------------------------------( )----|
 |                                                  |
 |   ServiceDone                                     |
 |----] [------------------------------------(RES RunT)--|
Run time adds up across every start and stop. ServiceDone clears it after maintenance.

On a real machine the preset would be hundreds of hours, but a minute is easier to watch in a simulator. Everything else works the same way.

Other uses

Where to put the reset

The RES can go on its own rung, as above, or right after the condition that finishes the job. Two details matter:

See how the scan cycle works for why rung order decides these cases.

Try it in the Playground

  1. Open the Playground and add two push buttons: Pump and Reset.
  2. Build rung 0: XIC Pump then RTO RunT, preset 10.0 seconds.
  3. Build rung 1: XIC RunT.DN then OTE Due. Build rung 2: XIC Reset then RES RunT.
  4. Press Run. Hold Pump for a few seconds at a time and watch ACC pause between presses in the Tags panel. When it reaches 10.0 s, Due turns on and stays on. Press Reset to start again.
  5. Now type over the RTO to make it a TON (double-click it) and try the same presses. The time no longer adds up.

Key points