Add "more" menu in LVGL interface#20940
Add "more" menu in LVGL interface#20940thinkyhead merged 11 commits intoMarlinFirmware:bugfix-2.0.xfrom
Conversation
|
Getting better :-) You should not enable by default it, on the configuration_adv. Test this branch too, to check if all the draw_more code are there |
done |
|
Congratulations! :-) Scott may review the config you added and he may merge it soon. |
|
How to define what icon's the different custom buttons use? #define CUSTOM_USER_MENUS
#define CUSTOM_USER_MENUS_LVGL |
|
The changes in the default config probably will be reverted by @thinkyhead. |
|
@rhapsodyv . //#define CUSTOM_USER_MENUS
#if ENABLED(CUSTOM_USER_MENUS)
//#define CUSTOM_USER_MENU_TITLE "Custom Commands"
#define USER_SCRIPT_DONE "M117 User Script Done"
#define USER_SCRIPT_AUDIBLE_FEEDBACK
//#define USER_SCRIPT_RETURN // Return to status screen after a script
#if ENABLED(TFT_LVGL_UI)
#define USER_CMD_1_ENABLE
#define USER_DESC_1 "Bed"
#define USER_GCODE_1 "M140 S" STRINGIFY(PREHEAT_2_TEMP_BED)
#define USER_CMD_2_ENABLE
#define USER_DESC_2 "Preheat \n for " PREHEAT_1_LABEL
#define USER_GCODE_2 "M140 S" STRINGIFY(PREHEAT_1_TEMP_BED) "\nM104 S" STRINGIFY(PREHEAT_1_TEMP_HOTEND)
#define USER_CMD_3_ENABLE
#define USER_DESC_3 "Preheat \n for " PREHEAT_2_LABEL
#define USER_GCODE_3 "M140 S" STRINGIFY(PREHEAT_2_TEMP_BED) "\nM104 S" STRINGIFY(PREHEAT_2_TEMP_HOTEND)
#define USER_CMD_4_ENABLE
#define USER_DESC_4 "cooling"
#define USER_GCODE_4 "M108\nM106 255"
#define USER_CMD_5_ENABLE
#define USER_DESC_5 "All home"
#define USER_GCODE_5 "G28"
#else
#define USER_DESC_1 "Home & UBL Info"
#define USER_GCODE_1 "G28\nG29W"
#define USER_DESC_2 "Preheat for " PREHEAT_1_LABEL
#define USER_GCODE_2 "M140 S" STRINGIFY(PREHEAT_1_TEMP_BED) "\nM104 S" STRINGIFY(PREHEAT_1_TEMP_HOTEND)
#define USER_DESC_3 "Preheat for " PREHEAT_2_LABEL
#define USER_GCODE_3 "M140 S" STRINGIFY(PREHEAT_2_TEMP_BED) "\nM104 S" STRINGIFY(PREHEAT_2_TEMP_HOTEND)
#define USER_DESC_4 "Heat Bed/Home/Level"
#define USER_GCODE_4 "M140 S" STRINGIFY(PREHEAT_2_TEMP_BED) "\nG28\nG29"
#define USER_DESC_5 "Home & Info"
#define USER_GCODE_5 "G28\nM503"
#endif
#endif |
The icons are always the same, the first 4 are as in the screenshot above, the rest look the same as icon 5 |
|
I've made some change in the G-Code console in that does also reenable it : #20755 |
|
I made the custom user menus code in a "marlin way", so I think it's ready to be reviewed and merged. |
|
Looks good to me. Thanks. |
This pr is no longer relevant. See 7c3121c |
|
What is the conflict you are referring to ? |
|
Thanks! |
In the draw_more.cpp file, USER_CMD_1_ENABLE (2, 3 ... 6) forgot to change to CUSTOM_USER_MENU_ITEM_1 (2, 3 ... 6)? |
Co-authored-by: Scott Lahteine <github@thinkyhead.com>
… into bugfix-2.0.x * 'bugfix-2.0.x' of https://github.com/MarlinFirmware/Marlin: (121 commits) [cron] Bump distribution date (2021-02-04) [cron] Bump distribution date (2021-02-03) Add "more" menu in LVGL interface (MarlinFirmware#20940) Evaluate ANY_SERIAL_IS in place Note (MarlinUI) limit on PREHEAT settings (MarlinFirmware#20966) Update a UBL comment (MarlinFirmware#20931) STM32 Shared Media - USB Mass Storage Device (MarlinFirmware#20956) Multi-language pertains to Color UI (MarlinFirmware#20972) Touch Calibration Screen auto-save option (MarlinFirmware#20971) Include ui_common for MARLIN_LOGO_FULL_SIZE (MarlinFirmware#20963) Fix host_response_handler compile (MarlinFirmware#20962) [cron] Bump distribution date (2021-02-02) LVGL UI G-code console (MarlinFirmware#20755) [cron] Bump distribution date (2021-02-01) Refresh screen on M22 (detach) (MarlinFirmware#20958) Fix AutoReporter implementation (MarlinFirmware#20959) Serial refactor followup (MarlinFirmware#20932) Init serial ports first (MarlinFirmware#20944) Remove extra G29 V newlines (MarlinFirmware#20955) [cron] Bump distribution date (2021-01-31) ...
Co-authored-by: Scott Lahteine <github@thinkyhead.com>
Co-authored-by: Scott Lahteine <github@thinkyhead.com>
Co-authored-by: Scott Lahteine <github@thinkyhead.com>
Co-authored-by: Scott Lahteine <github@thinkyhead.com>
Co-authored-by: Scott Lahteine <github@thinkyhead.com>
Co-authored-by: Scott Lahteine <github@thinkyhead.com>
Co-authored-by: Scott Lahteine <github@thinkyhead.com>
Description
Added "more" menu when using the interface from MKS LVGL (#define TFT_LVGL_UI in configuration.h). The menu is activated by the #define CUSTOM_USER_MENUS parameter in configuration_adv.h It is possible to add up to 7 custom commands.
Tested on MKS Robin nano v.2 with mks tft 35.