From 4bc6536f54fc6f4899551257c71e856d8f2142b9 Mon Sep 17 00:00:00 2001 From: Scott Lahteine Date: Sat, 10 Dec 2016 04:49:46 -0800 Subject: [PATCH] Move to safe zone on DELTA if using do_blocking_move_to* --- Marlin/Marlin_main.cpp | 5 +++++ Marlin/nozzle.h | 7 +++++-- 2 files changed, 10 insertions(+), 2 deletions(-) diff --git a/Marlin/Marlin_main.cpp b/Marlin/Marlin_main.cpp index 070749276..8736051c8 100755 --- a/Marlin/Marlin_main.cpp +++ b/Marlin/Marlin_main.cpp @@ -2177,6 +2177,11 @@ static void clean_up_after_endstop_or_probe_move() { float old_feedrate_mm_s = feedrate_mm_s; + #if ENABLED(DELTA) + if (current_position[Z_AXIS] > delta_clip_start_height) + do_blocking_move_to_z(delta_clip_start_height); + #endif + // Ensure a minimum height before moving the probe do_probe_raise(Z_CLEARANCE_BETWEEN_PROBES); diff --git a/Marlin/nozzle.h b/Marlin/nozzle.h index cce22db41..748610554 100644 --- a/Marlin/nozzle.h +++ b/Marlin/nozzle.h @@ -70,8 +70,7 @@ class Nozzle { #if ENABLED(NOZZLE_CLEAN_GOBACK) // Move the nozzle to the initial point - do_blocking_move_to_z(initial.z); - do_blocking_move_to_xy(initial.x, initial.y); + do_blocking_move_to(initial.x, initial.y, initial.z); #endif // NOZZLE_CLEAN_GOBACK #endif // NOZZLE_CLEAN_FEATURE @@ -149,6 +148,10 @@ class Nozzle { __attribute__((unused)) uint8_t const &objects = 0 ) __attribute__((optimize ("Os"))) { #if ENABLED(NOZZLE_CLEAN_FEATURE) + #if ENABLED(DELTA) + if (current_position[Z_AXIS] > delta_clip_start_height) + do_blocking_move_to_z(delta_clip_start_height); + #endif switch (pattern) { case 1: Nozzle::zigzag(