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>2022-08-08 20:47:05 +0300
committerDavid Crocker <dcrocker@eschertech.com>2022-08-08 20:47:05 +0300
commita7f56bebed7bdbc78cf227ef979853b5f18f6a19 (patch)
treebc545805f2cb6f44ab8e13f29152e046e050d1f8
parent79634870bc6a6050fef5b1a88435ab783ac3ac0b (diff)
Thermostatic fans now default to on if the sensor is not found
-rw-r--r--src/Fans/LocalFan.cpp6
1 files changed, 5 insertions, 1 deletions
diff --git a/src/Fans/LocalFan.cpp b/src/Fans/LocalFan.cpp
index c8205b21..691fc78d 100644
--- a/src/Fans/LocalFan.cpp
+++ b/src/Fans/LocalFan.cpp
@@ -87,7 +87,11 @@ void LocalFan::InternalRefresh(bool checkSensors) noexcept
([&reqVal, bangBangMode, this](unsigned int sensorNum, unsigned int) noexcept
{
const auto sensor = reprap.GetHeat().FindSensor(sensorNum);
- if (sensor.IsNotNull())
+ if (sensor.IsNull())
+ {
+ reqVal = maxVal; // sensor not found, so turn the fan fully on
+ }
+ else
{
//TODO we used to turn the fan on if the associated heater was being tuned
float ht;