I'm trying to make a thermostat and would like to include a thermal runaway protection in my code in case a thermistor fails or detaches. I also intend to use bimetalic switches as a safety net but I would like to have redundancy. I tried to find how others have solved the problem without using another thermistor and came up empty handed (there's Marlin firmware for 3D printers but I don't know where to look for the relevant code). I am thinking I should maybe:
- store the last, say, four temperatures recorded (once every five seconds) in an array
- store the last four MOSFET control states (i.e. heater on or off) in an array
- if the MOSFET has been on for the last four cycles and the recorded temperature is not sufficiently higher than the temperature three cycles ago, release the dogs/set the MOSFET control pins to 0.
Is that what you would do?
The expected currents (2 A) will never get anywhere near the limit of the MOSFETs (30 A) and I will use resettable fuses.
I don't know the likelihood of a MOSFET failing closed but I think could detect it by measuring the voltage across the drain and source (with a potential divider) and if it's low when the MOSFET is meant to be off, then I know it's failed open? Then I can display a message asking the user to manually intervene at their earliest possible convenience. The only thing I can think of is to have a second MOSFET in series with the first that's held permanently closed unless the first one fails closed in which case the second one opens?