PIDFController

constructor(kp: Double, ki: Double, kd: Double, kf: Double)

The base constructor for the PIDF controller.

Parameters

kp

The value of kP for the coefficients.

ki

The value of kI for the coefficients.

kd

The value of kD for the coefficients.

kf

The value of kF for the coefficients.


constructor(kp: Double, ki: Double, kd: Double, kf: Double, sp: Double, pv: Double)

This is the full constructor for the PIDF controller. This controller also includes a feedforward value which is useful for fighting friction.

Parameters

kp

The value of kP for the coefficients.

ki

The value of kI for the coefficients.

kd

The value of kD for the coefficients.

kf

The value of kF for the coefficients.

sp

The setpoint of the pid control loop.

pv

The measured value of the pid control loop. We want sp = pv, or to the degree such that sp - pv, or e(t) is less than the tolerance.