diff --git a/Firmware/Marlin_main.cpp b/Firmware/Marlin_main.cpp index fe88c8cae..22fb576b9 100644 --- a/Firmware/Marlin_main.cpp +++ b/Firmware/Marlin_main.cpp @@ -167,7 +167,7 @@ CardReader card; unsigned long PingTime = _millis(); unsigned long NcTime; -int mbl_z_probe_nr = 4; //numer of Z measurements for each point in mesh bed leveling calibration +int mbl_z_probe_nr = 3; //numer of Z measurements for each point in mesh bed leveling calibration //used for PINDA temp calibration and pause print #define DEFAULT_RETRACTION 1 @@ -1468,6 +1468,11 @@ void setup() } //mbl_mode_init(); mbl_settings_init(); + SilentModeMenu_MMU = eeprom_read_byte((uint8_t*)EEPROM_MMU_STEALTH); + if (SilentModeMenu_MMU == 255) { + SilentModeMenu_MMU = 1; + eeprom_write_byte((uint8_t*)EEPROM_MMU_STEALTH, SilentModeMenu_MMU); + } check_babystep(); //checking if Z babystep is in allowed range #ifdef UVLO_SUPPORT diff --git a/Firmware/eeprom.h b/Firmware/eeprom.h index 8a15248e9..56ee5f77d 100644 --- a/Firmware/eeprom.h +++ b/Firmware/eeprom.h @@ -159,6 +159,7 @@ #define EEPROM_MBL_MAGNET_ELIMINATION (EEPROM_MBL_TYPE -1) #define EEPROM_MBL_POINTS_NR (EEPROM_MBL_MAGNET_ELIMINATION -1) //uint8_t number of points in one exis for mesh bed leveling #define EEPROM_MBL_PROBE_NR (EEPROM_MBL_POINTS_NR-1) +#define EEPROM_MMU_STEALTH (EEPROM_MBL_PROBE_NR-1) // !!!!! // !!!!! this is end of EEPROM section ... all updates MUST BE inserted before this mark !!!!! // !!!!! diff --git a/Firmware/mesh_bed_calibration.cpp b/Firmware/mesh_bed_calibration.cpp index 7b53e2859..8de8fe81b 100644 --- a/Firmware/mesh_bed_calibration.cpp +++ b/Firmware/mesh_bed_calibration.cpp @@ -3093,7 +3093,7 @@ void mbl_settings_init() { } mbl_z_probe_nr = eeprom_read_byte((uint8_t*)EEPROM_MBL_POINTS_NR); if (mbl_z_probe_nr == 0xFF) { - mbl_z_probe_nr = 4; + mbl_z_probe_nr = 3; eeprom_update_byte((uint8_t*)EEPROM_MBL_POINTS_NR, mbl_z_probe_nr); } diff --git a/Firmware/mmu.cpp b/Firmware/mmu.cpp index 449efabd0..6d5cc5144 100644 --- a/Firmware/mmu.cpp +++ b/Firmware/mmu.cpp @@ -185,10 +185,8 @@ static bool activate_stealth_mode() { #if defined (MMU_FORCE_STEALTH_MODE) return true; -#elif defined (SILENT_MODE_STEALTH) - return (eeprom_read_byte((uint8_t*)EEPROM_SILENT) == SILENT_MODE_STEALTH); -#else - return false; +#elif + return (eeprom_read_byte((uint8_t*)EEPROM_MMU_STEALTH) == 1); #endif } diff --git a/Firmware/ultralcd.cpp b/Firmware/ultralcd.cpp index 5cdf6b8a5..169ae1434 100644 --- a/Firmware/ultralcd.cpp +++ b/Firmware/ultralcd.cpp @@ -53,6 +53,7 @@ int8_t ReInitLCD = 0; int8_t SilentModeMenu = SILENT_MODE_OFF; +uint8_t SilentModeMenu_MMU = 1; //activate mmu unit stealth mode int8_t FSensorStateMenu = 1; @@ -4515,6 +4516,12 @@ static void lcd_sound_state_set(void) Sound_CycleState(); } +static void lcd_silent_mode_mmu_set() { + if (SilentModeMenu_MMU == 1) SilentModeMenu_MMU = 0; + else SilentModeMenu_MMU = 1; + eeprom_update_byte((uint8_t*)EEPROM_MMU_STEALTH, SilentModeMenu_MMU); +} + static void lcd_silent_mode_set() { switch (SilentModeMenu) { #ifdef TMC2130 @@ -5288,6 +5295,13 @@ do\ break; /* (probably) not needed*/\ }\ }\ +#ifndef MMU_FORCE_STEALTH_MODE + if(mmu_enabled)\ + {\ + if (SilentModeMenu_MMU == 0) MENU_ITEM_FUNCTION_P(_i("MMU Mode [Fast]"), lcd_silent_mode_mmu_set);\ + else MENU_ITEM_FUNCTION_P(_i("MMU Mode [Stealth]"), lcd_silent_mode_mmu_set);\ + }\ +#endif //MMU_FORCE_STEALTH_MODE }\ while (0) #endif //TMC2130