Skip to content
Ladder (NT)Runs without an account · Updated

Fan run-on ladder logic with a TOF off-delay timer

A heater that has just switched off is still hot, so the fan that cools it has to keep going for a while. An off-delay timer does that. Its output turns on with its input and stays on for a set time after the input turns off.

Run it
The fan run-on example running in PLCflow Sim. The heater is off, the fan is still on, and the off-delay timer is counting towards 10000 ms.
Fan run-on, running in the PLCflow Sim workspace.

The program

XIC(Heater)TOF(RunOnTimer,10000,0);
XIC(RunOnTimer.DN)OTE(Fan);

How it works

Rung 0 is the timer. TOF(RunOnTimer,10000,0) has a preset of 10000 ms. While Heater is on, the timer's DN bit is on and ACC sits at 0. Nothing is being timed yet.

Rung 1 runs the fan from DN, so the fan starts with the heater.

Turn Heater off and the timing starts. DN stays on, TT turns on to show the timer is timing, and ACC counts up in milliseconds. When ACC reaches 10000, DN turns off and the fan stops.

If the heater comes back on during the run-on, ACC goes back to 0 and DN stays on. The fan never stopped, and the next time the heater turns off the full 10 seconds start again.

A TOF is the reverse of the TON in the conveyor example. A TON makes its output wait before turning on. A TOF makes it wait before turning off.

At start-up the timer begins with ACC at the preset and DN off, so the fan doesn't run until the heater has been on once.

Try this

In the simulator, an input changes when you click it in the tag list: click once to turn it on and again to turn it off. To press a button, turn it on; to release it, turn it off; to pulse it, do both.

  1. Turn Heater on. Fan turns on at once and RunOnTimer.ACC stays at 0.
  2. Turn Heater off and watch ACC climb to 10000. Fan turns off when it gets there.
  3. Turn Heater on, off, and on again within a few seconds. The fan never stops.
  4. Change the preset to 3000 and run it again.
Run it

Tags

TAGROLE
HeaterBOOL input. On while the heater is running.
RunOnTimerTIMER. Off-delay, preset 10000 ms.
FanBOOL output. On with the heater, and for 10 seconds after.

More examples

Conveyor with dwell

Ladder (NT)

The belt runs, a 5-second timer gives it time to get up to speed, and only then does the ready lamp light. Watch the accumulator climb.

RunRequestDwellTimer.ACCReadyLamp

Bottle counter

Ladder (NT)

A photo-eye counts bottles into a case of six. Pulse the sensor and watch the count climb, then reset it for the next case.

BottleSensorBottleCount.ACCCaseFull

Read more about the ladder logic simulator, or see all examples.