Merge pull request #4450 from gudnimg/PFW-1542-v3-3_13_2

3.13.2 Cherry-pick PFW-1542 Don't allow starting SD print if there is a thermal or fan error
This commit is contained in:
3d-gussner 2023-10-16 15:37:38 +02:00 committed by GitHub
commit 63680d69eb
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 24 additions and 14 deletions

View File

@ -146,6 +146,7 @@ void checkFanSpeed()
if ((fan_check_error == EFCE_FIXED) && !printer_active()){ if ((fan_check_error == EFCE_FIXED) && !printer_active()){
fan_check_error = EFCE_OK; //if the issue is fixed while the printer is doing nothing, reenable processing immediately. fan_check_error = EFCE_OK; //if the issue is fixed while the printer is doing nothing, reenable processing immediately.
lcd_reset_alert_level(); //for another fan speed error lcd_reset_alert_level(); //for another fan speed error
lcd_setstatuspgm(MSG_WELCOME); // Reset the status line message to visually show the error is gone
} }
if (fans_check_enabled && (fan_check_error == EFCE_OK)) if (fans_check_enabled && (fan_check_error == EFCE_OK))
{ {

View File

@ -5236,6 +5236,14 @@ static void lcd_main_menu()
MENU_ITEM_SUBMENU_P(_T(MSG_TM_ACK_ERROR), lcd_print_stop); MENU_ITEM_SUBMENU_P(_T(MSG_TM_ACK_ERROR), lcd_print_stop);
} }
#endif #endif
// only allow starting SD print if hardware errors (temperature or fan) are cleared
if(!get_temp_error()
#ifdef FANCHECK
&& fan_check_error != EFCE_REPORTED
#endif //FANCHECK
)
{
#ifdef SDSUPPORT //!@todo SDSUPPORT undefined creates several issues in source code #ifdef SDSUPPORT //!@todo SDSUPPORT undefined creates several issues in source code
if (card.cardOK || lcd_commands_type != LcdCommands::Idle) { if (card.cardOK || lcd_commands_type != LcdCommands::Idle) {
if (!card.isFileOpen()) { if (!card.isFileOpen()) {
@ -5255,6 +5263,7 @@ static void lcd_main_menu()
#endif //SDCARDDETECT #endif //SDCARDDETECT
} }
#endif //SDSUPPORT #endif //SDSUPPORT
}
if(!printer_active() && !farm_mode) { if(!printer_active() && !farm_mode) {
const int8_t sheet = eeprom_read_byte(&(EEPROM_Sheets_base->active_sheet)); const int8_t sheet = eeprom_read_byte(&(EEPROM_Sheets_base->active_sheet));