Servo Tuning Advice
01 Nov 2012 00:51 - 01 Nov 2012 01:00 #26154
by PCW
Replied by PCW on topic Servo Tuning Advice
No, pid.n.error is simply the difference between the command and the feedback PID inputs. There is no excuse for it being different from ferror
I am thinking more and more this looks like a pipelining error
(the PID feedback and command do no match the ferror calculations feedback and command but should) In fact it very much looks like one uses stale or early data
(since with almost 0 PID error in the last plot, the ferror seems to track velocity which is just what you would expect if one of the positions was stale/early)
I didn't think HAL net statements were assignments but that could cause this problem
with the possible solution of making sure all the motion statements were in one line net commands
I am thinking more and more this looks like a pipelining error
(the PID feedback and command do no match the ferror calculations feedback and command but should) In fact it very much looks like one uses stale or early data
(since with almost 0 PID error in the last plot, the ferror seems to track velocity which is just what you would expect if one of the positions was stale/early)
I didn't think HAL net statements were assignments but that could cause this problem
with the possible solution of making sure all the motion statements were in one line net commands
Last edit: 01 Nov 2012 01:00 by PCW.
Please Log in or Create an account to join the conversation.
- Todd Zuercher
-
Topic Author
- Away
- Platinum Member
-
Less
More
- Posts: 5000
- Thank you received: 1409
01 Nov 2012 02:53 #26158
by Todd Zuercher
Replied by Todd Zuercher on topic Servo Tuning Advice
Well I just tried and putting all the net z-pos-fb and net z-vel-fb statements in the same line did not seem to make a difference.
Please Log in or Create an account to join the conversation.
01 Nov 2012 03:08 #26160
by PCW
Replied by PCW on topic Servo Tuning Advice
did you do the same for the z-pos-cmd?
you should verify that z-pos-cmd and z-pos-fb only appear on one line each the hal file
you should verify that z-pos-cmd and z-pos-fb only appear on one line each the hal file
Please Log in or Create an account to join the conversation.
- Todd Zuercher
-
Topic Author
- Away
- Platinum Member
-
Less
More
- Posts: 5000
- Thank you received: 1409
01 Nov 2012 03:39 #26162
by Todd Zuercher
Replied by Todd Zuercher on topic Servo Tuning Advice
No I had not consolidated that one. I tried it just now and confirmed that the others only occured once. But still no change.
Please Log in or Create an account to join the conversation.
01 Nov 2012 04:01 #26163
by PCW
Replied by PCW on topic Servo Tuning Advice
Well looks like a LinuxCNC bug...
Please Log in or Create an account to join the conversation.
01 Nov 2012 04:57 #26165
by PCW
Replied by PCW on topic Servo Tuning Advice
What is the slew velocity of the move in the last plot?
Please Log in or Create an account to join the conversation.
- Todd Zuercher
-
Topic Author
- Away
- Platinum Member
-
Less
More
- Posts: 5000
- Thank you received: 1409
01 Nov 2012 07:35 #26166
by Todd Zuercher
Replied by Todd Zuercher on topic Servo Tuning Advice
The velocity is about 100 inches per minute
Please Log in or Create an account to join the conversation.
01 Nov 2012 09:45 #26169
by PCW
Replied by PCW on topic Servo Tuning Advice
Which is a fair match to the error in ferror (1.666 IPS*.0004 seconds = .000666 inches)
looking at the code in motion, it appears that ferror is calculated in the wrong place
(before the TP rather than after the TP)
and therefore not an accurate representation of the actual error (PID error)
A temporary workaround would be to tune for minimum PID error and ignore ferror
possibly having to set wider ferror limits that you would like
looking at the code in motion, it appears that ferror is calculated in the wrong place
(before the TP rather than after the TP)
and therefore not an accurate representation of the actual error (PID error)
A temporary workaround would be to tune for minimum PID error and ignore ferror
possibly having to set wider ferror limits that you would like
The following user(s) said Thank You: Todd Zuercher
Please Log in or Create an account to join the conversation.
- Todd Zuercher
-
Topic Author
- Away
- Platinum Member
-
Less
More
- Posts: 5000
- Thank you received: 1409
01 Nov 2012 10:46 #26171
by Todd Zuercher
Replied by Todd Zuercher on topic Servo Tuning Advice
Sounds like a very deeply embedded bug. Why don't others run into it?
Please Log in or Create an account to join the conversation.
01 Nov 2012 12:10 #26173
by PCW
Replied by PCW on topic Servo Tuning Advice
I suspect because most servo systems use velocity mode
which is easily tunable to make a small ferror via FF1
(but make the true error = PID error larger)
unless you look at both PID error and ferror, you would probably never notice
also for normal metal working machine speeds the error is pretty small and consistent, no more than a fraction of a mill at common cutting speeds
which is easily tunable to make a small ferror via FF1
(but make the true error = PID error larger)
unless you look at both PID error and ferror, you would probably never notice
also for normal metal working machine speeds the error is pretty small and consistent, no more than a fraction of a mill at common cutting speeds
Please Log in or Create an account to join the conversation.
Time to create page: 0.130 seconds