-
-
Notifications
You must be signed in to change notification settings - Fork 115
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Better Gyro Fusion #784
base: emuflight-1.0.0-master
Are you sure you want to change the base?
Better Gyro Fusion #784
Conversation
07ddd2b
to
7015291
Compare
a87bc6f
to
29365cc
Compare
7015291
to
4a922e6
Compare
29365cc
to
6413805
Compare
4a922e6
to
64a1957
Compare
6413805
to
1e0edeb
Compare
0c4ee8b
to
3aab740
Compare
3aab740
to
e86e758
Compare
1e0edeb
to
7d2cce7
Compare
|
Comparing this to the current gyro fusion, this code will make the gyro that performs worse be ignored more than one that is still working right. So if one gyro went bad it would fly better with this code than it would without this code. However, it isn't good enough to totally ignore a bad gyro and will still perform better if the bad gyro is just disabled completely. Perhaps it could be modified so that if it detects its constantly leaning hard towards one gyro that it will just disable the other gyro and only rely on one. |
fe70257
to
fe7710c
Compare
7d2cce7
to
4cf2e5c
Compare
SPRACINGH7CL
SPRACINGH7EF
This code looks at the variance over the last 8 samples and uses this to determine how to fuse dual gyros together. Gyros with more variance will be fused less while the gyro with less variance will be fused at a higher percent.
To test this code set your debug mode to fusion and set the gyro_to_use in the cli to be both_variance. Debug 0 is gyro1, debug 1 is gyro 2, debug 2 is the fused gyro data. It should be slightly cleaner than the other gyro signals.