1
0
mirror of https://github.com/MarlinFirmware/Marlin.git synced 2024-11-29 23:07:42 +00:00

Fix fade value for power-loss recovery

Fix #10817

Co-Authored-By: cdedwards <cd.edwards@sasktel.net>
This commit is contained in:
Scott Lahteine 2018-05-22 21:42:58 -05:00
parent 76019c83b5
commit 773a550472

View File

@ -127,13 +127,15 @@ void do_print_job_recovery() {
#endif #endif
)); ));
char str_1[16], str_2[16];
#if HAS_LEVELING #if HAS_LEVELING
// Restore leveling state before G92 sets Z // Restore leveling state before G92 sets Z
// This ensures the steppers correspond to the native Z // This ensures the steppers correspond to the native Z
sprintf_P(job_recovery_commands[ind++], PSTR("M420 S%i Z%s"), int(job_recovery_info.leveling), job_recovery_info.fade); dtostrf(job_recovery_info.fade, 1, 1, str_1);
sprintf_P(job_recovery_commands[ind++], PSTR("M420 S%i Z%s"), int(job_recovery_info.leveling), str_1);
#endif #endif
char str_1[16], str_2[16];
dtostrf(job_recovery_info.current_position[Z_AXIS] + 2, 1, 3, str_1); dtostrf(job_recovery_info.current_position[Z_AXIS] + 2, 1, 3, str_1);
dtostrf(job_recovery_info.current_position[E_AXIS] dtostrf(job_recovery_info.current_position[E_AXIS]
#if ENABLED(SAVE_EACH_CMD_MODE) #if ENABLED(SAVE_EACH_CMD_MODE)