One shot rising ONS

Passes power for one scan when the rung turns on.

TagAfter two scans
Run1

How it works

Passes power for one scan when the rung goes from false to true, then blocks it while the rung stays true.

How the edge is caught

ONS keeps the rung's state from the last scan. It passes power only when the rung is on now and was off last scan.

Run turns on at scan 3 and off at scan 7. ONS is on only in scan 3, the first scan where Run is on and Last scan is off.12345678ScanRunLast scanONSOSFRisingFalling
ScanRunLast scanONSOSF
1OffOffOffOff
2OffOffOffOff
3OnOffOnOff
4OnOnOffOff
5OnOnOffOff
6OnOnOffOff
7OffOnOffOn
8OffOffOffOff

OSF uses the same Last scan, but passes on the scan where the rung turns off.

How it's used

Use ONS when a held input must act once: add one, load a value, send a message.

TagValue
AddPB1
Count1

AddPB was held for three scans. Count went up by 1.

Operands

None. It works on the rung itself.

Common mistakes

  • Holding the input on to get more pulsesThe rung must go false before another rising edge can pass.

Learn it in a lesson

Related