From 0966bdcbc424908180fb9f2d963917236ef60ac2 Mon Sep 17 00:00:00 2001 From: Marcio Teixeira Date: Wed, 29 Aug 2018 15:51:14 -0600 Subject: [PATCH] Reorganized ultralcd menu (10317) (#10360) Replaced "Prepare" and "Control" menus with "Movement", "Temperature", "Configuration" and "Advanced Settings" --- Marlin/src/lcd/language/language_en.h | 6 + Marlin/src/lcd/ultralcd.cpp | 383 +++++++++++++------------- 2 files changed, 190 insertions(+), 199 deletions(-) diff --git a/Marlin/src/lcd/language/language_en.h b/Marlin/src/lcd/language/language_en.h index 577171b0d..7e1315c40 100644 --- a/Marlin/src/lcd/language/language_en.h +++ b/Marlin/src/lcd/language/language_en.h @@ -61,6 +61,12 @@ #ifndef MSG_MAIN #define MSG_MAIN _UxGT("Main") #endif +#ifndef MSG_ADVANCED_SETTINGS + #define MSG_ADVANCED_SETTINGS _UxGT("Advanced Settings") +#endif +#ifndef MSG_CONFIGURATION + #define MSG_CONFIGURATION _UxGT("Configuration") +#endif #ifndef MSG_AUTOSTART #define MSG_AUTOSTART _UxGT("Autostart") #endif diff --git a/Marlin/src/lcd/ultralcd.cpp b/Marlin/src/lcd/ultralcd.cpp index d33f2e1fd..a4c17ca1d 100644 --- a/Marlin/src/lcd/ultralcd.cpp +++ b/Marlin/src/lcd/ultralcd.cpp @@ -181,19 +181,19 @@ uint16_t max_display_update_time = 0; void lcd_main_menu(); void lcd_tune_menu(); - void lcd_prepare_menu(); + void lcd_movement_menu(); void lcd_move_menu(); - void lcd_control_menu(); - void lcd_control_temperature_menu(); - void lcd_control_motion_menu(); + void lcd_configuration_menu(); + void lcd_temperature_menu(); + void lcd_advanced_settings_menu(); #if DISABLED(SLIM_LCD_MENUS) - void lcd_control_temperature_preheat_material1_settings_menu(); - void lcd_control_temperature_preheat_material2_settings_menu(); + void lcd_configuration_temperature_preheat_material1_settings_menu(); + void lcd_configuration_temperature_preheat_material2_settings_menu(); #endif #if DISABLED(NO_VOLUMETRICS) || ENABLED(ADVANCED_PAUSE_FEATURE) - void lcd_control_filament_menu(); + void lcd_advanced_filament_menu(); #endif #if ENABLED(LCD_INFO_MENU) @@ -226,7 +226,7 @@ uint16_t max_display_update_time = 0; #if ENABLED(FWRETRACT) #include "../feature/fwretract.h" - void lcd_control_retract_menu(); + void lcd_config_retract_menu(); #endif #if ENABLED(DELTA_CALIBRATION_MENU) || ENABLED(DELTA_AUTO_CALIBRATION) @@ -1093,6 +1093,12 @@ void lcd_quick_feedback(const bool clear_buttons) { * */ + #if ENABLED(SDSUPPORT) && ENABLED(MENU_ADDAUTOSTART) + + void lcd_autostart_sd() { card.beginautostart(); } + + #endif + void lcd_main_menu() { START_MENU(); MENU_BACK(MSG_WATCH); @@ -1119,13 +1125,6 @@ void lcd_quick_feedback(const bool clear_buttons) { MENU_ITEM_EDIT_CALLBACK(bool, MSG_CASE_LIGHT, (bool*)&case_light_on, update_case_light); #endif - if (planner.movesplanned() || IS_SD_PRINTING) - MENU_ITEM(submenu, MSG_TUNE, lcd_tune_menu); - else - MENU_ITEM(submenu, MSG_PREPARE, lcd_prepare_menu); - - MENU_ITEM(submenu, MSG_CONTROL, lcd_control_menu); - #if ENABLED(SDSUPPORT) if (card.cardOK) { if (card.isFileOpen()) { @@ -1150,6 +1149,25 @@ void lcd_quick_feedback(const bool clear_buttons) { } #endif // SDSUPPORT + if (planner.movesplanned() || IS_SD_PRINTING) + MENU_ITEM(submenu, MSG_TUNE, lcd_tune_menu); + else { + MENU_ITEM(submenu, MSG_MOTION, lcd_movement_menu); + MENU_ITEM(submenu, MSG_TEMPERATURE, lcd_temperature_menu); + MENU_ITEM(submenu, MSG_CONFIGURATION, lcd_configuration_menu); + } + + #if ENABLED(ADVANCED_PAUSE_FEATURE) + #if E_STEPPERS == 1 && DISABLED(FILAMENT_LOAD_UNLOAD_GCODES) + if (thermalManager.targetHotEnoughToExtrude(active_extruder)) + MENU_ITEM(gcode, MSG_FILAMENTCHANGE, PSTR("M600 B0")); + else + MENU_ITEM(submenu, MSG_FILAMENTCHANGE, lcd_temp_menu_e0_filament_change); + #else + MENU_ITEM(submenu, MSG_FILAMENTCHANGE, lcd_change_filament_menu); + #endif + #endif + #if ENABLED(LCD_INFO_MENU) MENU_ITEM(submenu, MSG_INFO_MENU, lcd_info_menu); #endif @@ -1158,6 +1176,23 @@ void lcd_quick_feedback(const bool clear_buttons) { MENU_ITEM(submenu, MSG_LED_CONTROL, lcd_led_menu); #endif + // + // Switch power on/off + // + #if HAS_POWER_SWITCH + if (powersupply_on) + MENU_ITEM(gcode, MSG_SWITCH_PS_OFF, PSTR("M81")); + else + MENU_ITEM(gcode, MSG_SWITCH_PS_ON, PSTR("M80")); + #endif + + // + // Autostart + // + #if ENABLED(SDSUPPORT) && ENABLED(MENU_ADDAUTOSTART) + MENU_ITEM(function, MSG_AUTOSTART, lcd_autostart_sd); + #endif + END_MENU(); } @@ -1167,17 +1202,6 @@ void lcd_quick_feedback(const bool clear_buttons) { * */ - #if HAS_M206_COMMAND - /** - * Set the home offset based on the current_position - */ - void lcd_set_home_offsets() { - // M428 Command - enqueue_and_echo_commands_P(PSTR("M428")); - lcd_return_to_status(); - } - #endif - #if ENABLED(BABYSTEP_ZPROBE_GFX_OVERLAY) || ENABLED(MESH_EDIT_GFX_OVERLAY) void _lcd_zoffset_overlay_gfx(const float zvalue) { @@ -1511,20 +1535,6 @@ void lcd_quick_feedback(const bool clear_buttons) { #endif #endif - // - // Change filament - // - #if ENABLED(ADVANCED_PAUSE_FEATURE) - #if E_STEPPERS == 1 && DISABLED(FILAMENT_LOAD_UNLOAD_GCODES) - if (thermalManager.targetHotEnoughToExtrude(active_extruder)) - MENU_ITEM(gcode, MSG_FILAMENTCHANGE, PSTR("M600 B0")); - else - MENU_ITEM(submenu, MSG_FILAMENTCHANGE, lcd_temp_menu_e0_filament_change); - #else - MENU_ITEM(submenu, MSG_FILAMENTCHANGE, lcd_change_filament_menu); - #endif - #endif - END_MENU(); } @@ -1578,7 +1588,7 @@ void lcd_quick_feedback(const bool clear_buttons) { /** * - * "Prepare" submenu items + * "Temperature" submenu items * */ void _lcd_preheat(const int16_t endnum, const int16_t temph, const int16_t tempb, const int16_t fan) { @@ -1691,7 +1701,7 @@ void lcd_quick_feedback(const bool clear_buttons) { void lcd_preheat_m1_menu() { START_MENU(); - MENU_BACK(MSG_PREPARE); + MENU_BACK(MSG_TEMPERATURE); #if HOTENDS == 1 #if HAS_HEATED_BED MENU_ITEM(function, MSG_PREHEAT_1, lcd_preheat_m1_e0); @@ -1743,7 +1753,7 @@ void lcd_quick_feedback(const bool clear_buttons) { void lcd_preheat_m2_menu() { START_MENU(); - MENU_BACK(MSG_PREPARE); + MENU_BACK(MSG_TEMPERATURE); #if HOTENDS == 1 #if HAS_HEATED_BED MENU_ITEM(function, MSG_PREHEAT_2, lcd_preheat_m2_e0); @@ -1823,12 +1833,6 @@ void lcd_quick_feedback(const bool clear_buttons) { #endif - #if ENABLED(SDSUPPORT) && ENABLED(MENU_ADDAUTOSTART) - - void lcd_autostart_sd() { card.beginautostart(); } - - #endif - #if ENABLED(EEPROM_SETTINGS) static void lcd_store_settings() { lcd_completion_feedback(settings.save()); } static void lcd_load_settings() { lcd_completion_feedback(settings.load()); } @@ -1898,7 +1902,7 @@ void lcd_quick_feedback(const bool clear_buttons) { /** * - * "Prepare" > "Level Bed" handlers + * "Motion" > "Level Bed" handlers * */ @@ -2545,7 +2549,7 @@ void lcd_quick_feedback(const bool clear_buttons) { /** * UBL System submenu * - * << Prepare + * << Motion * - Manually Build Mesh >> * - Activate UBL >> * - Deactivate UBL >> @@ -2558,7 +2562,7 @@ void lcd_quick_feedback(const bool clear_buttons) { void _lcd_ubl_level_bed() { START_MENU(); - MENU_BACK(MSG_PREPARE); + MENU_BACK(MSG_MOTION); MENU_ITEM(gcode, MSG_UBL_ACTIVATE_MESH, PSTR("G29 A")); MENU_ITEM(gcode, MSG_UBL_DEACTIVATE_MESH, PSTR("G29 D")); MENU_ITEM(submenu, MSG_UBL_STEP_BY_STEP_MENU, _lcd_ubl_step_by_step); @@ -2585,7 +2589,7 @@ void lcd_quick_feedback(const bool clear_buttons) { /** * Step 1: Bed Level entry-point * - * << Prepare + * << Motion * Auto Home (if homing needed) * Leveling On/Off (if data exists, and homed) * Fade Height: --- (Req: ENABLE_LEVELING_FADE_HEIGHT) @@ -2598,7 +2602,7 @@ void lcd_quick_feedback(const bool clear_buttons) { */ void lcd_bed_leveling() { START_MENU(); - MENU_BACK(MSG_PREPARE); + MENU_BACK(MSG_MOTION); const bool is_homed = all_axes_known(); @@ -2656,11 +2660,11 @@ void lcd_quick_feedback(const bool clear_buttons) { /** * - * "Prepare" submenu + * "Movement" submenu * */ - void lcd_prepare_menu() { + void lcd_movement_menu() { START_MENU(); // @@ -2727,92 +2731,11 @@ void lcd_quick_feedback(const bool clear_buttons) { MENU_ITEM(function, MSG_LEVEL_CORNERS, _lcd_level_bed_corners); #endif - #if HAS_M206_COMMAND && DISABLED(SLIM_LCD_MENUS) - // - // Set Home Offsets - // - MENU_ITEM(function, MSG_SET_HOME_OFFSETS, lcd_set_home_offsets); - #endif - // // Disable Steppers // MENU_ITEM(gcode, MSG_DISABLE_STEPPERS, PSTR("M84")); - // - // Change filament - // - #if ENABLED(ADVANCED_PAUSE_FEATURE) - if (!IS_SD_FILE_OPEN) { - #if E_STEPPERS == 1 && DISABLED(FILAMENT_LOAD_UNLOAD_GCODES) - if (thermalManager.targetHotEnoughToExtrude(active_extruder)) - MENU_ITEM(gcode, MSG_FILAMENTCHANGE, PSTR("M600 B0")); - else - MENU_ITEM(submenu, MSG_FILAMENTCHANGE, lcd_temp_menu_e0_filament_change); - #else - MENU_ITEM(submenu, MSG_FILAMENTCHANGE, lcd_change_filament_menu); - #endif - } - #endif // ADVANCED_PAUSE_FEATURE - - #if HAS_TEMP_HOTEND - - // - // Cooldown - // - bool has_heat = false; - HOTEND_LOOP() if (thermalManager.target_temperature[HOTEND_INDEX]) { has_heat = true; break; } - #if HAS_HEATED_BED - if (thermalManager.target_temperature_bed) has_heat = true; - #endif - if (has_heat) MENU_ITEM(function, MSG_COOLDOWN, lcd_cooldown); - - // - // Preheat for Material 1 and 2 - // - #if TEMP_SENSOR_1 != 0 || TEMP_SENSOR_2 != 0 || TEMP_SENSOR_3 != 0 || TEMP_SENSOR_4 != 0 || HAS_HEATED_BED - MENU_ITEM(submenu, MSG_PREHEAT_1, lcd_preheat_m1_menu); - MENU_ITEM(submenu, MSG_PREHEAT_2, lcd_preheat_m2_menu); - #else - MENU_ITEM(function, MSG_PREHEAT_1, lcd_preheat_m1_e0_only); - MENU_ITEM(function, MSG_PREHEAT_2, lcd_preheat_m2_e0_only); - #endif - - #endif // HAS_TEMP_HOTEND - - // - // BLTouch Self-Test and Reset - // - #if ENABLED(BLTOUCH) - MENU_ITEM(gcode, MSG_BLTOUCH_SELFTEST, PSTR("M280 P" STRINGIFY(Z_PROBE_SERVO_NR) " S" STRINGIFY(BLTOUCH_SELFTEST))); - if (!endstops.z_probe_enabled && TEST_BLTOUCH()) - MENU_ITEM(gcode, MSG_BLTOUCH_RESET, PSTR("M280 P" STRINGIFY(Z_PROBE_SERVO_NR) " S" STRINGIFY(BLTOUCH_RESET))); - #endif - - // - // Switch power on/off - // - #if HAS_POWER_SWITCH - if (powersupply_on) - MENU_ITEM(gcode, MSG_SWITCH_PS_OFF, PSTR("M81")); - else - MENU_ITEM(gcode, MSG_SWITCH_PS_ON, PSTR("M80")); - #endif - - // - // Autostart - // - #if ENABLED(SDSUPPORT) && ENABLED(MENU_ADDAUTOSTART) - MENU_ITEM(function, MSG_AUTOSTART, lcd_autostart_sd); - #endif - - // - // Delta Calibration - // - #if ENABLED(DELTA_CALIBRATION_MENU) || ENABLED(DELTA_AUTO_CALIBRATION) - MENU_ITEM(submenu, MSG_DELTA_CALIBRATE, lcd_delta_calibrate_menu); - #endif - END_MENU(); } @@ -2991,7 +2914,7 @@ void lcd_quick_feedback(const bool clear_buttons) { /** * - * "Prepare" > "Move Axis" submenu + * "Motion" > "Move Axis" submenu * */ @@ -3143,7 +3066,7 @@ void lcd_quick_feedback(const bool clear_buttons) { /** * - * "Prepare" > "Move Xmm" > "Move XYZ" submenu + * "Motion" > "Move Xmm" > "Move XYZ" submenu * */ @@ -3199,7 +3122,7 @@ void lcd_quick_feedback(const bool clear_buttons) { /** * - * "Prepare" > "Move Axis" submenu + * "Motion" > "Move Axis" submenu * */ @@ -3221,7 +3144,7 @@ void lcd_quick_feedback(const bool clear_buttons) { void lcd_move_menu() { START_MENU(); - MENU_BACK(MSG_PREPARE); + MENU_BACK(MSG_MOTION); #if HAS_SOFTWARE_ENDSTOPS && ENABLED(SOFT_ENDSTOPS_MENU_ITEM) MENU_ITEM_EDIT(bool, MSG_LCD_SOFT_ENDSTOPS, &soft_endstops_enabled); @@ -3310,7 +3233,7 @@ void lcd_quick_feedback(const bool clear_buttons) { /** * - * "Control" submenu + * "Configuration" submenu * */ @@ -3332,30 +3255,31 @@ void lcd_quick_feedback(const bool clear_buttons) { static void lcd_init_eeprom_confirm() { START_MENU(); - MENU_BACK(MSG_CONTROL); + MENU_BACK(MSG_ADVANCED_SETTINGS); MENU_ITEM(function, MSG_INIT_EEPROM, lcd_init_eeprom); END_MENU(); } #endif - void lcd_control_menu() { + void lcd_configuration_menu() { START_MENU(); MENU_BACK(MSG_MAIN); - MENU_ITEM(submenu, MSG_TEMPERATURE, lcd_control_temperature_menu); - MENU_ITEM(submenu, MSG_MOTION, lcd_control_motion_menu); - #if DISABLED(NO_VOLUMETRICS) || ENABLED(ADVANCED_PAUSE_FEATURE) - MENU_ITEM(submenu, MSG_FILAMENT, lcd_control_filament_menu); - #elif ENABLED(LIN_ADVANCE) - MENU_ITEM_EDIT(float52, MSG_ADVANCE_K, &planner.extruder_advance_K, 0, 999); + MENU_ITEM(submenu, MSG_ADVANCED_SETTINGS, lcd_advanced_settings_menu); + + // + // Delta Calibration + // + #if ENABLED(DELTA_CALIBRATION_MENU) || ENABLED(DELTA_AUTO_CALIBRATION) + MENU_ITEM(submenu, MSG_DELTA_CALIBRATE, lcd_delta_calibrate_menu); #endif #if HAS_LCD_CONTRAST MENU_ITEM_EDIT_CALLBACK(int3, MSG_CONTRAST, &lcd_contrast, LCD_CONTRAST_MIN, LCD_CONTRAST_MAX, lcd_callback_set_contrast, true); #endif #if ENABLED(FWRETRACT) - MENU_ITEM(submenu, MSG_RETRACT, lcd_control_retract_menu); + MENU_ITEM(submenu, MSG_RETRACT, lcd_config_retract_menu); #endif #if ENABLED(DAC_STEPPER_CURRENT) MENU_ITEM(submenu, MSG_DRIVE_STRENGTH, lcd_dac_menu); @@ -3368,6 +3292,12 @@ void lcd_quick_feedback(const bool clear_buttons) { MENU_ITEM(submenu, MSG_BLTOUCH, bltouch_menu); #endif + #if DISABLED(SLIM_LCD_MENUS) + // Preheat configurations + MENU_ITEM(submenu, MSG_PREHEAT_1_SETTINGS, lcd_configuration_temperature_preheat_material1_settings_menu); + MENU_ITEM(submenu, MSG_PREHEAT_2_SETTINGS, lcd_configuration_temperature_preheat_material2_settings_menu); + #endif + #if ENABLED(EEPROM_SETTINGS) MENU_ITEM(function, MSG_STORE_EEPROM, lcd_store_settings); MENU_ITEM(function, MSG_LOAD_EEPROM, lcd_load_settings); @@ -3375,10 +3305,6 @@ void lcd_quick_feedback(const bool clear_buttons) { MENU_ITEM(function, MSG_RESTORE_FAILSAFE, lcd_factory_settings); - #if ENABLED(EEPROM_SETTINGS) && DISABLED(SLIM_LCD_MENUS) - MENU_ITEM(submenu, MSG_INIT_EEPROM, lcd_init_eeprom_confirm); - #endif - END_MENU(); } @@ -3464,16 +3390,12 @@ void lcd_quick_feedback(const bool clear_buttons) { /** * - * "Control" > "Temperature" submenu + * "Temperature" submenu * */ - void lcd_control_temperature_menu() { + void lcd_temperature_menu() { START_MENU(); - - // - // ^ Control - // - MENU_BACK(MSG_CONTROL); + MENU_BACK(MSG_MAIN); // // Nozzle: @@ -3526,6 +3448,42 @@ void lcd_quick_feedback(const bool clear_buttons) { #endif #endif // FAN_COUNT > 0 + #if HAS_TEMP_HOTEND + + // + // Cooldown + // + bool has_heat = false; + HOTEND_LOOP() if (thermalManager.target_temperature[HOTEND_INDEX]) { has_heat = true; break; } + #if HAS_TEMP_BED + if (thermalManager.target_temperature_bed) has_heat = true; + #endif + if (has_heat) MENU_ITEM(function, MSG_COOLDOWN, lcd_cooldown); + + // + // Preheat for Material 1 and 2 + // + #if TEMP_SENSOR_1 != 0 || TEMP_SENSOR_2 != 0 || TEMP_SENSOR_3 != 0 || TEMP_SENSOR_4 != 0 || HAS_HEATED_BED + MENU_ITEM(submenu, MSG_PREHEAT_1, lcd_preheat_m1_menu); + MENU_ITEM(submenu, MSG_PREHEAT_2, lcd_preheat_m2_menu); + #else + MENU_ITEM(function, MSG_PREHEAT_1, lcd_preheat_m1_e0_only); + MENU_ITEM(function, MSG_PREHEAT_2, lcd_preheat_m2_e0_only); + #endif + + #endif // HAS_TEMP_HOTEND + + END_MENU(); + } + + /** + * + * "Advanced Settings" -> "Temperature" submenu + * + */ + void lcd_advanced_temperature_menu() { + START_MENU(); + MENU_BACK(MSG_ADVANCED_SETTINGS); // // Autotemp, Min, Max, Fact // @@ -3587,24 +3545,12 @@ void lcd_quick_feedback(const bool clear_buttons) { #endif // PIDTEMP - #if DISABLED(SLIM_LCD_MENUS) - // - // Preheat Material 1 conf - // - MENU_ITEM(submenu, MSG_PREHEAT_1_SETTINGS, lcd_control_temperature_preheat_material1_settings_menu); - - // - // Preheat Material 2 conf - // - MENU_ITEM(submenu, MSG_PREHEAT_2_SETTINGS, lcd_control_temperature_preheat_material2_settings_menu); - #endif - END_MENU(); } #if DISABLED(SLIM_LCD_MENUS) - void _lcd_control_temperature_preheat_settings_menu(const uint8_t material) { + void _lcd_configuration_temperature_preheat_settings_menu(const uint8_t material) { #if HOTENDS > 4 #define MINTEMP_ALL MIN5(HEATER_0_MINTEMP, HEATER_1_MINTEMP, HEATER_2_MINTEMP, HEATER_3_MINTEMP, HEATER_4_MINTEMP) #define MAXTEMP_ALL MAX5(HEATER_0_MAXTEMP, HEATER_1_MAXTEMP, HEATER_2_MAXTEMP, HEATER_3_MAXTEMP, HEATER_4_MAXTEMP) @@ -3622,7 +3568,7 @@ void lcd_quick_feedback(const bool clear_buttons) { #define MAXTEMP_ALL HEATER_0_MAXTEMP #endif START_MENU(); - MENU_BACK(MSG_TEMPERATURE); + MENU_BACK(MSG_CONFIGURATION); MENU_ITEM_EDIT(int3, MSG_FAN_SPEED, &lcd_preheat_fan_speed[material], 0, 255); #if HAS_TEMP_HOTEND MENU_ITEM_EDIT(int3, MSG_NOZZLE, &lcd_preheat_hotend_temp[material], MINTEMP_ALL, MAXTEMP_ALL - 15); @@ -3641,14 +3587,14 @@ void lcd_quick_feedback(const bool clear_buttons) { * "Temperature" > "Preheat Material 1 conf" submenu * */ - void lcd_control_temperature_preheat_material1_settings_menu() { _lcd_control_temperature_preheat_settings_menu(0); } + void lcd_configuration_temperature_preheat_material1_settings_menu() { _lcd_configuration_temperature_preheat_settings_menu(0); } /** * * "Temperature" > "Preheat Material 2 conf" submenu * */ - void lcd_control_temperature_preheat_material2_settings_menu() { _lcd_control_temperature_preheat_settings_menu(1); } + void lcd_configuration_temperature_preheat_material2_settings_menu() { _lcd_configuration_temperature_preheat_settings_menu(1); } void _reset_acceleration_rates() { planner.reset_acceleration_rates(); } #if ENABLED(DISTINCT_E_FACTORS) @@ -3688,9 +3634,9 @@ void lcd_quick_feedback(const bool clear_buttons) { #endif // M203 / M205 Velocity options - void lcd_control_motion_velocity_menu() { + void lcd_advanced_velocity_menu() { START_MENU(); - MENU_BACK(MSG_MOTION); + MENU_BACK(MSG_ADVANCED_SETTINGS); // M203 Max Feedrate MENU_MULTIPLIER_ITEM_EDIT(float3, MSG_VMAX MSG_A, &planner.max_feedrate_mm_s[A_AXIS], 1, 999); @@ -3724,9 +3670,9 @@ void lcd_quick_feedback(const bool clear_buttons) { } // M201 / M204 Accelerations - void lcd_control_motion_acceleration_menu() { + void lcd_advanced_acceleration_menu() { START_MENU(); - MENU_BACK(MSG_MOTION); + MENU_BACK(MSG_ADVANCED_SETTINGS); // M204 P Acceleration MENU_MULTIPLIER_ITEM_EDIT(float5, MSG_ACC, &planner.acceleration, 10, 99000); @@ -3763,9 +3709,9 @@ void lcd_quick_feedback(const bool clear_buttons) { } // M205 Jerk - void lcd_control_motion_jerk_menu() { + void lcd_advanced_jerk_menu() { START_MENU(); - MENU_BACK(MSG_MOTION); + MENU_BACK(MSG_ADVANCED_SETTINGS); #if ENABLED(JUNCTION_DEVIATION) MENU_ITEM_EDIT_CALLBACK(float43, MSG_JUNCTION_DEVIATION, &planner.junction_deviation_mm, 0.01f, 0.3f, planner.recalculate_max_e_jerk); @@ -3784,9 +3730,9 @@ void lcd_quick_feedback(const bool clear_buttons) { } // M92 Steps-per-mm - void lcd_control_motion_steps_per_mm_menu() { + void lcd_advanced_steps_per_mm_menu() { START_MENU(); - MENU_BACK(MSG_MOTION); + MENU_BACK(MSG_ADVANCED_SETTINGS); MENU_MULTIPLIER_ITEM_EDIT_CALLBACK(float62, MSG_ASTEPS, &planner.axis_steps_per_mm[A_AXIS], 5, 9999, _planner_refresh_positioning); MENU_MULTIPLIER_ITEM_EDIT_CALLBACK(float62, MSG_BSTEPS, &planner.axis_steps_per_mm[B_AXIS], 5, 9999, _planner_refresh_positioning); @@ -3816,13 +3762,24 @@ void lcd_quick_feedback(const bool clear_buttons) { /** * - * "Control" > "Motion" submenu + * "Advanced Settings" submenu * */ - void lcd_control_motion_menu() { + #if HAS_M206_COMMAND + /** + * Set the home offset based on the current_position + */ + void lcd_set_home_offsets() { + // M428 Command + enqueue_and_echo_commands_P(PSTR("M428")); + lcd_return_to_status(); + } + #endif + + void lcd_advanced_settings_menu() { START_MENU(); - MENU_BACK(MSG_CONTROL); + MENU_BACK(MSG_CONFIGURATION); #if ENABLED(BABYSTEP_ZPROBE_OFFSET) MENU_ITEM(submenu, MSG_ZPROBE_ZOFFSET, lcd_babystep_zoffset); @@ -3832,37 +3789,65 @@ void lcd_quick_feedback(const bool clear_buttons) { #if DISABLED(SLIM_LCD_MENUS) + #if HAS_M206_COMMAND + // + // Set Home Offsets + // + MENU_ITEM(function, MSG_SET_HOME_OFFSETS, lcd_set_home_offsets); + #endif + // M203 / M205 - Feedrate items - MENU_ITEM(submenu, MSG_VELOCITY, lcd_control_motion_velocity_menu); + MENU_ITEM(submenu, MSG_VELOCITY, lcd_advanced_velocity_menu); // M201 - Acceleration items - MENU_ITEM(submenu, MSG_ACCELERATION, lcd_control_motion_acceleration_menu); + MENU_ITEM(submenu, MSG_ACCELERATION, lcd_advanced_acceleration_menu); // M205 - Max Jerk - MENU_ITEM(submenu, MSG_JERK, lcd_control_motion_jerk_menu); + MENU_ITEM(submenu, MSG_JERK, lcd_advanced_jerk_menu); // M92 - Steps Per mm - MENU_ITEM(submenu, MSG_STEPS_PER_MM, lcd_control_motion_steps_per_mm_menu); + MENU_ITEM(submenu, MSG_STEPS_PER_MM, lcd_advanced_steps_per_mm_menu); #endif // !SLIM_LCD_MENUS + MENU_ITEM(submenu, MSG_TEMPERATURE, lcd_advanced_temperature_menu); + + #if DISABLED(NO_VOLUMETRICS) || ENABLED(ADVANCED_PAUSE_FEATURE) + MENU_ITEM(submenu, MSG_FILAMENT, lcd_advanced_filament_menu); + #elif ENABLED(LIN_ADVANCE) + MENU_ITEM_EDIT(float32, MSG_ADVANCE_K, &planner.extruder_advance_K, 0, 999); + #endif + // M540 S - Abort on endstop hit when SD printing #if ENABLED(ABORT_ON_ENDSTOP_HIT_FEATURE_ENABLED) MENU_ITEM_EDIT(bool, MSG_ENDSTOP_ABORT, &planner.abort_on_endstop_hit); #endif + // + // BLTouch Self-Test and Reset + // + #if ENABLED(BLTOUCH) + MENU_ITEM(gcode, MSG_BLTOUCH_SELFTEST, PSTR("M280 P" STRINGIFY(Z_PROBE_SERVO_NR) " S" STRINGIFY(BLTOUCH_SELFTEST))); + if (!endstops.z_probe_enabled && TEST_BLTOUCH()) + MENU_ITEM(gcode, MSG_BLTOUCH_RESET, PSTR("M280 P" STRINGIFY(Z_PROBE_SERVO_NR) " S" STRINGIFY(BLTOUCH_RESET))); + #endif + + #if ENABLED(EEPROM_SETTINGS) && DISABLED(SLIM_LCD_MENUS) + MENU_ITEM(submenu, MSG_INIT_EEPROM, lcd_init_eeprom_confirm); + #endif + END_MENU(); } #if DISABLED(NO_VOLUMETRICS) || ENABLED(ADVANCED_PAUSE_FEATURE) /** * - * "Control" > "Filament" submenu + * "Advanced Settings" > "Filament" submenu * */ - void lcd_control_filament_menu() { + void lcd_advanced_filament_menu() { START_MENU(); - MENU_BACK(MSG_CONTROL); + MENU_BACK(MSG_ADVANCED_SETTINGS); #if ENABLED(LIN_ADVANCE) MENU_ITEM_EDIT(float52, MSG_ADVANCE_K, &planner.extruder_advance_K, 0, 999); @@ -3941,12 +3926,12 @@ void lcd_quick_feedback(const bool clear_buttons) { /** * - * "Control" > "Retract" submenu + * "Configuration" > "Retract" submenu * */ #if ENABLED(FWRETRACT) - void lcd_control_retract_menu() { + void lcd_config_retract_menu() { START_MENU(); MENU_BACK(MSG_CONTROL); MENU_ITEM_EDIT_CALLBACK(bool, MSG_AUTORETRACT, &fwretract.autoretract_enabled, fwretract.refresh_autoretract); @@ -4378,7 +4363,7 @@ void lcd_quick_feedback(const bool clear_buttons) { #if E_STEPPERS > 1 || ENABLED(FILAMENT_LOAD_UNLOAD_GCODES) void lcd_change_filament_menu() { START_MENU(); - MENU_BACK(MSG_PREPARE); + MENU_BACK(MSG_MAIN); // Change filament #if E_STEPPERS == 1