|
|
@ -789,6 +789,58 @@ void kill_screen(const char* lcd_msg) { |
|
|
|
|
|
|
|
#endif // HAS_DEBUG_MENU
|
|
|
|
|
|
|
|
#if ENABLED(CUSTOM_USER_MENUS) |
|
|
|
|
|
|
|
#ifdef USER_SCRIPT_DONE |
|
|
|
#define _DONE_SCRIPT "\n" USER_SCRIPT_DONE |
|
|
|
#else |
|
|
|
#define _DONE_SCRIPT "" |
|
|
|
#endif |
|
|
|
|
|
|
|
void _lcd_user_gcode(const char * const cmd) { |
|
|
|
lcd_return_to_status(); |
|
|
|
enqueue_and_echo_commands_P(cmd); |
|
|
|
} |
|
|
|
|
|
|
|
#if defined(USER_DESC_1) && defined(USER_GCODE_1) |
|
|
|
void lcd_user_gcode_1() { _lcd_user_gcode(PSTR(USER_GCODE_1 _DONE_SCRIPT)); } |
|
|
|
#endif |
|
|
|
#if defined(USER_DESC_2) && defined(USER_GCODE_2) |
|
|
|
void lcd_user_gcode_2() { _lcd_user_gcode(PSTR(USER_GCODE_2 _DONE_SCRIPT)); } |
|
|
|
#endif |
|
|
|
#if defined(USER_DESC_3) && defined(USER_GCODE_3) |
|
|
|
void lcd_user_gcode_3() { _lcd_user_gcode(PSTR(USER_GCODE_3 _DONE_SCRIPT)); } |
|
|
|
#endif |
|
|
|
#if defined(USER_DESC_4) && defined(USER_GCODE_4) |
|
|
|
void lcd_user_gcode_4() { _lcd_user_gcode(PSTR(USER_GCODE_4 _DONE_SCRIPT)); } |
|
|
|
#endif |
|
|
|
#if defined(USER_DESC_5) && defined(USER_GCODE_5) |
|
|
|
void lcd_user_gcode_5() { _lcd_user_gcode(PSTR(USER_GCODE_5 _DONE_SCRIPT)); } |
|
|
|
#endif |
|
|
|
|
|
|
|
void _lcd_user_menu() { |
|
|
|
START_MENU(); |
|
|
|
MENU_BACK(MSG_MAIN); |
|
|
|
#if defined(USER_DESC_1) && defined(USER_GCODE_1) |
|
|
|
MENU_ITEM(function, USER_DESC_1, lcd_user_gcode_1); |
|
|
|
#endif |
|
|
|
#if defined(USER_DESC_2) && defined(USER_GCODE_2) |
|
|
|
MENU_ITEM(function, USER_DESC_2, lcd_user_gcode_2); |
|
|
|
#endif |
|
|
|
#if defined(USER_DESC_3) && defined(USER_GCODE_3) |
|
|
|
MENU_ITEM(function, USER_DESC_3, lcd_user_gcode_3); |
|
|
|
#endif |
|
|
|
#if defined(USER_DESC_4) && defined(USER_GCODE_4) |
|
|
|
MENU_ITEM(function, USER_DESC_4, lcd_user_gcode_4); |
|
|
|
#endif |
|
|
|
#if defined(USER_DESC_5) && defined(USER_GCODE_5) |
|
|
|
MENU_ITEM(function, USER_DESC_5, lcd_user_gcode_5); |
|
|
|
#endif |
|
|
|
END_MENU(); |
|
|
|
} |
|
|
|
|
|
|
|
#endif |
|
|
|
|
|
|
|
/**
|
|
|
|
* |
|
|
|
* "Main" menu |
|
|
@ -804,6 +856,10 @@ void kill_screen(const char* lcd_msg) { |
|
|
|
START_MENU(); |
|
|
|
MENU_BACK(MSG_WATCH); |
|
|
|
|
|
|
|
#if ENABLED(CUSTOM_USER_MENUS) |
|
|
|
MENU_ITEM(submenu, MSG_USER_MENU, _lcd_user_menu); |
|
|
|
#endif |
|
|
|
|
|
|
|
//
|
|
|
|
// Debug Menu when certain options are enabled
|
|
|
|
//
|
|
|
|