Giving stepper motor location capabilities

I am aware that for my particular issue a servo motor would solve all of my problems, however it is not within the given budget as the project would require 2-3 servo motors. I need to operate an arm that has a 90 degree range and a base that has a 360 degree range. The issue I am encountering is that I need to be able to set these to specific locations based off of a reference point.

I am decently sure that I can do it with an unnecessarily difficult code. This would work but I do have a fear of misstepping as accuracy is desired.

Rotary coders are a bit expensive, so I would love to hear alternatives and possible solutions.

[Mod edit
Please note that @randomuser1219 has 3 questions open on related but separate subjects. These are:

]

A common solution for this is to give each stepper a microswitch it can use to home itself at startup.

1 Like

If the load on the motors is within their capabilities and the speed that they are run at is not excessive then they will not miss steps

That being the case, you only need to have one fixed, home, position to which you move each motor and count steps from there

This is not a foolproof solution but if you are not willing to use a better solution then you stuck with a less than perfect solution

1 Like

Stepper motors DO NOT move by degrees! They move by steps. You will have to adjust your expectations to relate to the number of steps your motor takes to move a complete rotation.
Encoders are no help with stepper motors. Your program counts the number of steps the motor moves.
Paul

I was hoping to accomplish the angle through math based on step size. My initial plan is to have a user input of angle desired and then convert that to steps with step size in mind. The angles possible are limited by step size, but this seems to me at the moment to be the best path for the constraints I have been given.

Don't forget that you can micro step to get greater resolution, at the cost of reduced torque.

1 Like

They're pretty handy if you want to make a closed loop stepper :wink:

That is exactly how you will do it!
But now you need to select the torque requirements, both moving and holding, for the rest of your design.
Paul

When you have the torque requirement you can select a stepper motor. Then select and appropriate stepper driver and power supply.

No torque penalty for using microstepping (a common myth) - you pretty much always want to use microstepping to greatly reduce noise and vibration. You get some extra accuracy
through microstepping, but less than you might naively imagine, but the main benefit is less risk of miss-stepping through resonance, and much quieter operation.