From 7c3619f8c00fdb38eb54622638f3d91d090965a8 Mon Sep 17 00:00:00 2001 From: sarusani Date: Tue, 20 Aug 2024 10:40:35 +0200 Subject: [PATCH] Remove lcd_menu_AutoLoadFilament --- Firmware/messages.cpp | 2 ++ Firmware/messages.h | 2 ++ Firmware/ultralcd.cpp | 15 +++++++++------ Firmware/variants/MK25-RAMBo10a.h | 3 +++ Firmware/variants/MK25-RAMBo13a.h | 3 +++ Firmware/variants/MK25S-RAMBo10a.h | 3 +++ Firmware/variants/MK25S-RAMBo13a.h | 3 +++ Firmware/variants/MK3-E3DREVO.h | 3 +++ Firmware/variants/MK3-E3DREVO_HF_60W.h | 3 +++ Firmware/variants/MK3.h | 3 +++ Firmware/variants/MK3S-E3DREVO.h | 3 +++ Firmware/variants/MK3S-E3DREVO_HF_60W.h | 3 +++ Firmware/variants/MK3S.h | 3 +++ .../obsolete/1_75mm_MK2-RAMBo10a-E3Dv6full.h | 3 +++ .../obsolete/1_75mm_MK2-RAMBo13a-E3Dv6full.h | 3 +++ 15 files changed, 49 insertions(+), 6 deletions(-) diff --git a/Firmware/messages.cpp b/Firmware/messages.cpp index 95d2ded1e4..d68aca79f7 100644 --- a/Firmware/messages.cpp +++ b/Firmware/messages.cpp @@ -253,7 +253,9 @@ extern const char MSG_LOADING_COLOR [] PROGMEM_I1 = ISTR("Loading color"); ////M extern const char MSG_CORRECTLY [] PROGMEM_I1 = ISTR("Changed correctly"); ////MSG_CORRECTLY c=19 extern const char MSG_NOT_LOADED [] PROGMEM_I1 = ISTR("Filament not loaded"); ////MSG_NOT_LOADED c=19 extern const char MSG_NOT_COLOR [] PROGMEM_I1 = ISTR("Color not correct"); ////MSG_NOT_COLOR c=19 +#ifndef REMOVE_AUTOLOAD_FILAMENT_MENU_ENTRY extern const char MSG_AUTOLOADING_ENABLED [] PROGMEM_I1 = ISTR("Autoloading filament is active, just press the knob and insert filament..."); ////MSG_AUTOLOADING_ENABLED c=20 r=4 +#endif //REMOVE_AUTOLOAD_FILAMENT_MENU_ENTRY extern const char MSG_FILAMENT_USED [] PROGMEM_I1 = ISTR("Filament used"); ////MSG_FILAMENT_USED c=19 extern const char MSG_PRINT_TIME [] PROGMEM_I1 = ISTR("Print time"); ////MSG_PRINT_TIME c=19 extern const char MSG_TOTAL_FILAMENT [] PROGMEM_I1 = ISTR("Total filament"); ////MSG_TOTAL_FILAMENT c=19 diff --git a/Firmware/messages.h b/Firmware/messages.h index 5abd460a5e..52adb82c40 100644 --- a/Firmware/messages.h +++ b/Firmware/messages.h @@ -252,7 +252,9 @@ extern const char MSG_LOADING_COLOR []; extern const char MSG_CORRECTLY []; extern const char MSG_NOT_LOADED []; extern const char MSG_NOT_COLOR []; +#ifndef REMOVE_AUTOLOAD_FILAMENT_MENU_ENTRY extern const char MSG_AUTOLOADING_ENABLED []; +#endif //REMOVE_AUTOLOAD_FILAMENT_MENU_ENTRY extern const char MSG_FILAMENT_USED []; extern const char MSG_PRINT_TIME []; extern const char MSG_TOTAL_FILAMENT []; diff --git a/Firmware/ultralcd.cpp b/Firmware/ultralcd.cpp index a73d072b23..21e47de899 100644 --- a/Firmware/ultralcd.cpp +++ b/Firmware/ultralcd.cpp @@ -2296,13 +2296,13 @@ void lcd_load_filament_color_check() } } -#ifdef FILAMENT_SENSOR +#if defined(FILAMENT_SENSOR) && !defined(REMOVE_AUTOLOAD_FILAMENT_MENU_ENTRY) static void lcd_menu_AutoLoadFilament() { lcd_display_message_fullscreen_nonBlocking_P(_T(MSG_AUTOLOADING_ENABLED)); menu_back_if_clicked(); } -#endif //FILAMENT_SENSOR +#endif //FILAMENT_SENSOR && REMOVE_AUTOLOAD_FILAMENT_MENU_ENTRY static void preheat_or_continue(FilamentAction action) { @@ -5351,13 +5351,16 @@ static void lcd_main_menu() if (!fsensor.getAutoLoadEnabled()) { MENU_ITEM_SUBMENU_P(_T(MSG_LOAD_FILAMENT), lcd_LoadFilament); } - if (!fsensor.getFilamentPresent()) { + if (fsensor.getFilamentPresent()) { + MENU_ITEM_SUBMENU_P(_T(MSG_UNLOAD_FILAMENT), lcd_unLoadFilament); + } +#ifndef REMOVE_AUTOLOAD_FILAMENT_MENU_ENTRY + else { if (fsensor.getAutoLoadEnabled()) { MENU_ITEM_SUBMENU_P(_T(MSG_AUTOLOAD_FILAMENT), lcd_menu_AutoLoadFilament); - } - } else { - MENU_ITEM_SUBMENU_P(_T(MSG_UNLOAD_FILAMENT), lcd_unLoadFilament); + } } +#endif //REMOVE_AUTOLOAD_FILAMENT_MENU_ENTRY } else { #endif //FILAMENT_SENSOR MENU_ITEM_SUBMENU_P(_T(MSG_LOAD_FILAMENT), lcd_LoadFilament); diff --git a/Firmware/variants/MK25-RAMBo10a.h b/Firmware/variants/MK25-RAMBo10a.h index 891d88385c..8bc1f786e8 100644 --- a/Firmware/variants/MK25-RAMBo10a.h +++ b/Firmware/variants/MK25-RAMBo10a.h @@ -527,4 +527,7 @@ //Show filename instead of print time after SD card print finished //#define SHOW_FILENAME_AFTER_FINISH +//Remove the "AutoLoad filament" LCD menu entry if autoload is enabled. +//#define REMOVE_AUTOLOAD_FILAMENT_MENU_ENTRY + #endif //__CONFIGURATION_PRUSA_H diff --git a/Firmware/variants/MK25-RAMBo13a.h b/Firmware/variants/MK25-RAMBo13a.h index a94097c41f..1b23dccfa6 100644 --- a/Firmware/variants/MK25-RAMBo13a.h +++ b/Firmware/variants/MK25-RAMBo13a.h @@ -531,4 +531,7 @@ //Show filename instead of print time after SD card print finished //#define SHOW_FILENAME_AFTER_FINISH +//Remove the "AutoLoad filament" LCD menu entry if autoload is enabled. +//#define REMOVE_AUTOLOAD_FILAMENT_MENU_ENTRY + #endif //__CONFIGURATION_PRUSA_H diff --git a/Firmware/variants/MK25S-RAMBo10a.h b/Firmware/variants/MK25S-RAMBo10a.h index 6e0484468b..e4c56a8a33 100644 --- a/Firmware/variants/MK25S-RAMBo10a.h +++ b/Firmware/variants/MK25S-RAMBo10a.h @@ -535,4 +535,7 @@ //Show filename instead of print time after SD card print finished //#define SHOW_FILENAME_AFTER_FINISH +//Remove the "AutoLoad filament" LCD menu entry if autoload is enabled. +//#define REMOVE_AUTOLOAD_FILAMENT_MENU_ENTRY + #endif //__CONFIGURATION_PRUSA_H diff --git a/Firmware/variants/MK25S-RAMBo13a.h b/Firmware/variants/MK25S-RAMBo13a.h index 1ae556fdb7..163b18ca0a 100644 --- a/Firmware/variants/MK25S-RAMBo13a.h +++ b/Firmware/variants/MK25S-RAMBo13a.h @@ -536,4 +536,7 @@ //Show filename instead of print time after SD card print finished //#define SHOW_FILENAME_AFTER_FINISH +//Remove the "AutoLoad filament" LCD menu entry if autoload is enabled. +//#define REMOVE_AUTOLOAD_FILAMENT_MENU_ENTRY + #endif //__CONFIGURATION_PRUSA_H diff --git a/Firmware/variants/MK3-E3DREVO.h b/Firmware/variants/MK3-E3DREVO.h index 4d81d5bb75..2275266bb4 100644 --- a/Firmware/variants/MK3-E3DREVO.h +++ b/Firmware/variants/MK3-E3DREVO.h @@ -694,4 +694,7 @@ //Show filename instead of print time after SD card print finished //#define SHOW_FILENAME_AFTER_FINISH +//Remove the "AutoLoad filament" LCD menu entry if autoload is enabled. +//#define REMOVE_AUTOLOAD_FILAMENT_MENU_ENTRY + #endif //__CONFIGURATION_PRUSA_H diff --git a/Firmware/variants/MK3-E3DREVO_HF_60W.h b/Firmware/variants/MK3-E3DREVO_HF_60W.h index 9c10541b6b..5373409212 100644 --- a/Firmware/variants/MK3-E3DREVO_HF_60W.h +++ b/Firmware/variants/MK3-E3DREVO_HF_60W.h @@ -695,4 +695,7 @@ //Show filename instead of print time after SD card print finished //#define SHOW_FILENAME_AFTER_FINISH +//Remove the "AutoLoad filament" LCD menu entry if autoload is enabled. +//#define REMOVE_AUTOLOAD_FILAMENT_MENU_ENTRY + #endif //__CONFIGURATION_PRUSA_H diff --git a/Firmware/variants/MK3.h b/Firmware/variants/MK3.h index 6b759993e3..a988139aa2 100644 --- a/Firmware/variants/MK3.h +++ b/Firmware/variants/MK3.h @@ -697,4 +697,7 @@ //Show filename instead of print time after SD card print finished //#define SHOW_FILENAME_AFTER_FINISH +//Remove the "AutoLoad filament" LCD menu entry if autoload is enabled. +//#define REMOVE_AUTOLOAD_FILAMENT_MENU_ENTRY + #endif //__CONFIGURATION_PRUSA_H diff --git a/Firmware/variants/MK3S-E3DREVO.h b/Firmware/variants/MK3S-E3DREVO.h index b6e98348f9..953b775b3b 100644 --- a/Firmware/variants/MK3S-E3DREVO.h +++ b/Firmware/variants/MK3S-E3DREVO.h @@ -706,4 +706,7 @@ //Show filename instead of print time after SD card print finished //#define SHOW_FILENAME_AFTER_FINISH +//Remove the "AutoLoad filament" LCD menu entry if autoload is enabled. +//#define REMOVE_AUTOLOAD_FILAMENT_MENU_ENTRY + #endif //__CONFIGURATION_PRUSA_H diff --git a/Firmware/variants/MK3S-E3DREVO_HF_60W.h b/Firmware/variants/MK3S-E3DREVO_HF_60W.h index 048c94faa0..eb173da03e 100644 --- a/Firmware/variants/MK3S-E3DREVO_HF_60W.h +++ b/Firmware/variants/MK3S-E3DREVO_HF_60W.h @@ -707,4 +707,7 @@ //Show filename instead of print time after SD card print finished //#define SHOW_FILENAME_AFTER_FINISH +//Remove the "AutoLoad filament" LCD menu entry if autoload is enabled. +//#define REMOVE_AUTOLOAD_FILAMENT_MENU_ENTRY + #endif //__CONFIGURATION_PRUSA_H diff --git a/Firmware/variants/MK3S.h b/Firmware/variants/MK3S.h index 962e74eff8..c6f6825547 100644 --- a/Firmware/variants/MK3S.h +++ b/Firmware/variants/MK3S.h @@ -709,4 +709,7 @@ //Show filename instead of print time after SD card print finished //#define SHOW_FILENAME_AFTER_FINISH +//Remove the "AutoLoad filament" LCD menu entry if autoload is enabled. +//#define REMOVE_AUTOLOAD_FILAMENT_MENU_ENTRY + #endif //__CONFIGURATION_PRUSA_H diff --git a/Firmware/variants/obsolete/1_75mm_MK2-RAMBo10a-E3Dv6full.h b/Firmware/variants/obsolete/1_75mm_MK2-RAMBo10a-E3Dv6full.h index 3f4d12a87b..fa816c066f 100644 --- a/Firmware/variants/obsolete/1_75mm_MK2-RAMBo10a-E3Dv6full.h +++ b/Firmware/variants/obsolete/1_75mm_MK2-RAMBo10a-E3Dv6full.h @@ -437,4 +437,7 @@ THERMISTORS SETTINGS //Show filename instead of print time after SD card print finished //#define SHOW_FILENAME_AFTER_FINISH +//Remove the "AutoLoad filament" LCD menu entry if autoload is enabled. +//#define REMOVE_AUTOLOAD_FILAMENT_MENU_ENTRY + #endif //__CONFIGURATION_PRUSA_H diff --git a/Firmware/variants/obsolete/1_75mm_MK2-RAMBo13a-E3Dv6full.h b/Firmware/variants/obsolete/1_75mm_MK2-RAMBo13a-E3Dv6full.h index 19183943af..0db3b785ee 100644 --- a/Firmware/variants/obsolete/1_75mm_MK2-RAMBo13a-E3Dv6full.h +++ b/Firmware/variants/obsolete/1_75mm_MK2-RAMBo13a-E3Dv6full.h @@ -436,4 +436,7 @@ THERMISTORS SETTINGS //Show filename instead of print time after SD card print finished //#define SHOW_FILENAME_AFTER_FINISH +//Remove the "AutoLoad filament" LCD menu entry if autoload is enabled. +//#define REMOVE_AUTOLOAD_FILAMENT_MENU_ENTRY + #endif //__CONFIGURATION_PRUSA_H