From 1d291be2baa73e4e3b29bcb748a5c9c9b2316d4a Mon Sep 17 00:00:00 2001 From: Scott Lahteine Date: Tue, 7 Apr 2015 20:01:08 -0700 Subject: [PATCH] Fix de after PREVENT_DANGEROUS_EXTRUDE - Set `de` to 0 when `position[E] = target[E]` - Address regression mention in #1846 --- Marlin/planner.cpp | 2 ++ 1 file changed, 2 insertions(+) diff --git a/Marlin/planner.cpp b/Marlin/planner.cpp index dcfbe674cf..a0474f94a9 100644 --- a/Marlin/planner.cpp +++ b/Marlin/planner.cpp @@ -511,12 +511,14 @@ float junction_deviation = 0.1; if (de) { if (degHotend(active_extruder) < extrude_min_temp) { position[E_AXIS] = target[E_AXIS]; //behave as if the move really took place, but ignore E part + de = 0; // no difference SERIAL_ECHO_START; SERIAL_ECHOLNPGM(MSG_ERR_COLD_EXTRUDE_STOP); } #ifdef PREVENT_LENGTHY_EXTRUDE if (labs(de) > axis_steps_per_unit[E_AXIS] * EXTRUDE_MAXLENGTH) { position[E_AXIS] = target[E_AXIS]; // Behave as if the move really took place, but ignore E part + de = 0; // no difference SERIAL_ECHO_START; SERIAL_ECHOLNPGM(MSG_ERR_LONG_EXTRUDE_STOP); }