I am trying to help a friend out with his Maker Faire project. I have programming, sys admin, and hardware experience but am new to stepper motors.
The basic functionality of the stepper that he needs is that at some point, it gets turned on and the speed of rotation increases over time at some rate depending on other conditions. Think of it like a dropped ping pong ball attached to a belt driven by the stepper. So it accelerates to a speed and then remains at that speed. Now, imagine that you turn on a fan under the ball that blew air up under it. The ball would decelerate, stop, and then accelerate in the opposite direction.
Now, while I'm a ham and have some electronics experience, I have never worked with stepper motors before. It seems like all you have to work with is steps (!) and you can choose the stepping mode. The controller being used is the Adafruit stepper controller and a NEMA 17 motor. So if I just sit in a loop and send step commands to the controller, that is as fast as it can rotate, right? And to get different speeds, you delay between sending the step commands, right? I will be doing this in python and have experience with python.
I did some google searching and it seems that a method of getting a stepper motor to step faster is by increasing the i2c speed from the default, right? Is that commonly used in programs to vary stepper speed? Or only if the max speed needs to be increased?
I would love to see examples of code doing this kind of acceleration and deceleration using stepper motors. Is it just a combination of step and wait commands? Any tips about controlling stepper speed would be appreciated! The Adafruit library does have a setSpeed function - how would this be used to get the desired acceleration and deceleration? It is mentioned here: https://learn.adafruit.com/adafruit-dc- ... per-motors But they don't have any examples of varying the speed.
I am using the parts that my friend speced and bought for his project, but wouldn't DC motors probably have been a better choice when you want to control the speed of motion of an object by a motor? Still, I have seem projects where people have made car and other mobile objects using steppers so they must have needed to deal with the same speed issues.
Thanks for any help!