mirror of
https://gitee.com/mirrors_PX4/PX4-Autopilot.git
synced 2026-10-22 11:33:33 +08:00
shouldUse321RotationSequence(const Dcmf& R)
This commit is contained in:
committed by
Paul Riseborough
parent
4872f2a545
commit
15afa8ae17
+1
-1
@@ -723,7 +723,7 @@ void Ekf::fuseHeading()
|
||||
_R_to_earth = Dcmf(_state.quat_nominal);
|
||||
|
||||
// determine if a 321 or 312 Euler sequence is best
|
||||
if (fabsf(_R_to_earth(2, 0)) < fabsf(_R_to_earth(2, 1))) {
|
||||
if (shouldUse321RotationSequence(_R_to_earth)) {
|
||||
// rolled more than pitched so use 321 rotation order to calculate the observed yaw angle
|
||||
Eulerf euler321(_state.quat_nominal);
|
||||
predicted_hdg = euler321(2);
|
||||
|
||||
Reference in New Issue
Block a user