1
0
mirror of https://github.com/MarlinFirmware/Marlin.git synced 2024-11-27 05:48:43 +00:00

Fix stepper shutdown during waiting for temperatures

In the wait loops of M109 M190 idle() is called, what checks
stepper_inactive_time against previous_cmd_ms.
Because we can be several minutes inside the loop, resetting
previous_cmd_ms only outside the loop caused stepper shutdowns.

The name of previous_cmd_ms does not really reflect its use. It's set
not only when a new command was received or executed but also in many of
the movement routines. For that the little extension of using it during
the wait will (hopefully) not hurt.

# Conflicts:
#	Marlin/Configuration_adv.h
This commit is contained in:
AnHardt 2015-10-08 21:23:18 +02:00
parent b6e69e71ce
commit 32ae9f9ab7

View File

@ -3975,6 +3975,7 @@ inline void gcode_M109() {
}
idle();
refresh_cmd_timeout(); // to prevent stepper_inactive_time from running out
#ifdef TEMP_RESIDENCY_TIME
// start/restart the TEMP_RESIDENCY_TIME timer whenever we reach target temp for the first time
@ -3989,7 +3990,6 @@ inline void gcode_M109() {
}
LCD_MESSAGEPGM(MSG_HEATING_COMPLETE);
refresh_cmd_timeout();
print_job_start_ms = previous_cmd_ms;
}
@ -4024,9 +4024,9 @@ inline void gcode_M109() {
#endif
}
idle();
refresh_cmd_timeout(); // to prevent stepper_inactive_time from running out
}
LCD_MESSAGEPGM(MSG_BED_DONE);
refresh_cmd_timeout();
}
#endif // HAS_TEMP_BED