AP_Vehicle: instantiate the AHRS object

This commit is contained in:
Peter Barker 2019-11-25 10:15:14 +11:00 committed by Peter Barker
parent d3ede184cf
commit ebd2b1d544
1 changed files with 9 additions and 0 deletions

View File

@ -136,6 +136,15 @@ protected:
// false disables external leds)
AP_Notify notify;
// Inertial Navigation EKF
#if AP_AHRS_NAVEKF_AVAILABLE
NavEKF2 EKF2{&ahrs, rangefinder};
NavEKF3 EKF3{&ahrs, rangefinder};
AP_AHRS_NavEKF ahrs{EKF2, EKF3};
#else
AP_AHRS_DCM ahrs;
#endif
private:
static AP_Vehicle *_singleton;