Thanks for the Info! I will give EK2_YAW_M_NOISE a try once the weather here is nice again. Even though I am not sure if it will solve my issues as it still relies on the compass as the single source of absolute heading.
Similarly I am not convinced the forward facing optical flow sensor will fix the issue as optical flow can only do relative but not absolut measurements.
I spend some more time looking into the GPS heading. It looks promising. I was able to run an auto mission without a compass but it required a few hacks.
- EKF2/3 seems to ignore the GPS heading. I think fusing the GPS heading is done when fusing the airspeed sensor. This makes sense for planes but doesn’t work for rovers as an airspeed sensor wouldn’t really work.
- DCM supports fusing GPS headings out of the box. I had to force using DCM with AHRS_EKF_TYPE=0. Otherwise ardupilot would switch to the incorrectly initialized EKF while reversing. This strange behavoir is triggered by clearing the fly_forward flag when reversing.
- I had to reduce the GPS_SPEED_MIN in the DCM code as my rover cannot reach 3 m/s.
- I had to disable some checks to allow enabling AUTO mode without a valid EKF.
- I had to disable a check for ahrs.home_is_set() in commands_logic.cpp, otherwise the rover would stop at the first waypoint.
@rmackay9, do you know if AUTO mode should work with DCM? Or if it’s intended to not work by design.