PFW-1542 Don't allow starting SD print if there is a fan error

Apply same conditions as on "Resume print" feature.
Starting a SD print should not be possible if there is an active hardware error
This commit is contained in:
gudnimg 2023-10-15 12:17:36 +00:00
parent bf80ea93f8
commit e1eb952f9e
1 changed files with 23 additions and 14 deletions

View File

@ -5236,6 +5236,14 @@ static void lcd_main_menu()
MENU_ITEM_SUBMENU_P(_T(MSG_TM_ACK_ERROR), lcd_print_stop);
}
#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
if (card.cardOK || lcd_commands_type != LcdCommands::Idle) {
if (!card.isFileOpen()) {
@ -5255,6 +5263,7 @@ static void lcd_main_menu()
#endif //SDCARDDETECT
}
#endif //SDSUPPORT
}
if(!printer_active() && !farm_mode) {
const int8_t sheet = eeprom_read_byte(&(EEPROM_Sheets_base->active_sheet));