Tuning Guide
Tuning Guide
Tuning Guide
Abstract:
I
n this document you will see how to setup your YAPSC (V1 or
10V versions) Servomotor Controller using YTT.
This documents covers rapid description of YTT and PID tuning
method using the step response tool of YTT.
You have to save the parameters in the board (by clicking “Write in board
EEPROM”) for the board to use the new value of the parameter.
2.2 Stability
First of all, you want your motor to go where you want him to go.
Here are, side by side, two things you want to avoid: divergence and oscillation
• from points 1-200, we have a nice example of divergence: the motor polarity is wrong,
so instead of bringing the motor back to the desired position, the control loop does the
exact opposite! To fix that, you can
◦ Turn off the board, swap the motor's ends
◦ or use negative P, I, D coefficients
• From points 201-400 we can see a nice oscillation of the motor: P and/or I and/or D are
set too high. Set I and D to 0 and decrease P until the loop stabilizes:
2.3 Overshoot
Remember Ill. 7? Well we had a stable loop that follows more or less the command.
It does also show something we want to avoid: overshoot.
Overshoot is when the motor's shaft goes over the command. Here is, on the right overshot
response curve and on the left a response curve with no overshoot:
Do not forget that the "Step Impulse Response" test makes the
motor move! In case of linear axis (example: X,Y and Z on a mill)
turn the motor manually to reach the middle of the axis under
testing before starting the test and setup the "Fault Error". Be
sure to choose a command step small enough to avoid the
carriage to crash on the ends of the slides.
First step for PID tuning is to set (roughly) the P parameter so we'll set I and D parameters to 0.
The general method for loop tuning is to change one parameter at a time, run the test, analyze
the response and start again until you cannot reduce the settling time anymore without loosing
stability.
3.2.1 P tuning
Augment progressively the P parameter until you get get no or little overshoot. A nice curve
would be between the "no overshoot" and "overshoot" example of Illustration 2.3: No-
overshoot and overshoot.
At this point, it is not a problem if there is little overshoot. The D parameter reduces efficiently
the overshoot.
3.2.2 I tuning
Most of time, P gain tuning alone cannot make the motor reach exactly the goal; there is a
static error. For example, you ask for a 50 steps move and the motor stops after 46 steps: the
static error is 4.
Augment I parameter until the static error reaches 0, but while keeping loop stability
3.2.3 D tuning
The D parameter should be used to erase eventual overshoot but don't set it too high as it will
reduce the response time.
3.2.4 Sum up
To Improve... Action on P Action on I Action on D
...Response time increase increase decrease
...Stability decrease decrease increase
...Precision Increase (decrease increase -
if not stable)
4 Troubleshooting
Here are the common problems you may face.