mirror of
https://gitee.com/mirrors_PX4/PX4-Autopilot.git
synced 2026-10-25 04:43:34 +08:00
EKF: use GPS to lookup declination from WMM before full GPS checks pass
This commit is contained in:
committed by
Mathieu Bresciani
parent
6b99ea2a60
commit
4c2355a638
+1
-1
@@ -524,7 +524,7 @@ float Ekf::getMagDeclination()
|
||||
|
||||
} else if (_params.mag_declination_source & MASK_USE_GEO_DECL) {
|
||||
// use parameter value until GPS is available, then use value returned by geo library
|
||||
if (_NED_origin_initialised) {
|
||||
if (_NED_origin_initialised || ISFINITE(_mag_declination_gps)) {
|
||||
return _mag_declination_gps;
|
||||
|
||||
} else {
|
||||
|
||||
Reference in New Issue
Block a user