Datasheet

heat. If the measured temperature is above the setpoint, it turns it off. To prevent rapid cycling
which could damage the system, there is typically some gap between the 'on' threshold and the 'off'
threshold. This is called 'hysteresis'.
An On/Off controller with hysteresis s sometimes called a "Differential Gap Controller". That sounds
pretty sophisticated, but it is still a very primitive type of controller.
On/Off control works well for controlling the temperature of your house, but it is not very good for
applications like robot motion control.
PID Control
You have probably heard of PID controllers. PID stands for Proportional, Integral and Derivative
control. So a PID controller is actually 3 types of controller in one. Because of this, PID control is
fairly versatile. But not all applications require all three forms of control.
Many so-called PID controllers are actually just operated as PI, PD or even just P type controllers.
Motion Control applications like the Pixy Pet generally use mostly P or PD control.
Proportional Control
Proportional control allows for a much smoother response than simple on/off control. Proportional
control calculates an output value that is proportional to the magnitude of the error. Small errors
yeild a small response. Larger errors result in a more aggressive response.
Proportional control can be used alone, or augmented with Integral or Derivative control as needed.
The Pixy object following code uses only proportional control. The object tracking code uses both
proportional and derivative control.
Integral Control
Integral control integrates the error over time. If the measurement is not converging on the setpoint,
the integral output keeps increasing to drive the system toward the setpoint.
Integral control is good for nudging steady, predictable processes closer to perfection. Since Pixy
Pet needs to always respond quickly to random unpredictable movements, integral control is not
appropriate.
Derivative Control
Derivative control looks at the rate of change in the error. If the error is rapidly approaching zero,
the output of the derivative calculation attempts to slow things down to avoid overshooting the