Homing Stepper Motors Question

Hello,

Is it better to "home" a stepper motor using acceleration (AccelStepper library) or no acceleration (and therefore no library)? What are the benefits/disadvantages of one over the other?

Also, if I am going to use the AccelStepper library throughout the rest of the code, should I just stick with the AccelStepper library the whole time and use it to "home" the stepper motors?

I appreciate any insight on this question.

Thank you!!

One thought, you can't decelerate to an unknown position.

Right. No deceleration, just acceleration. The stepper would simply just stop once it hits the limit switch.

Right. So it can't make any difference.

So...what could be an advantage/disadvantage over the other...

You mean, generally, apart from this one special case? BTW I haven't used it but from reading some threads it looks like it's one of the few non-blocking stepper libraries. That is certainly an advantage.

You are completely misunderstanding the homing procedure. The "HOME" position is the first step AWAY from the home position. Your program will never WANT to return to the home switch or what ever sensor you have, but just the step next to it. Many "homing" sensors, such as microswitches, will remain switched for more than one step of the motor.
You need to first find the home position, then back away one step and see if the home position sensor is still set. When it is no longer set, that position becomes the home or ZERO position.
Paul

1 Like

Inexperienced with steppers here, but after seeing those comments, wouldn't you want to move until the switch activates and then back until it releases? Then your home position should never activate the switch?

Oh wait, that's what you said in the end. But - one step at a time instead of at full speed.

1 Like

The stepper should be doing full steps to find the end stop and the zero position, and then change to whatever step rate is necessary.
Paul

1 Like

Yes, there is a lot of hysteresis in microswitches so you need to "clear" it.

1 Like

This topic was automatically closed 180 days after the last reply. New replies are no longer allowed.