power panic: refactor log output on recovery

Use M114 to print coordinates for all axis. We save
a lot of memory by reusing the M114 code

Change in memory:
Flash: -184 bytes
SRAM: 0 bytes
This commit is contained in:
Guðni Már Gilbert 2023-07-16 12:59:36 +00:00 committed by DRracer
parent 005f9f0d24
commit d5125c6b1e
1 changed files with 4 additions and 2 deletions

View File

@ -343,11 +343,13 @@ void recover_print(uint8_t automatic) {
enquecommandf_P(G1_E_F2700, default_retraction);
}
printf_P(_N("After waiting for temp:\nCurrent pos X_AXIS:%.3f\nCurrent pos Y_AXIS:%.3f\n"), current_position[X_AXIS], current_position[Y_AXIS]);
puts_P(_N("Temperature Restored\n"));
gcode_M114();
// Restart the print.
restore_print_from_eeprom(mbl_was_active);
printf_P(_N("Current pos Z_AXIS:%.3f\nCurrent pos E_AXIS:%.3f\n"), current_position[Z_AXIS], current_position[E_AXIS]);
puts_P(_N("Done reading EEPROM\n"));
gcode_M114();
}
bool recover_machine_state_after_power_panic() {