Author Topic: Determining rotational accuracy of a drive unit.  (Read 3115 times)

0 Members and 2 Guests are viewing this topic.

Offline Puffie40Topic starter

  • Regular Contributor
  • *
  • Posts: 54
  • Country: ca
  • Irregular Logic
Determining rotational accuracy of a drive unit.
« on: May 18, 2021, 04:47:18 pm »
So we have a stepper motor/worm gear drive at work that does not provide very good positional accuracy at work, and I am trying to figure out the accuracy mathematically.

The Stepper motor has a 25,000 step/rev resolution, and it is coupled to a 20:1 gearbox.  The supplier told us that means

(360/25,000)*(1/20) = 0.00072 degrees/step

I've determined the model of the gearbox used has a maximum backlash of 0.13 degrees, and I think this is a potential source of the problem (There is other issues, but this is the main one I can work with).
The problem I'm having is determining how that backlash factors into the original equation.  So far, I think this would be inserted into the equation as an error tolerance (ie 0.00072 degrees/step,+/- 0.13 Degrees).

Any thoughts?
 

Offline Benta

  • Super Contributor
  • ***
  • Posts: 5869
  • Country: de
Re: Determining rotational accuracy of a drive unit.
« Reply #1 on: May 18, 2021, 06:26:33 pm »
Depends on whether is has to work bidirectionally or only in one direction, and if the mechanical load is reasonably constant.
In just one direction, backlash is not very important. But when you reverse direction, you'll have a 0.13 degree "dead zone" before the output shaft starts moving again.

 

Offline HwAoRrDk

  • Super Contributor
  • ***
  • Posts: 1471
  • Country: gb
Re: Determining rotational accuracy of a drive unit.
« Reply #2 on: May 18, 2021, 07:22:51 pm »
Yeah, whether it's plus or minus 0.13 degrees will depend on the direction of rotation.

Seems silly having such a fine step resolution when it's massively outweighed by the mechanical backlash. :)
 

Offline nctnico

  • Super Contributor
  • ***
  • Posts: 26878
  • Country: nl
    • NCT Developments
Re: Determining rotational accuracy of a drive unit.
« Reply #3 on: May 18, 2021, 08:35:22 pm »
I'd use a toothed belt drive reduction instead of a gearbox combined with a servo motor. From there on an absolute position encoder along the worm drive to create a feedback system into the servo motor. One of the things I've learned is that stepper motors kinda suck as an open loop control system and if you can going for a closed loop, a servo motor gives you a much simpler control system.

Using gears together with stepper motors is a big no anyway because the stepper motor will wreck the gear teeth.
« Last Edit: May 18, 2021, 08:36:55 pm by nctnico »
There are small lies, big lies and then there is what is on the screen of your oscilloscope.
 

Offline james_s

  • Super Contributor
  • ***
  • Posts: 21611
  • Country: us
Re: Determining rotational accuracy of a drive unit.
« Reply #4 on: May 18, 2021, 08:44:50 pm »
CNC equipment typically has a backlash compensation setting, you measure the actual backlash under real world conditions and enter that constant and then whenever the drive changes direction it will account for that by turning the motor far enough to compensate. Can you do something like that with your system? You'll never completely eliminate backlash.
 

Offline Benta

  • Super Contributor
  • ***
  • Posts: 5869
  • Country: de
Re: Determining rotational accuracy of a drive unit.
« Reply #5 on: May 18, 2021, 08:57:13 pm »
I'd use a toothed belt drive reduction instead of a gearbox combined with a servo motor.

A 20:1 toothed belt reduction? Please post a picture.

 

Offline james_s

  • Super Contributor
  • ***
  • Posts: 21611
  • Country: us
Re: Determining rotational accuracy of a drive unit.
« Reply #6 on: May 18, 2021, 09:11:29 pm »
It's certainly possible to do a 20:1 belt reduction, but there's absolutely nothing wrong with using a gearbox.
 

Offline MarginallyStable

  • Regular Contributor
  • *
  • Posts: 65
  • Country: us
