Servo loop control (NOT stepper) Tachometer needed?

More
15 Feb 2019 16:55 #126568 by lrak
I understand PID (I have writen PID loops in assembler), but I'm trying to get a clear answer on Tachometer outputs.

The system I'm putting together has servo drives with tachometer outputs, and resolver outputs. It seems to me that I would get speed information from the resolver - no need for the old problomatic tachometer signals? But I'm being told to use these signals? I would think the LinuxCNC would be calculating velocity anyway?

--- Second - seperate question ---

I'm also thinking of puting in linear scales - perhaps not using the motor resolver signals - but the motors use a timing belt - I could see where this might want to oscilate.

Please Log in or Create an account to join the conversation.

More
16 Feb 2019 17:00 #126612 by pl7i92
Q A
You can find resolver mashine in the forum just search
second you can do a arduino resolver to encoder transaction if you like to

Q B

Best of all to mesure with liniarscale
They are Cheep and do scale pricise the position
The following user(s) said Thank You: lrak

Please Log in or Create an account to join the conversation.

More
16 Feb 2019 22:13 #126625 by rodw
LinuxCNC publishes the current velocity on the pin motion.current−vel

You could calculate the motor RPM by a mult2 and an appropriate scaling factor.
The following user(s) said Thank You: lrak

Please Log in or Create an account to join the conversation.

More
16 Feb 2019 23:34 #126629 by lrak
Thanks guys - I miss spoke - the motors actually have the encoder output (and tachometer outputs) - but I don't trust the condition of these encoders. ( For those following along - you give encoders 5V and ground and they return a differential A,B, and Z (quadrature and rotation zero)).

I am looking at some some Taishi and Sino-KAX00 scales - the documentation on these isn't great - and I'm seeing various claims of resolution on the same part numbers?

But - if I can use these or something close and close the servo loop in LinuxCNC without getting hunting - great - but I had a vendor telling me I need to use the tachometer outputs?

