DPRG List  

[DPRG] PID Loop Question

Subject: [DPRG] PID Loop Question
From: Stuart Stegall keltor at keltor.org
Date: Mon Feb 22 15:48:41 CST 2010

On Mon, Feb 22, 2010 at 2:16 PM, Ed Paradis <legomaniac at gmail.com> wrote:

> To take the filter idea a bit further, here is Yet Another Explanation:
> Your input signal is the error, which is a positive or negative value
> measuring the difference between where you want to be and where you
> are.
> The P term is just "Gain".  You multiply the error by a constant.
> The I term is like a Low Pass Filter.  It will tend pass correction
> that values that are long term and "slow" or "low in frequency".
> The D term is like a High Pass Filter.  It will cause corrections
> based on quick changes, short term, "fast" or "high in frequency".
> You add all the three correction terms together, some will be positive
> and some will be negative.  You'll end up with a single number that is
> your correction factor.
> Don't try to take this analogy too far, it sort of breaks down.  But
> its a quick way to figure out how to change the P I and D constants to
> get a desired effect.
> Is your robot not making much correction?  Does it need more OOMPH to
> get it to correct its error?  Increase the P. Increase the Gain.
> Is your robot slowly drifting off course? Does the error keep getting
> bigger and bigger?  It needs more "slow correction."  Increase the I
> term.
> Is your robot correcting OK, but it takes too long?  Increase the D
> term.  Increase the high frequency response.
> The easy method I use to tune a PID follows these guidelines:
> 1. Start out with all your constants at a minimum.  For some setups,
> this is 0.  For mine, it is 1.0.
> 2.  Increase just the P term until you start to see over correction.
> It will be right when the robot starts to oscillate back and forth
> after reaching the desired point.  It will have just a bit of an over
> shoot.
> 3.  Increase the I term decrease the oscillation to you get no
> overshoot or maybe one "swing", if that is OK for your application.
> 4.  At this point, it'll probably be too slow reaching the desired
> goal.  Increase D until the robot reaches its point quickly but does
> not oscillate.
> You can go back and fiddle and tweak, but I've found you're pretty
> close with the above procedure.  Wikipedia has a nice chart of what
> everything does:
> http://en.wikipedia.org/wiki/PID_tuning#Manual_tuning
> And like it was mentioned, you can usually get away with the D term
> being disabled.  You probably don't want to have just a PD controller,
> as these have always been too prone to oscillation (constant
> correction back and forth forever).
> Ed
> >> Quinones, Jose wrote:
> >>> I am trying to get a better understanding of the PID Loop.
> _______________________________________________
> DPRGlist mailing list
> DPRGlist at dprg.org
> http://list.dprg.org/mailman/listinfo/dprglist

Here's also a very nice one: http://www.embedded.com/2000/0010/0010feat3.htm
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://list.dprg.org/pipermail/dprglist/attachments/20100222/6716c98b/attachment.html

More information about the DPRG mailing list