There’s a lot of misconception about the subject (case in point: Excellent Reading). I also misinterpreted the information and made assumptions based on my (in)complete understanding of it. As such, here’s some excellent sources of information regarding such: CNCZone: Microstepping. The discussion goes on for some pages. Microstepping vs Full Stepping by Mariss Freimanis of GECKODRIVE, and others:
From Tom Kerekes:
Stepper motors don’t really have a torque mode like servo motors do. They are more like positional devices where mechanical torque is unrelated to motor current. Think of it like a fully energized electromagnet (pole position) pulling/holding the rotor to it. Under no load or friction the rotor will align to the the pole position such that there will be no motor torque. The rotor will be held to that position with a sort of spring force. As the rotor moves away from the pole there will be a restoring force that increases as a sinusoidal function of distance. At first the force will increase nearly linearly but then peak out (like a sinusoid) one full step away (1/200th of a motor rev). Beyond that distance the force (torque) will begin to drop and eventually reverse as it becomes attracted to the next pole. This is where a stepper stalls.
Stepper motors typically have high torque ripple and cogging so I wouldn’t expect high precision force control. Also stiction and friction in the ball screw would add to torque errors.
Steppers: 50-100 pole design
– Low cost
– High torque at low speeds and holding torque
– More torque density, smaller motor footprint for same power (Watt) size
– Can handle higher inertia mis-match ratios up to 30x + (inertia load/inertia of motor – assume directly coupled, not taking gearing or belt reduction into consideration). Servos start to get unstable at 10 – 20x range
– Requires more current to operate so run hotter in constant current mode (open loop)
– Slower acceleration due to pole design
– Noisier than servos
– More “cogging” than servos due to design
– Resolution: as good as 8000 cnts/rev encoder even with micro stepping
– Speeds limited, typically up to 2000 RPMs before torque is useless
Servos, 4-12 pole design
– High speed, high torque (up to 10,000 RPMs)
– Applications requiring high dynamic response
– Can synchronize multiple motors and do coordinated motion up to 4 axes typically
– Offers encoder resolutions up to 18 bit (262,144 counts/rev) and sometimes 20 bit.
– Typically more accuracy since encoders are within +/- 1 count with properly tuned systems
– Provides enough current to move or hold a load
– Other current algorithms are possible including learning machine vibrations and self compensating
– Overkill for simple motion and applications that require lower speed (1000 RPMs)
It’s a give and take kind of situation:
1) For the same peak current, a microstepped motor will have 71% (1/sqrt 2) the holding torque of a full-step drive. This is because motor torque is the vector sum of the phase currents. Advantage: Goes to full-steppers.
2) Most people want motors to turn, not just ‘hold’. As soon a full-step driven motor turns, its torque drops to 65% of its holding torque. Where did the missing torque go? To resonating the motor is where. Motor mfgs sometimes specify ‘dynamic torque’; this is specified at 5 full steps per second. It is always between 60 to 65% of holding torque. Not mentioned is the horrible racket the motor makes at 5 full steps per second.
Microstepped motors do not resonate at low speeds, so no torque is invested in resonance. Microstepped motors keep all their holding torque while turning slowly. 65% for full-steppers, 71% for microsteppers. Advantage: By a hair (6%), goes to microsteppers.
3) Things get a little dicy as speed increases. Microstepping ceases to have any benefit above 3 to 4 revolutions per second. The motor is now turning fast enough to not respond to the start-stop nature of full steps. You can say the step pulse rate is above the mechanical low-pass frequency limit (100Hz or so) of the motor. Motion becomes smooth either way.
Simple drives persist in microstepping anyway above this speed. This means they still try to make the motor phase currents sine and cosine past this speed. A little problem with that and it’s called ‘area under the curve’. The area under the sine function (0 to 180 degrees) is only 78% of a square wave (full-step). Advantage: Goes to full-step again.
More sophisticated drives transition from a sine-cosine currents to square-wave quadrature currents about then. Same as full-steppers. Advantage: Draw.
4) As peed increases even more, another really big problem crops up; mid-band resonance. This is the bane of full-steppers and microsteppers alike.
Maybe you have experienced it; the motor is turning 5 to 15 revs per second when you hear a descending growing sound from the motor and then it stalls for no good reason at all. Faster it’s OK, slower it’s OK, but not OK in that range. All you know is there is a big notch in the speed-torque curve. This mid-band instability, or parametric resonance.
Simple drives have no defense against this except to try not run the motor in this speed range. Better drives have circuitry to suppress this phenomena and it involves rate damping.
This is the equivalent of shock absorbers (rate dampers) on a car, without them a car bounces repeatedly. Imagine a washboard road surface in sync with this bounce; there would be sparks flying from the undercarriage in short order. With rate dampers the ‘bounce’ is suppressed to a single cycle. Mid-band compensation does the same with steppers.
5) More than any other type of motor, step motor performance is tied to the kind of drive connected to it. More than any other type motor, a stepper can be driven from very simple drives (full-step unipolar L/R) to very complex ones (microstepping full-bridge bipolar synchronous PWM mid-band compensated).
Motor performance will range from “Miserable, give me a servo, I’ll never use another stepper again” to “What is the big deal about servos anyway, this is just as good.”
It’s ALL in the drive.:-)
On Stepper Accuracy:
A typical step motor has a +/-5% non-accumulative tolerance specification. This means a full step will be 1.8 degrees, give or take 5% and the error is cyclic, meaning it cancels to zero for 1 full revolution. +/-5% means a 10% error band so the motor’s accuracy is 1/2,000th of a revolution and practice bears this out.
Any microstep resolution beyond 10 gives no additional accuracy, just empty resolution. The only uses for higher resolution are slightly smoother motion below 10 full-steps per second or the drive is used closed-loop.
On Torque Loss with Microstepping:
I’ve found this table, but from what i understood in this post, this valid for higher speeds than 5 steps per second.
Microsteps/full step Holding Torque/Microstep
[bbp]Your table of torque versus microstep resolution is somewhat misinterpreted. Holding torque is defined as the torque a motor exerts when its shaft is displaced +/- 1.8 degrees from its rest position.
The relationship between a stopped motor’s torque versus its shaft angle is sinusoidal over the span of 1 full step and your table reflects this relationship.
Let’s say you have a stopped 300 in-oz (about 2.1 Nm) motor. You apply a torque load that displaces the shaft 1/10 of a step (0.18 degrees) from its unloaded rest position. The applied torque equals 300 in-oz times sine (90 / 10) or 47 in-oz (1/3 Nm).
This is different than holding torque. Remove the 47 in-oz load and the motor returns to its original rest position. Exceed the 300 oz-in holding torque of the motor and it will jump to an adjacent pole location 7.2 degrees (4 full steps) away. It will not return to the original location when the load is removed.
What this means practically is the motor will always be 0.18 degrees behind where you think it is with a continuous 47 in-oz load and it will be 1.8 degrees behind if you apply a continuous 300 in-oz load. Exactly the same numbers apply for a full-step drive as well. Remove the load and the motor will spring to the zero error location whether it’s being microstepped or full-stepped.
Things get more interesting at higher speeds. The motor’s inductance introduces a 90 degree phase lag in winding current versus driving voltage. This results in an unloaded motor being 1.8 degrees behind where you think it is at higher speeds and 3.6 degrees behind when it’s loaded to just short of stalling. This behavior is drive-independent and the error is “reeled-in” when the motor slows down again.
OK, there are a bunch of misconceptions on this topic and they start with how microstepping versus torque is defined.
A step motor only generates restoring torque when the motor shaft is displaced from its rest position. You leave the motor alone, it sits perfectly at its rest position but generates no torque. Why? Because it’s sitting where it should be.
You apply some torque to the stopped motor. It moves from its rest position a little and it develops some torque to move it back to that position once you leave it alone. You apply even greater torque and it moves the motor further from its rest position. It generates even greater torque to get back to where it was before no one bothered it.
The motor acts like a torsional spring. Give it a little twist and the spring moves a little; give it a big twist and it moves more. Let go and it returns to where it was.
Unlike a spring, a step motor has a limit how hard you can twist it. The limit is the motor’s holding torque. Holding torque is reached when you twist the motor 1.8 degrees off of its rest position.
This is where the misconceptions come into play. Twist the motor at 10% of its holding torque and you will move the motor 1/10 of a full step. Twist the motor at 1% of its holding torque and you will move the motor 1/100 of a full step.
Does that mean the motor has only 10% or or 1% of its original holding torque? No; it’s still the same as before. All it means is the motor’s displacement angle is a function of the percentage of holding torque applied to the motor.
On what causes Mid-Band Resonance:
It’s actually system phase shift problem. A step motor is a mass-spring system meaning there is a 90 degree phase lag between torque and velocity. Think of a weight suspended from acoiled spring that has been pulled, then let go. Velocity is maximum when the restoring force is zero and visa versa.
At low speeds a step motor drive is a current source and contributes zero phase shift, making the loop phase lag 90 degrees. As speed increases, the drive has to revert from a current source to a voltage source when motor inductive reactance begins to limit current.
This adds another 90 degrees of phase lag, making the system phase lag 180 degrees. This is when trouble (mid-band resonance) begins. A 180 degree phase lag results in undamped and building oscillation; the motor stalls once the oscillation amplitude reaches +/-1 full step.
To stabilize the loop, a phase lead (derivative) component must be added. This takes the form of a rate of motor load change sense by the drive which is summed to the loop and adds about 70 degrees of phase margin.
On raising the voltage to a stepper motor to combat or delay Mid-Band Resonance:
Mid-band resonance cannot occur while the drive is in current mode. Increasing the supply voltage increases the ‘corner speed’ of the motor where the change from current mode to voltage mode occurs.
Testing for Mid-Band Resonance
Testing your motor and drive for mid-band resonance:
1) Set the motor on its side on a hard, flat surface. This can be a desktop; make sure there are no papers under the motor. It must be a hard surface.
2) Run the motor up to a speed where the drive is in voltage mode. This speed will be 5 to 15 revs per second depending on your motor inductance and supply voltage.
3) Pivot the motor up 1/2″ or so from the desktop using one corner of the motor’s mounting flange as a fulcrum. Keep the fulcrum flange corner in contact with the desktop.
4) Rotate the motor back down sharply (with a bang) onto the desktop and press down on it firmly.
5) The motor will immediately break out in mid-band resonance if the drive doesn’t have compensation. It will make a warbling or growling sound and then probably stall in a second or two if you continue to press down firmly on it.
Nothing interesting at all will happen if the drive has mid-band compensation.
On Step Motor Drives:
Step motor drives control current (are current sources) rather than the voltage going to the motor. The control feedback path compares the motor current against a reference value and adjusts the PWM power amplifier’s duty cycle to make the motor current equal to the reference.
The feedback loop is closed so long as the PWM duty cycle necessary is less than 100%. The motor’s inductive reactance increases with speed, requiring an increasing PWM duty cycle to keep motor current regulated to the reference value. Above some speed this requirement can no longer be met so motor current (and torque) decreases with further speed increase.
A current source in this predicament is said to have ‘run out of headroom’. This means the voltage necessary to maintain current regulation exceeds the available power supply voltage. The amplifier then cannot be described as current source anymore; it exhibits all the characteristics of a voltage source.
There is a symmetry between current sources and voltage sources: Let’s say you have a 1A current source limited to 1V and a 1V voltage source limited to 1A. How are they different and how do they behave?
An ideal current source will develop infinite voltage when working into an infinite Ohm load. An ideal voltage source will deliver infinite current to a 0 Ohm load.
A) 1V @ 1A voltage source:
1) Output impedance is zero Ohms.
2) Operates as a voltage source for all loads from 1 Ohm to infinite Ohms.
3) Output current is 1A for all loads less than 1 Ohm.
B) 1A @ 1V current source:
1) Output impedance is infinite.
2) Operates as a current source for all loads from 0 Ohms to 1 Ohm.
3) Output voltage is 1V for all loads greater than 1 Ohm.
It should be clear at this point there is no difference between a current source and a voltage source when there are limits on both current and voltage. The only characteristic that changes is the source impedance (from 0 Ohms to infinite Ohms and vice versa). It is this change of impedance that:
1) Inserts an additional -90 degrees in system phase lag.
2) Introduces an additional full-step lag in position.
3) Causes mid-band resonance for uncompensated drives.
4) Causes torque to decrease as the inverse of motor speed.
P.S. A few years ago I did an experiment to null-out the effects of inductive reactance by inserting a capacitance in series with each winding. The idea was a series LC circuit has zero reactance at its resonant frequency. The effect was a reasonably dramatic increase in motor torque at the LC resonant speed. The experiment was interesting but had no practical value; to be useful, it required the LC circuit to be resonant at every speed. This required (a), a variable capacitance ranging from infinite Farads at zero speed to less than 1uF at 3,000 RPM and (b) a means of servoing this variable capacitance to resonate the LC at the driven step frequency. No such variable capacitor exists in real life so solving for (b) was pointless.
For a motor inductance of 3mH, the capacitor size is:
3,000 RPM = 1.35 uF
300 RPM = 13 5uF
30 RPM = 13,500 uF
3 RPM = 1,350,000 uF
[responding to another poster’s post on drive technology]
1) The issue of microstepping versus full-stepping is moot when it comes to our drives. The reference waveform morphs from sinusoidal to quadrature square-wave once the speed is above where microstepping is of no further benefit (2-3 revs / sec). The motor is then being driven by a full-step drive waveform.
2) Non-recirculating switching is always used while the motor is moving. Recirculating mode switching is only used while the motor is stopped. The slow current decay time of this mode makes it impractical for use while the motor is motion.
3) The fundamental law of nature is “There Is No Free Lunch”; everything extracts a price. Increasing current source headroom or decreasing the winding inductance will increase mechanical power output. The relationship is V / SQRT L.
Power output increases proportionately with power supply voltage, unfortunately eddy current losses (motor heating) increase with the square of the supply voltage. Because heating losses out-race power increase, it places a practical limit on supply voltage for a given winding inductance. We derived an empirical equation (Vmax = 32 * SQRT L (in mH) ) to quantify this limit.
There are a lot of tricks one can use if one has a lot of logic gates to play with. That’s why I’ve gone with FPGAs for new drives instead of CPLDs.
A trick I’ve developed is to combine recirculating and non-recirculating modes within a single switching cycle and have the time spent in either mode a function of motor speed. At low speeds the switching cycle spends most of its time in the recirculating mode while at high speeds the majority of time is spent in the non-recirculating mode.
And this, my readers, is the apparent source of that often-quoted formula used to obtain the maximum useful voltage supply for a stepper motor.
On Power Supply Requirements:
[responding as to why the Gecko Drive in question has only a 7A fuse for four 3.5A motors]…The reason is a little different than that. Motor currents are 3.5A and there actually is 14 Amps total circulating through all 4 motors without any time limitations at all. The G540 motor drives are switching-type PWM drives; motor currents are always higher than the power supply current. At low speeds the PWM duty-cycle is around 60%. This means the drive pulls 3.5A from the supply for 60% of the switching cycle and then pushes that same 3.5A back into the power supply for the remaining 40% of the switching cycle. This happens 20,000 times a second. The average current drawn from the power supply is 0.7A for a motor that has 3.5A circulating in it’s windings. (60% * 3.5A – 40% * 3.5A = 0.7A)
You can also look at it intuitively: 3.5A at 48VDC is 168 Watts per motor and it’s enough heat to catch the motor on fire. Since that doesn’t happen then something else is going on.
Then, on encoders:
What’s nice about even quasi-sine encoders is they completely eliminate PID dithering or hunting when a motor is stopped or turning slowly. The improvement is very noticable. Also you can apply a micro-position adjust summing signal to move the motor to any location between the quadrature limits.
On his drive project (2012):
You could say I’m into designing drives. The drive project I’m working on will use an FPGA and optionally an MCU. The FPGA only version will have:
1) Direct digital step pulse frequency multiplication for full-stepping and half-stepping emulation with a 10 microstep drive. No more phase-locked loop circuits that have an intrinsic ambiguity on direction change.
2) Sub-microstepping. This is where a 10 microstep drive has its microsteps divided further into “sub-microsteps”. The divisor is the inverse of step pulse frequency; the slower you go, the more sub-microsteps there are. In effect, 10 microsteps are linearly interpolated and the motor motion is monotonic (non-incremental) no matter how slowly you go.
3) 3rd-harmonic compensation. Step motors have a non-linear electrical angle to mechanical angle transfer function. This non-linearity can be nulled by adding variable 3rd-harmonic content to the sine and cosine reference. There will be a family of sin/cos curves that have increasing 3rd-harmonic content. The look-up table address for these curves will be derived from an ADC reading a trimpot. This makes selecting the proper compensation curve intuitive to the user; just turn the trimpot to null any residual motor vibration. Even crappy motors can be made smooth.
4) Error blink codes. The drive has one green LED and one red LED. These will be flashed in a ‘1-2-3-pause’ sequence to indicate errors. For instance, GRN, GRN, RED might indicate motor Phase A isn’t connected. GRN, RED, GRN might indicate motor Phase B isn’t connected while GRN, RED, RED might indicate no motor is connected at all. You get the picture.
4) Mid-band resonance compensation. Mid-band resonance compensation requires 2nd-order damping (rate damping). We have a very effective electronic rate damping using rate of motor load change sensing which feeds a step pulse phase modulator to close the loop.
5) Reference morphing. Microstepping requires sin/cos current-loop reference inputs. Microstepping ceases to be important above 2 to 3 revolutions per second (the motor’s low-pass mechanical frequency response). The area under the curve for sine is 63% of a square-wave and that’s the torque you’ll get compared to a full-step drive if you persist with microsteppingabove the useful speed. I morph the reference waveform from a sinusoid to a square-wave for speeds above 3 revs/sec. The reference gradually changes from fully sine at 3 rps to fully square-wave by 6 rps. This is to avoid unpleasant torque discontinuities if it was switched abruptly.
6) Short-circuit and over-temperature protection, fused input. The short-circuit protection is fast-acting (<2uS), meaning it safely protects against insults while the drive is active, not just during power-up. Temperature protection warns at 95% limit, shuts down at 100% of limit. The drive is fused using an ultra-fast PicoFuse; it’s fast enough to prevent drive damage in the event of gross miss-application such as reversed
power supply polarity.
Ten codes are possible; 8 blink sequence codes plus continuous GRN for everything is OK while continuous RED indicates a fault condition.
That’s all in the FPGA and it constitutes the base drive. The drive is designed to also have an optional 16-bit MCU, and as a further option, a 4Mb Flash ROM and an RS-485 interface.
The 16-bit MCU only option allows:
1) VCO mode operation. On-board trimpots set CW and CCW speeds while a third trimpot sets the rate of acceleration. The STP and DIR opto-isolated inputs become the CW and CCW limit switch inputs, the ENABLE input becomes the RUN/STOP input and the FAULT output becomes the “motor is running or stopped” output. The trimpots go into ADC converters because the values are digitally handled.
About CW, CCW and ACEL values. The drive’s FPGA digitally generates 32,768 CW and CCW speeds. The speeds are all evenly spaced; if 1Hz is the minimum speed, 32,767 Hz is the next to the highest speed. All speeds have a 1Hz resolution. This is not a counter/timer circuit.
2) The drive operates autonomously; no PC or motion controller is needed. It accelerates at a set rate to a set CW speed, hits a CW limit switch, decelerates, changes direction and accelerates to a set CCW speed until it hits the CCW limit switch to repeat the process. It can cycle back and forth or single cycle depending on how the input switches are used. This takes care of many industrial processes.
3) The MCU only VCO option drive retrogrades to a non-MCU step motor drive via a DIP-switch setting for backwards compatibility. A manual on-board 10-position DIP switch sets motor current, drive step resolution, etc.
Things get much more interesting in the all-options (MCU, Flash ROM and RS-485) mode:
1) The drive can execute vector based motion. Vector based motion means moving along a 2D or 3D vector where the vector motion is defined as an acceleration, velocity and distance along a vector. Other than single axis vectors, multiple drives are involved that synchronize their activities between each other.
2) The vector motion control uses an “on the fly” algorithm. This means the three physics variables, acceleration, velocity and distance can be changed even while motion is in progress. Change the rate off accel/decel and you’ll get to where you were going. Change velocity while en route and you’ll get to where you were going. Change the destination and you’ll still get to the new one. Even if the new destination is behind where the axis are when you issue it. They will simply decelerate, reverse direction, accelerate, run, decelerate and stop at the new location.
2) Flash ROM. The Flash 4Mb ROM can store 1,000,000 coordinate locations to a 32-bit precision. Multiple drives can execute 1 million coordinate 2D, 3D or more dimension vector moves.
3) The RS-485 interface uses simple ASCII commands via a UART communications port. If you have NotePad and HyperTerminal, you can write a program to the drives. We have hired a hired-gun GUI professional to write us a really cool Windows application which will look very good and ease the task.
4) The drives will coordinate between each other to form a distributed virtual multi-axis motion controller. RS-485 is a half-duplex scheme which means there has to be a master and multiple slaves. The master drive (ID = 0x00) will synchronize, (phase lock loop) the slave Xtal oscillators and apportion the slave vector component tasks.
5) The drive and/or its slaves will be able to operate autonomously (no PC involved) running up to 1 million coordinate location programs. Once programmed via RS-485, no further PC involvement will be necessary.
6) RS-485 stretches to Hades and back. You could build a machine that has the X-axis drive here, the Y-axis drive there and a Z-axis drive somewhere else. Hundreds of feet could separate them if you have a really big machine. Yet they would find each other and coordinate between themselves as if they were run by a single motion controller.
7) Needless to say, the full-on drives can retrograde to the VCO mode and further retrograde to just a step motor drive (albeit the best and smoothest step motor drive you have ever seen).
P.S. My company is Geckodrive.
On adding dampeners (mass) / flywheels to remove harmonic bands:
Adding a flywheel is a losing proposition because it adversely affects your system’s torque to inertia ratio. The inertia of the flywheel limits your system’s ability to accelerate / decelerate. Furthermore, it masks the instability you are trying to cure by only shifting the speed at which it manifests itself.
Added by “Hendrikus”:
Adding a flywheel, will kill the dynamic performance of the stepper motor. These will always be optimized by the manufacturer for minimal rotational inertia. Resonance problems are much easier handled by the drives, like Mariss and I are doing. Once high-res microstepping is used, the resonance problems will arise from the inherent discontinuous sin/cos wave profile, as the total of (abs)current in both motor windings has a maximum at every 45degrees (cos45+sin45 = 1,41 and a minimum at every 90 degrees (cos0+sin0 = 1).
Correcting wave profiles for this, eliminates already a lot of resonance. Only with advanced drives it is possible to have this opportunity. Then it is also possible to correct for discontinuities in the magnet-tooth geometry. That is what you experience when turning an unconnected stepper motor by hand: you feel the 50 tooths, the same will happen if the motor is electrically driven.
This is also an answer to the question of microstepping vs full stepping and torque loss. Yes there is torque loss with microstepping (and also with half-stepping), at passing the 45degrees points of the si/cos wave. This is to be compared with full stepping, which is hopping with 90degrees through the sin/cos table and always has the same max. torque.
And now, Closed Loop Steppers, from the original linked article:
#5 by Jason Doege on 2011-09-11 – 14:33