11 template <
typename SCALAR>
13 : statePrevious_(
SCALAR(0.0)), I_(
SCALAR(0.0)), parameters_(parameters), setpoint_(setpoint)
17 template <
typename SCALAR>
23 template <
typename SCALAR>
28 template <
typename SCALAR>
34 template <
typename SCALAR>
40 template <
typename SCALAR>
46 template <
typename SCALAR>
53 template <
typename SCALAR>
80 template <
typename SCALAR>
108 template <
typename SCALAR>
117 template <
typename SCALAR>
123 template <
typename SCALAR>
129 template <
typename SCALAR>
136 template <
typename SCALAR>
setpoint_t setpoint_
the parameters of the PID controller
Definition: PIDController.h:150
parameters_t & Parameters()
returns a reference to the parameters
Definition: PIDController-impl.h:124
ct::core::ControlVector< control_dim > u
parameters_t parameters_
the current I part (integrated)
Definition: PIDController.h:149
SCALAR dt
differential gain
Definition: PIDController.h:53
void reset()
resets the controller
Definition: PIDController-impl.h:130
SCALAR k_d
integral gain
Definition: PIDController.h:52
PIDController * clone() const
clone operator
Definition: PIDController-impl.h:29
CppAD::AD< CppAD::cg::CG< double > > SCALAR
virtual ~PIDController()
destructor
Definition: PIDController-impl.h:24
void setInitialState(const SCALAR &state)
set the initial state
Definition: PIDController-impl.h:35
SCALAR computeControl(const SCALAR &state, const Time &t)
computes the control input based on the current state and time
Definition: PIDController-impl.h:54
SCALAR uMax
anti-windup I-part saturation
Definition: PIDController.h:55
SCALAR stateDesired_
Definition: PIDController.h:70
void setDesiredState(const SCALAR &state)
set the state
Definition: PIDController-impl.h:41
SCALAR stateDerivativeDesired_
desired state
Definition: PIDController.h:71
A standard PIDController.
Definition: PIDController.h:31
SCALAR k_p
Definition: PIDController.h:50
setpoint for the PID controller
Definition: PIDController.h:63
PIDController(const parameters_t ¶meters=parameters_t(), const setpoint_t &setpoint=setpoint_t())
default constructor
Definition: PIDController-impl.h:12
SCALAR k_i
proportional gain
Definition: PIDController.h:51
SCALAR uMin
max u output
Definition: PIDController.h:56
SCALAR Imax
timestep for I-part
Definition: PIDController.h:54
SCALAR statePrevious_
Definition: PIDController.h:146
Parameters of a PID Controller.
Definition: PIDController.h:38
void changeParameters(const parameters_t ¶meters)
change the control parameters
Definition: PIDController-impl.h:118
SCALAR I_
the previous state used for finite differences
Definition: PIDController.h:147
double Time
Definition: Time.h:11