|
@ -1682,7 +1682,7 @@ static_assert(hbm[Z_AXIS] >= 0, "HOMING_BUMP_MM.Z must be greater than or equal |
|
|
* Allen Key |
|
|
* Allen Key |
|
|
* Deploying the Allen Key probe uses big moves in z direction. Too dangerous for an unhomed z-axis. |
|
|
* Deploying the Allen Key probe uses big moves in z direction. Too dangerous for an unhomed z-axis. |
|
|
*/ |
|
|
*/ |
|
|
#if BOTH(Z_PROBE_ALLEN_KEY, Z_MIN_PROBE_USES_Z_MIN_ENDSTOP_PIN) && Z_HOME_DIR < 0 |
|
|
#if ALL(Z_HOME_TO_MIN, Z_PROBE_ALLEN_KEY, Z_MIN_PROBE_USES_Z_MIN_ENDSTOP_PIN) |
|
|
#error "You can't home to a Z min endstop with a Z_PROBE_ALLEN_KEY." |
|
|
#error "You can't home to a Z min endstop with a Z_PROBE_ALLEN_KEY." |
|
|
#endif |
|
|
#endif |
|
|
|
|
|
|
|
@ -1700,7 +1700,7 @@ static_assert(hbm[Z_AXIS] >= 0, "HOMING_BUMP_MM.Z must be greater than or equal |
|
|
#error "DUAL_X_CARRIAGE requires USE_XMAX_PLUG and an X Max Endstop." |
|
|
#error "DUAL_X_CARRIAGE requires USE_XMAX_PLUG and an X Max Endstop." |
|
|
#elif !defined(X2_HOME_POS) || !defined(X2_MIN_POS) || !defined(X2_MAX_POS) |
|
|
#elif !defined(X2_HOME_POS) || !defined(X2_MIN_POS) || !defined(X2_MAX_POS) |
|
|
#error "DUAL_X_CARRIAGE requires X2_HOME_POS, X2_MIN_POS, and X2_MAX_POS." |
|
|
#error "DUAL_X_CARRIAGE requires X2_HOME_POS, X2_MIN_POS, and X2_MAX_POS." |
|
|
#elif X_HOME_DIR != -1 || X2_HOME_DIR != 1 |
|
|
#elif X_HOME_TO_MAX || X2_HOME_TO_MIN |
|
|
#error "DUAL_X_CARRIAGE requires X_HOME_DIR -1 and X2_HOME_DIR 1." |
|
|
#error "DUAL_X_CARRIAGE requires X_HOME_DIR -1 and X2_HOME_DIR 1." |
|
|
#endif |
|
|
#endif |
|
|
#endif |
|
|
#endif |
|
@ -2089,25 +2089,25 @@ static_assert(hbm[Z_AXIS] >= 0, "HOMING_BUMP_MM.Z must be greater than or equal |
|
|
|
|
|
|
|
|
// Delta and Cartesian use 3 homing endstops
|
|
|
// Delta and Cartesian use 3 homing endstops
|
|
|
#if NONE(IS_SCARA, SPI_ENDSTOPS) |
|
|
#if NONE(IS_SCARA, SPI_ENDSTOPS) |
|
|
#if X_HOME_DIR < 0 && DISABLED(USE_XMIN_PLUG) |
|
|
#if X_HOME_TO_MIN && DISABLED(USE_XMIN_PLUG) |
|
|
#error "Enable USE_XMIN_PLUG when homing X to MIN." |
|
|
#error "Enable USE_XMIN_PLUG when homing X to MIN." |
|
|
#elif X_HOME_DIR > 0 && DISABLED(USE_XMAX_PLUG) |
|
|
#elif X_HOME_TO_MAX && DISABLED(USE_XMAX_PLUG) |
|
|
#error "Enable USE_XMAX_PLUG when homing X to MAX." |
|
|
#error "Enable USE_XMAX_PLUG when homing X to MAX." |
|
|
#elif Y_HOME_DIR < 0 && DISABLED(USE_YMIN_PLUG) |
|
|
#elif Y_HOME_TO_MIN && DISABLED(USE_YMIN_PLUG) |
|
|
#error "Enable USE_YMIN_PLUG when homing Y to MIN." |
|
|
#error "Enable USE_YMIN_PLUG when homing Y to MIN." |
|
|
#elif Y_HOME_DIR > 0 && DISABLED(USE_YMAX_PLUG) |
|
|
#elif Y_HOME_TO_MAX && DISABLED(USE_YMAX_PLUG) |
|
|
#error "Enable USE_YMAX_PLUG when homing Y to MAX." |
|
|
#error "Enable USE_YMAX_PLUG when homing Y to MAX." |
|
|
#endif |
|
|
#endif |
|
|
#endif |
|
|
#endif |
|
|
|
|
|
|
|
|
// Z homing direction and plug usage flags
|
|
|
// Z homing direction and plug usage flags
|
|
|
#if Z_HOME_DIR < 0 && NONE(USE_ZMIN_PLUG, HOMING_Z_WITH_PROBE) |
|
|
#if Z_HOME_TO_MIN && NONE(USE_ZMIN_PLUG, HOMING_Z_WITH_PROBE) |
|
|
#error "Enable USE_ZMIN_PLUG when homing Z to MIN." |
|
|
#error "Enable USE_ZMIN_PLUG when homing Z to MIN." |
|
|
#elif Z_HOME_DIR > 0 && ENABLED(USE_PROBE_FOR_Z_HOMING) |
|
|
#elif Z_HOME_TO_MAX && ENABLED(USE_PROBE_FOR_Z_HOMING) |
|
|
#error "Z_HOME_DIR must be -1 when homing Z with the probe." |
|
|
#error "Z_HOME_DIR must be -1 when homing Z with the probe." |
|
|
#elif BOTH(HOMING_Z_WITH_PROBE, Z_MULTI_ENDSTOPS) |
|
|
#elif BOTH(HOMING_Z_WITH_PROBE, Z_MULTI_ENDSTOPS) |
|
|
#error "Z_MULTI_ENDSTOPS is incompatible with USE_PROBE_FOR_Z_HOMING." |
|
|
#error "Z_MULTI_ENDSTOPS is incompatible with USE_PROBE_FOR_Z_HOMING." |
|
|
#elif Z_HOME_DIR > 0 && DISABLED(USE_ZMAX_PLUG) |
|
|
#elif Z_HOME_TO_MAX && DISABLED(USE_ZMAX_PLUG) |
|
|
#error "Enable USE_ZMAX_PLUG when homing Z to MAX." |
|
|
#error "Enable USE_ZMAX_PLUG when homing Z to MAX." |
|
|
#endif |
|
|
#endif |
|
|
#endif |
|
|
#endif |
|
@ -2630,17 +2630,17 @@ static_assert(hbm[Z_AXIS] >= 0, "HOMING_BUMP_MM.Z must be greater than or equal |
|
|
#define Z_ENDSTOP_INVERTING !AXIS_DRIVER_TYPE(Z,TMC2209) |
|
|
#define Z_ENDSTOP_INVERTING !AXIS_DRIVER_TYPE(Z,TMC2209) |
|
|
|
|
|
|
|
|
#if NONE(SPI_ENDSTOPS, ONBOARD_ENDSTOPPULLUPS, ENDSTOPPULLUPS) |
|
|
#if NONE(SPI_ENDSTOPS, ONBOARD_ENDSTOPPULLUPS, ENDSTOPPULLUPS) |
|
|
#if X_SENSORLESS && X_HOME_DIR < 0 && 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) when homing to X_MIN." |
|
|
#elif X_SENSORLESS && X_HOME_DIR > 0 && 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) when homing to X_MAX." |
|
|
#elif Y_SENSORLESS && Y_HOME_DIR < 0 && 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) when homing to Y_MIN." |
|
|
#elif Y_SENSORLESS && Y_HOME_DIR > 0 && 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) when homing to Y_MAX." |
|
|
#elif Z_SENSORLESS && Z_HOME_DIR < 0 && 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) when homing to Z_MIN." |
|
|
#elif Z_SENSORLESS && Z_HOME_DIR > 0 && 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." |
|
|
#error "SENSORLESS_HOMING requires ENDSTOPPULLUP_ZMAX (or ENDSTOPPULLUPS) when homing to Z_MAX." |
|
|
#endif |
|
|
#endif |
|
|
#endif |
|
|
#endif |
|
@ -2650,37 +2650,37 @@ static_assert(hbm[Z_AXIS] >= 0, "HOMING_BUMP_MM.Z must be greater than or equal |
|
|
#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 |
|
|
#else |
|
|
#if X_SENSORLESS && X_HOME_DIR < 0 && X_MIN_ENDSTOP_INVERTING != X_ENDSTOP_INVERTING |
|
|
#if X_SENSORLESS && X_HOME_TO_MIN && X_MIN_ENDSTOP_INVERTING != X_ENDSTOP_INVERTING |
|
|
#if X_ENDSTOP_INVERTING |
|
|
#if X_ENDSTOP_INVERTING |
|
|
#error "SENSORLESS_HOMING requires X_MIN_ENDSTOP_INVERTING = true when homing to X_MIN." |
|
|
#error "SENSORLESS_HOMING requires X_MIN_ENDSTOP_INVERTING = true when homing to X_MIN." |
|
|
#else |
|
|
#else |
|
|
#error "SENSORLESS_HOMING requires X_MIN_ENDSTOP_INVERTING = false when homing TMC2209 to X_MIN." |
|
|
#error "SENSORLESS_HOMING requires X_MIN_ENDSTOP_INVERTING = false when homing TMC2209 to X_MIN." |
|
|
#endif |
|
|
#endif |
|
|
#elif X_SENSORLESS && X_HOME_DIR > 0 && X_MAX_ENDSTOP_INVERTING != X_ENDSTOP_INVERTING |
|
|
#elif X_SENSORLESS && X_HOME_TO_MAX && X_MAX_ENDSTOP_INVERTING != X_ENDSTOP_INVERTING |
|
|
#if X_ENDSTOP_INVERTING |
|
|
#if X_ENDSTOP_INVERTING |
|
|
#error "SENSORLESS_HOMING requires X_MAX_ENDSTOP_INVERTING = true when homing to X_MAX." |
|
|
#error "SENSORLESS_HOMING requires X_MAX_ENDSTOP_INVERTING = true when homing to X_MAX." |
|
|
#else |
|
|
#else |
|
|
#error "SENSORLESS_HOMING requires X_MAX_ENDSTOP_INVERTING = false when homing TMC2209 to X_MAX." |
|
|
#error "SENSORLESS_HOMING requires X_MAX_ENDSTOP_INVERTING = false when homing TMC2209 to X_MAX." |
|
|
#endif |
|
|
#endif |
|
|
#elif Y_SENSORLESS && Y_HOME_DIR < 0 && Y_MIN_ENDSTOP_INVERTING != Y_ENDSTOP_INVERTING |
|
|
#elif Y_SENSORLESS && Y_HOME_TO_MIN && Y_MIN_ENDSTOP_INVERTING != Y_ENDSTOP_INVERTING |
|
|
#if Y_ENDSTOP_INVERTING |
|
|
#if Y_ENDSTOP_INVERTING |
|
|
#error "SENSORLESS_HOMING requires Y_MIN_ENDSTOP_INVERTING = true when homing to Y_MIN." |
|
|
#error "SENSORLESS_HOMING requires Y_MIN_ENDSTOP_INVERTING = true when homing to Y_MIN." |
|
|
#else |
|
|
#else |
|
|
#error "SENSORLESS_HOMING requires Y_MIN_ENDSTOP_INVERTING = false when homing TMC2209 to Y_MIN." |
|
|
#error "SENSORLESS_HOMING requires Y_MIN_ENDSTOP_INVERTING = false when homing TMC2209 to Y_MIN." |
|
|
#endif |
|
|
#endif |
|
|
#elif Y_SENSORLESS && Y_HOME_DIR > 0 && Y_MAX_ENDSTOP_INVERTING != Y_ENDSTOP_INVERTING |
|
|
#elif Y_SENSORLESS && Y_HOME_TO_MAX && Y_MAX_ENDSTOP_INVERTING != Y_ENDSTOP_INVERTING |
|
|
#if Y_ENDSTOP_INVERTING |
|
|
#if Y_ENDSTOP_INVERTING |
|
|
#error "SENSORLESS_HOMING requires Y_MAX_ENDSTOP_INVERTING = true when homing to Y_MAX." |
|
|
#error "SENSORLESS_HOMING requires Y_MAX_ENDSTOP_INVERTING = true when homing to Y_MAX." |
|
|
#else |
|
|
#else |
|
|
#error "SENSORLESS_HOMING requires Y_MAX_ENDSTOP_INVERTING = false when homing TMC2209 to Y_MAX." |
|
|
#error "SENSORLESS_HOMING requires Y_MAX_ENDSTOP_INVERTING = false when homing TMC2209 to Y_MAX." |
|
|
#endif |
|
|
#endif |
|
|
#elif Z_SENSORLESS && Z_HOME_DIR < 0 && Z_MIN_ENDSTOP_INVERTING != Z_ENDSTOP_INVERTING |
|
|
#elif Z_SENSORLESS && Z_HOME_TO_MIN && Z_MIN_ENDSTOP_INVERTING != Z_ENDSTOP_INVERTING |
|
|
#if Z_ENDSTOP_INVERTING |
|
|
#if Z_ENDSTOP_INVERTING |
|
|
#error "SENSORLESS_HOMING requires Z_MIN_ENDSTOP_INVERTING = true when homing to Z_MIN." |
|
|
#error "SENSORLESS_HOMING requires Z_MIN_ENDSTOP_INVERTING = true when homing to Z_MIN." |
|
|
#else |
|
|
#else |
|
|
#error "SENSORLESS_HOMING requires Z_MIN_ENDSTOP_INVERTING = false when homing TMC2209 to Z_MIN." |
|
|
#error "SENSORLESS_HOMING requires Z_MIN_ENDSTOP_INVERTING = false when homing TMC2209 to Z_MIN." |
|
|
#endif |
|
|
#endif |
|
|
#elif Z_SENSORLESS && Z_HOME_DIR > 0 && Z_MAX_ENDSTOP_INVERTING != Z_ENDSTOP_INVERTING |
|
|
#elif Z_SENSORLESS && Z_HOME_TO_MAX && Z_MAX_ENDSTOP_INVERTING != Z_ENDSTOP_INVERTING |
|
|
#if Z_ENDSTOP_INVERTING |
|
|
#if Z_ENDSTOP_INVERTING |
|
|
#error "SENSORLESS_HOMING requires Z_MAX_ENDSTOP_INVERTING = true when homing to Z_MAX." |
|
|
#error "SENSORLESS_HOMING requires Z_MAX_ENDSTOP_INVERTING = true when homing to Z_MAX." |
|
|
#else |
|
|
#else |
|
@ -2918,9 +2918,9 @@ static_assert( _ARR_TEST(3,0) && _ARR_TEST(3,1) && _ARR_TEST(3,2) |
|
|
#error "POWER_LOSS_RECOVER_ZHOME cannot be used with Z_SAFE_HOMING." |
|
|
#error "POWER_LOSS_RECOVER_ZHOME cannot be used with Z_SAFE_HOMING." |
|
|
#elif BOTH(POWER_LOSS_PULLUP, POWER_LOSS_PULLDOWN) |
|
|
#elif BOTH(POWER_LOSS_PULLUP, POWER_LOSS_PULLDOWN) |
|
|
#error "You can't enable POWER_LOSS_PULLUP and POWER_LOSS_PULLDOWN at the same time." |
|
|
#error "You can't enable POWER_LOSS_PULLUP and POWER_LOSS_PULLDOWN at the same time." |
|
|
#elif ENABLED(POWER_LOSS_RECOVER_ZHOME) && Z_HOME_DIR > 0 |
|
|
#elif ENABLED(POWER_LOSS_RECOVER_ZHOME) && Z_HOME_TO_MAX |
|
|
#error "POWER_LOSS_RECOVER_ZHOME is not needed on a machine that homes to ZMAX." |
|
|
#error "POWER_LOSS_RECOVER_ZHOME is not needed on a machine that homes to ZMAX." |
|
|
#elif BOTH(IS_CARTESIAN, POWER_LOSS_RECOVER_ZHOME) && Z_HOME_DIR < 0 && !defined(POWER_LOSS_ZHOME_POS) |
|
|
#elif BOTH(IS_CARTESIAN, POWER_LOSS_RECOVER_ZHOME) && Z_HOME_TO_MIN && !defined(POWER_LOSS_ZHOME_POS) |
|
|
#error "POWER_LOSS_RECOVER_ZHOME requires POWER_LOSS_ZHOME_POS for a Cartesian that homes to ZMIN." |
|
|
#error "POWER_LOSS_RECOVER_ZHOME requires POWER_LOSS_ZHOME_POS for a Cartesian that homes to ZMIN." |
|
|
#endif |
|
|
#endif |
|
|
#endif |
|
|
#endif |
|
|