Re: Determining rotational accuracy of a drive unit.
« Reply #7 on: May 18, 2021, 11:15:04 pm »
Most of the robotic arms I have seen utilize "harmonic gear reduction" which does give very little, if any, backlash. Also known as "Strain Wave Gear reduction".
https://en.wikipedia.org/wiki/Strain_wave_gearing
 

Online Someone

  • Super Contributor
  • ***
  • Posts: 4525
  • Country: au
    • send complaints here
Re: Determining rotational accuracy of a drive unit.
« Reply #8 on: May 19, 2021, 12:49:08 am »
One of the things I've learned is that stepper motors kinda suck as an open loop control system and if you can going for a closed loop, a servo motor gives you a much simpler control system.

Using gears together with stepper motors is a big no anyway because the stepper motor will wreck the gear teeth.
From your experience. In my experience open loop stepper motor systems can be built (cheaply, much cheaper than servos with the same resolution) that don't have those drawbacks and need interferometric angle measurement to observe the positioning accuracy and repeatability.

Its easy to do things poorly, but not that much effort to implement given technologies well. All this information is out there for people who want to find it.
« Last Edit: May 19, 2021, 12:54:31 am by Someone »
 

Online Someone

  • Super Contributor
  • ***
  • Posts: 4525
  • Country: au
    • send complaints here
Re: Determining rotational accuracy of a drive unit.
« Reply #9 on: May 19, 2021, 12:53:59 am »
I am trying to figure out the accuracy mathematically.
Good luck! most of the data sheet "specifications" are not going to translate into absolute accuracy. Some times you might get a "step accuracy" angular positioning tolerance which is where you'll need to start.
 

Offline NiHaoMike

  • Super Contributor
  • ***
  • Posts: 9007
  • Country: us
  • "Don't turn it on - Take it apart!"
    • Facebook Page
Re: Determining rotational accuracy of a drive unit.
« Reply #10 on: May 19, 2021, 01:22:47 am »
Using gears together with stepper motors is a big no anyway because the stepper motor will wreck the gear teeth.
Care to explain why? It's not that difficult to find a machine that uses a stepper motor driving gears and they seem reliable enough.
Cryptocurrency has taught me to love math and at the same time be baffled by it.

Cryptocurrency lesson 0: Altcoins and Bitcoin are not the same thing.
 

Online Someone

  • Super Contributor
  • ***
  • Posts: 4525
  • Country: au
    • send complaints here
Re: Determining rotational accuracy of a drive unit.
« Reply #11 on: May 19, 2021, 01:59:29 am »
Using gears together with stepper motors is a big no anyway because the stepper motor will wreck the gear teeth.
Care to explain why? It's not that difficult to find a machine that uses a stepper motor driving gears and they seem reliable enough.
This is a common misconception from experience of driving stepper motors without micro stepping. Its not stepper motors that are the problem, but a vibration inducing drive method (which could equally apply to most motion actuators).
 

Offline amyk

  • Super Contributor
  • ***
  • Posts: 8262
Re: Determining rotational accuracy of a drive unit.
« Reply #12 on: May 19, 2021, 03:20:39 am »
If you need no backlash at low to moderate loads, there are gearboxes that use a preload mechanism to do that (similar to the mechanism in a dial indicator.)
 
The following users thanked this post: Someone

Offline Benta

  • Super Contributor
  • ***
  • Posts: 5869
  • Country: de
Re: Determining rotational accuracy of a drive unit.
« Reply #13 on: May 19, 2021, 07:37:34 pm »
As the OP hasn't come back with more information, all this is moot.

 
The following users thanked this post: thm_w

Offline Puffie40Topic starter

  • Regular Contributor
  • *
  • Posts: 54
  • Country: ca
  • Irregular Logic
Re: Determining rotational accuracy of a drive unit.
« Reply #14 on: May 20, 2021, 06:04:08 pm »
The application is for a camera pan-tilt platform, so the load is constant.  The programmers noticed the positioning accuracy would constantly get worse the more it moved. I did some one-way position movement and noticed the drift was constantly increasing the further it moved from the start point.

 I've heard that stepper motors and gearboxes are bad for positional accuracy, but I also don't think not having any position feedback aside from some limit switches would help either :palm:

Because it is a supplier-provided component, I cant do any redesign, but I can write up a small report to explain why.
« Last Edit: May 20, 2021, 06:07:08 pm by Puffie40 »
 

