iCub-main
|
General structure of parallel (non-interactive) PID. More...
#include <pids.h>
Public Member Functions | |
parallelPID (const double _Ts, const yarp::sig::Vector &_Kp, const yarp::sig::Vector &_Ki, const yarp::sig::Vector &_Kd, const yarp::sig::Vector &_Wp, const yarp::sig::Vector &_Wi, const yarp::sig::Vector &_Wd, const yarp::sig::Vector &_N, const yarp::sig::Vector &_Tt, const yarp::sig::Matrix &_satLim) | |
Constructor. | |
virtual const yarp::sig::Vector & | compute (const yarp::sig::Vector &ref, const yarp::sig::Vector &fb) |
Computes the PID output. | |
virtual void | reset (const yarp::sig::Vector &u0) |
Resets the internal state of integral and derivative part. | |
virtual void | getOptions (yarp::os::Bottle &options) |
Returns the current options used by the pid. | |
virtual void | setOptions (const yarp::os::Bottle &options) |
Update the options used by the pid. | |
~parallelPID () | |
Destructor. | |
Protected Attributes | |
yarp::sig::Vector | Kp |
yarp::sig::Vector | Ki |
yarp::sig::Vector | Kd |
yarp::sig::Vector | Wp |
yarp::sig::Vector | Wi |
yarp::sig::Vector | Wd |
yarp::sig::Vector | N |
yarp::sig::Vector | Tt |
yarp::sig::Matrix | satLim |
yarp::sig::Vector | P |
yarp::sig::Vector | I |
yarp::sig::Vector | D |
yarp::sig::Vector | u |
yarp::sig::Vector | uSat |
unsigned int | dim |
double | Ts |
Integrator * | Int |
std::deque< Filter * > | Der |
Additional Inherited Members | |
Static Public Member Functions inherited from iCub::ctrl::helperPID | |
static void | addVectorToOption (yarp::os::Bottle &option, const char *key, const yarp::sig::Vector &val) |
Add the data contained in the specified vector to the specified bottle, using property-like form (i.e. | |
static bool | getVectorFromOption (const yarp::os::Bottle &options, const char *key, yarp::sig::Vector &val, int &size) |
Fill the specified vector with the data associated with the specified key in the specified property-like bottle. | |
General structure of parallel (non-interactive) PID.
u = sat(P + I + D)
Components expressed in Laplace transform:
iCub::ctrl::parallelPID::parallelPID | ( | const double | _Ts, |
const yarp::sig::Vector & | _Kp, | ||
const yarp::sig::Vector & | _Ki, | ||
const yarp::sig::Vector & | _Kd, | ||
const yarp::sig::Vector & | _Wp, | ||
const yarp::sig::Vector & | _Wi, | ||
const yarp::sig::Vector & | _Wd, | ||
const yarp::sig::Vector & | _N, | ||
const yarp::sig::Vector & | _Tt, | ||
const yarp::sig::Matrix & | _satLim | ||
) |
Constructor.
_Ts | is the block sample time in seconds. |
_Kp | are the proportional gains. |
_Ki | are the integral gains. |
_Kd | are the derivative gains. |
_Wp | are the setpoint weigths for proportional part. |
_Wi | are the setpoint weigths for integral part. |
_Wd | are the setpoint weigths for derivative part. |
_N | are derivative low-pass filter bandwidth (3 to 20, typ. 10, must be > 0). |
_Tt | are anti-windup reset time (0.1 to 1 times the value of Ti=Kp/Ki, greater than Td). |
_satLim | is the saturation thresholds matrix (min_i=satLim(i,0), max_i=satLim(i,1)). |
|
virtual |
|
virtual |
Returns the current options used by the pid.
options | is a property-like bottle containing the current configuration used by the pid. |
|
virtual |
|
virtual |
Update the options used by the pid.
options | is a property-like bottle containing the new configuration used by the pid. |
|
protected |