Set LCD status for EEPROM errors (#16977)

This commit is contained in:
InsanityAutomation
2020-02-26 04:04:02 -05:00
committed by GitHub
parent e78f607ef3
commit cdcd45d651
5 changed files with 30 additions and 16 deletions

View File

@ -1397,6 +1397,9 @@ void MarlinSettings::postprocess() {
}
DEBUG_ECHO_START();
DEBUG_ECHOLNPAIR("EEPROM version mismatch (EEPROM=", stored_ver, " Marlin=" EEPROM_VERSION ")");
#if HAS_LCD_MENU && DISABLED(EEPROM_AUTO_INIT)
ui.set_status_P(GET_TEXT(MSG_ERR_EEPROM_VERSION));
#endif
eeprom_error = true;
}
else {
@ -2205,11 +2208,17 @@ void MarlinSettings::postprocess() {
if (eeprom_error) {
DEBUG_ECHO_START();
DEBUG_ECHOLNPAIR("Index: ", int(eeprom_index - (EEPROM_OFFSET)), " Size: ", datasize());
#if HAS_LCD_MENU && DISABLED(EEPROM_AUTO_INIT)
ui.set_status_P(GET_TEXT(MSG_ERR_EEPROM_INDEX));
#endif
}
else if (working_crc != stored_crc) {
eeprom_error = true;
DEBUG_ERROR_START();
DEBUG_ECHOLNPAIR("EEPROM CRC mismatch - (stored) ", stored_crc, " != ", working_crc, " (calculated)!");
#if HAS_LCD_MENU && DISABLED(EEPROM_AUTO_INIT)
ui.set_status_P(GET_TEXT(MSG_ERR_EEPROM_CRC));
#endif
}
else if (!validating) {
DEBUG_ECHO_START();