mirror of
https://gitee.com/mirrors_PX4/PX4-Autopilot.git
synced 2026-10-22 16:03:34 +08:00
ekf2: Add new mag fusion mode
Adds a mode where mag fusion is only used update the field estimates
This commit is contained in:
+1
-1
@@ -1105,7 +1105,7 @@ void Ekf::controlMagFusion()
|
||||
// do no magnetometer fusion at all
|
||||
_control_status.flags.mag_hdg = false;
|
||||
_control_status.flags.mag_3D = false;
|
||||
} else if (_params.mag_fusion_type == MAG_FUSE_TYPE_AUTO) {
|
||||
} else if (_params.mag_fusion_type == MAG_FUSE_TYPE_AUTO || _params.mag_fusion_type == MAG_FUSE_TYPE_AUTOFW) {
|
||||
// Check if height has increased sufficiently to be away from ground magnetic anomalies
|
||||
bool height_achieved = (_last_on_ground_posD - _state.pos(2)) > 1.5f;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user