Quaternion correction in EKF2

Hello everyone,

I have been diving into the inner workings of PX4, specifically the Extended Kalman Filter (EKF2), and I’m trying to understand the reasoning behind certain design choices regarding quaternion correction and observation models.

From my understanding, the quaternion correction in EKF2 seems to be a fundamental part of the orientation estimation process, but I’m curious about a few aspects related to it:

  1. Quaternion Correction and EKF2: The quaternion correction in EKF2 appears to be well integrated for handling orientation, which is crucial for accurate state estimation. However, it seems that there is a more complex handling of observations beyond just correcting for orientation. Given that orientation estimation via quaternion correction is already non-trivial, when the observation models themselves appear relatively simple?

  2. Usage of Multiple Observations in EKF2: In the context of state estimation, how exactly are these body velocity and other observations incorporated into the filter? I understand that these observations help to refine the system’s state estimates, but how does the EKF leverage the multiple measurements in a way that improves its overall performance?

I’ve gone through the available documentation and slides, but I feel that certain implementation details aren’t fully covered. Any tips or guidance on this, especially with regard to how observations are processed in the EKF2 implementation and the rationale behind using multiple observations for specific state variables, would be greatly appreciated!

Thanks in advance for your insights!