From c07cc9e3f1d8037ec7d5379d8edc7c8261aa08e2 Mon Sep 17 00:00:00 2001 From: Scott Lahteine Date: Thu, 27 Oct 2016 07:41:39 -0500 Subject: [PATCH] Revert changes made to z dual endstop test #3631 broke z dual endstops. Solved by @Nocturnal42 in https://github.com/MarlinFirmware/Marlin/issues/5078#issuecomment-256572248 --- Marlin/endstops.cpp | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/Marlin/endstops.cpp b/Marlin/endstops.cpp index 4faf8a6b3f..7c0c9dbac6 100644 --- a/Marlin/endstops.cpp +++ b/Marlin/endstops.cpp @@ -220,8 +220,7 @@ void Endstops::M119() { // Pass the result of the endstop test void Endstops::test_dual_z_endstops(EndstopEnum es1, EndstopEnum es2) { byte z_test = TEST_ENDSTOP(es1) | (TEST_ENDSTOP(es2) << 1); // bit 0 for Z, bit 1 for Z2 - if (stepper.current_block->steps[Z_AXIS] > 0) { - stepper.endstop_triggered(Z_AXIS); + if (z_test && stepper.current_block->steps[Z_AXIS] > 0) { SBI(endstop_hit_bits, Z_MIN); if (!stepper.performing_homing || (z_test == 0x3)) //if not performing home or if both endstops were trigged during homing... stepper.kill_current_block();