Browse Source

Fix probe fan compiling error (#13930)

Ludy 6 years ago
parent
commit
a504366138

+ 1
- 1
Marlin/src/gcode/control/M80_M81.cpp View File

@@ -97,7 +97,7 @@ void GcodeSuite::M81() {
97 97
     thermalManager.zero_fan_speeds();
98 98
     #if ENABLED(PROBING_FANS_OFF)
99 99
       thermalManager.fans_paused = false;
100
-      ZERO(thermalManager.paused_fan_speed);
100
+      ZERO(thermalManager.saved_fan_speed);
101 101
     #endif
102 102
   #endif
103 103
 

+ 2
- 2
Marlin/src/module/temperature.cpp View File

@@ -138,8 +138,9 @@ hotend_info_t Temperature::temp_hotend[HOTENDS]; // = { 0 }
138 138
 
139 139
   #endif
140 140
 
141
-  #if ENABLED(PROBING_FANS_OFF)
141
+  #if EITHER(PROBING_FANS_OFF, ADVANCED_PAUSE_FANS_PAUSE)
142 142
     bool Temperature::fans_paused; // = false;
143
+    uint8_t Temperature::saved_fan_speed[FAN_COUNT]; // = { 0 }
143 144
   #endif
144 145
 
145 146
   #if ENABLED(ADAPTIVE_FAN_SLOWING)
@@ -181,7 +182,6 @@ hotend_info_t Temperature::temp_hotend[HOTENDS]; // = { 0 }
181 182
   #if EITHER(PROBING_FANS_OFF, ADVANCED_PAUSE_FANS_PAUSE)
182 183
 
183 184
     void Temperature::set_fans_paused(const bool p) {
184
-      static uint8_t saved_fan_speed[FAN_COUNT]; // = { 0 }
185 185
       if (p != fans_paused) {
186 186
         fans_paused = p;
187 187
         if (p)

+ 2
- 1
Marlin/src/module/temperature.h View File

@@ -459,8 +459,9 @@ class Temperature {
459 459
 
460 460
       static void set_fan_speed(const uint8_t target, const uint16_t speed);
461 461
 
462
-      #if ENABLED(PROBING_FANS_OFF)
462
+      #if EITHER(PROBING_FANS_OFF, ADVANCED_PAUSE_FANS_PAUSE)
463 463
         static bool fans_paused;
464
+        static uint8_t saved_fan_speed[FAN_COUNT];
464 465
       #endif
465 466
 
466 467
       static constexpr inline uint8_t fanPercent(const uint8_t speed) { return ui8_to_percent(speed); }

Loading…
Cancel
Save