diff --git a/Marlin/Version.h b/Marlin/Version.h index c26f4f9560..45879837c9 100644 --- a/Marlin/Version.h +++ b/Marlin/Version.h @@ -28,7 +28,7 @@ /** * Marlin release version identifier */ -#define SHORT_BUILD_VERSION "2.0.9_DW7.4" +#define SHORT_BUILD_VERSION "2.0.9_DW7.4.1" /** * Verbose version identifier which should contain a reference to the location diff --git a/Marlin/src/lcd/extui/dgus/mks/DGUSScreenHandler.cpp b/Marlin/src/lcd/extui/dgus/mks/DGUSScreenHandler.cpp index 0ee3828387..56e9c4d87f 100644 --- a/Marlin/src/lcd/extui/dgus/mks/DGUSScreenHandler.cpp +++ b/Marlin/src/lcd/extui/dgus/mks/DGUSScreenHandler.cpp @@ -304,6 +304,7 @@ void DGUSScreenHandler::ScreenChangeHook(DGUS_VP_Variable &var, void *val_ptr) { // Special handling for popup is to return to previous menu if (current_screen == DGUSLCD_SCREEN_POPUP && confirm_action_cb) confirm_action_cb(); + setPauseMenuResponse(PAUSE_RESPONSE_RESUME_PRINT); PopToOldScreen(); return; } diff --git a/Marlin/src/lcd/extui/dgus_creality/DGUSScreenHandler.cpp b/Marlin/src/lcd/extui/dgus_creality/DGUSScreenHandler.cpp index bf4c402d7f..e954eeaf1b 100644 --- a/Marlin/src/lcd/extui/dgus_creality/DGUSScreenHandler.cpp +++ b/Marlin/src/lcd/extui/dgus_creality/DGUSScreenHandler.cpp @@ -717,8 +717,10 @@ bool DGUSScreenHandler::HandlePendingUserConfirmation() { // Switch to the resume screen ScreenHandler.GotoScreen(DGUSLCD_SCREEN_PRINT_RUNNING, false); - + SERIAL_ECHOLN("HandlePending "); // We might be re-entrant here + + ExtUI::setPauseMenuResponse(PAUSE_RESPONSE_RESUME_PRINT); ExtUI::setUserConfirmed(); return true; @@ -1085,6 +1087,8 @@ void DGUSScreenHandler::ScreenChangeHook(DGUS_VP_Variable &var, void *val_ptr) { if (ExtUI::awaitingUserConfirm() && current_screen == DGUSLCD_SCREEN_POPUP) { DEBUG_ECHOLN("Executing confirmation action"); + + ExtUI::setPauseMenuResponse(PAUSE_RESPONSE_RESUME_PRINT); ExtUI::setUserConfirmed(); PopToOldScreen(); return; @@ -1731,6 +1735,11 @@ bool DGUSScreenHandler::loop() { GotoScreen(DGUSLCD_SCREEN_MAIN); } } + // Catch pause / wait for user that bypassed events + if (ScreenHandler.getCurrentScreen() != DGUSLCD_SCREEN_PRINT_PAUSED && ScreenHandler.getCurrentScreen() != DGUSLCD_SCREEN_POPUP && ExtUI::awaitingUserConfirm()) { + SERIAL_ECHOLN("Catch1"); + ExtUI::onUserConfirmRequired_P(PSTR("Paused")); + } return IsScreenComplete(); } diff --git a/Marlin/src/lcd/extui/dgus_creality/creality_touch/DGUSDisplayDef.h b/Marlin/src/lcd/extui/dgus_creality/creality_touch/DGUSDisplayDef.h index c18f2d1b32..122998c70e 100644 --- a/Marlin/src/lcd/extui/dgus_creality/creality_touch/DGUSDisplayDef.h +++ b/Marlin/src/lcd/extui/dgus_creality/creality_touch/DGUSDisplayDef.h @@ -194,7 +194,7 @@ constexpr uint16_t VP_MARLIN_VERSION = 0x2222; constexpr uint8_t VP_MARLIN_VERSION_LEN = 32; constexpr uint16_t VP_MARLIN_WEBSITE = 0x2242; -constexpr uint8_t VP_MARLIN_WEBSITE_LEN = 32; +constexpr uint8_t VP_MARLIN_WEBSITE_LEN = 32; constexpr uint16_t VP_STANDBY_BACKLIGHT_ICON = 0x2280; constexpr uint16_t VP_STANDBY_BACKLIGHT_TOGGLE = 0x2282; @@ -217,10 +217,10 @@ constexpr uint16_t VP_PREHEAT_ABS_BED_TEMP = 0x110a; // Place for status messages. // ... We have memory space for scrolling messages -constexpr uint16_t VP_M117 = 0x3000 + (3 * 1); // Text Variable Pointer. First three VP must be reserved [a VP is two bytes red.]. Text is saved after the 3rd VP and ended with 0x00 or 0x0F. +constexpr uint16_t VP_M117 = 0x3000 + (3 * 1); // Text Variable Pointer. First three VP must be reserved [a VP is two bytes red.]. Text is saved after the 3rd VP and ended with 0x00 or 0x0F. constexpr uint8_t VP_M117_LEN = 100; -// ... And memory space for static (short) messages. Note this VPAddr is also the VP of the 5 beta and alpha 4 touch screens. +// ... And memory space for static (short) messages. Note this VPAddr is also the VP of the 5 beta and alpha 4 touch screens. constexpr uint8_t M117_STATIC_DISPLAY_LEN = 28; // Fits "TFT flashed incorrectly v0" exactly constexpr uint16_t VP_M117_STATIC = 0x21B3; constexpr uint8_t VP_M117_STATIC_LEN = 70; @@ -335,15 +335,15 @@ constexpr uint16_t VP_AXIS_SETTINGS_AXIS_TMCSTEALTHCHOP_BUTTON = 0x22EB; // 2-by constexpr uint16_t VP_AXIS_SETTINGS_AXIS_TMCSTEALTHCHOP_ICON = 0x22ED; // 2-byte constexpr uint16_t VP_AXIS_SETTINGS_AXIS_TMCHYBRIDTHRESHOLD = 0x22EF; // 4-byte (!) -constexpr uint16_t VP_AXIS_TUNING_NAV_BUTTON = 0x22F5; -constexpr uint16_t VP_AXIS_TMC_NAV_BUTTON = 0x22F7; +constexpr uint16_t VP_AXIS_TUNING_NAV_BUTTON = 0x22F5; +constexpr uint16_t VP_AXIS_TMC_NAV_BUTTON = 0x22F7; constexpr uint16_t VP_AXIS_TMC_NAV_ICON = 0x22F3; // 2-byte constexpr uint16_t AXIS_TMC_NAV_ICON_SHOWING = 10; constexpr uint16_t AXIS_TMC_NAV_ICON_HIDING = 11; // ... Advanced movement settings -constexpr uint16_t VP_MOV_NAV_BUTTON = 0x2305; +constexpr uint16_t VP_MOV_NAV_BUTTON = 0x2305; constexpr uint16_t VP_MOV_MINIMUM_SEGMENT_TIME = 0x22F9; // uint 2-byte constexpr uint16_t VP_MOV_MINIMUM_FEEDRATE = 0x22FB; // float 2-byte @@ -355,7 +355,7 @@ constexpr uint16_t VP_MOV_MINIMUM_TRAVEL_ACCELERATION = 0x2303; // float 2-byte constexpr uint16_t VP_MOV_RETRACT_ACCELERATION = 0x2307; // float 4-byte // Misc settings -constexpr uint16_t VP_MISCSETTINGS_NAV_BUTTON = 0x2311; +constexpr uint16_t VP_MISCSETTINGS_NAV_BUTTON = 0x2311; constexpr uint16_t VP_FILAMENTRUNOUT_SENSOR_TOGGLE_BUTTON = 0x2309; constexpr uint16_t VP_FILAMENTRUNOUT_SENSOR_TOGGLE_ICON = 0x230b; diff --git a/Marlin/src/lcd/extui/dgus_creality/creality_touch/PageHandlers.cpp b/Marlin/src/lcd/extui/dgus_creality/creality_touch/PageHandlers.cpp index af1545d79b..d8ecfdc05f 100644 --- a/Marlin/src/lcd/extui/dgus_creality/creality_touch/PageHandlers.cpp +++ b/Marlin/src/lcd/extui/dgus_creality/creality_touch/PageHandlers.cpp @@ -244,6 +244,10 @@ void PrintRunningMenuHandler(DGUS_VP_Variable &var, unsigned short buttonValue) break; case VP_BUTTON_PAUSEPRINTKEY: + if (!ScreenHandler.HandlePendingUserConfirmation()) { + ExtUI::resumePrint(); + ScreenHandler.GotoScreen(DGUSLCD_SCREEN_PRINT_RUNNING); + } else ScreenHandler.GotoScreen(DGUSLCD_SCREEN_DIALOG_PAUSE); break; @@ -256,15 +260,15 @@ void PrintRunningMenuHandler(DGUS_VP_Variable &var, unsigned short buttonValue) void PrintPausedMenuHandler(DGUS_VP_Variable &var, unsigned short buttonValue) { switch (var.VP) { case VP_BUTTON_RESUMEPRINTKEY: -#if ENABLED(FILAMENT_RUNOUT_SENSOR) + #if ENABLED(FILAMENT_RUNOUT_SENSOR) runout.reset(); -#endif + #endif - if (!ScreenHandler.HandlePendingUserConfirmation()) { - ExtUI::resumePrint(); - ScreenHandler.GotoScreen(DGUSLCD_SCREEN_PRINT_RUNNING); - } - break; + if (!ScreenHandler.HandlePendingUserConfirmation()) { + ExtUI::resumePrint(); + ScreenHandler.GotoScreen(DGUSLCD_SCREEN_PRINT_RUNNING); + } + break; case VP_BUTTON_ADJUSTENTERKEY: ScreenHandler.GotoScreen(DGUSLCD_SCREEN_TUNING); diff --git a/Marlin/src/lcd/extui/dgus_creality_lcd.cpp b/Marlin/src/lcd/extui/dgus_creality_lcd.cpp index 6ad229afc3..2de5acfbe9 100644 --- a/Marlin/src/lcd/extui/dgus_creality_lcd.cpp +++ b/Marlin/src/lcd/extui/dgus_creality_lcd.cpp @@ -120,14 +120,14 @@ bool hasPrintTimer = false; } void onUserConfirmed() { - DEBUG_ECHOLN("User confirmation invoked"); - + SERIAL_ECHOLN("User confirmation invoked"); + setPauseMenuResponse(PAUSE_RESPONSE_RESUME_PRINT); ExtUI::setUserConfirmed(); } void onUserConfirmRequired(const char * const msg) { - if (msg) { - DEBUG_ECHOLNPAIR("User confirmation requested: ", msg); + //if (msg) { + SERIAL_ECHOLNPAIR("User confirmation requested: ", msg); if (ScreenHandler.getCurrentScreen() == DGUSLCD_SCREEN_FEED) { // We're in the feed (load filament) workflow - immediately assume confirmed @@ -143,13 +143,13 @@ bool hasPrintTimer = false; } else { ScreenHandler.GotoScreen(DGUSLCD_SCREEN_POPUP); } - } - else if (ScreenHandler.getCurrentScreen() == DGUSLCD_SCREEN_POPUP) { - DEBUG_ECHOLNPAIR("User confirmation canceled"); + //} + //else if (ScreenHandler.getCurrentScreen() == DGUSLCD_SCREEN_POPUP) { + // DEBUG_ECHOLNPAIR("User confirmation canceled"); - ScreenHandler.setstatusmessagePGM(nullptr); - ScreenHandler.PopToOldScreen(); - } + // ScreenHandler.setstatusmessagePGM(nullptr); + // ScreenHandler.PopToOldScreen(); + //} } void onStatusChanged(const char * const msg) { ScreenHandler.setstatusmessage(msg); } diff --git a/buildroot/share/PlatformIO/scripts/common-cxxflags.py b/buildroot/share/PlatformIO/scripts/common-cxxflags.py index 358894a3e9..c1d0472fa5 100644 --- a/buildroot/share/PlatformIO/scripts/common-cxxflags.py +++ b/buildroot/share/PlatformIO/scripts/common-cxxflags.py @@ -27,7 +27,7 @@ def add_cpu_freq(): if env.GetBuildType() == "debug" and env.get('UPLOAD_PROTOCOL') not in ['jlink', 'stlink']: env['BUILD_DIR'] = '$PROJECT_BUILD_DIR/$PIOENV/debug' env_name = str(env["PIOENV"]) -env.Replace(PROGNAME="%s_DW7.4" % (env_name)) +env.Replace(PROGNAME="%s_DW7.4.1" % (env_name)) print("Environment: %s" % (env_name)) # On some platform, F_CPU is a runtime variable. Since it's used to convert from ns diff --git a/buildroot/share/PlatformIO/scripts/random-bin.py b/buildroot/share/PlatformIO/scripts/random-bin.py index 91a8be64a0..48b4c69422 100644 --- a/buildroot/share/PlatformIO/scripts/random-bin.py +++ b/buildroot/share/PlatformIO/scripts/random-bin.py @@ -6,5 +6,5 @@ Import("env") from datetime import datetime env_name = str(env["PIOENV"]) -env['PROGNAME'] = "firmware_%s_DW7.4" % (env_name) +env['PROGNAME'] = "firmware_%s_DW7.4.1" % (env_name) #env['PROGNAME'] .= datetime.now().strftime("-%Y%m%d-%H%M%S")