30 void addStep(
float threshold,
float kP,
float kI,
float kD,
47 std::vector<ScheduledGain> schedules;
A scheduler that interpolates and selects PID gains based on the current error.
void addStep(float threshold, float kP, float kI, float kD, float slew=0.0f)
Add a scheduling step.
void clear()
Clears the current schedules.
PIDGains getGains(float error) const
Compute the correct gains based on the current error distance.
Structure holding PID controller gains and parameters.
A mapping of error threshold to specific PID gains.
float threshold
The error bound for these gains.
PIDGains gains
The PID gains applied when error is below this threshold.