[Home]PiD

LinuxCNCKnowledgeBase | RecentChanges | PageIndex | Preferences | LinuxCNC.org

This page just collects some random info on PID for the moment.

Consider a closed-loop spindle controller driving a VFD, where voltage in = speed out.

P-gain alone won't work. As soon as the spindle is at speed, then the P-output is zero, and the VFD demand is zero. So, you need a high gain, and are always just enough below the setpoint to give the necessary voltage output. (if it is 10V = 1000rpm and you want 500rpm, then with a P-gain of 1 you will have the output of 5V when the actual speed is 999.5 rpm, but that is likely to be too high a gain to be stable. Generally in closed-loop spindle control you end up using the I-term to provide a constant value for the P-term to modify.

FF0 would let you pre-program the speed/voltage factor in, then the P, I and D terms be small modifiers to that, so the gains can be lower, and the loop stability higher.

When I talk of the mathematical "order" I mean in the sense of time derivatives.

The closed-loop spindle is velocity-result & velocity command. A motor/tach machine is position-result and velocity command. A torque-mode servo machine is position-result and acceleration command (neglecting friction) a stepper system is position-result and position command.

So, FF0 would be useful in velocity-velocity or position-position systems, FF1 in position-velocity, and FF2 in position-acceleration systems.

From Peter on forum http://www.linuxcnc.org/index.php/english/forum/39-pncconf/26860-tuning-values

The FF are feed forward values:

FF0 adds a portion of the command to the output
FF1 adds a portion the first derivative of the command to the output
FF2 adds a portion of the second derivative of the command to the output

I tend to think of feed forward terms being used to center the operating
point of the PID loop.

For example, if linuxcnc is controlling a velocity mode servo, almost
all tuning (on linuxCNC) will be done with FF1 and P (FF1 is velocity feed
forward if the PID command is position)

With a velocity mode servo the PID output is a
velocity command to the drive. This means the PID
output will be near full-scale when doing rapids.
If only P was used, there would have to be enough
position error to generate a near full scale signal when
moving at full speed. Practically what this means is that
the actual position will lag the commanded position
by an amount proportional to the full scale PID output / Pgain,
which is quite significant. FF1 is used here to "forward"
the commanded velocity to the PID output so that the
PID output will be set to the required value for the current
commanded velocity _before_ any P correction is applied,
centering the PIDs operating point around the current velocity

Another example is controlling a torque mode drive. In this case, FF2
(acceleration feed forward if the command is position) is used to
compensate for the system inertia.

No controlled system is a perfect velocity or torque mode device so often
a bit of FF2 can be used to tune velocity mode drives error during acceleration,
and a bit of FF1 can compensate for velocity dependent drag on a a torque mode system


LinuxCNCKnowledgeBase | RecentChanges | PageIndex | Preferences | LinuxCNC.org
This page is read-only. Follow the BasicSteps to edit pages. | View other revisions
Last edited August 11, 2013 8:40 pm by Cmorley (diff)
Search:
Published under a Creative Commons License