another CL stepper + glass scale topic

More
07 Apr 2021 09:55 - 08 Apr 2021 06:45 #205241 by mydani
Hi guys,

not wanted to mess up Hakkans thread (thanks mate), so I started this one.
Sorry for writing a booklet-size post #1, but I have to note it down somewhere...

I am currently (again) retrofitting an EMCOTURN, this time with - you guessed it - CL steppers and glas scales.

So far it progresses well, however during tuning, I found some borders for my tuning capabilities.
For this I attached some scope pictures as well.

What I did:
  • Pictures 1-3: I measured the "real" ferror using the glas scales while not using the linuxcnc PID (standard settings from pncconf, P:1000 FF1:1) with glass scale feedback at different speeds. Beware, it's a bit awkward since the final position is also not 100% correct, and it counts into the ferror graph as well:
    SpeedFerror
    50000.17
    10000.07
    2000.02?
    Steppers sound smooth (as smooth as steppers can).
  • Pictures 4-6: Then I connected the glass scales position to the PID feedback and started tuning like you normally do with servos. FF1:1, PID up to where it reduces the follow error sufficiently but does not cause stability/vibration issues, also added very little FF2 and even smaller I term (which is not really that necessary after all).
    SpeedFerror
    5000+/-0.017
    1000+/-0.007
    200+/-0.007
    Good enough you might say, and I'd agree. However...
  • What happens is - only at fast speeds - every now and then (2 out of 10 moves) the movement sounds really "vibraty" and you can see the same in picture 7. I tried to narrow down what the issue is.
    • Without the glass scales/PID loop, this does not happen at all. So the PID causes this. And it eliminates the CL between motor and driver as root cause. It works reliably with 5m/min.
    • If I increase speeds even more, e.g. to 7m/min, even the closed loop btw. driver and motor struggles and it causes the same vibration. I conclude we run out of stepper motor torque at high rpm to do the necessary corrections sufficiently fast and this causes the vibration.
    • So back at 5m/min with the PID and glass scale loop, if I reduce the P value, the problem is also gone. happen. then it really also takes away precision at low speeds significantly, so it's not an option.
    • Reducing the stepper acceleration (750 => 400mm/s²), it also fixes the vibration issue, however it makes it - again also at slow speeds - little less exciting. So my conclusion seems more valid, running out of torque at high rpm. Seems the PID with glass scales demands little more torque/acceleration at 5m/min than only the loop btw. driver and motor.
    • Reducing the max. speed will of course fix this as well.

So now I am stuck with 3 options to get rid of the vibrations, and I dislike all of them. Reducing P is a no go because it renders the whole exercise of gaining more precision pretty much useless. Reducing speed also bugs me since w/o the PID loop it works reliably.
Which leaves me to reduce acceleration...

Now the question to you experts - what options do you see?
Is there a possibility to reduce acceleration only at higher speeds (motor rpms)?
Is is maybe better to leave everything to the controller and just add a second PID around to add an I term for position correctness?

Looking forward to some suggestions.

Regards,
Daniel
Last edit: 08 Apr 2021 06:45 by mydani.

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

More
07 Apr 2021 23:09 #205290 by andypugh
Try reducing P and increasing I to compensate.

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

More
08 Apr 2021 01:13 #205302 by PCW
You could also reduce P at higher speeds, perhaps using the lincurve
component to map velocity into appropriate P values

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

More
08 Apr 2021 03:18 - 08 Apr 2021 06:22 #205305 by Hakan
That's what I do, reduce pid parameters the faster the axis goes.
setp lincurve.Px.x-val-00           5
setp lincurve.Px.y-val-00  [JOINT_0]P
setp lincurve.Px.x-val-01          30
setp lincurve.Px.y-val-01          20

Input to the lincurve.in is the absolute value of the net x-vel-cmd
Last edit: 08 Apr 2021 06:22 by Hakan. Reason: was too short so added things

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

Time to create page: 0.068 seconds
Powered by Kunena Forum