,.,
So here is the rub - in my mind the motor position vs the table position won't be the same thing - with timing belt drive - the belt stretches a bit - and the ball-screw will always have a bit of backlash - so If I have LinuxCNC close this servo-loop - tuning could be problematic - or not?
Most folks are using steppers [BTW most steppers are actually servos in drag - they have a built in controller to take a step input which is the target position to drive the servo to - the user isn't aware of the servo-loop going on under the hood- they think it is a stepper].

So the most common loop that LinuxCNC is controlling is one where it is looking at a table position via a linear scale and updating the stepper to the position it should go to. What I need to do is a bit different - and it is possible that I should provide both motor-encoder feedback and linear-scale feedback? Linux CNC would use the motor-encoder feed back to figure out the dynamic backlash and drive an H-bridge to control these motors? I don't know if LinuxCNC can do this - I just don't want to paint my self in a corner with the hardware I'm going to buy.

Could be I should get some modern steppers? But it seems these motors ought to work with LinuxCNC driving an H-bridge.

I've done searches here - some were doing an etch-a-sketch drive some years ago - I remember reading that LinuxCNC would do a true servo-loop (besides the easier and common stepper-loop) - but I'm having trouble finding what I need to know to get started - a lot of the threads I find on servo-loops are actually using steppers.

Please Log in or Create an account to join the conversation.

More
More
25 Feb 2019 22:45 #127127 by andypugh
LinuxCNC does not need the tachometers. But it is very likely that the existing servo drives do. If you have velocity-mode servos then leave the tachos connected to them, but don't bother trying to connect them to LinuxCNC.

Do the drives accept +/- 10V control signals? If so then you will need some extra interface hardware. What do you currently have?

Please Log in or Create an account to join the conversation.

More
25 Feb 2019 22:48 #127128 by andypugh

T
I've done searches here - some were doing an etch-a-sketch drive some years ago - I remember reading that LinuxCNC would do a true servo-loop (besides the easier and common stepper-loop) - but I'm having trouble finding what I need to know to get started - a lot of the threads I find on servo-loops are actually using steppers.


This might be the Etch-a-Sketch emergent.unpythonic.net/projects/01142347802 but that is pretty old now, and was using the parallel port + custom hardware. probably not the best way to go now. (Mesa 5i25 + 7i77, Pico PPMC or General Mechatronics are likely to be the way to go)

Please Log in or Create an account to join the conversation.

More
26 Feb 2019 04:09 #127140 by lrak
@Andypugh
What I have are NOT servo drives - but DC brushed motors (with tachometer outputs that I probably won't use) that I will drive with an H-bridge - using LinuxCNC to create the servo-loop - looking at either a motor-shaft-rotary-encoder output and/or linear scales for the input of the loop.

The problem I'm having are so many of the threads use the terms "servo" "stepper" "DC drive" without understanding the difference.

What we want to do is know where the table is - where we want it to go - and then drive the motor to get us there with out overshooting or error. If someone (not me) is using steppers - they give it step pulses to control the movement (The stepper motor has its own electronics to do this). A servo drive would have an internal H-bridge - typically PWM(pulse width modulated), but some would get just an analog voltage. What I have is the raw DC drive - and will provide a H-bridge to drive it. LinuxCNC keeps track of where the table is, where it should be, how fast it should move - and via a PID-loop LinuxCNC can provide a PWM output to the H-bridge.

The question is about the backlash between the motor and the table - which can cause the control loop to oscillate - I'm trying to see if people are able to use linear scales as the position input of a true servo-loop with good results(DC motors driving a ballscrew via timing belts)? Or if I should use rotary encoders on the motor shaft which would have no backlash (from the point of view of LinuxCNC) but would have backlash error.

It is possible to create nested PID loops - where you have two feedbacks - both the Rotary-encoders and Linear-encoders - but I don't know that anyone has done that with LinuxCNC?

This would be equivalent to having steppers (which are mostly are not true steppers but servos - with and internal PID loop) that know where the motor shaft is and a linear table encoder that knows where the table is.

Please Log in or Create an account to join the conversation.

More
26 Feb 2019 09:17 #127146 by andypugh

@Andypugh
What I have are NOT servo drives - but DC brushed motors (with tachometer outputs that I probably won't use) that I will drive with an H-bridge


OK, I was assuming that this was a retrofit project and that you probably had both the original motors and the drives (or power amps as they are sometimes known).

Velocity mode servo drives for DC motors simply take a command input, subtract the tachometer output and send the (amplified) difference to the servo motor. This was a very simple and effective approach in the days of analogue electronics, and such systems still work just as well as they ever did.

There is probably no point taking the tachometer output to LinuxCNC, but there might be an argument for using some drives of that type. The velocity feedback loop (in the analogue realm) of such systems is rather effective. Then the LinuxCNC PID loop is a velocity-to-position one.

It is perfectly possible to run a torque-to-position loop in LinuxCNC (and, in fact, both my mill and lathe run that way, though they both use resolvers and brushless motors rather than your encoder and brushed motor system)

One possible way to control your system would be with a LinuxCNC PID loop using the encoders to provide a torque-to-velocity loop and then driving that with a second PID with linear scale feedback as a velocity-to-position loop.

I keep intending to try that with my machines, but they are working OK with a single layer (current-to-position, in fact)

Do you intend to build your own servo drives? If not, which drives do you have in mind? LinuxCNC has a number of ways to control a drive, including software PWM out of the parallel port (cheap, but probably not the best approach), PWM from dedicated hardware, analogue voltage control or digital serial commands. There is one brushless servo drive out there that takes a floating-point speed and position command from LinuxCNC using the Mesa smart-serial protocol, but I only mention that as an example as it won't drive your DC motors)

One reason that a lot of people use a step-dir input servo drive (true servo, not stepper motor) is that it needs minimal interface electronics between the digital control PC and the servo drive. The drawback with this approach is that typically that means that all the tuning has to be done in the drive, and often with proprietary Windows-only software. Running all the PID loops in LinuxCNC does at least mean that you can see what is going on. It also has the significant advantage that you can use Feed-forward. LinuxCNC knows the required velocity, whereas a step/dir input servo drive has to infer it from the step frequency which introduces a delay.

Please Log in or Create an account to join the conversation.

More
27 Feb 2019 05:02 #127222 by lrak
I own the old motors ( Google MT30M4 for details ) - the control system is 1980 and failed. (There was a problem doing tachometer with brushes - noise and crashes due to worn-out brushes ) .

I was imagining that one could possibly monitor the backlash and tweak the loop.

One possible way to control your system would be with a LinuxCNC PID loop using the encoders to provide a torque-to-velocity loop and then driving that with a second PID with linear scale feedback as a velocity-to-position loop.


Interesting idea -

Reading between the lines - it sounds like you have a system running with Linear scale feedback? Sounds like it is working? Are there drive belts?

OT - your name is ringing a bell - were you on the mailing list - say 10 years ago? Or did you work with digital video? Or burned EPROMs? Debian? Kicad?

I do intend to make these Brushed DC drives a servo with the addition of an H-bridge - MESA has an 7I29 but is sort of pricey for what it is .. I used to design switching power-supplies when I was young - might try to roll my own.

LinuxCNC knows the required velocity, whereas a step/dir input servo drive has to infer it from the step frequency which introduces a delay.


IMO most step/dir input drives have an internal loop that belongs in LinuxCNC ..

Sounds like MESA probably has the fastest I/O using FPGAs - I'm wondering which bus is fastest? Probably not a problem today - but like Vo/IP (but unlike video) latency matters in motion control.

Right now, I'm replacing bearings - hoping to finish my electronics shopping list - trying to avoid wrong turns.

Please Log in or Create an account to join the conversation.

Time to create page: 0.078 seconds
Powered by Kunena Forum