Implementation of a PID controller.