|
arduino-audio-tools
|
A simple header only PID Controller. More...
#include <PIDController.h>

Public Member Functions | |
| bool | begin (float dt, float max, float min, float kp, float ki, float kd) |
| float | calculate (float target, float measured) |
| void | reset () |
| void | setDt (float dt) |
Protected Attributes | |
| float | dt = 1.0f |
| float | integral = 0.0f |
| float | kd = 0.0f |
| float | ki = 0.0f |
| float | kp = 0.0f |
| float | max = 0.0f |
| float | min = 0.0f |
| float | preerror = 0.0f |
A simple header only PID Controller.
|
inline |
Clears the accumulated integral and derivative history without changing the configured dt/max/min/gains. Call this when the controlled process is reset/restarted so old error history doesn't leak into the new session.
|
inline |
Overrides the loop interval time used by the next calculate() call. Useful when the actual elapsed time between calls varies at runtime.
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |