mirror of
https://github.com/ArduPilot/ardupilot
synced 2025-01-13 03:18:29 -04:00
AP_AHRS: Set the new gps_fusion notify flag
Uses EKF filter state to set the new gps_fusion notify flag. This allows the GCS and notify devices to specifically be notified if the GPS is or is not usable.
This commit is contained in:
parent
22d0f41b1b
commit
61931fd326
@ -192,6 +192,9 @@ void AP_AHRS_NavEKF::update_EKF2(void)
|
||||
}
|
||||
}
|
||||
_accel_ef_ekf_blended = _accel_ef_ekf[primary_imu>=0?primary_imu:_ins.get_primary_accel()];
|
||||
nav_filter_status filt_state;
|
||||
EKF2.getFilterStatus(-1,filt_state);
|
||||
AP_Notify::flags.gps_fusion = filt_state.flags.using_gps; // Drives AP_Notify flag for usable GPS.
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -260,6 +263,9 @@ void AP_AHRS_NavEKF::update_EKF3(void)
|
||||
}
|
||||
}
|
||||
_accel_ef_ekf_blended = _accel_ef_ekf[_ins.get_primary_accel()];
|
||||
nav_filter_status filt_state;
|
||||
EKF3.getFilterStatus(-1,filt_state);
|
||||
AP_Notify::flags.gps_fusion = filt_state.flags.using_gps; // Drives AP_Notify flag for usable GPS.
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user