Skip to content
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

Yaw drifted after calibrating every minute #41

Open
nhungtrant opened this issue Nov 15, 2023 · 1 comment
Open

Yaw drifted after calibrating every minute #41

nhungtrant opened this issue Nov 15, 2023 · 1 comment

Comments

@nhungtrant
Copy link

I'm currently developing a code for the Teensy 4.1 to recalibrate the MPU6050 every minute until a triggering event occurs. However, with each recalibration, there seems to be a persistent yaw drift, gradually increasing from 0 to -11. Can you offer insights into what might be causing this issue? Additionally, during each recalibration, the offset yields a random symbol, and I'm uncertain whether this might be influencing the outcome.

Thank you

@revell1
Copy link

revell1 commented Nov 16, 2023

From memory, the MPU6050 only has Accelerometer and Gyro sensor, and no Magnetic compass, so over time, without a magnetic reference, the calibration is unable to track any magnetic rotation, I think that is what you may be seeing in your YAW drift. I think you may be able to prove that by rotating your MPU6050 so that you end up swapping the Z axis with either the X or Y axis, I think that would then move the drift from YAW to one of the other axis. I can't remember how to feed an I2C compass sensor data into the MPU6050, but I think it has some support, but has been some time since I played with that.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants