Hysteresis
Part of the Analog and Sequences section of Coddy's PLC Programming journey. Lesson 2 of 17.
Now the factory draws liquid from the tank all the time, 2 % a second, and the tank must refill itself. A first try: fill while the level is below High.
It works, badly. At 80 % Fill turns off, the level drops a hair, High goes FALSE and Fill turns on again. The valve clicks on and off every few scans. That is called chatter, and it wears out valves and contactors fast.
The fix is hysteresis: two switch points. Turn Fill on when the level falls below Low, turn it off at High, and in between keep doing whatever it was doing. A seal-in remembers that:
Below Low, the normally closed Low contact turns Fill on. The Fill contact holds it on while the level rises past Low, and High breaks it. Then Fill stays off until the level is down at Low again.
Challenge
MediumThe factory draws 2 % a second and the tank starts half full. Keep the level between Low and High:
- turn
Fillon when the level drops belowLow - keep it on until
High, then off until the level is below Low again
Try it yourself
{"v":1,"lang":"ld","tags":[],"rungs":[{"els":[]}]}All lessons in Analog and Sequences
1Analog Inputs
Fill to HighHysteresisRaw Analog ValuesScaling to PercentA High Level AlarmA ThermostatPractice on your own: PLC playground