Close

Motivation to Use Steppers over Servos

A project log for RoboBarista: A Coffee Brewing Robot

A flexible, open source robot arm that grinds, pours, and serves only the best robotic brewed Coffee.

jim-shealyJim Shealy 05/19/2014 at 23:440 Comments

In my quest to derive a robot control scheme from scratch, I've been working to figure out how to control a stepper motor. Stepper motors are great because they're cheap, relatively simple to control, and can maintain a constant torque without burning out. Unlike a hobby brushless motor or brushed motor, stepper motors don't burn out when they stall. They're designed to go to a position and stay there as long as it's below the rated torque. By changing the current going through the windings you make the motor "step" (hence "stepper motor") in a direction and stay there. You can see a simplified image below.

If you imagine driving the coils, the magnetic rotor will align with a set of coils. Energize the other ones and it'll "step" to align with the other coils. What's neat is that if you power the coils in various arrangements you can actually achieve fractional steps (albeit these steps tend to become less accurate as you divide them finer).

Why Not Use a Servo?

Servos are also (generally) meant to create large torques through a geared drivetrain. They also include control circuitry to go to a postion that you command, eliminating most of the control logic necessary. Albeit very convenient there's a few major disadvantages:

1- Jittery: Servos have a tendency to not hold an exact position and jitter. Cheap servos have control logic that makes them act like a really stiff spring from a commanded position. (This is proportional control; the force exerted is proportional to the distance from the desired target, IE a spring). Because cheap servos have a very low resolution they tend to jitter around the desired position due to their accuracy errors.

2- Inaccurate: Cheap servos don't necessarily go to the position commanded. Hysteresis (or the the inability to return to a state due to losses such as friction) and various loading conditions will prevent the servo from going all the way to the desired point. This is typically due to the proportional control lowering the output torque near the target position. While this doesn't make a difference on an RC system due to the human being able to compensate, on a robot arm these inaccuracies will be propagated, amplified, and compounded by the physical arm to result in very poor accuracy. This is not to say that there aren't accurate servos! they're just quite expensive (typically >$90)

3- Fragile: Servos definitely have higher holding torque per size than stepper motors. However, when a servo is over torqued and back driven, the gears have a tendency to break or strip. Stepper motors will instead just skip a magnetic pole and settle into the next allowable position. This is especially nice if for example the robot arm runs into an obstacle or is hit (ie bumped) by an object. These impacts are especially prone to breaking servos.

4- Expensive: Nice servos are expensive! There's a reason for this though, the accurate sensors, high speed, high torque drives cost more to produce.

5- Typically Limited range: Servos rarely are continuous rotation. This can present serious design challenges (and reduces the flexibility of the design!)

Now, that's all not to say that stepper motors are the god of all motors. Servos are extremely convenient and provide a very compact mechanical control package. They're very easy to control and if you're ok with low accuracy, they're definitely cost effective. The main difference here is that with a good mechanical design and control logic, stepper motors are more robust and potentially significantly cheaper. Especially with the proliferation of 3D printers that rely on stepper motors, it's become progressively cheaper and easier to use steppers.

Discussions