paparazzi/paparazzi — pull request #807 by EwoudSmeur (2014-08-18 10:00:28+00:00)
Title: ground detect fix and attitude quat int integrator changed

This should fix two things: the integrator could previously wrap around because it was an actual quaternion. Upon an error it would first go up to ~32000 and then if the error persisted go down again. This is obviously unwanted. I changed to a regular sum of each of the error values.

For the ground detection, the autopilot_ground_detected was reset before the nav would run and trigger the ground detect exception, since the nav stuff runs on a lower frequency. Autopilot_ground_detected should be reset in the nav function anyway.