Skip to content

Commit

Permalink
fix STEPTEST macro to restore homing with dual Z endstops
Browse files Browse the repository at this point in the history
This macro builds a string starting with "HAS_" but "HAS_" was replaced
with "USE_" in Marlin 2.1.2.2. Backport the upstream patch should
restore correct endstop polling and fix the bad homing behavior.

Fixes: #523
  • Loading branch information
stklcode committed Jun 5, 2024
1 parent 60b68f5 commit 5eac0f6
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion Marlin/src/module/stepper.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -274,7 +274,7 @@ xyze_int8_t Stepper::count_direction{0};
#define MINDIR(A) (count_direction[_AXIS(A)] < 0)
#define MAXDIR(A) (count_direction[_AXIS(A)] > 0)

#define STEPTEST(A,M,I) TERN0(HAS_ ##A## ##I## _ ##M, !(TEST(endstops.state(), A## ##I## _ ##M) && M## DIR(A)) && !locked_ ##A## ##I## _motor)
#define STEPTEST(A,M,I) TERN0(USE_##A##I##_##M, !(TEST(endstops.state(), A##I##_##M) && M## DIR(A)) && !locked_ ##A##I##_motor)

#define DUAL_ENDSTOP_APPLY_STEP(A,V) \
if (separate_multi_axis) { \
Expand Down

0 comments on commit 5eac0f6

Please sign in to comment.