mirror of
https://github.com/MarlinFirmware/Marlin.git
synced 2024-12-02 08:09:36 +00:00
🩹 ProUI - Remove ManualZOffset
This commit is contained in:
parent
7717beb793
commit
01e58de31a
@ -1298,6 +1298,7 @@
|
|||||||
// Clear probe pin settings when no probe is selected
|
// Clear probe pin settings when no probe is selected
|
||||||
#undef Z_MIN_PROBE_USES_Z_MIN_ENDSTOP_PIN
|
#undef Z_MIN_PROBE_USES_Z_MIN_ENDSTOP_PIN
|
||||||
#undef USE_PROBE_FOR_Z_HOMING
|
#undef USE_PROBE_FOR_Z_HOMING
|
||||||
|
#undef Z_MIN_PROBE_REPEATABILITY_TEST
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#if ENABLED(BELTPRINTER) && !defined(HOME_Y_BEFORE_X)
|
#if ENABLED(BELTPRINTER) && !defined(HOME_Y_BEFORE_X)
|
||||||
|
@ -79,6 +79,9 @@
|
|||||||
#define SERVO_DELAY { 50 }
|
#define SERVO_DELAY { 50 }
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
#if !HAS_BED_PROBE
|
||||||
|
#undef BABYSTEP_ZPROBE_OFFSET
|
||||||
|
#endif
|
||||||
#if !HAS_STOWABLE_PROBE
|
#if !HAS_STOWABLE_PROBE
|
||||||
#undef PROBE_DEPLOY_STOW_MENU
|
#undef PROBE_DEPLOY_STOW_MENU
|
||||||
#endif
|
#endif
|
||||||
|
@ -1938,15 +1938,17 @@ static_assert(Y_MAX_LENGTH >= Y_BED_SIZE, "Movement bounds (Y_MIN_POS, Y_MAX_POS
|
|||||||
* Make sure Z raise values are set
|
* Make sure Z raise values are set
|
||||||
*/
|
*/
|
||||||
#ifndef Z_CLEARANCE_DEPLOY_PROBE
|
#ifndef Z_CLEARANCE_DEPLOY_PROBE
|
||||||
#error "You must define Z_CLEARANCE_DEPLOY_PROBE in your configuration."
|
#error "Z_CLEARANCE_DEPLOY_PROBE is required for bed probes."
|
||||||
#elif !defined(Z_CLEARANCE_BETWEEN_PROBES)
|
#else
|
||||||
#error "You must define Z_CLEARANCE_BETWEEN_PROBES in your configuration."
|
static_assert(Z_CLEARANCE_DEPLOY_PROBE >= 0, "Probes require Z_CLEARANCE_DEPLOY_PROBE >= 0.");
|
||||||
#elif Z_CLEARANCE_DEPLOY_PROBE < 0
|
#endif
|
||||||
#error "Probes need Z_CLEARANCE_DEPLOY_PROBE >= 0."
|
#ifndef Z_CLEARANCE_BETWEEN_PROBES
|
||||||
#elif Z_CLEARANCE_BETWEEN_PROBES < 0
|
#error "Z_CLEARANCE_BETWEEN_PROBES is required for bed probes."
|
||||||
#error "Probes need Z_CLEARANCE_BETWEEN_PROBES >= 0."
|
#else
|
||||||
#elif Z_AFTER_PROBING < 0
|
static_assert(Z_CLEARANCE_BETWEEN_PROBES >= 0, "Probes require Z_CLEARANCE_BETWEEN_PROBES >= 0.");
|
||||||
#error "Probes need Z_AFTER_PROBING >= 0."
|
#endif
|
||||||
|
#ifdef Z_AFTER_PROBING
|
||||||
|
static_assert(Z_AFTER_PROBING >= 0, "Probes require Z_AFTER_PROBING >= 0.");
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#if MULTIPLE_PROBING > 0 || EXTRA_PROBING > 0
|
#if MULTIPLE_PROBING > 0 || EXTRA_PROBING > 0
|
||||||
|
@ -109,14 +109,8 @@
|
|||||||
#include "../../../feature/bltouch.h"
|
#include "../../../feature/bltouch.h"
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#if EITHER(BABYSTEPPING, HAS_BED_PROBE)
|
#if ENABLED(BABYSTEPPING)
|
||||||
#define HAS_ZOFFSET_ITEM 1
|
#include "../../../feature/babystep.h"
|
||||||
#if ENABLED(BABYSTEPPING)
|
|
||||||
#include "../../../feature/babystep.h"
|
|
||||||
#if !HAS_BED_PROBE
|
|
||||||
#define JUST_BABYSTEP 1
|
|
||||||
#endif
|
|
||||||
#endif
|
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#if ENABLED(POWER_LOSS_RECOVERY)
|
#if ENABLED(POWER_LOSS_RECOVERY)
|
||||||
@ -197,8 +191,8 @@
|
|||||||
#define DWIN_UPDATE_INTERVAL 1024
|
#define DWIN_UPDATE_INTERVAL 1024
|
||||||
#define DWIN_REMAIN_TIME_UPDATE_INTERVAL SEC_TO_MS(20)
|
#define DWIN_REMAIN_TIME_UPDATE_INTERVAL SEC_TO_MS(20)
|
||||||
|
|
||||||
#if HAS_MESH
|
#if HAS_MESH && HAS_BED_PROBE
|
||||||
#define BABY_Z_VAR TERN(HAS_BED_PROBE, probe.offset.z, HMI_data.ManualZOffset)
|
#define BABY_Z_VAR probe.offset.z
|
||||||
#else
|
#else
|
||||||
float z_offset = 0;
|
float z_offset = 0;
|
||||||
#define BABY_Z_VAR z_offset
|
#define BABY_Z_VAR z_offset
|
||||||
@ -1473,10 +1467,6 @@ void DWIN_HomingStart() {
|
|||||||
|
|
||||||
void DWIN_HomingDone() {
|
void DWIN_HomingDone() {
|
||||||
HMI_flag.home_flag = false;
|
HMI_flag.home_flag = false;
|
||||||
#if DISABLED(HAS_BED_PROBE) && EITHER(BABYSTEP_ZPROBE_OFFSET, JUST_BABYSTEP)
|
|
||||||
planner.synchronize();
|
|
||||||
babystep.add_mm(Z_AXIS, HMI_data.ManualZOffset);
|
|
||||||
#endif
|
|
||||||
HMI_ReturnScreen();
|
HMI_ReturnScreen();
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -1696,7 +1686,6 @@ void DWIN_SetDataDefaults() {
|
|||||||
#if BOTH(INDIVIDUAL_AXIS_HOMING_SUBMENU, MESH_BED_LEVELING)
|
#if BOTH(INDIVIDUAL_AXIS_HOMING_SUBMENU, MESH_BED_LEVELING)
|
||||||
HMI_data.z_after_homing = DEF_Z_AFTER_HOMING;
|
HMI_data.z_after_homing = DEF_Z_AFTER_HOMING;
|
||||||
#endif
|
#endif
|
||||||
IF_DISABLED(HAS_BED_PROBE, HMI_data.ManualZOffset = 0);
|
|
||||||
#if BOTH(LED_CONTROL_MENU, HAS_COLOR_LEDS)
|
#if BOTH(LED_CONTROL_MENU, HAS_COLOR_LEDS)
|
||||||
TERN_(LED_COLOR_PRESETS, leds.set_default());
|
TERN_(LED_COLOR_PRESETS, leds.set_default());
|
||||||
ApplyLEDColor();
|
ApplyLEDColor();
|
||||||
|
@ -35,6 +35,13 @@
|
|||||||
#include "../common/encoder.h"
|
#include "../common/encoder.h"
|
||||||
#include "../../../libs/BL24CXX.h"
|
#include "../../../libs/BL24CXX.h"
|
||||||
|
|
||||||
|
#if EITHER(BABYSTEPPING, HAS_BED_PROBE)
|
||||||
|
#define HAS_ZOFFSET_ITEM 1
|
||||||
|
#if !HAS_BED_PROBE
|
||||||
|
#define JUST_BABYSTEP 1
|
||||||
|
#endif
|
||||||
|
#endif
|
||||||
|
|
||||||
namespace GET_LANG(LCD_LANGUAGE) {
|
namespace GET_LANG(LCD_LANGUAGE) {
|
||||||
#define _MSG_PREHEAT(N) \
|
#define _MSG_PREHEAT(N) \
|
||||||
LSTR MSG_PREHEAT_##N = _UxGT("Preheat ") PREHEAT_## N ##_LABEL; \
|
LSTR MSG_PREHEAT_##N = _UxGT("Preheat ") PREHEAT_## N ##_LABEL; \
|
||||||
@ -118,15 +125,12 @@ typedef struct {
|
|||||||
#if ENABLED(BAUD_RATE_GCODE)
|
#if ENABLED(BAUD_RATE_GCODE)
|
||||||
bool Baud115K = false;
|
bool Baud115K = false;
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
bool FullManualTramming = false;
|
bool FullManualTramming = false;
|
||||||
bool MediaAutoMount = ENABLED(HAS_SD_EXTENDER);
|
bool MediaAutoMount = ENABLED(HAS_SD_EXTENDER);
|
||||||
#if BOTH(INDIVIDUAL_AXIS_HOMING_SUBMENU, MESH_BED_LEVELING)
|
#if BOTH(INDIVIDUAL_AXIS_HOMING_SUBMENU, MESH_BED_LEVELING)
|
||||||
uint8_t z_after_homing = DEF_Z_AFTER_HOMING;
|
uint8_t z_after_homing = DEF_Z_AFTER_HOMING;
|
||||||
#endif
|
#endif
|
||||||
#if ENABLED(MESH_BED_LEVELING)
|
|
||||||
float ManualZOffset = 0;
|
|
||||||
#endif
|
|
||||||
// Led
|
|
||||||
#if BOTH(LED_CONTROL_MENU, HAS_COLOR_LEDS)
|
#if BOTH(LED_CONTROL_MENU, HAS_COLOR_LEDS)
|
||||||
LEDColor Led_Color = Def_Leds_Color;
|
LEDColor Led_Color = Def_Leds_Color;
|
||||||
#endif
|
#endif
|
||||||
|
@ -68,10 +68,12 @@
|
|||||||
//
|
//
|
||||||
void _lcd_level_bed_done() {
|
void _lcd_level_bed_done() {
|
||||||
if (!ui.wait_for_move) {
|
if (!ui.wait_for_move) {
|
||||||
#if Z_AFTER_PROBING > 0 && DISABLED(MESH_BED_LEVELING)
|
#if DISABLED(MESH_BED_LEVELING) && defined(Z_AFTER_PROBING)
|
||||||
// Display "Done" screen and wait for moves to complete
|
if (Z_AFTER_PROBING) {
|
||||||
line_to_z(Z_AFTER_PROBING);
|
// Display "Done" screen and wait for moves to complete
|
||||||
ui.synchronize(GET_TEXT_F(MSG_LEVEL_BED_DONE));
|
line_to_z(Z_AFTER_PROBING);
|
||||||
|
ui.synchronize(GET_TEXT_F(MSG_LEVEL_BED_DONE));
|
||||||
|
}
|
||||||
#endif
|
#endif
|
||||||
ui.goto_previous_screen_no_defer();
|
ui.goto_previous_screen_no_defer();
|
||||||
ui.completion_feedback();
|
ui.completion_feedback();
|
||||||
|
@ -161,11 +161,9 @@ public:
|
|||||||
#endif
|
#endif
|
||||||
|
|
||||||
static void move_z_after_homing() {
|
static void move_z_after_homing() {
|
||||||
#if ALL(DWIN_LCD_PROUI, INDIVIDUAL_AXIS_HOMING_SUBMENU, MESH_BED_LEVELING)
|
#if ALL(DWIN_LCD_PROUI, INDIVIDUAL_AXIS_HOMING_SUBMENU, MESH_BED_LEVELING) || defined(Z_AFTER_HOMING)
|
||||||
do_z_clearance(HMI_data.z_after_homing, true);
|
do_z_clearance(Z_POST_CLEARANCE, true);
|
||||||
#elif defined(Z_AFTER_HOMING)
|
#elif HAS_BED_PROBE
|
||||||
do_z_clearance(Z_AFTER_HOMING, true);
|
|
||||||
#elif BOTH(Z_AFTER_PROBING, HAS_BED_PROBE)
|
|
||||||
move_z_after_probing();
|
move_z_after_probing();
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user