From 07ae23fe14851473c06d8a31b08c9d165e10bc09 Mon Sep 17 00:00:00 2001 From: Scott Lahteine Date: Sun, 4 Mar 2018 15:06:22 -0600 Subject: [PATCH] No pulse delay on last e_steps in advance isr --- Marlin/src/module/stepper.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Marlin/src/module/stepper.cpp b/Marlin/src/module/stepper.cpp index bf06c3139b..6834cc642a 100644 --- a/Marlin/src/module/stepper.cpp +++ b/Marlin/src/module/stepper.cpp @@ -851,9 +851,9 @@ void Stepper::isr() { // For minimum pulse time wait before looping #if EXTRA_CYCLES_E > 20 - while (EXTRA_CYCLES_E > (hal_timer_t)(HAL_timer_get_count(PULSE_TIMER_NUM) - pulse_start) * (PULSE_TIMER_PRESCALE)) { /* nada */ } + if (e_steps) while (EXTRA_CYCLES_E > (hal_timer_t)(HAL_timer_get_count(PULSE_TIMER_NUM) - pulse_start) * (PULSE_TIMER_PRESCALE)) { /* nada */ } #elif EXTRA_CYCLES_E > 0 - DELAY_NOPS(EXTRA_CYCLES_E); + if (e_steps) DELAY_NOPS(EXTRA_CYCLES_E); #endif } // e_steps