MINIMUM_STEPPER_DIR_DELAY in LA (#15154)
Add missed MINIMUM_STEPPER_DIR_DELAY after dir change in LinearAdvance interrupt.
This commit is contained in:
parent
75efa3cdac
commit
89a2161cac
@ -1879,19 +1879,24 @@ uint32_t Stepper::stepper_block_phase_isr() {
|
|||||||
else
|
else
|
||||||
interval = LA_ADV_NEVER;
|
interval = LA_ADV_NEVER;
|
||||||
|
|
||||||
#if ENABLED(MIXING_EXTRUDER)
|
#if ENABLED(MIXING_EXTRUDER)
|
||||||
// We don't know which steppers will be stepped because LA loop follows,
|
// We don't know which steppers will be stepped because LA loop follows,
|
||||||
// with potentially multiple steps. Set all.
|
// with potentially multiple steps. Set all.
|
||||||
if (LA_steps >= 0)
|
if (LA_steps >= 0)
|
||||||
MIXER_STEPPER_LOOP(j) NORM_E_DIR(j);
|
MIXER_STEPPER_LOOP(j) NORM_E_DIR(j);
|
||||||
else
|
else
|
||||||
MIXER_STEPPER_LOOP(j) REV_E_DIR(j);
|
MIXER_STEPPER_LOOP(j) REV_E_DIR(j);
|
||||||
#else
|
#else
|
||||||
if (LA_steps >= 0)
|
if (LA_steps >= 0)
|
||||||
NORM_E_DIR(stepper_extruder);
|
NORM_E_DIR(stepper_extruder);
|
||||||
else
|
else
|
||||||
REV_E_DIR(stepper_extruder);
|
REV_E_DIR(stepper_extruder);
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
// A small delay may be needed after changing direction
|
||||||
|
#if MINIMUM_STEPPER_DIR_DELAY > 0
|
||||||
|
DELAY_NS(MINIMUM_STEPPER_DIR_DELAY);
|
||||||
|
#endif
|
||||||
|
|
||||||
// Get the timer count and estimate the end of the pulse
|
// Get the timer count and estimate the end of the pulse
|
||||||
hal_timer_t pulse_end = HAL_timer_get_count(PULSE_TIMER_NUM) + hal_timer_t(MIN_PULSE_TICKS);
|
hal_timer_t pulse_end = HAL_timer_get_count(PULSE_TIMER_NUM) + hal_timer_t(MIN_PULSE_TICKS);
|
||||||
|
Loading…
Reference in New Issue
Block a user