understand the code and
makes programming, running,
and debugging easier. The
goal is to lower the cognitive
load and have fun, of course!
Lever Up with
Steppers
QI have some levers in an elevated location, and I was thinking of using
a stepper motor to control
them. I want to control the motor manually, i.e., rotate
clockwise while I observe, stop; no computer connection.
Maybe make another adjustment a half hour later, etc.
What motors and controller should I use?
G. Alldren
AStepper motors come in many sizes and shapes, accuracies, step resolutions, and even phases. It will be hard to make a real recommendation without knowing the specific
requirements. Some hobbyist suppliers have steppers and
controllers available.
Adafruit is one of my favorite suppliers of such things.
They also have great tutorials to get you started. There’s a
nice 12V/200 steps per revolution motor available fairly
cheaply at https://www.adafruit.com/product/324. The
torque is 1.6 kg-cm, which is not too shabby. It has two sets
of windings requiring 350 mA. This is just a guess as what
you might need, though. The size of the motor that can be
controlled will depend on the controller/driver.
Next, a controller is required to power the windings.
You can build one yourself from FETs but getting one
pre-made is so cheap that it’s almost not worth it — except
as a learning exercise. The DRV8833 looks like a good
choice with its 1.2A drive capability and dual H-bridges.
It’s very compact and has built-in current limiting. You can
see it on a breakout board at https://www.adafruit.com/
product/3297.
If your motor requires 1.2A or less at 2. 7 to 10.8V, this
should do the job. For the motor we chose above, we’ll
just run it on a little less voltage at the expense of a little
torque.
There’s a great tutorial for how to wire up the driver
board to the motor at https://learn.adafruit.com/
adafruit-drv8833-dc-stepper-motor-driver-breakout-board/
stepper-motor-usage.
Now, the controller above must be controlled, so to
speak. There are four digital inputs to the controller board.
While a small computer controller like an Arduino is ideal,
they can be controlled manually with a pair of switches.
It might be a bit tedious to get the motor to step, but it is
possible. The motor we chose is a bipolar stepper, so we
wire the four winding wires appropriately to the controller.
We can make a pair of transistor inverters that take
some of the complexity out of the control.
Since two of the four control wires are
always inversions of each other, we’ll let the
transistors do the work and then can use
a simple stepping sequence. If we reverse
the sequence, the motor should step in the
opposite direction.
First, look at Figure 2 to see the add-ons
for the controller. Note connections to AIN1,
AIN2, BIN1, and BIN2.
Figure 3 shows the stepping sequence.
Two toggle switches are used to set the wires
high and low as appropriate. If you want to
do this with an Arduino, there is a stepper
motor control library that will do all this as
if by magic. You’ll find it at https://www.
arduino.cc/en/Reference/Stepper. NV
QUESTIONS and ANSWERS
n FIGURE 3. Stepping sequence.
n FIGURE 2. Stepper motor driver additions.
16 May/June 2018