|
@@ -59,7 +59,7 @@ char lcd_status_message[3 * (LCD_WIDTH) + 1] = WELCOME_MSG; // worst case is kan
|
59
|
59
|
#endif
|
60
|
60
|
|
61
|
61
|
// The main status screen
|
62
|
|
-static void lcd_status_screen();
|
|
62
|
+void lcd_status_screen();
|
63
|
63
|
|
64
|
64
|
millis_t next_lcd_update_ms;
|
65
|
65
|
|
|
@@ -111,53 +111,53 @@ uint8_t lcdDrawUpdate = LCDVIEW_CLEAR_CALL_REDRAW; // Set when the LCD needs to
|
111
|
111
|
extern bool powersupply;
|
112
|
112
|
#endif
|
113
|
113
|
const float manual_feedrate_mm_m[] = MANUAL_FEEDRATE;
|
114
|
|
- static void lcd_main_menu();
|
115
|
|
- static void lcd_tune_menu();
|
116
|
|
- static void lcd_prepare_menu();
|
117
|
|
- static void lcd_move_menu();
|
118
|
|
- static void lcd_control_menu();
|
119
|
|
- static void lcd_control_temperature_menu();
|
120
|
|
- static void lcd_control_temperature_preheat_pla_settings_menu();
|
121
|
|
- static void lcd_control_temperature_preheat_abs_settings_menu();
|
122
|
|
- static void lcd_control_motion_menu();
|
123
|
|
- static void lcd_control_volumetric_menu();
|
|
114
|
+ void lcd_main_menu();
|
|
115
|
+ void lcd_tune_menu();
|
|
116
|
+ void lcd_prepare_menu();
|
|
117
|
+ void lcd_move_menu();
|
|
118
|
+ void lcd_control_menu();
|
|
119
|
+ void lcd_control_temperature_menu();
|
|
120
|
+ void lcd_control_temperature_preheat_pla_settings_menu();
|
|
121
|
+ void lcd_control_temperature_preheat_abs_settings_menu();
|
|
122
|
+ void lcd_control_motion_menu();
|
|
123
|
+ void lcd_control_volumetric_menu();
|
124
|
124
|
|
125
|
125
|
#if ENABLED(DAC_STEPPER_CURRENT)
|
126
|
|
- static void dac_driver_commit();
|
127
|
|
- static void dac_driver_getValues();
|
128
|
|
- static void lcd_dac_menu();
|
129
|
|
- static void lcd_dac_write_eeprom();
|
|
126
|
+ void dac_driver_commit();
|
|
127
|
+ void dac_driver_getValues();
|
|
128
|
+ void lcd_dac_menu();
|
|
129
|
+ void lcd_dac_write_eeprom();
|
130
|
130
|
#endif
|
131
|
131
|
|
132
|
132
|
#if ENABLED(LCD_INFO_MENU)
|
133
|
133
|
#if ENABLED(PRINTCOUNTER)
|
134
|
|
- static void lcd_info_stats_menu();
|
|
134
|
+ void lcd_info_stats_menu();
|
135
|
135
|
#endif
|
136
|
|
- static void lcd_info_thermistors_menu();
|
137
|
|
- static void lcd_info_board_menu();
|
138
|
|
- static void lcd_info_menu();
|
|
136
|
+ void lcd_info_thermistors_menu();
|
|
137
|
+ void lcd_info_board_menu();
|
|
138
|
+ void lcd_info_menu();
|
139
|
139
|
#endif // LCD_INFO_MENU
|
140
|
140
|
|
141
|
141
|
#if ENABLED(FILAMENT_CHANGE_FEATURE)
|
142
|
|
- static void lcd_filament_change_option_menu();
|
143
|
|
- static void lcd_filament_change_init_message();
|
144
|
|
- static void lcd_filament_change_unload_message();
|
145
|
|
- static void lcd_filament_change_insert_message();
|
146
|
|
- static void lcd_filament_change_load_message();
|
147
|
|
- static void lcd_filament_change_extrude_message();
|
148
|
|
- static void lcd_filament_change_resume_message();
|
|
142
|
+ void lcd_filament_change_option_menu();
|
|
143
|
+ void lcd_filament_change_init_message();
|
|
144
|
+ void lcd_filament_change_unload_message();
|
|
145
|
+ void lcd_filament_change_insert_message();
|
|
146
|
+ void lcd_filament_change_load_message();
|
|
147
|
+ void lcd_filament_change_extrude_message();
|
|
148
|
+ void lcd_filament_change_resume_message();
|
149
|
149
|
#endif
|
150
|
150
|
|
151
|
151
|
#if HAS_LCD_CONTRAST
|
152
|
|
- static void lcd_set_contrast();
|
|
152
|
+ void lcd_set_contrast();
|
153
|
153
|
#endif
|
154
|
154
|
|
155
|
155
|
#if ENABLED(FWRETRACT)
|
156
|
|
- static void lcd_control_retract_menu();
|
|
156
|
+ void lcd_control_retract_menu();
|
157
|
157
|
#endif
|
158
|
158
|
|
159
|
159
|
#if ENABLED(DELTA_CALIBRATION_MENU)
|
160
|
|
- static void lcd_delta_calibrate_menu();
|
|
160
|
+ void lcd_delta_calibrate_menu();
|
161
|
161
|
#endif
|
162
|
162
|
|
163
|
163
|
#if ENABLED(MANUAL_BED_LEVELING)
|
|
@@ -169,35 +169,35 @@ uint8_t lcdDrawUpdate = LCDVIEW_CLEAR_CALL_REDRAW; // Set when the LCD needs to
|
169
|
169
|
|
170
|
170
|
// Different types of actions that can be used in menu items.
|
171
|
171
|
#define menu_action_back(dummy) _menu_action_back()
|
172
|
|
- static void _menu_action_back();
|
173
|
|
- static void menu_action_submenu(screenFunc_t data);
|
174
|
|
- static void menu_action_gcode(const char* pgcode);
|
175
|
|
- static void menu_action_function(screenFunc_t data);
|
176
|
|
- static void menu_action_setting_edit_bool(const char* pstr, bool* ptr);
|
177
|
|
- static void menu_action_setting_edit_int3(const char* pstr, int* ptr, int minValue, int maxValue);
|
178
|
|
- static void menu_action_setting_edit_float3(const char* pstr, float* ptr, float minValue, float maxValue);
|
179
|
|
- static void menu_action_setting_edit_float32(const char* pstr, float* ptr, float minValue, float maxValue);
|
180
|
|
- static void menu_action_setting_edit_float43(const char* pstr, float* ptr, float minValue, float maxValue);
|
181
|
|
- static void menu_action_setting_edit_float5(const char* pstr, float* ptr, float minValue, float maxValue);
|
182
|
|
- static void menu_action_setting_edit_float51(const char* pstr, float* ptr, float minValue, float maxValue);
|
183
|
|
- static void menu_action_setting_edit_float52(const char* pstr, float* ptr, float minValue, float maxValue);
|
184
|
|
- static void menu_action_setting_edit_float62(const char* pstr, float* ptr, float minValue, float maxValue);
|
185
|
|
- static void menu_action_setting_edit_long5(const char* pstr, unsigned long* ptr, unsigned long minValue, unsigned long maxValue);
|
186
|
|
- static void menu_action_setting_edit_callback_bool(const char* pstr, bool* ptr, screenFunc_t callbackFunc);
|
187
|
|
- static void menu_action_setting_edit_callback_int3(const char* pstr, int* ptr, int minValue, int maxValue, screenFunc_t callbackFunc);
|
188
|
|
- static void menu_action_setting_edit_callback_float3(const char* pstr, float* ptr, float minValue, float maxValue, screenFunc_t callbackFunc);
|
189
|
|
- static void menu_action_setting_edit_callback_float32(const char* pstr, float* ptr, float minValue, float maxValue, screenFunc_t callbackFunc);
|
190
|
|
- static void menu_action_setting_edit_callback_float43(const char* pstr, float* ptr, float minValue, float maxValue, screenFunc_t callbackFunc);
|
191
|
|
- static void menu_action_setting_edit_callback_float5(const char* pstr, float* ptr, float minValue, float maxValue, screenFunc_t callbackFunc);
|
192
|
|
- static void menu_action_setting_edit_callback_float51(const char* pstr, float* ptr, float minValue, float maxValue, screenFunc_t callbackFunc);
|
193
|
|
- static void menu_action_setting_edit_callback_float52(const char* pstr, float* ptr, float minValue, float maxValue, screenFunc_t callbackFunc);
|
194
|
|
- static void menu_action_setting_edit_callback_float62(const char* pstr, float* ptr, float minValue, float maxValue, screenFunc_t callbackFunc);
|
195
|
|
- static void menu_action_setting_edit_callback_long5(const char* pstr, unsigned long* ptr, unsigned long minValue, unsigned long maxValue, screenFunc_t callbackFunc);
|
|
172
|
+ void _menu_action_back();
|
|
173
|
+ void menu_action_submenu(screenFunc_t data);
|
|
174
|
+ void menu_action_gcode(const char* pgcode);
|
|
175
|
+ void menu_action_function(screenFunc_t data);
|
|
176
|
+ void menu_action_setting_edit_bool(const char* pstr, bool* ptr);
|
|
177
|
+ void menu_action_setting_edit_int3(const char* pstr, int* ptr, int minValue, int maxValue);
|
|
178
|
+ void menu_action_setting_edit_float3(const char* pstr, float* ptr, float minValue, float maxValue);
|
|
179
|
+ void menu_action_setting_edit_float32(const char* pstr, float* ptr, float minValue, float maxValue);
|
|
180
|
+ void menu_action_setting_edit_float43(const char* pstr, float* ptr, float minValue, float maxValue);
|
|
181
|
+ void menu_action_setting_edit_float5(const char* pstr, float* ptr, float minValue, float maxValue);
|
|
182
|
+ void menu_action_setting_edit_float51(const char* pstr, float* ptr, float minValue, float maxValue);
|
|
183
|
+ void menu_action_setting_edit_float52(const char* pstr, float* ptr, float minValue, float maxValue);
|
|
184
|
+ void menu_action_setting_edit_float62(const char* pstr, float* ptr, float minValue, float maxValue);
|
|
185
|
+ void menu_action_setting_edit_long5(const char* pstr, unsigned long* ptr, unsigned long minValue, unsigned long maxValue);
|
|
186
|
+ void menu_action_setting_edit_callback_bool(const char* pstr, bool* ptr, screenFunc_t callbackFunc);
|
|
187
|
+ void menu_action_setting_edit_callback_int3(const char* pstr, int* ptr, int minValue, int maxValue, screenFunc_t callbackFunc);
|
|
188
|
+ void menu_action_setting_edit_callback_float3(const char* pstr, float* ptr, float minValue, float maxValue, screenFunc_t callbackFunc);
|
|
189
|
+ void menu_action_setting_edit_callback_float32(const char* pstr, float* ptr, float minValue, float maxValue, screenFunc_t callbackFunc);
|
|
190
|
+ void menu_action_setting_edit_callback_float43(const char* pstr, float* ptr, float minValue, float maxValue, screenFunc_t callbackFunc);
|
|
191
|
+ void menu_action_setting_edit_callback_float5(const char* pstr, float* ptr, float minValue, float maxValue, screenFunc_t callbackFunc);
|
|
192
|
+ void menu_action_setting_edit_callback_float51(const char* pstr, float* ptr, float minValue, float maxValue, screenFunc_t callbackFunc);
|
|
193
|
+ void menu_action_setting_edit_callback_float52(const char* pstr, float* ptr, float minValue, float maxValue, screenFunc_t callbackFunc);
|
|
194
|
+ void menu_action_setting_edit_callback_float62(const char* pstr, float* ptr, float minValue, float maxValue, screenFunc_t callbackFunc);
|
|
195
|
+ void menu_action_setting_edit_callback_long5(const char* pstr, unsigned long* ptr, unsigned long minValue, unsigned long maxValue, screenFunc_t callbackFunc);
|
196
|
196
|
|
197
|
197
|
#if ENABLED(SDSUPPORT)
|
198
|
|
- static void lcd_sdcard_menu();
|
199
|
|
- static void menu_action_sdfile(const char* filename, char* longFilename);
|
200
|
|
- static void menu_action_sddirectory(const char* filename, char* longFilename);
|
|
198
|
+ void lcd_sdcard_menu();
|
|
199
|
+ void menu_action_sdfile(const char* filename, char* longFilename);
|
|
200
|
+ void menu_action_sddirectory(const char* filename, char* longFilename);
|
201
|
201
|
#endif
|
202
|
202
|
|
203
|
203
|
/* Helper macros for menus */
|
|
@@ -391,7 +391,7 @@ uint8_t lcdDrawUpdate = LCDVIEW_CLEAR_CALL_REDRAW; // Set when the LCD needs to
|
391
|
391
|
/**
|
392
|
392
|
* General function to go directly to a screen
|
393
|
393
|
*/
|
394
|
|
- static void lcd_goto_screen(screenFunc_t screen, const uint32_t encoder = 0) {
|
|
394
|
+ void lcd_goto_screen(screenFunc_t screen, const uint32_t encoder = 0) {
|
395
|
395
|
if (currentScreen != screen) {
|
396
|
396
|
currentScreen = screen;
|
397
|
397
|
encoderPosition = encoder;
|
|
@@ -408,7 +408,7 @@ uint8_t lcdDrawUpdate = LCDVIEW_CLEAR_CALL_REDRAW; // Set when the LCD needs to
|
408
|
408
|
}
|
409
|
409
|
}
|
410
|
410
|
|
411
|
|
- static void lcd_return_to_status() { lcd_goto_screen(lcd_status_screen); }
|
|
411
|
+ void lcd_return_to_status() { lcd_goto_screen(lcd_status_screen); }
|
412
|
412
|
|
413
|
413
|
inline void lcd_save_previous_menu() {
|
414
|
414
|
if (screen_history_depth < COUNT(screen_history)) {
|
|
@@ -418,7 +418,7 @@ uint8_t lcdDrawUpdate = LCDVIEW_CLEAR_CALL_REDRAW; // Set when the LCD needs to
|
418
|
418
|
}
|
419
|
419
|
}
|
420
|
420
|
|
421
|
|
- static void lcd_goto_previous_menu() {
|
|
421
|
+ void lcd_goto_previous_menu() {
|
422
|
422
|
if (screen_history_depth > 0) {
|
423
|
423
|
--screen_history_depth;
|
424
|
424
|
lcd_goto_screen(
|
|
@@ -439,7 +439,7 @@ uint8_t lcdDrawUpdate = LCDVIEW_CLEAR_CALL_REDRAW; // Set when the LCD needs to
|
439
|
439
|
* This is very display-dependent, so the lcd implementation draws this.
|
440
|
440
|
*/
|
441
|
441
|
|
442
|
|
-static void lcd_status_screen() {
|
|
442
|
+void lcd_status_screen() {
|
443
|
443
|
|
444
|
444
|
#if ENABLED(ULTIPANEL)
|
445
|
445
|
ENCODER_DIRECTION_NORMAL();
|
|
@@ -549,17 +549,17 @@ void kill_screen(const char* lcd_msg) {
|
549
|
549
|
|
550
|
550
|
#if ENABLED(SDSUPPORT)
|
551
|
551
|
|
552
|
|
- static void lcd_sdcard_pause() {
|
|
552
|
+ void lcd_sdcard_pause() {
|
553
|
553
|
card.pauseSDPrint();
|
554
|
554
|
print_job_timer.pause();
|
555
|
555
|
}
|
556
|
556
|
|
557
|
|
- static void lcd_sdcard_resume() {
|
|
557
|
+ void lcd_sdcard_resume() {
|
558
|
558
|
card.startFileprint();
|
559
|
559
|
print_job_timer.start();
|
560
|
560
|
}
|
561
|
561
|
|
562
|
|
- static void lcd_sdcard_stop() {
|
|
562
|
+ void lcd_sdcard_stop() {
|
563
|
563
|
card.stopSDPrint();
|
564
|
564
|
clear_command_queue();
|
565
|
565
|
quickstop_stepper();
|
|
@@ -579,7 +579,7 @@ void kill_screen(const char* lcd_msg) {
|
579
|
579
|
*
|
580
|
580
|
*/
|
581
|
581
|
|
582
|
|
- static void lcd_main_menu() {
|
|
582
|
+ void lcd_main_menu() {
|
583
|
583
|
START_MENU();
|
584
|
584
|
MENU_BACK(MSG_WATCH);
|
585
|
585
|
|
|
@@ -649,7 +649,7 @@ void kill_screen(const char* lcd_msg) {
|
649
|
649
|
|
650
|
650
|
long babysteps_done = 0;
|
651
|
651
|
|
652
|
|
- static void _lcd_babystep(const AxisEnum axis, const char* msg) {
|
|
652
|
+ void _lcd_babystep(const AxisEnum axis, const char* msg) {
|
653
|
653
|
if (lcd_clicked) { defer_return_to_status = false; return lcd_goto_previous_menu(); }
|
654
|
654
|
ENCODER_DIRECTION_NORMAL();
|
655
|
655
|
if (encoderPosition) {
|
|
@@ -666,13 +666,13 @@ void kill_screen(const char* lcd_msg) {
|
666
|
666
|
}
|
667
|
667
|
|
668
|
668
|
#if ENABLED(BABYSTEP_XY)
|
669
|
|
- static void _lcd_babystep_x() { _lcd_babystep(X_AXIS, PSTR(MSG_BABYSTEPPING_X)); }
|
670
|
|
- static void _lcd_babystep_y() { _lcd_babystep(Y_AXIS, PSTR(MSG_BABYSTEPPING_Y)); }
|
671
|
|
- static void lcd_babystep_x() { lcd_goto_screen(_lcd_babystep_x); babysteps_done = 0; defer_return_to_status = true; }
|
672
|
|
- static void lcd_babystep_y() { lcd_goto_screen(_lcd_babystep_y); babysteps_done = 0; defer_return_to_status = true; }
|
|
669
|
+ void _lcd_babystep_x() { _lcd_babystep(X_AXIS, PSTR(MSG_BABYSTEPPING_X)); }
|
|
670
|
+ void _lcd_babystep_y() { _lcd_babystep(Y_AXIS, PSTR(MSG_BABYSTEPPING_Y)); }
|
|
671
|
+ void lcd_babystep_x() { lcd_goto_screen(_lcd_babystep_x); babysteps_done = 0; defer_return_to_status = true; }
|
|
672
|
+ void lcd_babystep_y() { lcd_goto_screen(_lcd_babystep_y); babysteps_done = 0; defer_return_to_status = true; }
|
673
|
673
|
#endif
|
674
|
|
- static void _lcd_babystep_z() { _lcd_babystep(Z_AXIS, PSTR(MSG_BABYSTEPPING_Z)); }
|
675
|
|
- static void lcd_babystep_z() { lcd_goto_screen(_lcd_babystep_z); babysteps_done = 0; defer_return_to_status = true; }
|
|
674
|
+ void _lcd_babystep_z() { _lcd_babystep(Z_AXIS, PSTR(MSG_BABYSTEPPING_Z)); }
|
|
675
|
+ void lcd_babystep_z() { lcd_goto_screen(_lcd_babystep_z); babysteps_done = 0; defer_return_to_status = true; }
|
676
|
676
|
|
677
|
677
|
#endif //BABYSTEPPING
|
678
|
678
|
|
|
@@ -718,7 +718,7 @@ void kill_screen(const char* lcd_msg) {
|
718
|
718
|
#endif
|
719
|
719
|
|
720
|
720
|
#if ENABLED(FILAMENT_CHANGE_FEATURE)
|
721
|
|
- static void lcd_enqueue_filament_change() {
|
|
721
|
+ void lcd_enqueue_filament_change() {
|
722
|
722
|
lcd_filament_change_show_message(FILAMENT_CHANGE_MESSAGE_INIT);
|
723
|
723
|
enqueue_and_echo_commands_P(PSTR("M600"));
|
724
|
724
|
}
|
|
@@ -729,7 +729,7 @@ void kill_screen(const char* lcd_msg) {
|
729
|
729
|
* "Tune" submenu
|
730
|
730
|
*
|
731
|
731
|
*/
|
732
|
|
- static void lcd_tune_menu() {
|
|
732
|
+ void lcd_tune_menu() {
|
733
|
733
|
START_MENU();
|
734
|
734
|
|
735
|
735
|
//
|
|
@@ -851,13 +851,13 @@ void kill_screen(const char* lcd_msg) {
|
851
|
851
|
*
|
852
|
852
|
*/
|
853
|
853
|
#if ENABLED(DAC_STEPPER_CURRENT)
|
854
|
|
- static void dac_driver_getValues() { LOOP_XYZE(i) driverPercent[i] = dac_current_get_percent((AxisEnum)i); }
|
|
854
|
+ void dac_driver_getValues() { LOOP_XYZE(i) driverPercent[i] = dac_current_get_percent((AxisEnum)i); }
|
855
|
855
|
|
856
|
|
- static void dac_driver_commit() { dac_current_set_percents(driverPercent); }
|
|
856
|
+ void dac_driver_commit() { dac_current_set_percents(driverPercent); }
|
857
|
857
|
|
858
|
|
- static void dac_driver_eeprom_write() { dac_commit_eeprom(); }
|
|
858
|
+ void dac_driver_eeprom_write() { dac_commit_eeprom(); }
|
859
|
859
|
|
860
|
|
- static void lcd_dac_menu() {
|
|
860
|
+ void lcd_dac_menu() {
|
861
|
861
|
dac_driver_getValues();
|
862
|
862
|
START_MENU();
|
863
|
863
|
MENU_BACK(MSG_CONTROL);
|
|
@@ -945,7 +945,7 @@ void kill_screen(const char* lcd_msg) {
|
945
|
945
|
|
946
|
946
|
#if TEMP_SENSOR_0 != 0 && (TEMP_SENSOR_1 != 0 || TEMP_SENSOR_2 != 0 || TEMP_SENSOR_3 != 0 || TEMP_SENSOR_BED != 0)
|
947
|
947
|
|
948
|
|
- static void lcd_preheat_pla_menu() {
|
|
948
|
+ void lcd_preheat_pla_menu() {
|
949
|
949
|
START_MENU();
|
950
|
950
|
MENU_BACK(MSG_PREPARE);
|
951
|
951
|
#if HOTENDS == 1
|
|
@@ -967,7 +967,7 @@ void kill_screen(const char* lcd_msg) {
|
967
|
967
|
END_MENU();
|
968
|
968
|
}
|
969
|
969
|
|
970
|
|
- static void lcd_preheat_abs_menu() {
|
|
970
|
+ void lcd_preheat_abs_menu() {
|
971
|
971
|
START_MENU();
|
972
|
972
|
MENU_BACK(MSG_PREPARE);
|
973
|
973
|
#if HOTENDS == 1
|
|
@@ -1001,7 +1001,7 @@ void kill_screen(const char* lcd_msg) {
|
1001
|
1001
|
|
1002
|
1002
|
#if ENABLED(SDSUPPORT) && ENABLED(MENU_ADDAUTOSTART)
|
1003
|
1003
|
|
1004
|
|
- static void lcd_autostart_sd() {
|
|
1004
|
+ void lcd_autostart_sd() {
|
1005
|
1005
|
card.autostart_index = 0;
|
1006
|
1006
|
card.setroot();
|
1007
|
1007
|
card.checkautostart(true);
|
|
@@ -1036,9 +1036,9 @@ void kill_screen(const char* lcd_msg) {
|
1036
|
1036
|
stepper.synchronize();
|
1037
|
1037
|
}
|
1038
|
1038
|
|
1039
|
|
- static void _lcd_level_goto_next_point();
|
|
1039
|
+ void _lcd_level_goto_next_point();
|
1040
|
1040
|
|
1041
|
|
- static void _lcd_level_bed_done() {
|
|
1041
|
+ void _lcd_level_bed_done() {
|
1042
|
1042
|
if (lcdDrawUpdate) lcd_implementation_drawedit(PSTR(MSG_LEVEL_BED_DONE));
|
1043
|
1043
|
lcdDrawUpdate =
|
1044
|
1044
|
#if ENABLED(DOGLCD)
|
|
@@ -1052,7 +1052,7 @@ void kill_screen(const char* lcd_msg) {
|
1052
|
1052
|
/**
|
1053
|
1053
|
* Step 7: Get the Z coordinate, then goto next point or exit
|
1054
|
1054
|
*/
|
1055
|
|
- static void _lcd_level_bed_get_z() {
|
|
1055
|
+ void _lcd_level_bed_get_z() {
|
1056
|
1056
|
ENCODER_DIRECTION_NORMAL();
|
1057
|
1057
|
|
1058
|
1058
|
// Encoder wheel adjusts the Z position
|
|
@@ -1114,7 +1114,7 @@ void kill_screen(const char* lcd_msg) {
|
1114
|
1114
|
/**
|
1115
|
1115
|
* Step 6: Display "Next point: 1 / 9" while waiting for move to finish
|
1116
|
1116
|
*/
|
1117
|
|
- static void _lcd_level_bed_moving() {
|
|
1117
|
+ void _lcd_level_bed_moving() {
|
1118
|
1118
|
if (lcdDrawUpdate) {
|
1119
|
1119
|
char msg[10];
|
1120
|
1120
|
sprintf_P(msg, PSTR("%i / %u"), (int)(_lcd_level_bed_position + 1), (MESH_NUM_X_POINTS) * (MESH_NUM_Y_POINTS));
|
|
@@ -1133,7 +1133,7 @@ void kill_screen(const char* lcd_msg) {
|
1133
|
1133
|
/**
|
1134
|
1134
|
* Step 5: Initiate a move to the next point
|
1135
|
1135
|
*/
|
1136
|
|
- static void _lcd_level_goto_next_point() {
|
|
1136
|
+ void _lcd_level_goto_next_point() {
|
1137
|
1137
|
// Set the menu to display ahead of blocking call
|
1138
|
1138
|
lcd_goto_screen(_lcd_level_bed_moving);
|
1139
|
1139
|
|
|
@@ -1150,7 +1150,7 @@ void kill_screen(const char* lcd_msg) {
|
1150
|
1150
|
* Step 4: Display "Click to Begin", wait for click
|
1151
|
1151
|
* Move to the first probe position
|
1152
|
1152
|
*/
|
1153
|
|
- static void _lcd_level_bed_homing_done() {
|
|
1153
|
+ void _lcd_level_bed_homing_done() {
|
1154
|
1154
|
if (lcdDrawUpdate) lcd_implementation_drawedit(PSTR(MSG_LEVEL_BED_WAITING));
|
1155
|
1155
|
if (lcd_clicked) {
|
1156
|
1156
|
_lcd_level_bed_position = 0;
|
|
@@ -1167,7 +1167,7 @@ void kill_screen(const char* lcd_msg) {
|
1167
|
1167
|
/**
|
1168
|
1168
|
* Step 3: Display "Homing XYZ" - Wait for homing to finish
|
1169
|
1169
|
*/
|
1170
|
|
- static void _lcd_level_bed_homing() {
|
|
1170
|
+ void _lcd_level_bed_homing() {
|
1171
|
1171
|
if (lcdDrawUpdate) lcd_implementation_drawedit(PSTR(MSG_LEVEL_BED_HOMING), NULL);
|
1172
|
1172
|
lcdDrawUpdate =
|
1173
|
1173
|
#if ENABLED(DOGLCD)
|
|
@@ -1183,7 +1183,7 @@ void kill_screen(const char* lcd_msg) {
|
1183
|
1183
|
/**
|
1184
|
1184
|
* Step 2: Continue Bed Leveling...
|
1185
|
1185
|
*/
|
1186
|
|
- static void _lcd_level_bed_continue() {
|
|
1186
|
+ void _lcd_level_bed_continue() {
|
1187
|
1187
|
defer_return_to_status = true;
|
1188
|
1188
|
axis_homed[X_AXIS] = axis_homed[Y_AXIS] = axis_homed[Z_AXIS] = false;
|
1189
|
1189
|
mbl.reset();
|
|
@@ -1194,7 +1194,7 @@ void kill_screen(const char* lcd_msg) {
|
1194
|
1194
|
/**
|
1195
|
1195
|
* Step 1: MBL entry-point: "Cancel" or "Level Bed"
|
1196
|
1196
|
*/
|
1197
|
|
- static void lcd_level_bed() {
|
|
1197
|
+ void lcd_level_bed() {
|
1198
|
1198
|
START_MENU();
|
1199
|
1199
|
MENU_BACK(MSG_LEVEL_BED_CANCEL);
|
1200
|
1200
|
MENU_ITEM(submenu, MSG_LEVEL_BED, _lcd_level_bed_continue);
|
|
@@ -1209,7 +1209,7 @@ void kill_screen(const char* lcd_msg) {
|
1209
|
1209
|
*
|
1210
|
1210
|
*/
|
1211
|
1211
|
|
1212
|
|
- static void lcd_prepare_menu() {
|
|
1212
|
+ void lcd_prepare_menu() {
|
1213
|
1213
|
START_MENU();
|
1214
|
1214
|
|
1215
|
1215
|
//
|
|
@@ -1304,7 +1304,7 @@ void kill_screen(const char* lcd_msg) {
|
1304
|
1304
|
|
1305
|
1305
|
#if ENABLED(DELTA_CALIBRATION_MENU)
|
1306
|
1306
|
|
1307
|
|
- static void _goto_tower_pos(const float &a) {
|
|
1307
|
+ void _goto_tower_pos(const float &a) {
|
1308
|
1308
|
do_blocking_move_to(
|
1309
|
1309
|
a < 0 ? X_HOME_POS : sin(a) * -(DELTA_PRINTABLE_RADIUS),
|
1310
|
1310
|
a < 0 ? Y_HOME_POS : cos(a) * (DELTA_PRINTABLE_RADIUS),
|
|
@@ -1312,12 +1312,12 @@ void kill_screen(const char* lcd_msg) {
|
1312
|
1312
|
);
|
1313
|
1313
|
}
|
1314
|
1314
|
|
1315
|
|
- static void _goto_tower_x() { _goto_tower_pos(RADIANS(120)); }
|
1316
|
|
- static void _goto_tower_y() { _goto_tower_pos(RADIANS(240)); }
|
1317
|
|
- static void _goto_tower_z() { _goto_tower_pos(0); }
|
1318
|
|
- static void _goto_center() { _goto_tower_pos(-1); }
|
|
1315
|
+ void _goto_tower_x() { _goto_tower_pos(RADIANS(120)); }
|
|
1316
|
+ void _goto_tower_y() { _goto_tower_pos(RADIANS(240)); }
|
|
1317
|
+ void _goto_tower_z() { _goto_tower_pos(0); }
|
|
1318
|
+ void _goto_center() { _goto_tower_pos(-1); }
|
1319
|
1319
|
|
1320
|
|
- static void lcd_delta_calibrate_menu() {
|
|
1320
|
+ void lcd_delta_calibrate_menu() {
|
1321
|
1321
|
START_MENU();
|
1322
|
1322
|
MENU_BACK(MSG_MAIN);
|
1323
|
1323
|
MENU_ITEM(gcode, MSG_AUTO_HOME, PSTR("G28"));
|
|
@@ -1365,7 +1365,7 @@ void kill_screen(const char* lcd_msg) {
|
1365
|
1365
|
*
|
1366
|
1366
|
*/
|
1367
|
1367
|
|
1368
|
|
- static void _lcd_move_xyz(const char* name, AxisEnum axis) {
|
|
1368
|
+ void _lcd_move_xyz(const char* name, AxisEnum axis) {
|
1369
|
1369
|
if (lcd_clicked) { return lcd_goto_previous_menu(); }
|
1370
|
1370
|
ENCODER_DIRECTION_NORMAL();
|
1371
|
1371
|
if (encoderPosition) {
|
|
@@ -1398,10 +1398,10 @@ void kill_screen(const char* lcd_msg) {
|
1398
|
1398
|
}
|
1399
|
1399
|
if (lcdDrawUpdate) lcd_implementation_drawedit(name, ftostr41sign(current_position[axis]));
|
1400
|
1400
|
}
|
1401
|
|
- static void lcd_move_x() { _lcd_move_xyz(PSTR(MSG_MOVE_X), X_AXIS); }
|
1402
|
|
- static void lcd_move_y() { _lcd_move_xyz(PSTR(MSG_MOVE_Y), Y_AXIS); }
|
1403
|
|
- static void lcd_move_z() { _lcd_move_xyz(PSTR(MSG_MOVE_Z), Z_AXIS); }
|
1404
|
|
- static void _lcd_move_e(
|
|
1401
|
+ void lcd_move_x() { _lcd_move_xyz(PSTR(MSG_MOVE_X), X_AXIS); }
|
|
1402
|
+ void lcd_move_y() { _lcd_move_xyz(PSTR(MSG_MOVE_Y), Y_AXIS); }
|
|
1403
|
+ void lcd_move_z() { _lcd_move_xyz(PSTR(MSG_MOVE_Z), Z_AXIS); }
|
|
1404
|
+ void _lcd_move_e(
|
1405
|
1405
|
#if E_MANUAL > 1
|
1406
|
1406
|
int8_t eindex=-1
|
1407
|
1407
|
#endif
|
|
@@ -1438,14 +1438,14 @@ void kill_screen(const char* lcd_msg) {
|
1438
|
1438
|
}
|
1439
|
1439
|
}
|
1440
|
1440
|
|
1441
|
|
- static void lcd_move_e() { _lcd_move_e(); }
|
|
1441
|
+ void lcd_move_e() { _lcd_move_e(); }
|
1442
|
1442
|
#if E_MANUAL > 1
|
1443
|
|
- static void lcd_move_e0() { _lcd_move_e(0); }
|
1444
|
|
- static void lcd_move_e1() { _lcd_move_e(1); }
|
|
1443
|
+ void lcd_move_e0() { _lcd_move_e(0); }
|
|
1444
|
+ void lcd_move_e1() { _lcd_move_e(1); }
|
1445
|
1445
|
#if E_MANUAL > 2
|
1446
|
|
- static void lcd_move_e2() { _lcd_move_e(2); }
|
|
1446
|
+ void lcd_move_e2() { _lcd_move_e(2); }
|
1447
|
1447
|
#if E_MANUAL > 3
|
1448
|
|
- static void lcd_move_e3() { _lcd_move_e(3); }
|
|
1448
|
+ void lcd_move_e3() { _lcd_move_e(3); }
|
1449
|
1449
|
#endif
|
1450
|
1450
|
#endif
|
1451
|
1451
|
#endif
|
|
@@ -1462,7 +1462,7 @@ void kill_screen(const char* lcd_msg) {
|
1462
|
1462
|
#define _MOVE_XYZ_ALLOWED true
|
1463
|
1463
|
#endif
|
1464
|
1464
|
|
1465
|
|
- static void _lcd_move_menu_axis() {
|
|
1465
|
+ void _lcd_move_menu_axis() {
|
1466
|
1466
|
START_MENU();
|
1467
|
1467
|
MENU_BACK(MSG_MOVE_AXIS);
|
1468
|
1468
|
|
|
@@ -1496,15 +1496,15 @@ void kill_screen(const char* lcd_msg) {
|
1496
|
1496
|
END_MENU();
|
1497
|
1497
|
}
|
1498
|
1498
|
|
1499
|
|
- static void lcd_move_menu_10mm() {
|
|
1499
|
+ void lcd_move_menu_10mm() {
|
1500
|
1500
|
move_menu_scale = 10.0;
|
1501
|
1501
|
_lcd_move_menu_axis();
|
1502
|
1502
|
}
|
1503
|
|
- static void lcd_move_menu_1mm() {
|
|
1503
|
+ void lcd_move_menu_1mm() {
|
1504
|
1504
|
move_menu_scale = 1.0;
|
1505
|
1505
|
_lcd_move_menu_axis();
|
1506
|
1506
|
}
|
1507
|
|
- static void lcd_move_menu_01mm() {
|
|
1507
|
+ void lcd_move_menu_01mm() {
|
1508
|
1508
|
move_menu_scale = 0.1;
|
1509
|
1509
|
_lcd_move_menu_axis();
|
1510
|
1510
|
}
|
|
@@ -1515,7 +1515,7 @@ void kill_screen(const char* lcd_msg) {
|
1515
|
1515
|
*
|
1516
|
1516
|
*/
|
1517
|
1517
|
|
1518
|
|
- static void lcd_move_menu() {
|
|
1518
|
+ void lcd_move_menu() {
|
1519
|
1519
|
START_MENU();
|
1520
|
1520
|
MENU_BACK(MSG_PREPARE);
|
1521
|
1521
|
|
|
@@ -1534,7 +1534,7 @@ void kill_screen(const char* lcd_msg) {
|
1534
|
1534
|
*
|
1535
|
1535
|
*/
|
1536
|
1536
|
|
1537
|
|
- static void lcd_control_menu() {
|
|
1537
|
+ void lcd_control_menu() {
|
1538
|
1538
|
START_MENU();
|
1539
|
1539
|
MENU_BACK(MSG_MAIN);
|
1540
|
1540
|
MENU_ITEM(submenu, MSG_TEMPERATURE, lcd_control_temperature_menu);
|
|
@@ -1577,7 +1577,7 @@ void kill_screen(const char* lcd_msg) {
|
1577
|
1577
|
int autotune_temp_bed = 70;
|
1578
|
1578
|
#endif
|
1579
|
1579
|
|
1580
|
|
- static void _lcd_autotune(int e) {
|
|
1580
|
+ void _lcd_autotune(int e) {
|
1581
|
1581
|
char cmd[30];
|
1582
|
1582
|
sprintf_P(cmd, PSTR("M303 U1 E%i S%i"), e,
|
1583
|
1583
|
#if HAS_PID_FOR_BOTH
|
|
@@ -1643,7 +1643,7 @@ void kill_screen(const char* lcd_msg) {
|
1643
|
1643
|
* "Control" > "Temperature" submenu
|
1644
|
1644
|
*
|
1645
|
1645
|
*/
|
1646
|
|
- static void lcd_control_temperature_menu() {
|
|
1646
|
+ void lcd_control_temperature_menu() {
|
1647
|
1647
|
START_MENU();
|
1648
|
1648
|
|
1649
|
1649
|
//
|
|
@@ -1774,7 +1774,7 @@ void kill_screen(const char* lcd_msg) {
|
1774
|
1774
|
END_MENU();
|
1775
|
1775
|
}
|
1776
|
1776
|
|
1777
|
|
- static void _lcd_control_temperature_preheat_settings_menu(uint8_t material) {
|
|
1777
|
+ void _lcd_control_temperature_preheat_settings_menu(uint8_t material) {
|
1778
|
1778
|
START_MENU();
|
1779
|
1779
|
MENU_BACK(MSG_TEMPERATURE);
|
1780
|
1780
|
MENU_ITEM_EDIT(int3, MSG_FAN_SPEED, &lcd_preheat_fan_speed[material], 0, 255);
|
|
@@ -1795,24 +1795,24 @@ void kill_screen(const char* lcd_msg) {
|
1795
|
1795
|
* "Temperature" > "Preheat PLA conf" submenu
|
1796
|
1796
|
*
|
1797
|
1797
|
*/
|
1798
|
|
- static void lcd_control_temperature_preheat_pla_settings_menu() { _lcd_control_temperature_preheat_settings_menu(0); }
|
|
1798
|
+ void lcd_control_temperature_preheat_pla_settings_menu() { _lcd_control_temperature_preheat_settings_menu(0); }
|
1799
|
1799
|
|
1800
|
1800
|
/**
|
1801
|
1801
|
*
|
1802
|
1802
|
* "Temperature" > "Preheat ABS conf" submenu
|
1803
|
1803
|
*
|
1804
|
1804
|
*/
|
1805
|
|
- static void lcd_control_temperature_preheat_abs_settings_menu() { _lcd_control_temperature_preheat_settings_menu(1); }
|
|
1805
|
+ void lcd_control_temperature_preheat_abs_settings_menu() { _lcd_control_temperature_preheat_settings_menu(1); }
|
1806
|
1806
|
|
1807
|
|
- static void _reset_acceleration_rates() { planner.reset_acceleration_rates(); }
|
1808
|
|
- static void _planner_refresh_positioning() { planner.refresh_positioning(); }
|
|
1807
|
+ void _reset_acceleration_rates() { planner.reset_acceleration_rates(); }
|
|
1808
|
+ void _planner_refresh_positioning() { planner.refresh_positioning(); }
|
1809
|
1809
|
|
1810
|
1810
|
/**
|
1811
|
1811
|
*
|
1812
|
1812
|
* "Control" > "Motion" submenu
|
1813
|
1813
|
*
|
1814
|
1814
|
*/
|
1815
|
|
- static void lcd_control_motion_menu() {
|
|
1815
|
+ void lcd_control_motion_menu() {
|
1816
|
1816
|
START_MENU();
|
1817
|
1817
|
MENU_BACK(MSG_CONTROL);
|
1818
|
1818
|
#if HAS_BED_PROBE
|
|
@@ -1858,7 +1858,7 @@ void kill_screen(const char* lcd_msg) {
|
1858
|
1858
|
* "Control" > "Filament" submenu
|
1859
|
1859
|
*
|
1860
|
1860
|
*/
|
1861
|
|
- static void lcd_control_volumetric_menu() {
|
|
1861
|
+ void lcd_control_volumetric_menu() {
|
1862
|
1862
|
START_MENU();
|
1863
|
1863
|
MENU_BACK(MSG_CONTROL);
|
1864
|
1864
|
|
|
@@ -1888,7 +1888,7 @@ void kill_screen(const char* lcd_msg) {
|
1888
|
1888
|
*
|
1889
|
1889
|
*/
|
1890
|
1890
|
#if HAS_LCD_CONTRAST
|
1891
|
|
- static void lcd_set_contrast() {
|
|
1891
|
+ void lcd_set_contrast() {
|
1892
|
1892
|
if (lcd_clicked) { return lcd_goto_previous_menu(); }
|
1893
|
1893
|
ENCODER_DIRECTION_NORMAL();
|
1894
|
1894
|
if (encoderPosition) {
|
|
@@ -1915,7 +1915,7 @@ void kill_screen(const char* lcd_msg) {
|
1915
|
1915
|
*/
|
1916
|
1916
|
#if ENABLED(FWRETRACT)
|
1917
|
1917
|
|
1918
|
|
- static void lcd_control_retract_menu() {
|
|
1918
|
+ void lcd_control_retract_menu() {
|
1919
|
1919
|
START_MENU();
|
1920
|
1920
|
MENU_BACK(MSG_CONTROL);
|
1921
|
1921
|
MENU_ITEM_EDIT(bool, MSG_AUTORETRACT, &autoretract_enabled);
|
|
@@ -1938,13 +1938,13 @@ void kill_screen(const char* lcd_msg) {
|
1938
|
1938
|
#if ENABLED(SDSUPPORT)
|
1939
|
1939
|
|
1940
|
1940
|
#if !PIN_EXISTS(SD_DETECT)
|
1941
|
|
- static void lcd_sd_refresh() {
|
|
1941
|
+ void lcd_sd_refresh() {
|
1942
|
1942
|
card.initsd();
|
1943
|
1943
|
encoderTopLine = 0;
|
1944
|
1944
|
}
|
1945
|
1945
|
#endif
|
1946
|
1946
|
|
1947
|
|
- static void lcd_sd_updir() {
|
|
1947
|
+ void lcd_sd_updir() {
|
1948
|
1948
|
card.updir();
|
1949
|
1949
|
encoderTopLine = 0;
|
1950
|
1950
|
}
|
|
@@ -2001,7 +2001,7 @@ void kill_screen(const char* lcd_msg) {
|
2001
|
2001
|
* About Printer > Statistics submenu
|
2002
|
2002
|
*
|
2003
|
2003
|
*/
|
2004
|
|
- static void lcd_info_stats_menu() {
|
|
2004
|
+ void lcd_info_stats_menu() {
|
2005
|
2005
|
if (lcd_clicked) { return lcd_goto_previous_menu(); }
|
2006
|
2006
|
|
2007
|
2007
|
char buffer[21];
|
|
@@ -2035,7 +2035,7 @@ void kill_screen(const char* lcd_msg) {
|
2035
|
2035
|
* About Printer > Thermistors
|
2036
|
2036
|
*
|
2037
|
2037
|
*/
|
2038
|
|
- static void lcd_info_thermistors_menu() {
|
|
2038
|
+ void lcd_info_thermistors_menu() {
|
2039
|
2039
|
if (lcd_clicked) { return lcd_goto_previous_menu(); }
|
2040
|
2040
|
START_SCREEN();
|
2041
|
2041
|
#define THERMISTOR_ID TEMP_SENSOR_0
|
|
@@ -2087,7 +2087,7 @@ void kill_screen(const char* lcd_msg) {
|
2087
|
2087
|
* About Printer > Board Info
|
2088
|
2088
|
*
|
2089
|
2089
|
*/
|
2090
|
|
- static void lcd_info_board_menu() {
|
|
2090
|
+ void lcd_info_board_menu() {
|
2091
|
2091
|
if (lcd_clicked) { return lcd_goto_previous_menu(); }
|
2092
|
2092
|
START_SCREEN();
|
2093
|
2093
|
STATIC_ITEM(BOARD_NAME, true, true); // MyPrinterController
|
|
@@ -2108,7 +2108,7 @@ void kill_screen(const char* lcd_msg) {
|
2108
|
2108
|
* About Printer > Printer Info
|
2109
|
2109
|
*
|
2110
|
2110
|
*/
|
2111
|
|
- static void lcd_info_printer_menu() {
|
|
2111
|
+ void lcd_info_printer_menu() {
|
2112
|
2112
|
if (lcd_clicked) { return lcd_goto_previous_menu(); }
|
2113
|
2113
|
START_SCREEN();
|
2114
|
2114
|
STATIC_ITEM(MSG_MARLIN, true, true); // Marlin
|
|
@@ -2125,7 +2125,7 @@ void kill_screen(const char* lcd_msg) {
|
2125
|
2125
|
* "About Printer" submenu
|
2126
|
2126
|
*
|
2127
|
2127
|
*/
|
2128
|
|
- static void lcd_info_menu() {
|
|
2128
|
+ void lcd_info_menu() {
|
2129
|
2129
|
START_MENU();
|
2130
|
2130
|
MENU_BACK(MSG_MAIN);
|
2131
|
2131
|
MENU_ITEM(submenu, MSG_INFO_PRINTER_MENU, lcd_info_printer_menu); // Printer Info >
|
|
@@ -2140,16 +2140,16 @@ void kill_screen(const char* lcd_msg) {
|
2140
|
2140
|
|
2141
|
2141
|
#if ENABLED(FILAMENT_CHANGE_FEATURE)
|
2142
|
2142
|
|
2143
|
|
- static void lcd_filament_change_resume_print() {
|
|
2143
|
+ void lcd_filament_change_resume_print() {
|
2144
|
2144
|
filament_change_menu_response = FILAMENT_CHANGE_RESPONSE_RESUME_PRINT;
|
2145
|
2145
|
lcd_goto_screen(lcd_status_screen);
|
2146
|
2146
|
}
|
2147
|
2147
|
|
2148
|
|
- static void lcd_filament_change_extrude_more() {
|
|
2148
|
+ void lcd_filament_change_extrude_more() {
|
2149
|
2149
|
filament_change_menu_response = FILAMENT_CHANGE_RESPONSE_EXTRUDE_MORE;
|
2150
|
2150
|
}
|
2151
|
2151
|
|
2152
|
|
- static void lcd_filament_change_option_menu() {
|
|
2152
|
+ void lcd_filament_change_option_menu() {
|
2153
|
2153
|
START_MENU();
|
2154
|
2154
|
#if LCD_HEIGHT > 2
|
2155
|
2155
|
STATIC_ITEM(MSG_FILAMENT_CHANGE_OPTION_HEADER, true, false);
|
|
@@ -2159,7 +2159,7 @@ void kill_screen(const char* lcd_msg) {
|
2159
|
2159
|
END_MENU();
|
2160
|
2160
|
}
|
2161
|
2161
|
|
2162
|
|
- static void lcd_filament_change_init_message() {
|
|
2162
|
+ void lcd_filament_change_init_message() {
|
2163
|
2163
|
START_SCREEN();
|
2164
|
2164
|
STATIC_ITEM(MSG_FILAMENT_CHANGE_HEADER, true, true);
|
2165
|
2165
|
STATIC_ITEM(MSG_FILAMENT_CHANGE_INIT_1);
|
|
@@ -2172,7 +2172,7 @@ void kill_screen(const char* lcd_msg) {
|
2172
|
2172
|
END_SCREEN();
|
2173
|
2173
|
}
|
2174
|
2174
|
|
2175
|
|
- static void lcd_filament_change_unload_message() {
|
|
2175
|
+ void lcd_filament_change_unload_message() {
|
2176
|
2176
|
START_SCREEN();
|
2177
|
2177
|
STATIC_ITEM(MSG_FILAMENT_CHANGE_HEADER, true, true);
|
2178
|
2178
|
STATIC_ITEM(MSG_FILAMENT_CHANGE_UNLOAD_1);
|
|
@@ -2185,7 +2185,7 @@ void kill_screen(const char* lcd_msg) {
|
2185
|
2185
|
END_SCREEN();
|
2186
|
2186
|
}
|
2187
|
2187
|
|
2188
|
|
- static void lcd_filament_change_insert_message() {
|
|
2188
|
+ void lcd_filament_change_insert_message() {
|
2189
|
2189
|
START_SCREEN();
|
2190
|
2190
|
STATIC_ITEM(MSG_FILAMENT_CHANGE_HEADER, true, true);
|
2191
|
2191
|
STATIC_ITEM(MSG_FILAMENT_CHANGE_INSERT_1);
|
|
@@ -2198,7 +2198,7 @@ void kill_screen(const char* lcd_msg) {
|
2198
|
2198
|
END_SCREEN();
|
2199
|
2199
|
}
|
2200
|
2200
|
|
2201
|
|
- static void lcd_filament_change_load_message() {
|
|
2201
|
+ void lcd_filament_change_load_message() {
|
2202
|
2202
|
START_SCREEN();
|
2203
|
2203
|
STATIC_ITEM(MSG_FILAMENT_CHANGE_HEADER, true, true);
|
2204
|
2204
|
STATIC_ITEM(MSG_FILAMENT_CHANGE_LOAD_1);
|
|
@@ -2211,7 +2211,7 @@ void kill_screen(const char* lcd_msg) {
|
2211
|
2211
|
END_SCREEN();
|
2212
|
2212
|
}
|
2213
|
2213
|
|
2214
|
|
- static void lcd_filament_change_extrude_message() {
|
|
2214
|
+ void lcd_filament_change_extrude_message() {
|
2215
|
2215
|
START_SCREEN();
|
2216
|
2216
|
STATIC_ITEM(MSG_FILAMENT_CHANGE_HEADER, true, true);
|
2217
|
2217
|
STATIC_ITEM(MSG_FILAMENT_CHANGE_EXTRUDE_1);
|
|
@@ -2224,7 +2224,7 @@ void kill_screen(const char* lcd_msg) {
|
2224
|
2224
|
END_SCREEN();
|
2225
|
2225
|
}
|
2226
|
2226
|
|
2227
|
|
- static void lcd_filament_change_resume_message() {
|
|
2227
|
+ void lcd_filament_change_resume_message() {
|
2228
|
2228
|
START_SCREEN();
|
2229
|
2229
|
STATIC_ITEM(MSG_FILAMENT_CHANGE_HEADER, true, true);
|
2230
|
2230
|
STATIC_ITEM(MSG_FILAMENT_CHANGE_RESUME_1);
|
|
@@ -2281,9 +2281,9 @@ void kill_screen(const char* lcd_msg) {
|
2281
|
2281
|
* bool _menu_edit_int3();
|
2282
|
2282
|
* void menu_edit_int3(); // edit int (interactively)
|
2283
|
2283
|
* void menu_edit_callback_int3(); // edit int (interactively) with callback on completion
|
2284
|
|
- * static void _menu_action_setting_edit_int3(const char* pstr, int* ptr, int minValue, int maxValue);
|
2285
|
|
- * static void menu_action_setting_edit_int3(const char* pstr, int* ptr, int minValue, int maxValue);
|
2286
|
|
- * static void menu_action_setting_edit_callback_int3(const char* pstr, int* ptr, int minValue, int maxValue, screenFunc_t callback); // edit int with callback
|
|
2284
|
+ * void _menu_action_setting_edit_int3(const char* pstr, int* ptr, int minValue, int maxValue);
|
|
2285
|
+ * void menu_action_setting_edit_int3(const char* pstr, int* ptr, int minValue, int maxValue);
|
|
2286
|
+ * void menu_action_setting_edit_callback_int3(const char* pstr, int* ptr, int minValue, int maxValue, screenFunc_t callback); // edit int with callback
|
2287
|
2287
|
*
|
2288
|
2288
|
* You can then use one of the menu macros to present the edit interface:
|
2289
|
2289
|
* MENU_ITEM_EDIT(int3, MSG_SPEED, &feedrate_percentage, 10, 999)
|
|
@@ -2311,7 +2311,7 @@ void kill_screen(const char* lcd_msg) {
|
2311
|
2311
|
} \
|
2312
|
2312
|
void menu_edit_ ## _name () { _menu_edit_ ## _name(); } \
|
2313
|
2313
|
void menu_edit_callback_ ## _name () { if (_menu_edit_ ## _name ()) (*callbackFunc)(); } \
|
2314
|
|
- static void _menu_action_setting_edit_ ## _name (const char* pstr, _type* ptr, _type minValue, _type maxValue) { \
|
|
2314
|
+ void _menu_action_setting_edit_ ## _name (const char* pstr, _type* ptr, _type minValue, _type maxValue) { \
|
2315
|
2315
|
lcd_save_previous_menu(); \
|
2316
|
2316
|
\
|
2317
|
2317
|
lcdDrawUpdate = LCDVIEW_CLEAR_CALL_REDRAW; \
|
|
@@ -2322,11 +2322,11 @@ void kill_screen(const char* lcd_msg) {
|
2322
|
2322
|
maxEditValue = maxValue * scale - minEditValue; \
|
2323
|
2323
|
encoderPosition = (*ptr) * scale - minEditValue; \
|
2324
|
2324
|
} \
|
2325
|
|
- static void menu_action_setting_edit_ ## _name (const char* pstr, _type* ptr, _type minValue, _type maxValue) { \
|
|
2325
|
+ void menu_action_setting_edit_ ## _name (const char* pstr, _type* ptr, _type minValue, _type maxValue) { \
|
2326
|
2326
|
_menu_action_setting_edit_ ## _name(pstr, ptr, minValue, maxValue); \
|
2327
|
2327
|
currentScreen = menu_edit_ ## _name; \
|
2328
|
2328
|
}\
|
2329
|
|
- static void menu_action_setting_edit_callback_ ## _name (const char* pstr, _type* ptr, _type minValue, _type maxValue, screenFunc_t callback) { \
|
|
2329
|
+ void menu_action_setting_edit_callback_ ## _name (const char* pstr, _type* ptr, _type minValue, _type maxValue, screenFunc_t callback) { \
|
2330
|
2330
|
_menu_action_setting_edit_ ## _name(pstr, ptr, minValue, maxValue); \
|
2331
|
2331
|
currentScreen = menu_edit_callback_ ## _name; \
|
2332
|
2332
|
callbackFunc = callback; \
|
|
@@ -2348,7 +2348,7 @@ void kill_screen(const char* lcd_msg) {
|
2348
|
2348
|
*
|
2349
|
2349
|
*/
|
2350
|
2350
|
#if ENABLED(REPRAPWORLD_KEYPAD)
|
2351
|
|
- static void _reprapworld_keypad_move(AxisEnum axis, int dir) {
|
|
2351
|
+ void _reprapworld_keypad_move(AxisEnum axis, int dir) {
|
2352
|
2352
|
move_menu_scale = REPRAPWORLD_KEYPAD_MOVE_STEP;
|
2353
|
2353
|
encoderPosition = dir;
|
2354
|
2354
|
switch (axis) {
|
|
@@ -2358,14 +2358,14 @@ void kill_screen(const char* lcd_msg) {
|
2358
|
2358
|
default: break;
|
2359
|
2359
|
}
|
2360
|
2360
|
}
|
2361
|
|
- static void reprapworld_keypad_move_z_up() { _reprapworld_keypad_move(Z_AXIS, 1); }
|
2362
|
|
- static void reprapworld_keypad_move_z_down() { _reprapworld_keypad_move(Z_AXIS, -1); }
|
2363
|
|
- static void reprapworld_keypad_move_x_left() { _reprapworld_keypad_move(X_AXIS, -1); }
|
2364
|
|
- static void reprapworld_keypad_move_x_right() { _reprapworld_keypad_move(X_AXIS, 1); }
|
2365
|
|
- static void reprapworld_keypad_move_y_up() { _reprapworld_keypad_move(Y_AXIS, -1); }
|
2366
|
|
- static void reprapworld_keypad_move_y_down() { _reprapworld_keypad_move(Y_AXIS, 1); }
|
2367
|
|
- static void reprapworld_keypad_move_home() { enqueue_and_echo_commands_P(PSTR("G28")); } // move all axes home and wait
|
2368
|
|
- static void reprapworld_keypad_move_menu() { lcd_goto_screen(lcd_move_menu); }
|
|
2361
|
+ void reprapworld_keypad_move_z_up() { _reprapworld_keypad_move(Z_AXIS, 1); }
|
|
2362
|
+ void reprapworld_keypad_move_z_down() { _reprapworld_keypad_move(Z_AXIS, -1); }
|
|
2363
|
+ void reprapworld_keypad_move_x_left() { _reprapworld_keypad_move(X_AXIS, -1); }
|
|
2364
|
+ void reprapworld_keypad_move_x_right() { _reprapworld_keypad_move(X_AXIS, 1); }
|
|
2365
|
+ void reprapworld_keypad_move_y_up() { _reprapworld_keypad_move(Y_AXIS, -1); }
|
|
2366
|
+ void reprapworld_keypad_move_y_down() { _reprapworld_keypad_move(Y_AXIS, 1); }
|
|
2367
|
+ void reprapworld_keypad_move_home() { enqueue_and_echo_commands_P(PSTR("G28")); } // move all axes home and wait
|
|
2368
|
+ void reprapworld_keypad_move_menu() { lcd_goto_screen(lcd_move_menu); }
|
2369
|
2369
|
#endif // REPRAPWORLD_KEYPAD
|
2370
|
2370
|
|
2371
|
2371
|
/**
|
|
@@ -2402,20 +2402,20 @@ void kill_screen(const char* lcd_msg) {
|
2402
|
2402
|
* Menu actions
|
2403
|
2403
|
*
|
2404
|
2404
|
*/
|
2405
|
|
- static void _menu_action_back() { lcd_goto_previous_menu(); }
|
2406
|
|
- static void menu_action_submenu(screenFunc_t func) { lcd_save_previous_menu(); lcd_goto_screen(func); }
|
2407
|
|
- static void menu_action_gcode(const char* pgcode) { enqueue_and_echo_commands_P(pgcode); }
|
2408
|
|
- static void menu_action_function(screenFunc_t func) { (*func)(); }
|
|
2405
|
+ void _menu_action_back() { lcd_goto_previous_menu(); }
|
|
2406
|
+ void menu_action_submenu(screenFunc_t func) { lcd_save_previous_menu(); lcd_goto_screen(func); }
|
|
2407
|
+ void menu_action_gcode(const char* pgcode) { enqueue_and_echo_commands_P(pgcode); }
|
|
2408
|
+ void menu_action_function(screenFunc_t func) { (*func)(); }
|
2409
|
2409
|
|
2410
|
2410
|
#if ENABLED(SDSUPPORT)
|
2411
|
2411
|
|
2412
|
|
- static void menu_action_sdfile(const char* filename, char* longFilename) {
|
|
2412
|
+ void menu_action_sdfile(const char* filename, char* longFilename) {
|
2413
|
2413
|
UNUSED(longFilename);
|
2414
|
2414
|
card.openAndPrintFile(filename);
|
2415
|
2415
|
lcd_return_to_status();
|
2416
|
2416
|
}
|
2417
|
2417
|
|
2418
|
|
- static void menu_action_sddirectory(const char* filename, char* longFilename) {
|
|
2418
|
+ void menu_action_sddirectory(const char* filename, char* longFilename) {
|
2419
|
2419
|
UNUSED(longFilename);
|
2420
|
2420
|
card.chdir(filename);
|
2421
|
2421
|
encoderPosition = 0;
|
|
@@ -2423,8 +2423,8 @@ void kill_screen(const char* lcd_msg) {
|
2423
|
2423
|
|
2424
|
2424
|
#endif //SDSUPPORT
|
2425
|
2425
|
|
2426
|
|
- static void menu_action_setting_edit_bool(const char* pstr, bool* ptr) {UNUSED(pstr); *ptr = !(*ptr); }
|
2427
|
|
- static void menu_action_setting_edit_callback_bool(const char* pstr, bool* ptr, screenFunc_t callback) {
|
|
2426
|
+ void menu_action_setting_edit_bool(const char* pstr, bool* ptr) {UNUSED(pstr); *ptr = !(*ptr); }
|
|
2427
|
+ void menu_action_setting_edit_callback_bool(const char* pstr, bool* ptr, screenFunc_t callback) {
|
2428
|
2428
|
menu_action_setting_edit_bool(pstr, ptr);
|
2429
|
2429
|
(*callback)();
|
2430
|
2430
|
}
|