mirror of
https://github.com/ArduPilot/ardupilot
synced 2025-01-10 09:58:28 -04:00
AP_AHRS: use compass get_{field,offsets}() functions
Both functions are equivalent, so we're going to simply use get_{field,offsets}() instead of get_{field,offsets}_milligauss().
This commit is contained in:
parent
4375606eeb
commit
84f811fe76
@ -276,7 +276,7 @@ AP_AHRS_DCM::normalize(void)
|
|||||||
float
|
float
|
||||||
AP_AHRS_DCM::yaw_error_compass(void)
|
AP_AHRS_DCM::yaw_error_compass(void)
|
||||||
{
|
{
|
||||||
const Vector3f &mag = _compass->get_field_milligauss();
|
const Vector3f &mag = _compass->get_field();
|
||||||
// get the mag vector in the earth frame
|
// get the mag vector in the earth frame
|
||||||
Vector2f rb = _dcm_matrix.mulXY(mag);
|
Vector2f rb = _dcm_matrix.mulXY(mag);
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user