mirror of
https://github.com/Klipper3d/klipper.git
synced 2025-07-20 21:27:53 -06:00
stepper: Reset the next step time on a stepper stop
Automatically reset the next step time to zero on a stepper_stop() call. This makes the host code simpler as it no longer needs to schedule an explicit reset_step_clock command on the step after a homing operation. Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
This commit is contained in:
parent
941427554a
commit
9ad8153d33
3 changed files with 5 additions and 8 deletions
|
@ -238,6 +238,7 @@ void
|
|||
stepper_stop(struct stepper *s)
|
||||
{
|
||||
sched_del_timer(&s->time);
|
||||
s->next_step_time = 0;
|
||||
s->position = -stepper_get_position(s);
|
||||
s->count = 0;
|
||||
s->flags &= SF_INVERT_STEP;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue