diff --git a/Marlin/src/inc/Version.h b/Marlin/src/inc/Version.h index d8fb4c12..d84871b7 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.2.0-b_4.5" + #define CUSTOM_BUILD_VERSION "1.2.0-b_4.6" #ifndef STRING_DISTRIBUTION_DATE - #define STRING_DISTRIBUTION_DATE "2021-06-18" + #define STRING_DISTRIBUTION_DATE "2021-06-19" #endif /** diff --git a/Marlin/src/lcd/anycubic_touchscreen.cpp b/Marlin/src/lcd/anycubic_touchscreen.cpp index 963130c3..f0d114e1 100755 --- a/Marlin/src/lcd/anycubic_touchscreen.cpp +++ b/Marlin/src/lcd/anycubic_touchscreen.cpp @@ -649,7 +649,7 @@ void AnycubicTouchscreenClass::HandleSpecialMenu() || (strcasestr_P(currentTouchscreenSelection, PSTR(SM_SAVE_EEPROM_S)) != NULL)) { SERIAL_ECHOLNPGM("Special Menu: Save EEPROM"); - queue.inject_P(PSTR("M500")); + settings.save(); // M500 buzzer.tone(105, 1108); buzzer.tone(210, 1661); } @@ -657,9 +657,9 @@ void AnycubicTouchscreenClass::HandleSpecialMenu() || (strcasestr_P(currentTouchscreenSelection, PSTR(SM_LOAD_DEFAULTS_S)) != NULL)) { SERIAL_ECHOLNPGM("Special Menu: Load FW Defaults"); - queue.inject_P(PSTR("M502")); + settings.reset(); // M502 #if ENABLED(KNUTWURST_TFT_LEVELING) - initializeGrid(); + initializeGrid(); #endif buzzer.tone(105, 1661); buzzer.tone(210, 1108); @@ -1999,12 +1999,28 @@ void AnycubicTouchscreenClass::GetCommandFromTFT() if (!all_axes_known()) { queue.inject_P(PSTR("G28\n")); - } else { + /* + set_axis_is_at_home(X_AXIS); + sync_plan_position(); + set_axis_is_at_home(Y_AXIS); + sync_plan_position(); + set_axis_is_at_home(Z_AXIS); + sync_plan_position(); + report_current_position(); + */ + } else { // Go up before moving + //SERIAL_ECHOLNPGM("Z Up"); setAxisPosition_mm(5.0,Z); + //report_current_position(); + //SERIAL_ECHOLNPGM("Move X"); setAxisPosition_mm(_GET_MESH_X(mx),X); + //report_current_position(); + //SERIAL_ECHOLNPGM("Move Y"); setAxisPosition_mm(_GET_MESH_Y(my),Y); + //report_current_position(); + //SERIAL_ECHOLNPGM("Z Down"); setAxisPosition_mm(EXT_LEVEL_HIGH,Z); report_current_position(); diff --git a/Marlin/src/lcd/anycubic_touchscreen.h b/Marlin/src/lcd/anycubic_touchscreen.h index 98eeb25f..721ab7ee 100755 --- a/Marlin/src/lcd/anycubic_touchscreen.h +++ b/Marlin/src/lcd/anycubic_touchscreen.h @@ -34,7 +34,7 @@ enum axis_t : uint8_t { X, Y, Z, X2, Y2, Z2, Z3, Z4 }; enum extruder_t : uint8_t { E0, E1, E2, E3, E4, E5, E6, E7 }; void setAxisPosition_mm(const float, const axis_t, const feedRate_t=0); - +void initializeGrid(); char *itostr2(const uint8_t &x);