|
|
@ -85,12 +85,13 @@ int16_t lcd_preheat_hotend_temp[2], lcd_preheat_bed_temp[2], lcd_preheat_fan_spe
|
|
|
|
#endif
|
|
|
|
#endif
|
|
|
|
|
|
|
|
|
|
|
|
uint8_t lcd_status_update_delay = 1, // First update one loop delayed
|
|
|
|
uint8_t lcd_status_update_delay = 1, // First update one loop delayed
|
|
|
|
lcd_status_message_level; // Higher level overrides lower
|
|
|
|
lcd_status_message_level; // Higher level blocks lower level
|
|
|
|
char lcd_status_message[3 * (LCD_WIDTH) + 1] = WELCOME_MSG; // worst case is kana with up to 3*LCD_WIDTH+1
|
|
|
|
char lcd_status_message[3 * (LCD_WIDTH) + 1] = WELCOME_MSG; // worst case is kana with up to 3*LCD_WIDTH+1
|
|
|
|
|
|
|
|
|
|
|
|
#if ENABLED(STATUS_MESSAGE_SCROLLING)
|
|
|
|
#if ENABLED(STATUS_MESSAGE_SCROLLING)
|
|
|
|
uint8_t status_scroll_pos = 0;
|
|
|
|
uint8_t status_scroll_pos = 0;
|
|
|
|
#endif
|
|
|
|
#endif
|
|
|
|
|
|
|
|
|
|
|
|
#if ENABLED(SCROLL_LONG_FILENAMES)
|
|
|
|
#if ENABLED(SCROLL_LONG_FILENAMES)
|
|
|
|
uint8_t filename_scroll_pos, filename_scroll_max, filename_scroll_hash;
|
|
|
|
uint8_t filename_scroll_pos, filename_scroll_max, filename_scroll_hash;
|
|
|
|
#endif
|
|
|
|
#endif
|
|
|
@ -163,8 +164,6 @@ uint16_t max_display_update_time = 0;
|
|
|
|
extern bool powersupply_on;
|
|
|
|
extern bool powersupply_on;
|
|
|
|
#endif
|
|
|
|
#endif
|
|
|
|
|
|
|
|
|
|
|
|
float move_menu_scale;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
////////////////////////////////////////////
|
|
|
|
////////////////////////////////////////////
|
|
|
|
///////////////// Menu Tree ////////////////
|
|
|
|
///////////////// Menu Tree ////////////////
|
|
|
|
////////////////////////////////////////////
|
|
|
|
////////////////////////////////////////////
|
|
|
@ -244,7 +243,6 @@ uint16_t max_display_update_time = 0;
|
|
|
|
void menu_action_setting_edit_callback_ ## _name(const char * const pstr, _type * const ptr, const _type minValue, const _type maxValue, const screenFunc_t callback, const bool live=false); \
|
|
|
|
void menu_action_setting_edit_callback_ ## _name(const char * const pstr, _type * const ptr, const _type minValue, const _type maxValue, const screenFunc_t callback, const bool live=false); \
|
|
|
|
typedef void _name##_void
|
|
|
|
typedef void _name##_void
|
|
|
|
|
|
|
|
|
|
|
|
DECLARE_MENU_EDIT_TYPE(uint32_t, long5);
|
|
|
|
|
|
|
|
DECLARE_MENU_EDIT_TYPE(int16_t, int3);
|
|
|
|
DECLARE_MENU_EDIT_TYPE(int16_t, int3);
|
|
|
|
DECLARE_MENU_EDIT_TYPE(uint8_t, int8);
|
|
|
|
DECLARE_MENU_EDIT_TYPE(uint8_t, int8);
|
|
|
|
DECLARE_MENU_EDIT_TYPE(float, float3);
|
|
|
|
DECLARE_MENU_EDIT_TYPE(float, float3);
|
|
|
@ -254,6 +252,7 @@ uint16_t max_display_update_time = 0;
|
|
|
|
DECLARE_MENU_EDIT_TYPE(float, float51);
|
|
|
|
DECLARE_MENU_EDIT_TYPE(float, float51);
|
|
|
|
DECLARE_MENU_EDIT_TYPE(float, float52);
|
|
|
|
DECLARE_MENU_EDIT_TYPE(float, float52);
|
|
|
|
DECLARE_MENU_EDIT_TYPE(float, float62);
|
|
|
|
DECLARE_MENU_EDIT_TYPE(float, float62);
|
|
|
|
|
|
|
|
DECLARE_MENU_EDIT_TYPE(uint32_t, long5);
|
|
|
|
|
|
|
|
|
|
|
|
void menu_action_setting_edit_bool(const char* pstr, bool* ptr);
|
|
|
|
void menu_action_setting_edit_bool(const char* pstr, bool* ptr);
|
|
|
|
void menu_action_setting_edit_callback_bool(const char* pstr, bool* ptr, screenFunc_t callbackFunc);
|
|
|
|
void menu_action_setting_edit_callback_bool(const char* pstr, bool* ptr, screenFunc_t callbackFunc);
|
|
|
@ -566,10 +565,9 @@ uint16_t max_display_update_time = 0;
|
|
|
|
static bool no_reentry = false;
|
|
|
|
static bool no_reentry = false;
|
|
|
|
if (lcdDrawUpdate) lcd_implementation_drawmenu_static(LCD_HEIGHT >= 4 ? 1 : 0, sync_message);
|
|
|
|
if (lcdDrawUpdate) lcd_implementation_drawmenu_static(LCD_HEIGHT >= 4 ? 1 : 0, sync_message);
|
|
|
|
if (no_reentry) return;
|
|
|
|
if (no_reentry) return;
|
|
|
|
|
|
|
|
|
|
|
|
// Make this the current handler till all moves are done
|
|
|
|
// Make this the current handler till all moves are done
|
|
|
|
no_reentry = true;
|
|
|
|
no_reentry = true;
|
|
|
|
screenFunc_t old_screen = currentScreen;
|
|
|
|
const screenFunc_t old_screen = currentScreen;
|
|
|
|
lcd_goto_screen(_lcd_synchronize);
|
|
|
|
lcd_goto_screen(_lcd_synchronize);
|
|
|
|
stepper.synchronize();
|
|
|
|
stepper.synchronize();
|
|
|
|
no_reentry = false;
|
|
|
|
no_reentry = false;
|
|
|
@ -997,7 +995,7 @@ void kill_screen(const char* lcd_msg) {
|
|
|
|
#if ENABLED(SDSUPPORT)
|
|
|
|
#if ENABLED(SDSUPPORT)
|
|
|
|
if (card.cardOK) {
|
|
|
|
if (card.cardOK) {
|
|
|
|
if (card.isFileOpen()) {
|
|
|
|
if (card.isFileOpen()) {
|
|
|
|
if (IS_SD_PRINTING)
|
|
|
|
if (card.sdprinting)
|
|
|
|
MENU_ITEM(function, MSG_PAUSE_PRINT, lcd_sdcard_pause);
|
|
|
|
MENU_ITEM(function, MSG_PAUSE_PRINT, lcd_sdcard_pause);
|
|
|
|
else
|
|
|
|
else
|
|
|
|
MENU_ITEM(function, MSG_RESUME_PRINT, lcd_sdcard_resume);
|
|
|
|
MENU_ITEM(function, MSG_RESUME_PRINT, lcd_sdcard_resume);
|
|
|
@ -1115,6 +1113,8 @@ void kill_screen(const char* lcd_msg) {
|
|
|
|
ENCODER_DIRECTION_NORMAL();
|
|
|
|
ENCODER_DIRECTION_NORMAL();
|
|
|
|
if (encoderPosition) {
|
|
|
|
if (encoderPosition) {
|
|
|
|
const int16_t babystep_increment = (int32_t)encoderPosition * (BABYSTEP_MULTIPLICATOR);
|
|
|
|
const int16_t babystep_increment = (int32_t)encoderPosition * (BABYSTEP_MULTIPLICATOR);
|
|
|
|
|
|
|
|
encoderPosition = 0;
|
|
|
|
|
|
|
|
|
|
|
|
const float new_zoffset = zprobe_zoffset + planner.steps_to_mm[Z_AXIS] * babystep_increment;
|
|
|
|
const float new_zoffset = zprobe_zoffset + planner.steps_to_mm[Z_AXIS] * babystep_increment;
|
|
|
|
if (WITHIN(new_zoffset, Z_PROBE_OFFSET_RANGE_MIN, Z_PROBE_OFFSET_RANGE_MAX)) {
|
|
|
|
if (WITHIN(new_zoffset, Z_PROBE_OFFSET_RANGE_MIN, Z_PROBE_OFFSET_RANGE_MAX)) {
|
|
|
|
|
|
|
|
|
|
|
@ -1124,7 +1124,6 @@ void kill_screen(const char* lcd_msg) {
|
|
|
|
zprobe_zoffset = new_zoffset;
|
|
|
|
zprobe_zoffset = new_zoffset;
|
|
|
|
lcdDrawUpdate = LCDVIEW_CALL_REDRAW_NEXT;
|
|
|
|
lcdDrawUpdate = LCDVIEW_CALL_REDRAW_NEXT;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
encoderPosition = 0;
|
|
|
|
|
|
|
|
}
|
|
|
|
}
|
|
|
|
if (lcdDrawUpdate) {
|
|
|
|
if (lcdDrawUpdate) {
|
|
|
|
lcd_implementation_drawedit(PSTR(MSG_ZPROBE_ZOFFSET), ftostr43sign(zprobe_zoffset));
|
|
|
|
lcd_implementation_drawedit(PSTR(MSG_ZPROBE_ZOFFSET), ftostr43sign(zprobe_zoffset));
|
|
|
@ -1164,12 +1163,13 @@ void kill_screen(const char* lcd_msg) {
|
|
|
|
mesh_edit_value = float(rounded - (rounded % 5L)) / 1000.0;
|
|
|
|
mesh_edit_value = float(rounded - (rounded % 5L)) / 1000.0;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
if (lcdDrawUpdate)
|
|
|
|
if (lcdDrawUpdate) {
|
|
|
|
lcd_implementation_drawedit(msg, ftostr43sign(mesh_edit_value));
|
|
|
|
lcd_implementation_drawedit(msg, ftostr43sign(mesh_edit_value));
|
|
|
|
#if ENABLED(MESH_EDIT_GFX_OVERLAY)
|
|
|
|
#if ENABLED(MESH_EDIT_GFX_OVERLAY)
|
|
|
|
_lcd_zoffset_overlay_gfx(mesh_edit_value);
|
|
|
|
_lcd_zoffset_overlay_gfx(mesh_edit_value);
|
|
|
|
#endif
|
|
|
|
#endif
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
void _lcd_mesh_edit_NOP() {
|
|
|
|
void _lcd_mesh_edit_NOP() {
|
|
|
|
defer_return_to_status = true;
|
|
|
|
defer_return_to_status = true;
|
|
|
@ -1182,7 +1182,7 @@ void kill_screen(const char* lcd_msg) {
|
|
|
|
return mesh_edit_value;
|
|
|
|
return mesh_edit_value;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
void lcd_mesh_edit_setup(float initial) {
|
|
|
|
void lcd_mesh_edit_setup(const float initial) {
|
|
|
|
mesh_edit_value = mesh_edit_accumulator = initial;
|
|
|
|
mesh_edit_value = mesh_edit_accumulator = initial;
|
|
|
|
lcd_goto_screen(_lcd_mesh_edit_NOP);
|
|
|
|
lcd_goto_screen(_lcd_mesh_edit_NOP);
|
|
|
|
}
|
|
|
|
}
|
|
|
@ -1203,6 +1203,7 @@ void kill_screen(const char* lcd_msg) {
|
|
|
|
|
|
|
|
|
|
|
|
#endif // AUTO_BED_LEVELING_UBL
|
|
|
|
#endif // AUTO_BED_LEVELING_UBL
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
/**
|
|
|
|
* Watch temperature callbacks
|
|
|
|
* Watch temperature callbacks
|
|
|
|
*/
|
|
|
|
*/
|
|
|
@ -2030,8 +2031,8 @@ void kill_screen(const char* lcd_msg) {
|
|
|
|
*/
|
|
|
|
*/
|
|
|
|
void _lcd_ubl_adjust_height_cmd() {
|
|
|
|
void _lcd_ubl_adjust_height_cmd() {
|
|
|
|
char UBL_LCD_GCODE[16];
|
|
|
|
char UBL_LCD_GCODE[16];
|
|
|
|
const int ind = ubl_height_amount < 0 ? 6 : 7;
|
|
|
|
const int ind = ubl_height_amount > 0 ? 9 : 10;
|
|
|
|
strcpy_P(UBL_LCD_GCODE, PSTR("G29 P6-"));
|
|
|
|
strcpy_P(UBL_LCD_GCODE, PSTR("G29 P6 C -"));
|
|
|
|
sprintf_P(&UBL_LCD_GCODE[ind], PSTR(".%i"), abs(ubl_height_amount));
|
|
|
|
sprintf_P(&UBL_LCD_GCODE[ind], PSTR(".%i"), abs(ubl_height_amount));
|
|
|
|
enqueue_and_echo_command(UBL_LCD_GCODE);
|
|
|
|
enqueue_and_echo_command(UBL_LCD_GCODE);
|
|
|
|
}
|
|
|
|
}
|
|
|
@ -2047,8 +2048,7 @@ void kill_screen(const char* lcd_msg) {
|
|
|
|
void _lcd_ubl_height_adjust_menu() {
|
|
|
|
void _lcd_ubl_height_adjust_menu() {
|
|
|
|
START_MENU();
|
|
|
|
START_MENU();
|
|
|
|
MENU_BACK(MSG_UBL_EDIT_MESH_MENU);
|
|
|
|
MENU_BACK(MSG_UBL_EDIT_MESH_MENU);
|
|
|
|
MENU_ITEM_EDIT(int3, MSG_UBL_MESH_HEIGHT_AMOUNT, &ubl_height_amount, -9, 9);
|
|
|
|
MENU_ITEM_EDIT_CALLBACK(int3, MSG_UBL_MESH_HEIGHT_AMOUNT, &ubl_height_amount, -9, 9, _lcd_ubl_adjust_height_cmd);
|
|
|
|
MENU_ITEM(function, MSG_UBL_MESH_HEIGHT_ADJUST, _lcd_ubl_adjust_height_cmd);
|
|
|
|
|
|
|
|
MENU_ITEM(function, MSG_WATCH, lcd_return_to_status);
|
|
|
|
MENU_ITEM(function, MSG_WATCH, lcd_return_to_status);
|
|
|
|
END_MENU();
|
|
|
|
END_MENU();
|
|
|
|
}
|
|
|
|
}
|
|
|
@ -2184,8 +2184,7 @@ void kill_screen(const char* lcd_msg) {
|
|
|
|
void _lcd_ubl_fillin_menu() {
|
|
|
|
void _lcd_ubl_fillin_menu() {
|
|
|
|
START_MENU();
|
|
|
|
START_MENU();
|
|
|
|
MENU_BACK(MSG_UBL_BUILD_MESH_MENU);
|
|
|
|
MENU_BACK(MSG_UBL_BUILD_MESH_MENU);
|
|
|
|
MENU_ITEM_EDIT(int3, MSG_UBL_FILLIN_AMOUNT, &ubl_fillin_amount, 0, 9);
|
|
|
|
MENU_ITEM_EDIT_CALLBACK(int3, MSG_UBL_FILLIN_AMOUNT, &ubl_fillin_amount, 0, 9, _lcd_ubl_fillin_amount_cmd);
|
|
|
|
MENU_ITEM(function, MSG_UBL_FILLIN_MESH, _lcd_ubl_fillin_amount_cmd);
|
|
|
|
|
|
|
|
MENU_ITEM(function, MSG_UBL_SMART_FILLIN, _lcd_ubl_smart_fillin_cmd);
|
|
|
|
MENU_ITEM(function, MSG_UBL_SMART_FILLIN, _lcd_ubl_smart_fillin_cmd);
|
|
|
|
MENU_ITEM(gcode, MSG_UBL_MANUAL_FILLIN, PSTR("G29 P2 B T0"));
|
|
|
|
MENU_ITEM(gcode, MSG_UBL_MANUAL_FILLIN, PSTR("G29 P2 B T0"));
|
|
|
|
MENU_ITEM(function, MSG_WATCH, lcd_return_to_status);
|
|
|
|
MENU_ITEM(function, MSG_WATCH, lcd_return_to_status);
|
|
|
@ -2644,6 +2643,8 @@ void kill_screen(const char* lcd_msg) {
|
|
|
|
END_MENU();
|
|
|
|
END_MENU();
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
float move_menu_scale;
|
|
|
|
|
|
|
|
|
|
|
|
#if ENABLED(DELTA_CALIBRATION_MENU) || (ENABLED(DELTA_AUTO_CALIBRATION) && !HAS_BED_PROBE)
|
|
|
|
#if ENABLED(DELTA_CALIBRATION_MENU) || (ENABLED(DELTA_AUTO_CALIBRATION) && !HAS_BED_PROBE)
|
|
|
|
|
|
|
|
|
|
|
|
void lcd_move_z();
|
|
|
|
void lcd_move_z();
|
|
|
@ -2653,13 +2654,11 @@ void kill_screen(const char* lcd_msg) {
|
|
|
|
reset_bed_level(); // After calibration bed-level data is no longer valid
|
|
|
|
reset_bed_level(); // After calibration bed-level data is no longer valid
|
|
|
|
#endif
|
|
|
|
#endif
|
|
|
|
|
|
|
|
|
|
|
|
float z_dest = (Z_CLEARANCE_BETWEEN_PROBES) + (DELTA_PRINTABLE_RADIUS) / 5;
|
|
|
|
line_to_z((Z_CLEARANCE_BETWEEN_PROBES) + (DELTA_PRINTABLE_RADIUS) / 5);
|
|
|
|
line_to_z(z_dest);
|
|
|
|
|
|
|
|
current_position[X_AXIS] = rx;
|
|
|
|
current_position[X_AXIS] = rx;
|
|
|
|
current_position[Y_AXIS] = ry;
|
|
|
|
current_position[Y_AXIS] = ry;
|
|
|
|
line_to_current_z();
|
|
|
|
line_to_current_z();
|
|
|
|
z_dest = Z_CLEARANCE_BETWEEN_PROBES;
|
|
|
|
line_to_z(Z_CLEARANCE_BETWEEN_PROBES);
|
|
|
|
line_to_z(z_dest);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
lcd_synchronize();
|
|
|
|
lcd_synchronize();
|
|
|
|
move_menu_scale = PROBE_MANUALLY_STEP;
|
|
|
|
move_menu_scale = PROBE_MANUALLY_STEP;
|
|
|
@ -2813,7 +2812,6 @@ void kill_screen(const char* lcd_msg) {
|
|
|
|
#endif
|
|
|
|
#endif
|
|
|
|
manual_move_e_index = eindex >= 0 ? eindex : active_extruder;
|
|
|
|
manual_move_e_index = eindex >= 0 ? eindex : active_extruder;
|
|
|
|
#endif
|
|
|
|
#endif
|
|
|
|
|
|
|
|
|
|
|
|
manual_move_start_time = millis() + (move_menu_scale < 0.99 ? 0UL : 250UL); // delay for bigger moves
|
|
|
|
manual_move_start_time = millis() + (move_menu_scale < 0.99 ? 0UL : 250UL); // delay for bigger moves
|
|
|
|
manual_move_axis = (int8_t)axis;
|
|
|
|
manual_move_axis = (int8_t)axis;
|
|
|
|
}
|
|
|
|
}
|
|
|
@ -2830,6 +2828,7 @@ void kill_screen(const char* lcd_msg) {
|
|
|
|
if (encoderPosition && !processing_manual_move) {
|
|
|
|
if (encoderPosition && !processing_manual_move) {
|
|
|
|
gcode.refresh_cmd_timeout();
|
|
|
|
gcode.refresh_cmd_timeout();
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
// Start with no limits to movement
|
|
|
|
float min = current_position[axis] - 1000,
|
|
|
|
float min = current_position[axis] - 1000,
|
|
|
|
max = current_position[axis] + 1000;
|
|
|
|
max = current_position[axis] + 1000;
|
|
|
|
|
|
|
|
|
|
|
@ -2867,7 +2866,7 @@ void kill_screen(const char* lcd_msg) {
|
|
|
|
// This assumes the center is 0,0
|
|
|
|
// This assumes the center is 0,0
|
|
|
|
#if ENABLED(DELTA)
|
|
|
|
#if ENABLED(DELTA)
|
|
|
|
if (axis != Z_AXIS) {
|
|
|
|
if (axis != Z_AXIS) {
|
|
|
|
max = SQRT(sq((float)(DELTA_PRINTABLE_RADIUS)) - sq(current_position[Y_AXIS - axis]));
|
|
|
|
max = SQRT(sq((float)(DELTA_PRINTABLE_RADIUS)) - sq(current_position[Y_AXIS - axis])); // (Y_AXIS - axis) == the other axis
|
|
|
|
min = -max;
|
|
|
|
min = -max;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
#endif
|
|
|
|
#endif
|
|
|
@ -3131,7 +3130,7 @@ void kill_screen(const char* lcd_msg) {
|
|
|
|
MENU_ITEM(submenu, MSG_FILAMENT, lcd_control_filament_menu);
|
|
|
|
MENU_ITEM(submenu, MSG_FILAMENT, lcd_control_filament_menu);
|
|
|
|
|
|
|
|
|
|
|
|
#if HAS_LCD_CONTRAST
|
|
|
|
#if HAS_LCD_CONTRAST
|
|
|
|
MENU_ITEM_EDIT_CALLBACK(int3, MSG_CONTRAST, (int16_t*)&lcd_contrast, LCD_CONTRAST_MIN, LCD_CONTRAST_MAX, lcd_callback_set_contrast, true);
|
|
|
|
MENU_ITEM_EDIT_CALLBACK(int3, MSG_CONTRAST, &lcd_contrast, LCD_CONTRAST_MIN, LCD_CONTRAST_MAX, lcd_callback_set_contrast, true);
|
|
|
|
#endif
|
|
|
|
#endif
|
|
|
|
#if ENABLED(FWRETRACT)
|
|
|
|
#if ENABLED(FWRETRACT)
|
|
|
|
MENU_ITEM(submenu, MSG_RETRACT, lcd_control_retract_menu);
|
|
|
|
MENU_ITEM(submenu, MSG_RETRACT, lcd_control_retract_menu);
|
|
|
@ -3724,7 +3723,7 @@ void kill_screen(const char* lcd_msg) {
|
|
|
|
|
|
|
|
|
|
|
|
lcd_goto_screen(lcd_sdcard_menu, last_sdfile_encoderPosition);
|
|
|
|
lcd_goto_screen(lcd_sdcard_menu, last_sdfile_encoderPosition);
|
|
|
|
defer_return_to_status = true;
|
|
|
|
defer_return_to_status = true;
|
|
|
|
last_sdfile_encoderPosition == 0xFFFF;
|
|
|
|
last_sdfile_encoderPosition = 0xFFFF;
|
|
|
|
|
|
|
|
|
|
|
|
#if ENABLED(DOGLCD)
|
|
|
|
#if ENABLED(DOGLCD)
|
|
|
|
lcd_update();
|
|
|
|
lcd_update();
|
|
|
@ -3749,7 +3748,6 @@ void kill_screen(const char* lcd_msg) {
|
|
|
|
MENU_ITEM(function, LCD_STR_FOLDER "..", lcd_sd_updir);
|
|
|
|
MENU_ITEM(function, LCD_STR_FOLDER "..", lcd_sd_updir);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
if (fileCnt) {
|
|
|
|
|
|
|
|
for (uint16_t i = 0; i < fileCnt; i++) {
|
|
|
|
for (uint16_t i = 0; i < fileCnt; i++) {
|
|
|
|
if (_menuLineNr == _thisItemNr) {
|
|
|
|
if (_menuLineNr == _thisItemNr) {
|
|
|
|
const uint16_t nr =
|
|
|
|
const uint16_t nr =
|
|
|
@ -3773,7 +3771,6 @@ void kill_screen(const char* lcd_msg) {
|
|
|
|
MENU_ITEM_DUMMY();
|
|
|
|
MENU_ITEM_DUMMY();
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
END_MENU();
|
|
|
|
END_MENU();
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
@ -4476,13 +4473,14 @@ void lcd_init() {
|
|
|
|
lcd_implementation_init();
|
|
|
|
lcd_implementation_init();
|
|
|
|
|
|
|
|
|
|
|
|
#if ENABLED(NEWPANEL)
|
|
|
|
#if ENABLED(NEWPANEL)
|
|
|
|
|
|
|
|
|
|
|
|
#if BUTTON_EXISTS(EN1)
|
|
|
|
#if BUTTON_EXISTS(EN1)
|
|
|
|
SET_INPUT_PULLUP(BTN_EN1);
|
|
|
|
SET_INPUT_PULLUP(BTN_EN1);
|
|
|
|
#endif
|
|
|
|
#endif
|
|
|
|
|
|
|
|
|
|
|
|
#if BUTTON_EXISTS(EN2)
|
|
|
|
#if BUTTON_EXISTS(EN2)
|
|
|
|
SET_INPUT_PULLUP(BTN_EN2);
|
|
|
|
SET_INPUT_PULLUP(BTN_EN2);
|
|
|
|
#endif
|
|
|
|
#endif
|
|
|
|
|
|
|
|
|
|
|
|
#if BUTTON_EXISTS(ENC)
|
|
|
|
#if BUTTON_EXISTS(ENC)
|
|
|
|
SET_INPUT_PULLUP(BTN_ENC);
|
|
|
|
SET_INPUT_PULLUP(BTN_ENC);
|
|
|
|
#endif
|
|
|
|
#endif
|
|
|
@ -4684,7 +4682,7 @@ void lcd_update() {
|
|
|
|
|
|
|
|
|
|
|
|
#endif
|
|
|
|
#endif
|
|
|
|
|
|
|
|
|
|
|
|
bool encoderPastThreshold = (abs(encoderDiff) >= ENCODER_PULSES_PER_STEP);
|
|
|
|
const bool encoderPastThreshold = (abs(encoderDiff) >= ENCODER_PULSES_PER_STEP);
|
|
|
|
if (encoderPastThreshold || lcd_clicked) {
|
|
|
|
if (encoderPastThreshold || lcd_clicked) {
|
|
|
|
if (encoderPastThreshold) {
|
|
|
|
if (encoderPastThreshold) {
|
|
|
|
int32_t encoderMultiplier = 1;
|
|
|
|
int32_t encoderMultiplier = 1;
|
|
|
@ -4979,11 +4977,6 @@ void lcd_reset_alert_level() { lcd_status_message_level = 0; }
|
|
|
|
if (BUTTON_PRESSED(ENC)) newbutton |= EN_C;
|
|
|
|
if (BUTTON_PRESSED(ENC)) newbutton |= EN_C;
|
|
|
|
#endif
|
|
|
|
#endif
|
|
|
|
|
|
|
|
|
|
|
|
buttons = newbutton;
|
|
|
|
|
|
|
|
#if ENABLED(LCD_HAS_SLOW_BUTTONS)
|
|
|
|
|
|
|
|
buttons |= slow_buttons;
|
|
|
|
|
|
|
|
#endif
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
//
|
|
|
|
//
|
|
|
|
// Directional buttons
|
|
|
|
// Directional buttons
|
|
|
|
//
|
|
|
|
//
|
|
|
@ -5032,6 +5025,11 @@ void lcd_reset_alert_level() { lcd_status_message_level = 0; }
|
|
|
|
|
|
|
|
|
|
|
|
#endif // LCD_HAS_DIRECTIONAL_BUTTONS
|
|
|
|
#endif // LCD_HAS_DIRECTIONAL_BUTTONS
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
buttons = newbutton;
|
|
|
|
|
|
|
|
#if ENABLED(LCD_HAS_SLOW_BUTTONS)
|
|
|
|
|
|
|
|
buttons |= slow_buttons;
|
|
|
|
|
|
|
|
#endif
|
|
|
|
|
|
|
|
|
|
|
|
#if ENABLED(ADC_KEYPAD)
|
|
|
|
#if ENABLED(ADC_KEYPAD)
|
|
|
|
|
|
|
|
|
|
|
|
uint8_t newbutton_reprapworld_keypad = 0;
|
|
|
|
uint8_t newbutton_reprapworld_keypad = 0;
|
|
|
|