Z_DUAL_ENDSTOP - make offset a configuration item
The offset for Z_DUAL_ENDSTOP (z_endstop_adj) is already in Marlin. This PR just makes it a configuration item. z_endstop_adj is initialized in two places so both had to be modified.
This commit is contained in:
parent
3b6333c613
commit
62cbaa302e
|
@ -285,6 +285,7 @@
|
||||||
|
|
||||||
#if ENABLED(Z_DUAL_ENDSTOPS)
|
#if ENABLED(Z_DUAL_ENDSTOPS)
|
||||||
#define Z2_USE_ENDSTOP _XMAX_
|
#define Z2_USE_ENDSTOP _XMAX_
|
||||||
|
#define Z_DUAL_ENDSTOPS_ADJUSTMENT 0 // use M666 command to determine/test this value
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#endif // Z_DUAL_STEPPER_DRIVERS
|
#endif // Z_DUAL_STEPPER_DRIVERS
|
||||||
|
|
|
@ -963,7 +963,11 @@ void Config_ResetDefault() {
|
||||||
COPY(delta_diagonal_rod_trim, drt);
|
COPY(delta_diagonal_rod_trim, drt);
|
||||||
COPY(delta_tower_angle_trim, dta);
|
COPY(delta_tower_angle_trim, dta);
|
||||||
#elif ENABLED(Z_DUAL_ENDSTOPS)
|
#elif ENABLED(Z_DUAL_ENDSTOPS)
|
||||||
z_endstop_adj = 0;
|
#if defined(Z_DUAL_ENDSTOPS_ADJUSTMENT)
|
||||||
|
float z_endstop_adj = Z_DUAL_ENDSTOPS_ADJUSTMENT;
|
||||||
|
#else
|
||||||
|
float z_endstop_adj = 0;
|
||||||
|
#endif
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#if ENABLED(ULTIPANEL)
|
#if ENABLED(ULTIPANEL)
|
||||||
|
|
|
@ -285,6 +285,7 @@
|
||||||
|
|
||||||
#if ENABLED(Z_DUAL_ENDSTOPS)
|
#if ENABLED(Z_DUAL_ENDSTOPS)
|
||||||
#define Z2_USE_ENDSTOP _XMAX_
|
#define Z2_USE_ENDSTOP _XMAX_
|
||||||
|
#define Z_DUAL_ENDSTOPS_ADJUSTMENT 0 // use M666 command to determine this value
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#endif // Z_DUAL_STEPPER_DRIVERS
|
#endif // Z_DUAL_STEPPER_DRIVERS
|
||||||
|
|
|
@ -285,6 +285,7 @@
|
||||||
|
|
||||||
#if ENABLED(Z_DUAL_ENDSTOPS)
|
#if ENABLED(Z_DUAL_ENDSTOPS)
|
||||||
#define Z2_USE_ENDSTOP _XMAX_
|
#define Z2_USE_ENDSTOP _XMAX_
|
||||||
|
#define Z_DUAL_ENDSTOPS_ADJUSTMENT 0 // use M666 command to determine this value
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#endif // Z_DUAL_STEPPER_DRIVERS
|
#endif // Z_DUAL_STEPPER_DRIVERS
|
||||||
|
|
|
@ -285,6 +285,7 @@
|
||||||
|
|
||||||
#if ENABLED(Z_DUAL_ENDSTOPS)
|
#if ENABLED(Z_DUAL_ENDSTOPS)
|
||||||
#define Z2_USE_ENDSTOP _XMAX_
|
#define Z2_USE_ENDSTOP _XMAX_
|
||||||
|
#define Z_DUAL_ENDSTOPS_ADJUSTMENT 0 // use M666 command to determine this value
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#endif // Z_DUAL_STEPPER_DRIVERS
|
#endif // Z_DUAL_STEPPER_DRIVERS
|
||||||
|
|
|
@ -285,6 +285,7 @@
|
||||||
|
|
||||||
#if ENABLED(Z_DUAL_ENDSTOPS)
|
#if ENABLED(Z_DUAL_ENDSTOPS)
|
||||||
#define Z2_USE_ENDSTOP _XMAX_
|
#define Z2_USE_ENDSTOP _XMAX_
|
||||||
|
#define Z_DUAL_ENDSTOPS_ADJUSTMENT 0 // use M666 command to determine this value
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#endif // Z_DUAL_STEPPER_DRIVERS
|
#endif // Z_DUAL_STEPPER_DRIVERS
|
||||||
|
|
|
@ -298,6 +298,7 @@
|
||||||
|
|
||||||
#if ENABLED(Z_DUAL_ENDSTOPS)
|
#if ENABLED(Z_DUAL_ENDSTOPS)
|
||||||
#define Z2_USE_ENDSTOP _XMAX_
|
#define Z2_USE_ENDSTOP _XMAX_
|
||||||
|
#define Z_DUAL_ENDSTOPS_ADJUSTMENT 0 // use M666 command to determine this value
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#endif // Z_DUAL_STEPPER_DRIVERS
|
#endif // Z_DUAL_STEPPER_DRIVERS
|
||||||
|
|
|
@ -285,6 +285,7 @@
|
||||||
|
|
||||||
#if ENABLED(Z_DUAL_ENDSTOPS)
|
#if ENABLED(Z_DUAL_ENDSTOPS)
|
||||||
#define Z2_USE_ENDSTOP _XMAX_
|
#define Z2_USE_ENDSTOP _XMAX_
|
||||||
|
#define Z_DUAL_ENDSTOPS_ADJUSTMENT 0 // use M666 command to determine this value
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#endif // Z_DUAL_STEPPER_DRIVERS
|
#endif // Z_DUAL_STEPPER_DRIVERS
|
||||||
|
|
|
@ -285,6 +285,7 @@
|
||||||
|
|
||||||
#if ENABLED(Z_DUAL_ENDSTOPS)
|
#if ENABLED(Z_DUAL_ENDSTOPS)
|
||||||
#define Z2_USE_ENDSTOP _XMAX_
|
#define Z2_USE_ENDSTOP _XMAX_
|
||||||
|
#define Z_DUAL_ENDSTOPS_ADJUSTMENT 0 // use M666 command to determine this value
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#endif // Z_DUAL_STEPPER_DRIVERS
|
#endif // Z_DUAL_STEPPER_DRIVERS
|
||||||
|
|
|
@ -285,6 +285,7 @@
|
||||||
|
|
||||||
#if ENABLED(Z_DUAL_ENDSTOPS)
|
#if ENABLED(Z_DUAL_ENDSTOPS)
|
||||||
#define Z2_USE_ENDSTOP _XMAX_
|
#define Z2_USE_ENDSTOP _XMAX_
|
||||||
|
#define Z_DUAL_ENDSTOPS_ADJUSTMENT 0 // use M666 command to determine this value
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#endif // Z_DUAL_STEPPER_DRIVERS
|
#endif // Z_DUAL_STEPPER_DRIVERS
|
||||||
|
|
|
@ -293,6 +293,7 @@
|
||||||
|
|
||||||
#if ENABLED(Z_DUAL_ENDSTOPS)
|
#if ENABLED(Z_DUAL_ENDSTOPS)
|
||||||
#define Z2_USE_ENDSTOP _XMAX_
|
#define Z2_USE_ENDSTOP _XMAX_
|
||||||
|
#define Z_DUAL_ENDSTOPS_ADJUSTMENT 0 // use M666 command to determine this value
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#endif // Z_DUAL_STEPPER_DRIVERS
|
#endif // Z_DUAL_STEPPER_DRIVERS
|
||||||
|
|
|
@ -285,6 +285,7 @@
|
||||||
|
|
||||||
#if ENABLED(Z_DUAL_ENDSTOPS)
|
#if ENABLED(Z_DUAL_ENDSTOPS)
|
||||||
#define Z2_USE_ENDSTOP _XMAX_
|
#define Z2_USE_ENDSTOP _XMAX_
|
||||||
|
#define Z_DUAL_ENDSTOPS_ADJUSTMENT 0 // use M666 command to determine this value
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#endif // Z_DUAL_STEPPER_DRIVERS
|
#endif // Z_DUAL_STEPPER_DRIVERS
|
||||||
|
|
|
@ -285,6 +285,7 @@
|
||||||
|
|
||||||
#if ENABLED(Z_DUAL_ENDSTOPS)
|
#if ENABLED(Z_DUAL_ENDSTOPS)
|
||||||
#define Z2_USE_ENDSTOP _XMAX_
|
#define Z2_USE_ENDSTOP _XMAX_
|
||||||
|
#define Z_DUAL_ENDSTOPS_ADJUSTMENT 0 // use M666 command to determine this value
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#endif // Z_DUAL_STEPPER_DRIVERS
|
#endif // Z_DUAL_STEPPER_DRIVERS
|
||||||
|
|
|
@ -285,6 +285,7 @@
|
||||||
|
|
||||||
#if ENABLED(Z_DUAL_ENDSTOPS)
|
#if ENABLED(Z_DUAL_ENDSTOPS)
|
||||||
#define Z2_USE_ENDSTOP _XMAX_
|
#define Z2_USE_ENDSTOP _XMAX_
|
||||||
|
#define Z_DUAL_ENDSTOPS_ADJUSTMENT 0 // use M666 command to determine this value
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#endif // Z_DUAL_STEPPER_DRIVERS
|
#endif // Z_DUAL_STEPPER_DRIVERS
|
||||||
|
|
|
@ -285,6 +285,7 @@
|
||||||
|
|
||||||
#if ENABLED(Z_DUAL_ENDSTOPS)
|
#if ENABLED(Z_DUAL_ENDSTOPS)
|
||||||
#define Z2_USE_ENDSTOP _XMAX_
|
#define Z2_USE_ENDSTOP _XMAX_
|
||||||
|
#define Z_DUAL_ENDSTOPS_ADJUSTMENT 0 // use M666 command to determine this value
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#endif // Z_DUAL_STEPPER_DRIVERS
|
#endif // Z_DUAL_STEPPER_DRIVERS
|
||||||
|
|
|
@ -290,6 +290,7 @@
|
||||||
|
|
||||||
#if ENABLED(Z_DUAL_ENDSTOPS)
|
#if ENABLED(Z_DUAL_ENDSTOPS)
|
||||||
#define Z2_USE_ENDSTOP _XMAX_
|
#define Z2_USE_ENDSTOP _XMAX_
|
||||||
|
#define Z_DUAL_ENDSTOPS_ADJUSTMENT 0 // use M666 command to determine this value
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#endif // Z_DUAL_STEPPER_DRIVERS
|
#endif // Z_DUAL_STEPPER_DRIVERS
|
||||||
|
|
|
@ -285,6 +285,7 @@
|
||||||
|
|
||||||
#if ENABLED(Z_DUAL_ENDSTOPS)
|
#if ENABLED(Z_DUAL_ENDSTOPS)
|
||||||
#define Z2_USE_ENDSTOP _XMAX_
|
#define Z2_USE_ENDSTOP _XMAX_
|
||||||
|
#define Z_DUAL_ENDSTOPS_ADJUSTMENT 0 // use M666 command to determine this value
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#endif // Z_DUAL_STEPPER_DRIVERS
|
#endif // Z_DUAL_STEPPER_DRIVERS
|
||||||
|
|
|
@ -285,6 +285,7 @@
|
||||||
|
|
||||||
#if ENABLED(Z_DUAL_ENDSTOPS)
|
#if ENABLED(Z_DUAL_ENDSTOPS)
|
||||||
#define Z2_USE_ENDSTOP _XMAX_
|
#define Z2_USE_ENDSTOP _XMAX_
|
||||||
|
#define Z_DUAL_ENDSTOPS_ADJUSTMENT 0 // use M666 command to determine this value
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#endif // Z_DUAL_STEPPER_DRIVERS
|
#endif // Z_DUAL_STEPPER_DRIVERS
|
||||||
|
|
|
@ -285,6 +285,7 @@
|
||||||
|
|
||||||
#if ENABLED(Z_DUAL_ENDSTOPS)
|
#if ENABLED(Z_DUAL_ENDSTOPS)
|
||||||
#define Z2_USE_ENDSTOP _XMAX_
|
#define Z2_USE_ENDSTOP _XMAX_
|
||||||
|
#define Z_DUAL_ENDSTOPS_ADJUSTMENT 0 // use M666 command to determine this value
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#endif // Z_DUAL_STEPPER_DRIVERS
|
#endif // Z_DUAL_STEPPER_DRIVERS
|
||||||
|
|
Loading…
Reference in a new issue