Anti-backlash algorithms - Page 1
Forum section: electronics / general

author: Infraviolet
author_rank: Super Contributor
timestamp: March 16, 2023, 09:25:18 pm
content: Can anyone point to any good resources on these. That is to say algorithms for motor control when there is backlash (wobble) within a gear chain.In my circumstances I've got the motor itself, which feeds from the actual DC motor, through the motor's built in gearbox (which will have some backlash), to an output shaft. The output shaft then powers one gearbox which feeds rotation to an encoder, and powers a seperate gearbox which gears down a bit further before the final output. So the place I measure at is both some backlash away from the motor's internals, and some backlash away from the output.Does anyone know of any resources about the sort of algorithms which could let me calculate backlash reduction methods which, during operation (at potentially many different torque loads), can take input data only from that encoder, although some amount of "training" (I'm not talking AI here so much as taking measurements beforehand at other points on the shafts system) with measurements at the motor, the output shaft and the encoder shaft would be possible (but only at one or two torque levels, not at all the levels the system could find itself handling).ThanksP.S. I'm talking about practically focused resources, not highly abstracted academic papers, and I'm mroe interested in reading things tounderstand this and implement my own code for it, rather than full existing libraries which do it all but don'texplain how they do it. I understand this sort of anti-backlash method occurs sometimes within industrial servo units where they use multiple encoders, one at the motor itself and one at the actual output shaft, but what about circumstances where you're trying to extrapolate knowledge of these from an encoder separate from them by some slightly backlashy gears already.

author: Infraviolet
author_rank: Super Contributor
timestamp: March 28, 2023, 08:32:46 pm
content: Any thoughts on this? And perhaps also the related question of how to do PID when a system isn'tproperlylinear, the way a DC motor won't start turning until some threshold voltage isapplied, but then is immediately going very quickly from that voltage upwards.Thanks

author: beanflying
author_rank: Super Contributor
timestamp: March 30, 2023, 07:10:35 am
content: The best backlash compensation macro or algorithm is to remove as much or all backlash mechanically then not use one.The issue with electronic backlash compensation is as you mention you need additional encoders or scales of some sort and if you haven't tightened up the mechanical side of it or added a lock to that movement then that is a futile exercise too as any PID loop will be slamming either side trying to hold position against that slop.Doing this in gearboxes typically gets really expensive so maybe providing you don't need a direction change to back away from a nominal and drive forward and include a break (depending on application) Thhis is how most dividing heads on mills are used as an example as you can more or less ignore backlash as you leave the gearbox loaded and clamp before an operation.It doesn't mean it can't be done but you can't go in to it thinking you can electronically fix inherently bad mechanics.

author: Infraviolet
author_rank: Super Contributor
timestamp: March 31, 2023, 07:49:37 pm
content: Thanks, I guess it was a bit stupid of me to immediately turn to the "algorithms can fix it" philosophy.

author: Smokey
author_rank: Super Contributor
timestamp: April 06, 2023, 04:08:10 am
content: Quote from: Infraviolet on March 28, 2023, 08:32:46 pmThe answer to this part is don't use voltage control. Use current control. Get yourself a servo drive that has at a minimum a current loop and use that. If your application is more like constant velocity, then use a servo drive with velocity control. If you are going point to point, then get yourself a servo drive that has position control. I know it sounds forwards, but if you aren't interested in "highly abstracted academic papers" then proper control systems algorithms is probably not something you want to get too deep into. You can still use whatever processor you are using to send the servo drive current/velocity/position commands.For the backlash:If you are driving some long gear train that has a lot of slop and it actually matters that you have accurate position control at the end of that, then you have a few options:1) Redesign the system to not have all that play.2) Have position feedback in two places. 1=At the motor, 2=at the end of everything. Then get a servo drive that takes dual feedback and has provisions for compensation. Even with this, don't expect miracles. But it's your best bet.You didn't say what voltage/current levels we are talking about, but here is an example of a set of drives that will do all of the above. Yes, they are expensive new. But that's why they invented ebay.https://copleycontrols.com/en/products/