Yaw drifting and gyroscope sensor

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Yaw drifting and gyroscope sensor

2,344 Views
chudaidai
Contributor I

When I use fRun_6DOF_GY_KALMAN, the yaw keeps drifting,  when in stationary condition the gyroscope sensor frame is shown below:

145678_145678.pngpastedImage_0.png

I don't know if it is the reason for drifting? the output of the gyroscope is not around zero, or it is normal for gyroscope sensors?

 

 

Thanks!

ChuDaidai

Labels (1)
0 Kudos
3 Replies

1,102 Views
michaelestanley
NXP Employee
NXP Employee

Our Kalman filters are based on equations of motion and work best when the board is moving.  If your board is stationary on a table top, then the gravity vector is expressed entirely in the Z-axis and there is no information in X&Y to help compute Z-axis offset.  Yaw drift is eventually always going to occur in that case.  Pick the board up, rotate it in free space a few seconds and put it back down, you'll see the yaw drift rate cut dramtically.  Eventually it will creep back up.

That said, I don't see a clear drift in the plot you included, just offset.  That is normal.  Take a look at the angular velocity graph on "Dynamics" tab to see what the corrected angular rate looks like.

0 Kudos

1,102 Views
chudaidai
Contributor I

Hi

Thank you

I did as you told, and find that the yaw drift rate cut. However, it's not obvious. I put the board on the table in another way as follows:

pastedImage_0.png

And after a long time, the yaw drift isn't very obvious, and the angular velocity graph on "Dynamics" tab shows that the corrected angular rate walks sround zero.

Then comes another problem, the liner acceleration of z axis is bigger than x axis and y axis, it looks strange.

pastedImage_1.png

Thanks!

ChuDaidai

0 Kudos

1,102 Views
michaelestanley
NXP Employee
NXP Employee

ChuDaidai,

There are several issues at play:

  1. Not modelled in the V5.00 library
    • Accelerometer offsets
    • Gravity variation over the surface of the earth (about 0.6% range in large cities)
    • Gyro scale factor errors
    • Sensor non-linearities
    • Sustained acceleration
    • non-fixed environmental magnetic interference
  2. Kalman filters effectively do a least squares fit to a state-based model

#2 means that any errors from any of the terms in #1 get distributed  across modeled terms as a function of the various covariances used in the Kalman filter.  So an error in a gyro could manifest as a residual error in an acceleration term.

Basically, my advice is to not over think it.

Mike

0 Kudos