Added a 3 value median filter to the motion controller.