diff --git a/Marlin/Configuration.h b/Marlin/Configuration.h index 2743b5da..bcf0867a 100755 --- a/Marlin/Configuration.h +++ b/Marlin/Configuration.h @@ -99,19 +99,6 @@ #endif -/* - * Here you can set the default preheat-Temperatures - * which are set when you use the builtin preheat - * functions in the TFT. - * - * These settings are required and not set by PlatformIO. - */ -#define KNUTWURST_PRHEAT_NOZZLE_PLA 200 -#define KNUTWURST_PRHEAT_BED_PLA 60 -#define KNUTWURST_PRHEAT_NOZZLE_ABS 240 -#define KNUTWURST_PRHEAT_BED_ABS 90 - - // =========================================================================== // ============================= Getting Started ============================= // =========================================================================== diff --git a/Marlin/src/inc/Version.h b/Marlin/src/inc/Version.h index bb124078..f01fd866 100755 --- a/Marlin/src/inc/Version.h +++ b/Marlin/src/inc/Version.h @@ -41,10 +41,10 @@ * here we define this default string as the date where the latest release * version was tagged. */ - #define CUSTOM_BUILD_VERSION "1.5.0" + #define CUSTOM_BUILD_VERSION "1.5.1" #ifndef STRING_DISTRIBUTION_DATE - #define STRING_DISTRIBUTION_DATE "2023-06-07" + #define STRING_DISTRIBUTION_DATE "2023-06-08" #endif /** diff --git a/Marlin/src/lcd/extui/knutwurst/anycubic_touchscreen.cpp b/Marlin/src/lcd/extui/knutwurst/anycubic_touchscreen.cpp index e0642843..327a04dd 100755 --- a/Marlin/src/lcd/extui/knutwurst/anycubic_touchscreen.cpp +++ b/Marlin/src/lcd/extui/knutwurst/anycubic_touchscreen.cpp @@ -32,7 +32,7 @@ #include "../../../module/motion.h" #include "../../../module/stepper.h" -//#define ANYCUBIC_TFT_DEBUG +#define ANYCUBIC_TFT_DEBUG //#define KNUTWURST_DGUS2_TFT //#define KNUTWURST_TFT_LEVELING @@ -525,13 +525,13 @@ || (strcasestr_P(currentTouchscreenSelection, PSTR(SM_BLTZ_UP_S)) != NULL) ) { SERIAL_ECHOLNPGM("Special Menu: Offset UP"); - probe.offset.z += 0.01F; + setZOffset_mm(getZOffset_mm() + 0.01F); } else if ((strcasestr_P(currentTouchscreenSelection, PSTR(SM_BLTZ_DN_L)) != NULL) || (strcasestr_P(currentTouchscreenSelection, PSTR(SM_BLTZ_DN_S)) != NULL) ) { SERIAL_ECHOLNPGM("Special Menu: Offset Down"); - probe.offset.z -= 0.01F; + setZOffset_mm(getZOffset_mm() - 0.01F); } else if ((strcasestr_P(currentTouchscreenSelection, PSTR(SM_HS_ENABLE_L)) != NULL) || (strcasestr_P(currentTouchscreenSelection, PSTR(SM_HS_ENABLE_S)) != NULL) @@ -736,11 +736,11 @@ void AnycubicTouchscreenClass::RenderSpecialMenu(uint16_t selectedNumber) { zOffsetBuffer = SM_BLTZ_DISP_L; #ifdef ANYCUBIC_TFT_DEBUG - SERIAL_ECHOPGM("TFT Serial Debug: Current probe.offset.z: ", float(probe.offset.z)); + SERIAL_ECHOPGM("TFT Serial Debug: Current getZOffset_mm(): ", getZOffset_mm()); SERIAL_EOL(); #endif - zOffsetBuffer.replace("XXXXX", String(float(probe.offset.z))); + zOffsetBuffer.replace("XXXXX", String(getZOffset_mm())); switch (selectedNumber) { case 0: // Page 1 @@ -878,11 +878,22 @@ void AnycubicTouchscreenClass::RenderCurrentFolder(uint16_t selectedNumber) { } else { max_files = selectedNumber + 3; #ifdef ANYCUBIC_TFT_DEBUG - SERIAL_ECHOLN("max_files = filenumber + 3;"); + SERIAL_ECHOLN("max_files = selectedNumber + 3;"); #endif } - if (filesOnSDCard == 3) filenumber = 0; + if (filesOnSDCard == 3) selectedNumber = 0; + + #ifdef ANYCUBIC_TFT_DEBUG + SERIAL_ECHOPGM("filesOnSDCard: "); + SERIAL_ECHOLN(filesOnSDCard); + SERIAL_ECHOPGM("selectedNumber: "); + SERIAL_ECHOLN(selectedNumber); + SERIAL_ECHOPGM("max_files: "); + SERIAL_ECHOLN(max_files); + SERIAL_ECHOPGM("count: "); + SERIAL_ECHOLN(count); + #endif for (count = selectedNumber; count <= max_files; count++) { if (count == 0) { // Special Entry @@ -911,7 +922,6 @@ void AnycubicTouchscreenClass::RenderCurrentFolder(uint16_t selectedNumber) { SERIAL_ECHOLN(currentFileList.filename()); #endif - // The longname may not be filed, so we use the built-in fallback here. char* fileName = strdup(currentFileList.filename()); int fileNameLen = strlen(fileName); diff --git a/Marlin/src/lcd/extui/knutwurst/anycubic_touchscreen.h b/Marlin/src/lcd/extui/knutwurst/anycubic_touchscreen.h index 58ffbf7f..5f8cdefa 100755 --- a/Marlin/src/lcd/extui/knutwurst/anycubic_touchscreen.h +++ b/Marlin/src/lcd/extui/knutwurst/anycubic_touchscreen.h @@ -226,7 +226,6 @@ char serial3_char; int serial3_count = 0; char *TFTstrchr_pointer; char FlagResumFromOutage = 0; -int filenumber = 0; uint8_t tmp_extruder = 0; uint16_t HeaterCheckCount = 0; int currentFlowRate = 0;