From ef68c1910c4597b55df7ac641a37485eb60f1b61 Mon Sep 17 00:00:00 2001 From: Scott Lahteine Date: Sat, 27 Feb 2016 22:26:44 -0800 Subject: [PATCH] Check that the temperature is close to target --- Marlin/Marlin_main.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/Marlin/Marlin_main.cpp b/Marlin/Marlin_main.cpp index bcedd19c9..9f49d3c5e 100644 --- a/Marlin/Marlin_main.cpp +++ b/Marlin/Marlin_main.cpp @@ -3960,8 +3960,8 @@ inline void gcode_M109() { // Loop until the temperature has stabilized #define TEMP_CONDITIONS (residency_start_ms < 0 || now < residency_start_ms + TEMP_RESIDENCY_TIME * 1000UL) #else - // Loop until the temperature is exactly on target - #define TEMP_CONDITIONS (degHotend(target_extruder) != degTargetHotend(target_extruder)) + // Loop until the temperature is very close target + #define TEMP_CONDITIONS (fabs(degHotend(target_extruder) - degTargetHotend(target_extruder)) < 0.75f) #endif //TEMP_RESIDENCY_TIME cancel_heatup = false; @@ -3984,7 +3984,7 @@ inline void gcode_M109() { } #else SERIAL_EOL; - #endif + #endif //TEMP_RESIDENCY_TIME } idle();