From f0aed9dac7ee7fc3421891f9b24f92679c769bb4 Mon Sep 17 00:00:00 2001 From: Greg Cormier Date: Sat, 22 Oct 2016 20:45:13 -0400 Subject: [PATCH] Fix #4995 - M48/G29 on CoreXY maybe others? --- Marlin/Marlin_main.cpp | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/Marlin/Marlin_main.cpp b/Marlin/Marlin_main.cpp index 402f97cfe9..a215368551 100755 --- a/Marlin/Marlin_main.cpp +++ b/Marlin/Marlin_main.cpp @@ -2082,12 +2082,13 @@ static void clean_up_after_endstop_or_probe_move() { // Clear endstop flags endstops.hit_on_purpose(); - // Tell the planner where we actually are - planner.sync_from_steppers(); - // Get Z where the steppers were interrupted set_current_from_steppers_for_axis(Z_AXIS); + // Tell the planner where we actually are + SYNC_PLAN_POSITION_KINEMATIC(); + + #if ENABLED(DEBUG_LEVELING_FEATURE) if (DEBUGGING(LEVELING)) DEBUG_POS("<<< do_probe_move", current_position); #endif @@ -3819,7 +3820,7 @@ inline void gcode_G28() { set_current_from_steppers_for_axis(ALL_AXES); // Sync the planner to where the steppers stopped - planner.sync_from_steppers(); + SYNC_PLAN_POSITION_KINEMATIC(); } setup_for_endstop_or_probe_move();