|
@@ -450,7 +450,7 @@ void lcdui_print_feedrate(void)
|
|
|
|
|
|
void lcdui_print_percent_done(void)
|
|
|
{
|
|
|
- const char* src = is_usb_printing?_N("USB"):(IS_SD_PRINTING?_N(" SD"):_N(" "));
|
|
|
+ const char* src = usb_timer.running()?_N("USB"):(IS_SD_PRINTING?_N(" SD"):_N(" "));
|
|
|
char per[4];
|
|
|
bool num = IS_SD_PRINTING || (PRINTER_ACTIVE && (print_percent_done_normal != PRINT_PERCENT_DONE_INIT));
|
|
|
if (!num || heating_status != HeatingStatus::NO_HEATING)
|
|
@@ -3849,7 +3849,7 @@ static void lcd_show_sensors_state()
|
|
|
|
|
|
|
|
|
|
|
|
- if (!moves_planned() && !IS_SD_PRINTING && !is_usb_printing && (lcd_commands_type != LcdCommands::Layer1Cal))
|
|
|
+ if (!moves_planned() && !IS_SD_PRINTING && !usb_timer.running() && (lcd_commands_type != LcdCommands::Layer1Cal))
|
|
|
pat9125_update();
|
|
|
lcd_set_cursor(0, 2);
|
|
|
lcd_printf_P(_N(
|
|
@@ -4358,7 +4358,7 @@ static void crash_mode_switch()
|
|
|
{
|
|
|
lcd_crash_detect_enable();
|
|
|
}
|
|
|
- if (IS_SD_PRINTING || is_usb_printing || (lcd_commands_type == LcdCommands::Layer1Cal)) menu_goto(lcd_tune_menu, 9, true, true);
|
|
|
+ if (IS_SD_PRINTING || usb_timer.running() || (lcd_commands_type == LcdCommands::Layer1Cal)) menu_goto(lcd_tune_menu, 9, true, true);
|
|
|
else menu_goto(lcd_settings_menu, 9, true, true);
|
|
|
}
|
|
|
#endif
|
|
@@ -6339,7 +6339,7 @@ void lcd_resume_print()
|
|
|
lcd_return_to_status();
|
|
|
lcd_reset_alert_level();
|
|
|
if (fan_error_selftest()) {
|
|
|
- if (is_usb_printing) SERIAL_PROTOCOLLNRPGM(MSG_OCTOPRINT_PAUSED);
|
|
|
+ if (usb_timer.running()) SERIAL_PROTOCOLLNRPGM(MSG_OCTOPRINT_PAUSED);
|
|
|
return;
|
|
|
}
|
|
|
cmdqueue_serial_disabled = false;
|
|
@@ -6516,7 +6516,7 @@ static void lcd_main_menu()
|
|
|
MENU_ITEM_FUNCTION_P(PSTR("power panic"), uvlo_);
|
|
|
#endif
|
|
|
|
|
|
- if ( ( IS_SD_PRINTING || is_usb_printing || (lcd_commands_type == LcdCommands::Layer1Cal)) && (current_position[Z_AXIS] < Z_HEIGHT_HIDE_LIVE_ADJUST_MENU) && !homing_flag && !mesh_bed_leveling_flag) {
|
|
|
+ if ( ( IS_SD_PRINTING || usb_timer.running() || (lcd_commands_type == LcdCommands::Layer1Cal)) && (current_position[Z_AXIS] < Z_HEIGHT_HIDE_LIVE_ADJUST_MENU) && !homing_flag && !mesh_bed_leveling_flag) {
|
|
|
MENU_ITEM_SUBMENU_P(_T(MSG_BABYSTEP_Z), lcd_babystep_z);
|
|
|
}
|
|
|
|
|
@@ -6530,7 +6530,7 @@ static void lcd_main_menu()
|
|
|
}
|
|
|
|
|
|
if (mesh_bed_leveling_flag == false && homing_flag == false && !isPrintPaused) {
|
|
|
- if (is_usb_printing) {
|
|
|
+ if (usb_timer.running()) {
|
|
|
MENU_ITEM_FUNCTION_P(_T(MSG_PAUSE_PRINT), lcd_pause_usb_print);
|
|
|
} else if (IS_SD_PRINTING) {
|
|
|
MENU_ITEM_FUNCTION_P(_T(MSG_PAUSE_PRINT), lcd_pause_print);
|
|
@@ -6542,20 +6542,20 @@ static void lcd_main_menu()
|
|
|
if((fan_check_error == EFCE_FIXED) || (fan_check_error == EFCE_OK))
|
|
|
#endif
|
|
|
{
|
|
|
- if (is_usb_printing) {
|
|
|
+ if (usb_timer.running()) {
|
|
|
MENU_ITEM_SUBMENU_P(_T(MSG_RESUME_PRINT), lcd_resume_usb_print);
|
|
|
} else {
|
|
|
MENU_ITEM_SUBMENU_P(_T(MSG_RESUME_PRINT), lcd_resume_print);
|
|
|
}
|
|
|
}
|
|
|
}
|
|
|
- if((IS_SD_PRINTING || is_usb_printing || isPrintPaused) && (custom_message_type != CustomMsg::MeshBedLeveling)) {
|
|
|
+ if((IS_SD_PRINTING || usb_timer.running() || isPrintPaused) && (custom_message_type != CustomMsg::MeshBedLeveling)) {
|
|
|
MENU_ITEM_SUBMENU_P(_T(MSG_STOP_PRINT), lcd_sdcard_stop);
|
|
|
}
|
|
|
#ifdef SDSUPPORT
|
|
|
if (card.cardOK || lcd_commands_type == LcdCommands::Layer1Cal) {
|
|
|
if (!card.isFileOpen()) {
|
|
|
- if (!is_usb_printing && (lcd_commands_type != LcdCommands::Layer1Cal)) {
|
|
|
+ if (!usb_timer.running() && (lcd_commands_type != LcdCommands::Layer1Cal)) {
|
|
|
|
|
|
{
|
|
|
bMain=true;
|
|
@@ -6575,7 +6575,7 @@ static void lcd_main_menu()
|
|
|
}
|
|
|
#endif
|
|
|
|
|
|
- if(!isPrintPaused && !IS_SD_PRINTING && !is_usb_printing && (lcd_commands_type != LcdCommands::Layer1Cal)) {
|
|
|
+ if(!isPrintPaused && !IS_SD_PRINTING && !usb_timer.running() && (lcd_commands_type != LcdCommands::Layer1Cal)) {
|
|
|
if (!farm_mode) {
|
|
|
const int8_t sheet = eeprom_read_byte(&(EEPROM_Sheets_base->active_sheet));
|
|
|
const int8_t nextSheet = eeprom_next_initialized_sheet(sheet);
|
|
@@ -6585,7 +6585,7 @@ static void lcd_main_menu()
|
|
|
}
|
|
|
}
|
|
|
|
|
|
- if ( ! ( IS_SD_PRINTING || is_usb_printing || (lcd_commands_type == LcdCommands::Layer1Cal) ) ) {
|
|
|
+ if ( ! ( IS_SD_PRINTING || usb_timer.running() || (lcd_commands_type == LcdCommands::Layer1Cal) ) ) {
|
|
|
if (mmu_enabled) {
|
|
|
MENU_ITEM_SUBMENU_P(_T(MSG_LOAD_FILAMENT), fil_load_menu);
|
|
|
MENU_ITEM_SUBMENU_P(_i("Load to nozzle"), mmu_load_to_nozzle_menu);
|
|
@@ -6617,7 +6617,7 @@ static void lcd_main_menu()
|
|
|
if(!isPrintPaused) MENU_ITEM_SUBMENU_P(_T(MSG_MENU_CALIBRATION), lcd_calibration_menu);
|
|
|
}
|
|
|
|
|
|
- if (!is_usb_printing && (lcd_commands_type != LcdCommands::Layer1Cal)) {
|
|
|
+ if (!usb_timer.running() && (lcd_commands_type != LcdCommands::Layer1Cal)) {
|
|
|
MENU_ITEM_SUBMENU_P(_i("Statistics"), lcd_menu_statistics);
|
|
|
}
|
|
|
|
|
@@ -8718,7 +8718,7 @@ void menu_lcd_longpress_func(void)
|
|
|
|
|
|
|
|
|
|
|
|
- if ( (moves_planned() || IS_SD_PRINTING || is_usb_printing )){
|
|
|
+ if ( (moves_planned() || IS_SD_PRINTING || usb_timer.running() )){
|
|
|
if(( current_position[Z_AXIS] < Z_HEIGHT_HIDE_LIVE_ADJUST_MENU )
|
|
|
&& ( menu_menu == lcd_status_screen
|
|
|
|| menu_menu == lcd_main_menu
|