Offline james_s

  • Super Contributor
  • ***
  • Posts: 21611
  • Country: us
Re: Determining rotational accuracy of a drive unit.
« Reply #15 on: May 20, 2021, 06:17:05 pm »
Missed steps can be an issue too, it's something that should be investigated. If anything ever causes a missed step to occur it's going to be a problem, because without any type of feedback the missed steps will accumulate. A classic workaround was the Apple II floppy drive, at power on it would drive the head positioning stepper with enough steps to move it all the way to the end stop from any position, it had no home sensor, it would just blindly crash it into the stop and then it knew it was in the home position, it's the reason for the iconic grinding chatter when you power on one of those machines. Something similar could be done with a camera positioner I suppose, but a home sensor would be better.
 

Offline Puffie40Topic starter

  • Regular Contributor
  • *
  • Posts: 54
  • Country: ca
  • Irregular Logic
Re: Determining rotational accuracy of a drive unit.
« Reply #16 on: May 20, 2021, 06:22:29 pm »
Missed steps can be an issue too, it's something that should be investigated.

How could one check for missed steps?
 

Offline ajb

  • Super Contributor
  • ***
  • Posts: 2596
  • Country: us
Re: Determining rotational accuracy of a drive unit.
« Reply #17 on: May 20, 2021, 06:39:44 pm »
There are several different kinds of "accuracy" and it's not immediately clear which kind you're describing.  There's actual accuracy, which is how close the system gets to its commanded position, repeatability, which is how close the system gets to a commanded position after moving to another position, stability/drift, which is how much the position error changes over time and can be a short- or long-term, linearity, which is how consistent the positioning is over the range, and noise, which is how much the system moves when commanded to hold position.   

The application is for a camera pan-tilt platform, so the load is constant.
That's only true if the load is balanced over both rotational axes.  If it's not perfectly balanced, then the load will change through the rotation.  This could introduce an error term via simple mechanical deflection in the drive or the mechanical structure, or by the fact that the required positioning and holding torque will keep the motor itself from holding its commanded position.  Even if there were no gearbox involved and the load were solidly mounted to the shaft there would be a positioning error as the torque changed because the torque will move the rotor away from its theoretical magnetic position.  The direction of the holding torque may even reverse if the load's center of gravity crosses from one side of the axis to the other, which in combination with backlash could be a significant issue. 

