Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/Duet3D/RepRapFirmware.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDavid Crocker <dcrocker@eschertech.com>2020-12-27 13:23:37 +0300
committerDavid Crocker <dcrocker@eschertech.com>2020-12-27 13:23:37 +0300
commita91af1ab9b32cf28ae9dde7b8b997ff397023c25 (patch)
tree7959f9e02596e56a0f4bfff8b4d34a9acd0d52a8 /src/Heating
parent1db24819be24f5c1bbc2c80f1d516cc39a051bc6 (diff)
parentc99c5be037e504775b2531c99be5c78d33f0205d (diff)
Merge branch 'v3.02-dev' into 3.3-dev
Diffstat (limited to 'src/Heating')
-rw-r--r--src/Heating/Sensors/Thermistor.cpp4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/Heating/Sensors/Thermistor.cpp b/src/Heating/Sensors/Thermistor.cpp
index 4fa8e1e0..873e4325 100644
--- a/src/Heating/Sensors/Thermistor.cpp
+++ b/src/Heating/Sensors/Thermistor.cpp
@@ -324,7 +324,9 @@ void Thermistor::Poll() noexcept
const float recipT = shA + shB * logResistance + shC * logResistance * logResistance * logResistance;
const float temp = (recipT > 0.0) ? (1.0/recipT) + ABS_ZERO : BadErrorTemperature;
- if (temp < MinimumConnectedTemperature)
+ // It's hard to distinguish between an open circuit and a cold high-resistance thermistor.
+ // So we treat a temperature below -5C as an open circuit, unless we are using a low-resistance thermistor. The E3D thermistor has a resistance of about 470k @ -5C.
+ if (temp < MinimumConnectedTemperature && resistance > seriesR * 100)
{
// Assume thermistor is disconnected
SetResult(ABS_ZERO, TemperatureError::openCircuit);