|
@@ -1876,19 +1876,19 @@ static_assert(X_MAX_LENGTH >= X_BED_SIZE, "Movement bounds (X_MIN_POS, X_MAX_POS
|
|
#endif
|
|
#endif
|
|
|
|
|
|
#if ENABLED(INVERTED_PROBE_STATE)
|
|
#if ENABLED(INVERTED_PROBE_STATE)
|
|
- #if !Z_MIN_PROBE_ENDSTOP_INVERTING
|
|
|
|
- #error "BLTOUCH requires Z_MIN_PROBE_ENDSTOP_INVERTING set to true."
|
|
|
|
|
|
+ #if Z_MIN_PROBE_ENDSTOP_HIT_STATE != LOW
|
|
|
|
+ #error "BLTOUCH requires Z_MIN_PROBE_ENDSTOP_HIT_STATE LOW."
|
|
#endif
|
|
#endif
|
|
- #elif Z_MIN_PROBE_ENDSTOP_INVERTING
|
|
|
|
- #error "BLTOUCH requires Z_MIN_PROBE_ENDSTOP_INVERTING set to false."
|
|
|
|
|
|
+ #elif Z_MIN_PROBE_ENDSTOP_HIT_STATE != HIGH
|
|
|
|
+ #error "BLTOUCH requires Z_MIN_PROBE_ENDSTOP_HIT_STATE HIGH."
|
|
#endif
|
|
#endif
|
|
#if ENABLED(Z_MIN_PROBE_USES_Z_MIN_ENDSTOP_PIN)
|
|
#if ENABLED(Z_MIN_PROBE_USES_Z_MIN_ENDSTOP_PIN)
|
|
#if ENABLED(INVERTED_PROBE_STATE)
|
|
#if ENABLED(INVERTED_PROBE_STATE)
|
|
- #if !Z_MIN_ENDSTOP_INVERTING
|
|
|
|
- #error "BLTOUCH requires Z_MIN_ENDSTOP_INVERTING set to true."
|
|
|
|
|
|
+ #if Z_MIN_ENDSTOP_HIT_STATE != LOW
|
|
|
|
+ #error "BLTOUCH requires Z_MIN_ENDSTOP_HIT_STATE LOW."
|
|
#endif
|
|
#endif
|
|
- #elif Z_MIN_ENDSTOP_INVERTING
|
|
|
|
- #error "BLTOUCH requires Z_MIN_ENDSTOP_INVERTING set to false."
|
|
|
|
|
|
+ #elif Z_MIN_ENDSTOP_HIT_STATE != HIGH
|
|
|
|
+ #error "BLTOUCH requires Z_MIN_ENDSTOP_HIT_STATE HIGH."
|
|
#endif
|
|
#endif
|
|
#endif
|
|
#endif
|
|
|
|
|
|
@@ -1916,19 +1916,19 @@ static_assert(X_MAX_LENGTH >= X_BED_SIZE, "Movement bounds (X_MIN_POS, X_MAX_POS
|
|
#error "TOUCH_MI_PROBE currently requires an LCD controller or EMERGENCY_PARSER."
|
|
#error "TOUCH_MI_PROBE currently requires an LCD controller or EMERGENCY_PARSER."
|
|
#endif
|
|
#endif
|
|
#if ENABLED(INVERTED_PROBE_STATE)
|
|
#if ENABLED(INVERTED_PROBE_STATE)
|
|
- #if !Z_MIN_PROBE_ENDSTOP_INVERTING
|
|
|
|
- #error "TOUCH_MI_PROBE requires Z_MIN_PROBE_ENDSTOP_INVERTING set to true."
|
|
|
|
|
|
+ #if Z_MIN_PROBE_ENDSTOP_HIT_STATE != LOW
|
|
|
|
+ #error "TOUCH_MI_PROBE requires Z_MIN_PROBE_ENDSTOP_HIT_STATE LOW."
|
|
#endif
|
|
#endif
|
|
- #elif Z_MIN_PROBE_ENDSTOP_INVERTING
|
|
|
|
- #error "TOUCH_MI_PROBE requires Z_MIN_PROBE_ENDSTOP_INVERTING set to false."
|
|
|
|
|
|
+ #elif Z_MIN_PROBE_ENDSTOP_HIT_STATE != HIGH
|
|
|
|
+ #error "TOUCH_MI_PROBE requires Z_MIN_PROBE_ENDSTOP_HIT_STATE HIGH."
|
|
#endif
|
|
#endif
|
|
#if ENABLED(Z_MIN_PROBE_USES_Z_MIN_ENDSTOP_PIN)
|
|
#if ENABLED(Z_MIN_PROBE_USES_Z_MIN_ENDSTOP_PIN)
|
|
#if ENABLED(INVERTED_PROBE_STATE)
|
|
#if ENABLED(INVERTED_PROBE_STATE)
|
|
- #if !Z_MIN_ENDSTOP_INVERTING
|
|
|
|
- #error "TOUCH_MI_PROBE requires Z_MIN_ENDSTOP_INVERTING set to true."
|
|
|
|
|
|
+ #if Z_MIN_ENDSTOP_HIT_STATE != LOW
|
|
|
|
+ #error "TOUCH_MI_PROBE requires Z_MIN_ENDSTOP_HIT_STATE LOW."
|
|
#endif
|
|
#endif
|
|
- #elif Z_MIN_ENDSTOP_INVERTING
|
|
|
|
- #error "TOUCH_MI_PROBE requires Z_MIN_ENDSTOP_INVERTING set to false."
|
|
|
|
|
|
+ #elif Z_MIN_ENDSTOP_HIT_STATE != HIGH
|
|
|
|
+ #error "TOUCH_MI_PROBE requires Z_MIN_ENDSTOP_HIT_STATE HIGH."
|
|
#endif
|
|
#endif
|
|
#endif
|
|
#endif
|
|
#endif // TOUCH_MI_PROBE
|
|
#endif // TOUCH_MI_PROBE
|
|
@@ -1967,8 +1967,8 @@ static_assert(X_MAX_LENGTH >= X_BED_SIZE, "Movement bounds (X_MIN_POS, X_MAX_POS
|
|
#error "Z_MIN_PROBE_USES_Z_MIN_ENDSTOP_PIN requires USE_ZMIN_PLUG to be enabled."
|
|
#error "Z_MIN_PROBE_USES_Z_MIN_ENDSTOP_PIN requires USE_ZMIN_PLUG to be enabled."
|
|
#elif !HAS_Z_MIN
|
|
#elif !HAS_Z_MIN
|
|
#error "Z_MIN_PROBE_USES_Z_MIN_ENDSTOP_PIN requires the Z_MIN_PIN to be defined."
|
|
#error "Z_MIN_PROBE_USES_Z_MIN_ENDSTOP_PIN requires the Z_MIN_PIN to be defined."
|
|
- #elif Z_MIN_PROBE_ENDSTOP_INVERTING != Z_MIN_ENDSTOP_INVERTING
|
|
|
|
- #error "Z_MIN_PROBE_USES_Z_MIN_ENDSTOP_PIN requires Z_MIN_ENDSTOP_INVERTING to match Z_MIN_PROBE_ENDSTOP_INVERTING."
|
|
|
|
|
|
+ #elif Z_MIN_PROBE_ENDSTOP_HIT_STATE != Z_MIN_ENDSTOP_HIT_STATE
|
|
|
|
+ #error "Z_MIN_PROBE_USES_Z_MIN_ENDSTOP_PIN requires Z_MIN_ENDSTOP_HIT_STATE to match Z_MIN_PROBE_ENDSTOP_HIT_STATE."
|
|
#endif
|
|
#endif
|
|
#elif !HAS_Z_MIN_PROBE_PIN
|
|
#elif !HAS_Z_MIN_PROBE_PIN
|
|
#error "Z_MIN_PROBE_PIN must be defined if Z_MIN_PROBE_USES_Z_MIN_ENDSTOP_PIN is not enabled."
|
|
#error "Z_MIN_PROBE_PIN must be defined if Z_MIN_PROBE_USES_Z_MIN_ENDSTOP_PIN is not enabled."
|
|
@@ -3449,17 +3449,17 @@ static_assert(X_MAX_LENGTH >= X_BED_SIZE, "Movement bounds (X_MIN_POS, X_MAX_POS
|
|
#error "TMC2208 or TMC2209 on E6 requires E6_HARDWARE_SERIAL or E6_SERIAL_(RX|TX)_PIN."
|
|
#error "TMC2208 or TMC2209 on E6 requires E6_HARDWARE_SERIAL or E6_SERIAL_(RX|TX)_PIN."
|
|
#elif INVALID_TMC_UART(E7)
|
|
#elif INVALID_TMC_UART(E7)
|
|
#error "TMC2208 or TMC2209 on E7 requires E7_HARDWARE_SERIAL or E7_SERIAL_(RX|TX)_PIN."
|
|
#error "TMC2208 or TMC2209 on E7 requires E7_HARDWARE_SERIAL or E7_SERIAL_(RX|TX)_PIN."
|
|
-#elif HAS_I_AXIS && INVALID_TMC_UART(I)
|
|
|
|
|
|
+#elif INVALID_TMC_UART(I)
|
|
#error "TMC2208 or TMC2209 on I requires I_HARDWARE_SERIAL or I_SERIAL_(RX|TX)_PIN."
|
|
#error "TMC2208 or TMC2209 on I requires I_HARDWARE_SERIAL or I_SERIAL_(RX|TX)_PIN."
|
|
-#elif HAS_J_AXIS && INVALID_TMC_UART(J)
|
|
|
|
|
|
+#elif INVALID_TMC_UART(J)
|
|
#error "TMC2208 or TMC2209 on J requires J_HARDWARE_SERIAL or J_SERIAL_(RX|TX)_PIN."
|
|
#error "TMC2208 or TMC2209 on J requires J_HARDWARE_SERIAL or J_SERIAL_(RX|TX)_PIN."
|
|
-#elif HAS_K_AXIS && INVALID_TMC_UART(K)
|
|
|
|
|
|
+#elif INVALID_TMC_UART(K)
|
|
#error "TMC2208 or TMC2209 on K requires K_HARDWARE_SERIAL or K_SERIAL_(RX|TX)_PIN."
|
|
#error "TMC2208 or TMC2209 on K requires K_HARDWARE_SERIAL or K_SERIAL_(RX|TX)_PIN."
|
|
-#elif HAS_U_AXIS && INVALID_TMC_UART(U)
|
|
|
|
|
|
+#elif INVALID_TMC_UART(U)
|
|
#error "TMC2208 or TMC2209 on U requires U_HARDWARE_SERIAL or U_SERIAL_(RX|TX)_PIN."
|
|
#error "TMC2208 or TMC2209 on U requires U_HARDWARE_SERIAL or U_SERIAL_(RX|TX)_PIN."
|
|
-#elif HAS_V_AXIS && INVALID_TMC_UART(V)
|
|
|
|
|
|
+#elif INVALID_TMC_UART(V)
|
|
#error "TMC2208 or TMC2209 on V requires V_HARDWARE_SERIAL or V_SERIAL_(RX|TX)_PIN."
|
|
#error "TMC2208 or TMC2209 on V requires V_HARDWARE_SERIAL or V_SERIAL_(RX|TX)_PIN."
|
|
-#elif HAS_W_AXIS && INVALID_TMC_UART(W)
|
|
|
|
|
|
+#elif INVALID_TMC_UART(W)
|
|
#error "TMC2208 or TMC2209 on W requires W_HARDWARE_SERIAL or W_SERIAL_(RX|TX)_PIN."
|
|
#error "TMC2208 or TMC2209 on W requires W_HARDWARE_SERIAL or W_SERIAL_(RX|TX)_PIN."
|
|
|
|
|
|
#endif
|
|
#endif
|
|
@@ -3552,17 +3552,17 @@ static_assert(X_MAX_LENGTH >= X_BED_SIZE, "Movement bounds (X_MIN_POS, X_MAX_POS
|
|
INVALID_TMC_MS(E6)
|
|
INVALID_TMC_MS(E6)
|
|
#elif !TMC_MICROSTEP_IS_VALID(E7)
|
|
#elif !TMC_MICROSTEP_IS_VALID(E7)
|
|
INVALID_TMC_MS(E7)
|
|
INVALID_TMC_MS(E7)
|
|
-#elif HAS_I_AXIS && !TMC_MICROSTEP_IS_VALID(I)
|
|
|
|
|
|
+#elif !TMC_MICROSTEP_IS_VALID(I)
|
|
INVALID_TMC_MS(I)
|
|
INVALID_TMC_MS(I)
|
|
-#elif HAS_J_AXIS && !TMC_MICROSTEP_IS_VALID(J)
|
|
|
|
|
|
+#elif !TMC_MICROSTEP_IS_VALID(J)
|
|
INVALID_TMC_MS(J)
|
|
INVALID_TMC_MS(J)
|
|
-#elif HAS_K_AXIS && !TMC_MICROSTEP_IS_VALID(K)
|
|
|
|
|
|
+#elif !TMC_MICROSTEP_IS_VALID(K)
|
|
INVALID_TMC_MS(K)
|
|
INVALID_TMC_MS(K)
|
|
-#elif HAS_U_AXIS && !TMC_MICROSTEP_IS_VALID(U)
|
|
|
|
|
|
+#elif !TMC_MICROSTEP_IS_VALID(U)
|
|
INVALID_TMC_MS(U)
|
|
INVALID_TMC_MS(U)
|
|
-#elif HAS_V_AXIS && !TMC_MICROSTEP_IS_VALID(V)
|
|
|
|
|
|
+#elif !TMC_MICROSTEP_IS_VALID(V)
|
|
INVALID_TMC_MS(V)
|
|
INVALID_TMC_MS(V)
|
|
-#elif HAS_W_AXIS && !TMC_MICROSTEP_IS_VALID(W)
|
|
|
|
|
|
+#elif !TMC_MICROSTEP_IS_VALID(W)
|
|
INVALID_TMC_MS(W)
|
|
INVALID_TMC_MS(W)
|
|
#endif
|
|
#endif
|
|
#undef INVALID_TMC_MS
|
|
#undef INVALID_TMC_MS
|
|
@@ -3579,67 +3579,43 @@ static_assert(X_MAX_LENGTH >= X_BED_SIZE, "Movement bounds (X_MIN_POS, X_MAX_POS
|
|
// towers to +Z and the individual homing of each tower. This restriction can be removed once a means of
|
|
// towers to +Z and the individual homing of each tower. This restriction can be removed once a means of
|
|
// clearing the stallGuard activated status is found.
|
|
// clearing the stallGuard activated status is found.
|
|
|
|
|
|
- // Stall detection DIAG = HIGH : TMC2209
|
|
|
|
- // Stall detection DIAG = LOW : TMC2130/TMC2160/TMC2660/TMC5130/TMC5160
|
|
|
|
- #define X_ENDSTOP_INVERTING !AXIS_DRIVER_TYPE(X,TMC2209)
|
|
|
|
- #define Y_ENDSTOP_INVERTING !AXIS_DRIVER_TYPE(Y,TMC2209)
|
|
|
|
- #define Z_ENDSTOP_INVERTING !AXIS_DRIVER_TYPE(Z,TMC2209)
|
|
|
|
- #if HAS_I_AXIS
|
|
|
|
- #define I_ENDSTOP_INVERTING !AXIS_DRIVER_TYPE(I,TMC2209)
|
|
|
|
- #endif
|
|
|
|
- #if HAS_J_AXIS
|
|
|
|
- #define J_ENDSTOP_INVERTING !AXIS_DRIVER_TYPE(J,TMC2209)
|
|
|
|
- #endif
|
|
|
|
- #if HAS_K_AXIS
|
|
|
|
- #define K_ENDSTOP_INVERTING !AXIS_DRIVER_TYPE(K,TMC2209)
|
|
|
|
- #endif
|
|
|
|
- #if HAS_U_AXIS
|
|
|
|
- #define U_ENDSTOP_INVERTING !AXIS_DRIVER_TYPE(U,TMC2209)
|
|
|
|
- #endif
|
|
|
|
- #if HAS_V_AXIS
|
|
|
|
- #define V_ENDSTOP_INVERTING !AXIS_DRIVER_TYPE(V,TMC2209)
|
|
|
|
- #endif
|
|
|
|
- #if HAS_W_AXIS
|
|
|
|
- #define W_ENDSTOP_INVERTING !AXIS_DRIVER_TYPE(W,TMC2209)
|
|
|
|
- #endif
|
|
|
|
-
|
|
|
|
#if NONE(SPI_ENDSTOPS, ONBOARD_ENDSTOPPULLUPS, ENDSTOPPULLUPS)
|
|
#if NONE(SPI_ENDSTOPS, ONBOARD_ENDSTOPPULLUPS, ENDSTOPPULLUPS)
|
|
#if X_SENSORLESS && X_HOME_TO_MIN && DISABLED(ENDSTOPPULLUP_XMIN)
|
|
#if X_SENSORLESS && X_HOME_TO_MIN && DISABLED(ENDSTOPPULLUP_XMIN)
|
|
- #error "SENSORLESS_HOMING requires ENDSTOPPULLUP_XMIN (or ENDSTOPPULLUPS) when homing to X_MIN."
|
|
|
|
|
|
+ #error "SENSORLESS_HOMING requires ENDSTOPPULLUP_XMIN (or ENDSTOPPULLUPS) for X_MIN homing."
|
|
#elif X_SENSORLESS && X_HOME_TO_MAX && DISABLED(ENDSTOPPULLUP_XMAX)
|
|
#elif X_SENSORLESS && X_HOME_TO_MAX && DISABLED(ENDSTOPPULLUP_XMAX)
|
|
- #error "SENSORLESS_HOMING requires ENDSTOPPULLUP_XMAX (or ENDSTOPPULLUPS) when homing to X_MAX."
|
|
|
|
|
|
+ #error "SENSORLESS_HOMING requires ENDSTOPPULLUP_XMAX (or ENDSTOPPULLUPS) for X_MAX homing."
|
|
#elif Y_SENSORLESS && Y_HOME_TO_MIN && DISABLED(ENDSTOPPULLUP_YMIN)
|
|
#elif Y_SENSORLESS && Y_HOME_TO_MIN && DISABLED(ENDSTOPPULLUP_YMIN)
|
|
- #error "SENSORLESS_HOMING requires ENDSTOPPULLUP_YMIN (or ENDSTOPPULLUPS) when homing to Y_MIN."
|
|
|
|
|
|
+ #error "SENSORLESS_HOMING requires ENDSTOPPULLUP_YMIN (or ENDSTOPPULLUPS) for Y_MIN homing."
|
|
#elif Y_SENSORLESS && Y_HOME_TO_MAX && DISABLED(ENDSTOPPULLUP_YMAX)
|
|
#elif Y_SENSORLESS && Y_HOME_TO_MAX && DISABLED(ENDSTOPPULLUP_YMAX)
|
|
- #error "SENSORLESS_HOMING requires ENDSTOPPULLUP_YMAX (or ENDSTOPPULLUPS) when homing to Y_MAX."
|
|
|
|
|
|
+ #error "SENSORLESS_HOMING requires ENDSTOPPULLUP_YMAX (or ENDSTOPPULLUPS) for Y_MAX homing."
|
|
#elif Z_SENSORLESS && Z_HOME_TO_MIN && DISABLED(ENDSTOPPULLUP_ZMIN)
|
|
#elif Z_SENSORLESS && Z_HOME_TO_MIN && DISABLED(ENDSTOPPULLUP_ZMIN)
|
|
- #error "SENSORLESS_HOMING requires ENDSTOPPULLUP_ZMIN (or ENDSTOPPULLUPS) when homing to Z_MIN."
|
|
|
|
|
|
+ #error "SENSORLESS_HOMING requires ENDSTOPPULLUP_ZMIN (or ENDSTOPPULLUPS) for Z_MIN homing."
|
|
#elif Z_SENSORLESS && Z_HOME_TO_MAX && DISABLED(ENDSTOPPULLUP_ZMAX)
|
|
#elif Z_SENSORLESS && Z_HOME_TO_MAX && DISABLED(ENDSTOPPULLUP_ZMAX)
|
|
- #error "SENSORLESS_HOMING requires ENDSTOPPULLUP_ZMAX (or ENDSTOPPULLUPS) when homing to Z_MAX."
|
|
|
|
- #elif ALL(HAS_I_AXIS, I_SENSORLESS, I_HOME_TO_MIN) && DISABLED(ENDSTOPPULLUP_IMIN)
|
|
|
|
- #error "SENSORLESS_HOMING requires ENDSTOPPULLUP_IMIN (or ENDSTOPPULLUPS) when homing to I_MIN."
|
|
|
|
- #elif ALL(HAS_I_AXIS, I_SENSORLESS, I_HOME_TO_MAX) && DISABLED(ENDSTOPPULLUP_IMAX)
|
|
|
|
- #error "SENSORLESS_HOMING requires ENDSTOPPULLUP_IMAX (or ENDSTOPPULLUPS) when homing to I_MAX."
|
|
|
|
- #elif ALL(HAS_J_AXIS, J_SENSORLESS, J_HOME_TO_MIN) && DISABLED(ENDSTOPPULLUP_JMIN)
|
|
|
|
- #error "SENSORLESS_HOMING requires ENDSTOPPULLUP_JMIN (or ENDSTOPPULLUPS) when homing to J_MIN."
|
|
|
|
- #elif ALL(HAS_J_AXIS, J_SENSORLESS, J_HOME_TO_MAX) && DISABLED(ENDSTOPPULLUP_JMAX)
|
|
|
|
- #error "SENSORLESS_HOMING requires ENDSTOPPULLUP_JMAX (or ENDSTOPPULLUPS) when homing to J_MAX."
|
|
|
|
- #elif ALL(HAS_K_AXIS, K_SENSORLESS, K_HOME_TO_MIN) && DISABLED(ENDSTOPPULLUP_KMIN)
|
|
|
|
- #error "SENSORLESS_HOMING requires ENDSTOPPULLUP_KMIN (or ENDSTOPPULLUPS) when homing to K_MIN."
|
|
|
|
- #elif ALL(HAS_K_AXIS, K_SENSORLESS, K_HOME_TO_MAX) && DISABLED(ENDSTOPPULLUP_KMAX)
|
|
|
|
- #error "SENSORLESS_HOMING requires ENDSTOPPULLUP_KMAX (or ENDSTOPPULLUPS) when homing to K_MAX."
|
|
|
|
- #elif HAS_U_AXIS && U_SENSORLESS && U_HOME_TO_MIN && DISABLED(ENDSTOPPULLUP_UMIN)
|
|
|
|
- #error "SENSORLESS_HOMING requires ENDSTOPPULLUP_UMIN (or ENDSTOPPULLUPS) when homing to U_MIN."
|
|
|
|
- #elif HAS_U_AXIS && U_SENSORLESS && U_HOME_TO_MAX && DISABLED(ENDSTOPPULLUP_UMAX)
|
|
|
|
- #error "SENSORLESS_HOMING requires ENDSTOPPULLUP_UMAX (or ENDSTOPPULLUPS) when homing to U_MAX."
|
|
|
|
- #elif HAS_V_AXIS && V_SENSORLESS && V_HOME_TO_MIN && DISABLED(ENDSTOPPULLUP_VMIN)
|
|
|
|
- #error "SENSORLESS_HOMING requires ENDSTOPPULLUP_VMIN (or ENDSTOPPULLUPS) when homing to V_MIN."
|
|
|
|
- #elif HAS_V_AXIS && V_SENSORLESS && V_HOME_TO_MAX && DISABLED(ENDSTOPPULLUP_VMAX)
|
|
|
|
- #error "SENSORLESS_HOMING requires ENDSTOPPULLUP_VMAX (or ENDSTOPPULLUPS) when homing to V_MAX."
|
|
|
|
- #elif HAS_W_AXIS && W_SENSORLESS && W_HOME_TO_MIN && DISABLED(ENDSTOPPULLUP_WMIN)
|
|
|
|
- #error "SENSORLESS_HOMING requires ENDSTOPPULLUP_WMIN (or ENDSTOPPULLUPS) when homing to W_MIN."
|
|
|
|
- #elif HAS_W_AXIS && W_SENSORLESS && W_HOME_TO_MAX && DISABLED(ENDSTOPPULLUP_WMAX)
|
|
|
|
- #error "SENSORLESS_HOMING requires ENDSTOPPULLUP_WMAX (or ENDSTOPPULLUPS) when homing to W_MAX."
|
|
|
|
|
|
+ #error "SENSORLESS_HOMING requires ENDSTOPPULLUP_ZMAX (or ENDSTOPPULLUPS) for Z_MAX homing."
|
|
|
|
+ #elif I_SENSORLESS && I_HOME_TO_MIN && DISABLED(ENDSTOPPULLUP_IMIN)
|
|
|
|
+ #error "SENSORLESS_HOMING requires ENDSTOPPULLUP_IMIN (or ENDSTOPPULLUPS) for I_MIN homing."
|
|
|
|
+ #elif I_SENSORLESS && I_HOME_TO_MAX && DISABLED(ENDSTOPPULLUP_IMAX)
|
|
|
|
+ #error "SENSORLESS_HOMING requires ENDSTOPPULLUP_IMAX (or ENDSTOPPULLUPS) for I_MAX homing."
|
|
|
|
+ #elif J_SENSORLESS && J_HOME_TO_MIN && DISABLED(ENDSTOPPULLUP_JMIN)
|
|
|
|
+ #error "SENSORLESS_HOMING requires ENDSTOPPULLUP_JMIN (or ENDSTOPPULLUPS) for J_MIN homing."
|
|
|
|
+ #elif J_SENSORLESS && J_HOME_TO_MAX && DISABLED(ENDSTOPPULLUP_JMAX)
|
|
|
|
+ #error "SENSORLESS_HOMING requires ENDSTOPPULLUP_JMAX (or ENDSTOPPULLUPS) for J_MAX homing."
|
|
|
|
+ #elif K_SENSORLESS && K_HOME_TO_MIN && DISABLED(ENDSTOPPULLUP_KMIN)
|
|
|
|
+ #error "SENSORLESS_HOMING requires ENDSTOPPULLUP_KMIN (or ENDSTOPPULLUPS) for K_MIN homing."
|
|
|
|
+ #elif K_SENSORLESS && K_HOME_TO_MAX && DISABLED(ENDSTOPPULLUP_KMAX)
|
|
|
|
+ #error "SENSORLESS_HOMING requires ENDSTOPPULLUP_KMAX (or ENDSTOPPULLUPS) for K_MAX homing."
|
|
|
|
+ #elif U_SENSORLESS && U_HOME_TO_MIN && DISABLED(ENDSTOPPULLUP_UMIN)
|
|
|
|
+ #error "SENSORLESS_HOMING requires ENDSTOPPULLUP_UMIN (or ENDSTOPPULLUPS) for U_MIN homing."
|
|
|
|
+ #elif U_SENSORLESS && U_HOME_TO_MAX && DISABLED(ENDSTOPPULLUP_UMAX)
|
|
|
|
+ #error "SENSORLESS_HOMING requires ENDSTOPPULLUP_UMAX (or ENDSTOPPULLUPS) for U_MAX homing."
|
|
|
|
+ #elif V_SENSORLESS && V_HOME_TO_MIN && DISABLED(ENDSTOPPULLUP_VMIN)
|
|
|
|
+ #error "SENSORLESS_HOMING requires ENDSTOPPULLUP_VMIN (or ENDSTOPPULLUPS) for V_MIN homing."
|
|
|
|
+ #elif V_SENSORLESS && V_HOME_TO_MAX && DISABLED(ENDSTOPPULLUP_VMAX)
|
|
|
|
+ #error "SENSORLESS_HOMING requires ENDSTOPPULLUP_VMAX (or ENDSTOPPULLUPS) for V_MAX homing."
|
|
|
|
+ #elif W_SENSORLESS && W_HOME_TO_MIN && DISABLED(ENDSTOPPULLUP_WMIN)
|
|
|
|
+ #error "SENSORLESS_HOMING requires ENDSTOPPULLUP_WMIN (or ENDSTOPPULLUPS) for W_MIN homing."
|
|
|
|
+ #elif W_SENSORLESS && W_HOME_TO_MAX && DISABLED(ENDSTOPPULLUP_WMAX)
|
|
|
|
+ #error "SENSORLESS_HOMING requires ENDSTOPPULLUP_WMAX (or ENDSTOPPULLUPS) for W_MAX homing."
|
|
|
|
|
|
#endif
|
|
#endif
|
|
#endif
|
|
#endif
|
|
@@ -3648,117 +3624,172 @@ static_assert(X_MAX_LENGTH >= X_BED_SIZE, "Movement bounds (X_MIN_POS, X_MAX_POS
|
|
#if ENABLED(QUICK_HOME)
|
|
#if ENABLED(QUICK_HOME)
|
|
#warning "SPI_ENDSTOPS may be unreliable with QUICK_HOME. Adjust back-offs for better results."
|
|
#warning "SPI_ENDSTOPS may be unreliable with QUICK_HOME. Adjust back-offs for better results."
|
|
#endif
|
|
#endif
|
|
- #else
|
|
|
|
- #if X_SENSORLESS && X_HOME_TO_MIN && X_MIN_ENDSTOP_INVERTING != X_ENDSTOP_INVERTING
|
|
|
|
- #if X_ENDSTOP_INVERTING
|
|
|
|
- #error "SENSORLESS_HOMING requires X_MIN_ENDSTOP_INVERTING = true when homing to X_MIN."
|
|
|
|
- #else
|
|
|
|
- #error "SENSORLESS_HOMING requires X_MIN_ENDSTOP_INVERTING = false when homing TMC2209 to X_MIN."
|
|
|
|
- #endif
|
|
|
|
- #elif X_SENSORLESS && X_HOME_TO_MAX && X_MAX_ENDSTOP_INVERTING != X_ENDSTOP_INVERTING
|
|
|
|
- #if X_ENDSTOP_INVERTING
|
|
|
|
- #error "SENSORLESS_HOMING requires X_MAX_ENDSTOP_INVERTING = true when homing to X_MAX."
|
|
|
|
- #else
|
|
|
|
- #error "SENSORLESS_HOMING requires X_MAX_ENDSTOP_INVERTING = false when homing TMC2209 to X_MAX."
|
|
|
|
- #endif
|
|
|
|
- #elif Y_SENSORLESS && Y_HOME_TO_MIN && Y_MIN_ENDSTOP_INVERTING != Y_ENDSTOP_INVERTING
|
|
|
|
- #if Y_ENDSTOP_INVERTING
|
|
|
|
- #error "SENSORLESS_HOMING requires Y_MIN_ENDSTOP_INVERTING = true when homing to Y_MIN."
|
|
|
|
- #else
|
|
|
|
- #error "SENSORLESS_HOMING requires Y_MIN_ENDSTOP_INVERTING = false when homing TMC2209 to Y_MIN."
|
|
|
|
- #endif
|
|
|
|
- #elif Y_SENSORLESS && Y_HOME_TO_MAX && Y_MAX_ENDSTOP_INVERTING != Y_ENDSTOP_INVERTING
|
|
|
|
- #if Y_ENDSTOP_INVERTING
|
|
|
|
- #error "SENSORLESS_HOMING requires Y_MAX_ENDSTOP_INVERTING = true when homing to Y_MAX."
|
|
|
|
- #else
|
|
|
|
- #error "SENSORLESS_HOMING requires Y_MAX_ENDSTOP_INVERTING = false when homing TMC2209 to Y_MAX."
|
|
|
|
- #endif
|
|
|
|
- #elif Z_SENSORLESS && Z_HOME_TO_MIN && Z_MIN_ENDSTOP_INVERTING != Z_ENDSTOP_INVERTING
|
|
|
|
- #if Z_ENDSTOP_INVERTING
|
|
|
|
- #error "SENSORLESS_HOMING requires Z_MIN_ENDSTOP_INVERTING = true when homing to Z_MIN."
|
|
|
|
- #else
|
|
|
|
- #error "SENSORLESS_HOMING requires Z_MIN_ENDSTOP_INVERTING = false when homing TMC2209 to Z_MIN."
|
|
|
|
- #endif
|
|
|
|
- #elif Z_SENSORLESS && Z_HOME_TO_MAX && Z_MAX_ENDSTOP_INVERTING != Z_ENDSTOP_INVERTING
|
|
|
|
- #if Z_ENDSTOP_INVERTING
|
|
|
|
- #error "SENSORLESS_HOMING requires Z_MAX_ENDSTOP_INVERTING = true when homing to Z_MAX."
|
|
|
|
- #else
|
|
|
|
- #error "SENSORLESS_HOMING requires Z_MAX_ENDSTOP_INVERTING = false when homing TMC2209 to Z_MAX."
|
|
|
|
- #endif
|
|
|
|
- #elif ALL(HAS_I_AXIS, I_SENSORLESS, I_HOME_TO_MIN) && I_MIN_ENDSTOP_INVERTING != I_ENDSTOP_INVERTING
|
|
|
|
- #if I_ENDSTOP_INVERTING
|
|
|
|
- #error "SENSORLESS_HOMING requires I_MIN_ENDSTOP_INVERTING = true when homing to I_MIN."
|
|
|
|
- #else
|
|
|
|
- #error "SENSORLESS_HOMING requires I_MIN_ENDSTOP_INVERTING = false when homing TMC2209 to I_MIN."
|
|
|
|
- #endif
|
|
|
|
- #elif ALL(HAS_I_AXIS, I_SENSORLESS, I_HOME_TO_MAX) && I_MAX_ENDSTOP_INVERTING != I_ENDSTOP_INVERTING
|
|
|
|
- #if I_ENDSTOP_INVERTING
|
|
|
|
- #error "SENSORLESS_HOMING requires I_MAX_ENDSTOP_INVERTING = true when homing to I_MAX."
|
|
|
|
- #else
|
|
|
|
- #error "SENSORLESS_HOMING requires I_MAX_ENDSTOP_INVERTING = false when homing TMC2209 to I_MAX."
|
|
|
|
- #endif
|
|
|
|
- #elif ALL(HAS_J_AXIS, J_SENSORLESS, J_HOME_TO_MIN) && J_MIN_ENDSTOP_INVERTING != J_ENDSTOP_INVERTING
|
|
|
|
- #if J_ENDSTOP_INVERTING
|
|
|
|
- #error "SENSORLESS_HOMING requires J_MIN_ENDSTOP_INVERTING = true when homing to J_MIN."
|
|
|
|
- #else
|
|
|
|
- #error "SENSORLESS_HOMING requires J_MIN_ENDSTOP_INVERTING = false when homing TMC2209 to J_MIN."
|
|
|
|
- #endif
|
|
|
|
- #elif ALL(HAS_J_AXIS, J_SENSORLESS, J_HOME_TO_MAX) && J_MAX_ENDSTOP_INVERTING != J_ENDSTOP_INVERTING
|
|
|
|
- #if J_ENDSTOP_INVERTING
|
|
|
|
- #error "SENSORLESS_HOMING requires J_MAX_ENDSTOP_INVERTING = true when homing to J_MAX."
|
|
|
|
- #else
|
|
|
|
- #error "SENSORLESS_HOMING requires J_MAX_ENDSTOP_INVERTING = false when homing TMC2209 to J_MAX."
|
|
|
|
|
|
+ #else // !SPI_ENDSTOPS
|
|
|
|
+ // Stall detection DIAG = HIGH : TMC2209
|
|
|
|
+ // Stall detection DIAG = LOW : TMC2130/TMC2160/TMC2660/TMC5130/TMC5160
|
|
|
|
+ #if X_SENSORLESS
|
|
|
|
+ #define _HIT_STATE AXIS_DRIVER_TYPE(X,TMC2209)
|
|
|
|
+ #if X_HOME_TO_MIN && X_MIN_ENDSTOP_HIT_STATE != _HIT_STATE
|
|
|
|
+ #if _HIT_STATE
|
|
|
|
+ #error "SENSORLESS_HOMING requires X_MIN_ENDSTOP_HIT_STATE LOW for X_MIN homing."
|
|
|
|
+ #else
|
|
|
|
+ #error "SENSORLESS_HOMING requires X_MIN_ENDSTOP_HIT_STATE HIGH for X_MIN homing with TMC2209."
|
|
|
|
+ #endif
|
|
|
|
+ #elif X_HOME_TO_MAX && X_MAX_ENDSTOP_HIT_STATE != _HIT_STATE
|
|
|
|
+ #if _HIT_STATE
|
|
|
|
+ #error "SENSORLESS_HOMING requires X_MAX_ENDSTOP_HIT_STATE LOW for X_MAX homing."
|
|
|
|
+ #else
|
|
|
|
+ #error "SENSORLESS_HOMING requires X_MAX_ENDSTOP_HIT_STATE HIGH for X_MAX homing with TMC2209."
|
|
|
|
+ #endif
|
|
#endif
|
|
#endif
|
|
- #elif ALL(HAS_K_AXIS, K_SENSORLESS, K_HOME_TO_MIN) && K_MIN_ENDSTOP_INVERTING != K_ENDSTOP_INVERTING
|
|
|
|
- #if K_ENDSTOP_INVERTING
|
|
|
|
- #error "SENSORLESS_HOMING requires K_MIN_ENDSTOP_INVERTING = true when homing to K_MIN."
|
|
|
|
- #else
|
|
|
|
- #error "SENSORLESS_HOMING requires K_MIN_ENDSTOP_INVERTING = false when homing TMC2209 to K_MIN."
|
|
|
|
|
|
+ #undef _HIT_STATE
|
|
|
|
+ #endif
|
|
|
|
+
|
|
|
|
+ #if Y_SENSORLESS
|
|
|
|
+ #define _HIT_STATE AXIS_DRIVER_TYPE(Y,TMC2209)
|
|
|
|
+ #if Y_HOME_TO_MIN && Y_MIN_ENDSTOP_HIT_STATE != _HIT_STATE
|
|
|
|
+ #if _HIT_STATE
|
|
|
|
+ #error "SENSORLESS_HOMING requires Y_MIN_ENDSTOP_HIT_STATE LOW for Y_MIN homing."
|
|
|
|
+ #else
|
|
|
|
+ #error "SENSORLESS_HOMING requires Y_MIN_ENDSTOP_HIT_STATE HIGH for Y_MIN homing with TMC2209."
|
|
|
|
+ #endif
|
|
|
|
+ #elif Y_HOME_TO_MAX && Y_MAX_ENDSTOP_HIT_STATE != _HIT_STATE
|
|
|
|
+ #if _HIT_STATE
|
|
|
|
+ #error "SENSORLESS_HOMING requires Y_MAY_ENDSTOP_HIT_STATE LOW for Y_MAX homing."
|
|
|
|
+ #else
|
|
|
|
+ #error "SENSORLESS_HOMING requires Y_MAY_ENDSTOP_HIT_STATE HIGH for Y_MAX homing with TMC2209."
|
|
|
|
+ #endif
|
|
#endif
|
|
#endif
|
|
- #elif ALL(HAS_K_AXIS, K_SENSORLESS, K_HOME_TO_MAX) && K_MAX_ENDSTOP_INVERTING != K_ENDSTOP_INVERTING
|
|
|
|
- #if K_ENDSTOP_INVERTING
|
|
|
|
- #error "SENSORLESS_HOMING requires K_MAX_ENDSTOP_INVERTING = true when homing to K_MAX."
|
|
|
|
- #else
|
|
|
|
- #error "SENSORLESS_HOMING requires K_MAX_ENDSTOP_INVERTING = false when homing TMC2209 to K_MAX."
|
|
|
|
|
|
+ #undef _HIT_STATE
|
|
|
|
+ #endif
|
|
|
|
+
|
|
|
|
+ #if Z_SENSORLESS
|
|
|
|
+ #define _HIT_STATE AXIS_DRIVER_TYPE(Z,TMC2209)
|
|
|
|
+ #if Z_HOME_TO_MIN && Z_MIN_ENDSTOP_HIT_STATE != _HIT_STATE
|
|
|
|
+ #if _HIT_STATE
|
|
|
|
+ #error "SENSORLESS_HOMING requires Z_MIN_ENDSTOP_HIT_STATE LOW for Z_MIN homing."
|
|
|
|
+ #else
|
|
|
|
+ #error "SENSORLESS_HOMING requires Z_MIN_ENDSTOP_HIT_STATE HIGH for Z_MIN homing with TMC2209."
|
|
|
|
+ #endif
|
|
|
|
+ #elif Z_HOME_TO_MAX && Z_MAX_ENDSTOP_HIT_STATE != _HIT_STATE
|
|
|
|
+ #if _HIT_STATE
|
|
|
|
+ #error "SENSORLESS_HOMING requires Z_MAZ_ENDSTOP_HIT_STATE LOW for Z_MAX homing."
|
|
|
|
+ #else
|
|
|
|
+ #error "SENSORLESS_HOMING requires Z_MAZ_ENDSTOP_HIT_STATE HIGH for Z_MAX homing with TMC2209."
|
|
|
|
+ #endif
|
|
#endif
|
|
#endif
|
|
- #elif ALL(HAS_U_AXIS, U_SENSORLESS, U_HOME_TO_MIN) && U_MIN_ENDSTOP_INVERTING != U_ENDSTOP_INVERTING
|
|
|
|
- #if U_ENDSTOP_INVERTING
|
|
|
|
- #error "SENSORLESS_HOMING requires U_MIN_ENDSTOP_INVERTING = true when homing to U_MIN."
|
|
|
|
- #else
|
|
|
|
- #error "SENSORLESS_HOMING requires U_MIN_ENDSTOP_INVERTING = false when homing TMC2209 to U_MIN."
|
|
|
|
|
|
+ #undef _HIT_STATE
|
|
|
|
+ #endif
|
|
|
|
+
|
|
|
|
+ #if I_SENSORLESS
|
|
|
|
+ #define _HIT_STATE AXIS_DRIVER_TYPE(I,TMC2209)
|
|
|
|
+ #if I_HOME_TO_MIN && I_MIN_ENDSTOP_HIT_STATE != _HIT_STATE
|
|
|
|
+ #if _HIT_STATE
|
|
|
|
+ #error "SENSORLESS_HOMING requires I_MIN_ENDSTOP_HIT_STATE LOW for I_MIN homing."
|
|
|
|
+ #else
|
|
|
|
+ #error "SENSORLESS_HOMING requires I_MIN_ENDSTOP_HIT_STATE HIGH for I_MIN homing with TMC2209."
|
|
|
|
+ #endif
|
|
|
|
+ #elif I_HOME_TO_MAX && I_MAX_ENDSTOP_HIT_STATE != _HIT_STATE
|
|
|
|
+ #if _HIT_STATE
|
|
|
|
+ #error "SENSORLESS_HOMING requires I_MAI_ENDSTOP_HIT_STATE LOW for I_MAX homing."
|
|
|
|
+ #else
|
|
|
|
+ #error "SENSORLESS_HOMING requires I_MAI_ENDSTOP_HIT_STATE HIGH for I_MAX homing with TMC2209."
|
|
|
|
+ #endif
|
|
#endif
|
|
#endif
|
|
- #elif ALL(HAS_U_AXIS, U_SENSORLESS, U_HOME_TO_MAX) && U_MAX_ENDSTOP_INVERTING != U_ENDSTOP_INVERTING
|
|
|
|
- #if U_ENDSTOP_INVERTING
|
|
|
|
- #error "SENSORLESS_HOMING requires U_MAX_ENDSTOP_INVERTING = true when homing to U_MAX."
|
|
|
|
- #else
|
|
|
|
- #error "SENSORLESS_HOMING requires U_MAX_ENDSTOP_INVERTING = false when homing TMC2209 to U_MAX."
|
|
|
|
|
|
+ #undef _HIT_STATE
|
|
|
|
+ #endif
|
|
|
|
+
|
|
|
|
+ #if J_SENSORLESS
|
|
|
|
+ #define _HIT_STATE AXIS_DRIVER_TYPE(J,TMC2209)
|
|
|
|
+ #if J_HOME_TO_MIN && J_MIN_ENDSTOP_HIT_STATE != _HIT_STATE
|
|
|
|
+ #if _HIT_STATE
|
|
|
|
+ #error "SENSORLESS_HOMING requires J_MIN_ENDSTOP_HIT_STATE LOW for J_MIN homing."
|
|
|
|
+ #else
|
|
|
|
+ #error "SENSORLESS_HOMING requires J_MIN_ENDSTOP_HIT_STATE HIGH for J_MIN homing with TMC2209."
|
|
|
|
+ #endif
|
|
|
|
+ #elif J_HOME_TO_MAX && J_MAX_ENDSTOP_HIT_STATE != _HIT_STATE
|
|
|
|
+ #if _HIT_STATE
|
|
|
|
+ #error "SENSORLESS_HOMING requires J_MAJ_ENDSTOP_HIT_STATE LOW for J_MAX homing."
|
|
|
|
+ #else
|
|
|
|
+ #error "SENSORLESS_HOMING requires J_MAJ_ENDSTOP_HIT_STATE HIGH for J_MAX homing with TMC2209."
|
|
|
|
+ #endif
|
|
#endif
|
|
#endif
|
|
- #elif ALL(HAS_V_AXIS, V_SENSORLESS, V_HOME_TO_MIN) && V_MIN_ENDSTOP_INVERTING != V_ENDSTOP_INVERTING
|
|
|
|
- #if V_ENDSTOP_INVERTING
|
|
|
|
- #error "SENSORLESS_HOMING requires V_MIN_ENDSTOP_INVERTING = true when homing to V_MIN."
|
|
|
|
- #else
|
|
|
|
- #error "SENSORLESS_HOMING requires V_MIN_ENDSTOP_INVERTING = false when homing TMC2209 to V_MIN."
|
|
|
|
|
|
+ #undef _HIT_STATE
|
|
|
|
+ #endif
|
|
|
|
+
|
|
|
|
+ #if K_SENSORLESS
|
|
|
|
+ #define _HIT_STATE AXIS_DRIVER_TYPE(K,TMC2209)
|
|
|
|
+ #if K_HOME_TO_MIN && K_MIN_ENDSTOP_HIT_STATE != _HIT_STATE
|
|
|
|
+ #if _HIT_STATE
|
|
|
|
+ #error "SENSORLESS_HOMING requires K_MIN_ENDSTOP_HIT_STATE LOW for K_MIN homing."
|
|
|
|
+ #else
|
|
|
|
+ #error "SENSORLESS_HOMING requires K_MIN_ENDSTOP_HIT_STATE HIGH for K_MIN homing with TMC2209."
|
|
|
|
+ #endif
|
|
|
|
+ #elif K_HOME_TO_MAX && K_MAX_ENDSTOP_HIT_STATE != _HIT_STATE
|
|
|
|
+ #if _HIT_STATE
|
|
|
|
+ #error "SENSORLESS_HOMING requires K_MAK_ENDSTOP_HIT_STATE LOW for K_MAX homing."
|
|
|
|
+ #else
|
|
|
|
+ #error "SENSORLESS_HOMING requires K_MAK_ENDSTOP_HIT_STATE HIGH for K_MAX homing with TMC2209."
|
|
|
|
+ #endif
|
|
#endif
|
|
#endif
|
|
- #elif ALL(HAS_V_AXIS, V_SENSORLESS, V_HOME_TO_MAX) && V_MAX_ENDSTOP_INVERTING != V_ENDSTOP_INVERTING
|
|
|
|
- #if V_ENDSTOP_INVERTING
|
|
|
|
- #error "SENSORLESS_HOMING requires V_MAX_ENDSTOP_INVERTING = true when homing to V_MAX."
|
|
|
|
- #else
|
|
|
|
- #error "SENSORLESS_HOMING requires V_MAX_ENDSTOP_INVERTING = false when homing TMC2209 to V_MAX."
|
|
|
|
|
|
+ #undef _HIT_STATE
|
|
|
|
+ #endif
|
|
|
|
+
|
|
|
|
+ #if U_SENSORLESS
|
|
|
|
+ #define _HIT_STATE AXIS_DRIVER_TYPE(U,TMC2209)
|
|
|
|
+ #if U_HOME_TO_MIN && U_MIN_ENDSTOP_HIT_STATE != _HIT_STATE
|
|
|
|
+ #if _HIT_STATE
|
|
|
|
+ #error "SENSORLESS_HOMING requires U_MIN_ENDSTOP_HIT_STATE LOW for U_MIN homing."
|
|
|
|
+ #else
|
|
|
|
+ #error "SENSORLESS_HOMING requires U_MIN_ENDSTOP_HIT_STATE HIGH for U_MIN homing with TMC2209."
|
|
|
|
+ #endif
|
|
|
|
+ #elif U_HOME_TO_MAX && U_MAX_ENDSTOP_HIT_STATE != _HIT_STATE
|
|
|
|
+ #if _HIT_STATE
|
|
|
|
+ #error "SENSORLESS_HOMING requires U_MAU_ENDSTOP_HIT_STATE LOW for U_MAX homing."
|
|
|
|
+ #else
|
|
|
|
+ #error "SENSORLESS_HOMING requires U_MAU_ENDSTOP_HIT_STATE HIGH for U_MAX homing with TMC2209."
|
|
|
|
+ #endif
|
|
#endif
|
|
#endif
|
|
- #elif ALL(HAS_W_AXIS, W_SENSORLESS, W_HOME_TO_MIN) && W_MIN_ENDSTOP_INVERTING != W_ENDSTOP_INVERTING
|
|
|
|
- #if W_ENDSTOP_INVERTING
|
|
|
|
- #error "SENSORLESS_HOMING requires W_MIN_ENDSTOP_INVERTING = true when homing to W_MIN."
|
|
|
|
- #else
|
|
|
|
- #error "SENSORLESS_HOMING requires W_MIN_ENDSTOP_INVERTING = false when homing TMC2209 to W_MIN."
|
|
|
|
|
|
+ #undef _HIT_STATE
|
|
|
|
+ #endif
|
|
|
|
+
|
|
|
|
+ #if V_SENSORLESS
|
|
|
|
+ #define _HIT_STATE AXIS_DRIVER_TYPE(V,TMC2209)
|
|
|
|
+ #if V_HOME_TO_MIN && V_MIN_ENDSTOP_HIT_STATE != _HIT_STATE
|
|
|
|
+ #if _HIT_STATE
|
|
|
|
+ #error "SENSORLESS_HOMING requires V_MIN_ENDSTOP_HIT_STATE LOW for V_MIN homing."
|
|
|
|
+ #else
|
|
|
|
+ #error "SENSORLESS_HOMING requires V_MIN_ENDSTOP_HIT_STATE HIGH for V_MIN homing with TMC2209."
|
|
|
|
+ #endif
|
|
|
|
+ #elif V_HOME_TO_MAX && V_MAX_ENDSTOP_HIT_STATE != _HIT_STATE
|
|
|
|
+ #if _HIT_STATE
|
|
|
|
+ #error "SENSORLESS_HOMING requires V_MAV_ENDSTOP_HIT_STATE LOW for V_MAX homing."
|
|
|
|
+ #else
|
|
|
|
+ #error "SENSORLESS_HOMING requires V_MAV_ENDSTOP_HIT_STATE HIGH for V_MAX homing with TMC2209."
|
|
|
|
+ #endif
|
|
#endif
|
|
#endif
|
|
- #elif ALL(HAS_W_AXIS, W_SENSORLESS, W_HOME_TO_MAX0) && W_MAX_ENDSTOP_INVERTING != W_ENDSTOP_INVERTING
|
|
|
|
- #if W_ENDSTOP_INVERTING
|
|
|
|
- #error "SENSORLESS_HOMING requires W_MAX_ENDSTOP_INVERTING = true when homing to W_MAX."
|
|
|
|
- #else
|
|
|
|
- #error "SENSORLESS_HOMING requires W_MAX_ENDSTOP_INVERTING = false when homing TMC2209 to W_MAX."
|
|
|
|
|
|
+ #undef _HIT_STATE
|
|
|
|
+ #endif
|
|
|
|
+
|
|
|
|
+ #if W_SENSORLESS
|
|
|
|
+ #define _HIT_STATE AXIS_DRIVER_TYPE(W,TMC2209)
|
|
|
|
+ #if W_HOME_TO_MIN && W_MIN_ENDSTOP_HIT_STATE != _HIT_STATE
|
|
|
|
+ #if _HIT_STATE
|
|
|
|
+ #error "SENSORLESS_HOMING requires W_MIN_ENDSTOP_HIT_STATE LOW for W_MIN homing."
|
|
|
|
+ #else
|
|
|
|
+ #error "SENSORLESS_HOMING requires W_MIN_ENDSTOP_HIT_STATE HIGH for W_MIN homing with TMC2209."
|
|
|
|
+ #endif
|
|
|
|
+ #elif W_HOME_TO_MAX && W_MAX_ENDSTOP_HIT_STATE != _HIT_STATE
|
|
|
|
+ #if _HIT_STATE
|
|
|
|
+ #error "SENSORLESS_HOMING requires W_MAW_ENDSTOP_HIT_STATE LOW for W_MAX homing."
|
|
|
|
+ #else
|
|
|
|
+ #error "SENSORLESS_HOMING requires W_MAW_ENDSTOP_HIT_STATE HIGH for W_MAX homing with TMC2209."
|
|
|
|
+ #endif
|
|
#endif
|
|
#endif
|
|
|
|
+ #undef _HIT_STATE
|
|
#endif
|
|
#endif
|
|
- #endif
|
|
|
|
|
|
+
|
|
|
|
+ #endif // !SPI_ENDSTOPS
|
|
|
|
|
|
#if ENABLED(DELTA) && !BOTH(STEALTHCHOP_XY, STEALTHCHOP_Z)
|
|
#if ENABLED(DELTA) && !BOTH(STEALTHCHOP_XY, STEALTHCHOP_Z)
|
|
#error "SENSORLESS_HOMING on DELTA currently requires STEALTHCHOP_XY and STEALTHCHOP_Z."
|
|
#error "SENSORLESS_HOMING on DELTA currently requires STEALTHCHOP_XY and STEALTHCHOP_Z."
|
|
@@ -3768,15 +3799,6 @@ static_assert(X_MAX_LENGTH >= X_BED_SIZE, "Movement bounds (X_MIN_POS, X_MAX_POS
|
|
#error "SENSORLESS_HOMING requires a TMC stepper driver with StallGuard on X, Y, Z, I, J, K, U, V, or W axes."
|
|
#error "SENSORLESS_HOMING requires a TMC stepper driver with StallGuard on X, Y, Z, I, J, K, U, V, or W axes."
|
|
#endif
|
|
#endif
|
|
|
|
|
|
- #undef X_ENDSTOP_INVERTING
|
|
|
|
- #undef Y_ENDSTOP_INVERTING
|
|
|
|
- #undef Z_ENDSTOP_INVERTING
|
|
|
|
- #undef I_ENDSTOP_INVERTING
|
|
|
|
- #undef J_ENDSTOP_INVERTING
|
|
|
|
- #undef K_ENDSTOP_INVERTING
|
|
|
|
- #undef U_ENDSTOP_INVERTING
|
|
|
|
- #undef V_ENDSTOP_INVERTING
|
|
|
|
- #undef W_ENDSTOP_INVERTING
|
|
|
|
#endif
|
|
#endif
|
|
|
|
|
|
// Sensorless probing requirements
|
|
// Sensorless probing requirements
|