This repository has been archived by the owner on May 1, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 510
EKF: fix covariance and output filter buffer initialization #586
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Signed-off-by: CarlOlsson <carlolsson.co@gmail.com>
Signed-off-by: CarlOlsson <carlolsson.co@gmail.com>
in alignOutputFilter() Signed-off-by: CarlOlsson <carlolsson.co@gmail.com>
alignOutputFilter() Signed-off-by: CarlOlsson <carlolsson.co@gmail.com>
Signed-off-by: CarlOlsson <carlolsson.co@gmail.com>
1) init tilt 2) init yaw 3) init tilt uncertainty 4) init yaw uncertainty Signed-off-by: CarlOlsson <carlolsson.co@gmail.com>
This was referenced Mar 8, 2019
…. Is is now done in alignOutputFilter()
priseborough
approved these changes
Mar 11, 2019
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Good work.
RomanBapst
approved these changes
Mar 12, 2019
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@CarlOlsson Nice!
dagar
pushed a commit
to priseborough/PX4-Autopilot
that referenced
this pull request
Mar 13, 2019
Bug Fixes: PX4/PX4-ECL#586 - EKF: fix covariance and output filter buffer initialization PX4/PX4-ECL#590 - EKF: Fix innovation in fuseDeclination() Enhancements: PX4/PX4-ECL#543 - ekf_helper: add more useful methods to interface with the covariances PX4/PX4-ECL#588 - Add unit tests for DataValidator Note: PX4/PX4-ECL#543 has required a change to how the state variances are accessed .
priseborough
added a commit
to PX4/PX4-Autopilot
that referenced
this pull request
Mar 14, 2019
Bug Fixes: PX4/PX4-ECL#586 - EKF: fix covariance and output filter buffer initialization PX4/PX4-ECL#590 - EKF: Fix innovation in fuseDeclination() Enhancements: PX4/PX4-ECL#543 - ekf_helper: add more useful methods to interface with the covariances PX4/PX4-ECL#588 - Add unit tests for DataValidator Note: PX4/PX4-ECL#543 has required a change to how the state variances are accessed .
Closed
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This PR fixes several issues that were present in the initialization of the attitude covariances and the output filter buffer.
_output_new
quaternion was not initialized to a valid quaternionThis PR changes the EKF initialization to:
This have quite large consequences. Below is a logfile with high temperature gradient replayed with master code and this PR.
On master the delta velocity bias states diverge before takeoff triggering a reset of the covariance matrix while on the PR they are stable
master/PR
This is because on the PR the uncertainty in the delta velocity bias aligned with gravity decrease much faster since this axis is more observable than the axes aligned with the horizontal plane.
master/PR
Note that this plot is from a tailsitter with body x axis facing upwards
This is a plot comparing the attitude estimate at the current time and at the delayed time horizon right after the EKF initialization. (This is normally not logged since the ekf2_main.cpp only logs the attitude estimate when tilt is aligned. So for testing the attitude estimate at the current time is added to estimator status)
master/PR