From afc737ca0c8493603881a184f27bd245a943d25c Mon Sep 17 00:00:00 2001 From: alexborro Date: Fri, 13 Feb 2015 14:38:05 -0200 Subject: [PATCH] Fix CoreXY Homing Routine. Fixed how stepper ISR figure it out when the head (extruder) is going to Min or Max direction. Added Homing to Max Endstops. --- Marlin/Configuration.h | 5 ----- Marlin/planner.cpp | 12 ++++++++++-- Marlin/stepper.cpp | 16 ++++++++++------ 3 files changed, 20 insertions(+), 13 deletions(-) diff --git a/Marlin/Configuration.h b/Marlin/Configuration.h index fef159330..41e1ed7ed 100644 --- a/Marlin/Configuration.h +++ b/Marlin/Configuration.h @@ -326,11 +326,6 @@ const bool Z_MAX_ENDSTOP_INVERTING = true; // set to true to invert the logic of //#define DISABLE_MAX_ENDSTOPS //#define DISABLE_MIN_ENDSTOPS -// Disable max endstops for compatibility with endstop checking routine -#if defined(COREXY) && !defined(DISABLE_MAX_ENDSTOPS) - #define DISABLE_MAX_ENDSTOPS -#endif - // For Inverting Stepper Enable Pins (Active Low) use 0, Non Inverting (Active High) use 1 #define X_ENABLE_ON 0 #define Y_ENABLE_ON 0 diff --git a/Marlin/planner.cpp b/Marlin/planner.cpp index 82702286b..cee1981bc 100644 --- a/Marlin/planner.cpp +++ b/Marlin/planner.cpp @@ -629,13 +629,21 @@ block->steps_y = labs((target[X_AXIS]-position[X_AXIS]) - (target[Y_AXIS]-positi block->direction_bits |= (1<direction_bits |= (1<direction_bits |= (1<direction_bits |= (1<direction_bits |= (1<direction_bits |= (1<direction_bits |= (1< -1 @@ -465,7 +468,8 @@ ISR(TIMER1_COMPA_vect) #endif } } - else { // +direction + else + { // +direction CHECK_ENDSTOPS { #if defined(Y_MAX_PIN) && Y_MAX_PIN > -1