Lessons · Industrial control · silence is a fault
Silence is a fault
Raise the alarm on the ABSENCE of the healthy signal, so losing the sensor raises it rather than silencing it.
Hone is a place to practise programming. This is one of its lessons, written out in full and free to read without an account.
What it is for
An alarm a dead sensor cannot trigger is not an alarm. It is a light that happens to work while nothing is wrong.
How to think about it
Make the healthy state the one that needs a live signal, and keep needing it. It is the same idea as the normally closed stop, applied to information rather than power -- and the same reason network devices send heartbeats.
Worked example
[/Sensor] (Alarm)Sensor healthy on the first scan, then lost. Alarm: 0 1
Your turn
The alarm should be raised by the absence of the
signal
Run a rung and watch the scan
The trap
Latch the alarm so an intermittent fault still has to be seen -- and then make sure the reset is one that can actually run.