How to tell when the stepper motor is done stepping

arduinostepper motor

I am working on a project that requires mildly accurate positioning of the x and y axis. It involves an airsoft gun and it is basically a motion tracking turret. Because of the requirements for movement that could be tracked I determined that a stepper motor would probably be the best option. I have ran into a problem though while picking the motor and a driver or even if I am going to stay with the stepper motor idea. My question is how do I know when my stepper motor is done moving like is there a pin that goes low on most drivers saying that the motor is done moving? Or should I just move onto using a servo. I choose stepper motors because they were powerful and relatively cheap but I don't really understand how to control them. I understand the whole signal sending idea and I will be using the accel-libary with an arduino to control it but how do I know when to give the motor a new position. Also as a side note will a motor with a torque rating of .1416 in-pd's I will be using a .5pd airsoft gun and will mount it in the middle of it's center.

Best Answer

Stepper motors are actually not very powerful compared to a geared DC motor, but they have the advantage of providing accurate positioning without needing a feedback mechanism. The whole idea of a stepper motor is that it only moves when you step it, otherwise it stays put. So the answer is, it's done stepping when you stop stepping it!

However this only works reliably if you:-

  1. Don't step too fast, or accelerate and then try to slow down too quickly.
  2. Supply enough holding current to stop it from slipping under heavy load.
  3. Have some way to detect or set the 'home' position.

Some early disk drives set the home position by simply stepping in one direction enough times that the mechanism must have hit its end-stop, which would make a horrible clattering sound if the heads weren't on the innermost track!