Quote
  The programmers noticed the positioning accuracy would constantly get worse the more it moved. I did some one-way position movement and noticed the drift was constantly increasing the further it moved from the start point.
  So is the problem getting worse as the system makes more moves (as if it's wearing, for example), or is the accuracy over a single move worse the longer the move is?  If the latter is it really the length of the move or where the destination is within the range?  These all imply different underlying problems.

Quote
I've heard that stepper motors and gearboxes are bad for positional accuracy, but I also don't think not having any position feedback aside from some limit switches would help either :palm:

Well, define "bad"?  Open loop steppers are used all over the place because they're good enough for a lot of applications.  Closed loop is certainly better in terms of reliable accuracy, but costs more and is therefore "bad" if the application doesn't require it.  Closed loop where the loop includes all of the mechanics--like some high end CNC machines that use glass scales directly on the axes for position feedback--is even better, but even more expensive.  Gearboxes and other mechanical transmissions certainly introduce additional potential error terms, and where accuracy is required those need to be designed to minimize those errors, which is why you see harmonic drives used in robots (where the mechanics amplify angular errors so angular position is REALLY important) and ball screws with preloaded angular contact bearings and zero-backlash preloaded ball nuts in CNC machines.  It's engineering, "bad" and "good" are all relative to the application. 

One other thing specific to steppers, although this is likely not significant here because it will be largely swamped by your gearbox issues, is that when microstepping the microsteps are often not linear across a full step.  This is because the way that fractional step currents in the windings translate to magnetic field strengths and thus torque on the rotor varies a bit from the theory due to design and manufacturing factors in the motor itself.  Trinamic has an appnote about this somewhere, and some of their drivers include a lookup table that can be programmed to modify the shape of the microstepping curves to compensate.  They also have their own line of motors specifically designed to provide very linear microstepping, which in my testing are noticeably better than at least the real cheap ones from ebay or wherever. 
 

Offline nctnico

  • Super Contributor
  • ***
  • Posts: 26878
  • Country: nl
    • NCT Developments
Re: Determining rotational accuracy of a drive unit.
« Reply #18 on: May 20, 2021, 07:11:31 pm »
Well, define "bad"?  Open loop steppers are used all over the place because they're good enough for a lot of applications.
If you look more closely you'll notice that none of them are actually open loop. All of them have at least some form of nulling.
There are small lies, big lies and then there is what is on the screen of your oscilloscope.
 

Offline Puffie40Topic starter

  • Regular Contributor
  • *
  • Posts: 54
  • Country: ca
  • Irregular Logic
Re: Determining rotational accuracy of a drive unit.
« Reply #19 on: May 20, 2021, 07:36:16 pm »
There are several different kinds of "accuracy" and it's not immediately clear which kind you're describing.  There's actual accuracy, which is how close the system gets to its commanded position, repeatability, which is how close the system gets to a commanded position after moving to another position, stability/drift, which is how much the position error changes over time and can be a short- or long-term, linearity, which is how consistent the positioning is over the range, and noise, which is how much the system moves when commanded to hold position.
I would say actual and repeatability are the two big ones.  The Called-for angle, and the measured angle can be off as much as two degrees, and that positional error appears to increase the more the pan-tilt has traveled from the start. (For example, after initalizing the PT to 0 degrees, and move the PT to 90 degrees, I get an angle of 89.8.  If I move the PT forward a complete revolution around to 90 degrees again, I get a actual angle of 88.8.
   

Quote
So is the problem getting worse as the system makes more moves (as if it's wearing, for example), or is the accuracy over a single move worse the longer the move is?  If the latter is it really the length of the move or where the destination is within the range?  These all imply different underlying problems.
I did some measurements with increasingly larger movement increments, and observed that the error pattern in the graphs stays about the same. The curious part of my testing has shown that the error increases quite a bit after the PT moves past 180 degrees, and as I move past 360 degrees, that error continues to increase in the same pattern.  It even reverses when you move in the opposite direction.

I am feeling rather inexperienced with these kinds of issues, so you'll have to forgive me if I seem to be giving confusing information.
 

Offline ajb

  • Super Contributor
  • ***
  • Posts: 2596
  • Country: us
Re: Determining rotational accuracy of a drive unit.
« Reply #20 on: May 20, 2021, 07:49:24 pm »
Well, define "bad"?  Open loop steppers are used all over the place because they're good enough for a lot of applications.
If you look more closely you'll notice that none of them are actually open loop. All of them have at least some form of nulling.

Not sure what you're trying to say here.  If you're talking about nulling in the conventional electronic sense as part of the driver's current control system that's hardly the same thing as using an encoder to close the loop around the mechanical position of the motor.  If you're talking about "nulling" the mechanics by referencing an initial position to a limit or home switch, that's also different because the loop is only "closed" during the referencing and does not in and of itself provide any assurance that any other position is accurate the way a true closed-loop mechanical system with an encoder would. 
 

Offline Benta

  • Super Contributor
  • ***
  • Posts: 5869
  • Country: de
Re: Determining rotational accuracy of a drive unit.
« Reply #21 on: May 20, 2021, 07:55:30 pm »
There's an interesting issue which is rarely mentioned.
This is the mechanical resonance of the stepper motor vs. stepping frequency.

I attended a very interesting conference on this point (must've been around 12 years ago) hosted by AMI Semiconductor.
The mechanical response of the motors in relation to step frequency and ramp speed was astonishing. At certain frequencies, the motor would simply lose torque or holding torque and begin step-slipping. AMI had some really smart devices that would detect this and modify the driver parameters accordingly (yeah, I know, sales talk).
But the Bode plots of the motors were extremely interesting.

Unfortunately, I no longer have the conference material, but perhaps a search on www.onsemi.com in the "Power Management" section might find some app notes, presentations or videos.

Not necessarily relevant to this discussion, but something to keep in mind.
 

Offline james_s

  • Super Contributor
  • ***
  • Posts: 21611
  • Country: us
Re: Determining rotational accuracy of a drive unit.
« Reply #22 on: May 20, 2021, 08:01:54 pm »
How could one check for missed steps?

Well, that can be tricky. Probably the easiest way to do it is figure out a way of connecting an external position sensor and then write a script that makes repeated movement commands and record the offset between commanded position and measured position and look over the data to see if the offset appears to randomly jump around. You could also repeatedly sweep from say 90% in one direction to 90% in the other direction and see if it develops an offset over time, which would suggest missed steps. The difficulty will be if it's missing approximately the same percentage of steps in both directions over time.

You might also see if you can slow down the stepping so that it's moving one step at a time, at low speed a stepper is less likely to miss, and it's more apparent if you send it a step command and the device doesn't move. If there's always an offset near the end of the travel range and the offset doesn't seem to vary much then it's possible that your drive ratio is not quite precisely what you think it is.
« Last Edit: May 20, 2021, 08:04:59 pm by james_s »
 

Online Someone

  • Super Contributor
  • ***
  • Posts: 4525
  • Country: au
    • send complaints here
Re: Determining rotational accuracy of a drive unit.
« Reply #23 on: May 21, 2021, 12:23:03 am »
How could one check for missed steps?
Well, that can be tricky. Probably the easiest way to do it is figure out a way of connecting an external position sensor and then write a script that makes repeated movement commands and record the offset between commanded position and measured position and look over the data to see if the offset appears to randomly jump around. You could also repeatedly sweep from say 90% in one direction to 90% in the other direction and see if it develops an offset over time, which would suggest missed steps. The difficulty will be if it's missing approximately the same percentage of steps in both directions over time.

You might also see if you can slow down the stepping so that it's moving one step at a time, at low speed a stepper is less likely to miss, and it's more apparent if you send it a step command and the device doesn't move. If there's always an offset near the end of the travel range and the offset doesn't seem to vary much then it's possible that your drive ratio is not quite precisely what you think it is.
To expand on this a bit more, missed steps are often from acceleration as much as velocity (noting the velocity resonances mentioned above (which can't be measured from bode plots in steady state (and can be only reproducible in operation with the specific loads (motion ends up with many layers of context/complexity)))). So the classic way to test for missing steps is to walk the system to random positions at random speeds and accelerations inside the operating envelope, then periodically return to a known/observable origin and check the alignment there.

I would say actual and repeatability are the two big ones.  The Called-for angle, and the measured angle can be off as much as two degrees, and that positional error appears to increase the more the pan-tilt has traveled from the start. (For example, after initalizing the PT to 0 degrees, and move the PT to 90 degrees, I get an angle of 89.8.  If I move the PT forward a complete revolution around to 90 degrees again, I get a actual angle of 88.8.
...
I am feeling rather inexperienced with these kinds of issues, so you'll have to forgive me if I seem to be giving confusing information.
Simple things like how you measured angles and what the drive was commanded/configured to do are important here. Describing "error" and their accumulations or patterns isn't working so well and you'd probably be better off plotting it to show what you mean. Being out by a degree or more could be entirely the gearbox, or some ratio calculation in the software that is incorrect (floating point is not a magic answer to precision).
 

Offline james_s

  • Super Contributor
  • ***
  • Posts: 21611
  • Country: us
Re: Determining rotational accuracy of a drive unit.
« Reply #24 on: May 21, 2021, 02:53:16 am »
After thinking about this some more, I think a good place to start is to single step it through the entire range from one end to the other and measure the angle every 5 degrees or so. You need to find the total number of steps required to traverse the entire range and see if it equals the value that you think it does. For example of the gear ratio is off very slightly you might find that instead of 3,000 steps it actually takes 2973 or 3019, just numbers I pulled out of thin air for sake of example. If you're assuming 3,000 steps then your calculations going between relative positions are going to be off. The backlash ought to be more or less constant, at any given position the moving part will have +/- x degrees of slop if you wiggle it. If it hasn't missed any steps the actual position should never be off any more than the amount of backlash in the mechanism.
 


Share me

Digg  Facebook  SlashDot  Delicious  Technorati  Twitter  Google  Yahoo
Smf