aboutsummaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authorBen V. Brown <[email protected]>2024-12-07 14:22:19 +1100
committerBen V. Brown <[email protected]>2024-12-09 21:40:17 +1100
commitc90d3126fa26b4065bad90347a3b9071129d5ace (patch)
tree02d347e17e3ab71548f6bf382db61e6ce60ecdd6
parent2f32721438a5b2471f0950edea77304a8b66e295 (diff)
downloadIronOS-issue-1946-thermal-runaway-update.tar.gz
IronOS-issue-1946-thermal-runaway-update.zip
-rw-r--r--source/Core/Threads/PIDThread.cpp5
1 files changed, 5 insertions, 0 deletions
diff --git a/source/Core/Threads/PIDThread.cpp b/source/Core/Threads/PIDThread.cpp
index b928692c..c7b27118 100644
--- a/source/Core/Threads/PIDThread.cpp
+++ b/source/Core/Threads/PIDThread.cpp
@@ -248,6 +248,11 @@ void detectThermalRunaway(const TemperatureType_t currentTipTempInC, const uint3
static bool haveSeenDelta = false;
+ // Check for readings being pegged at the top of the ADC while the heater is off
+ if (!thisCycleIsHeating && (getTipRawTemp(0) > (0x7FFF - 16))) {
+ heaterThermalRunaway = true;
+ }
+
if (haveSeenDelta) {
return;
}