ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | ros @ Robotics Stack Exchange
Ask Your Question
1

UM7 IMU: adjust / turn off extended kalman filter to arrest drift?

asked 2017-12-10 21:26:32 -0500

tbar gravatar image

updated 2017-12-11 10:50:56 -0500

I am having considerable difficulty obtaining accurate results out of my UM7 IMU: yaw, pitch, and roll drift ~20 deg per minute making the sensor almost unusable. The drift exists during motion, and when the robot is sitting still on the ground. The output drifts when the acceleration and magnetometer values are unchanging. Viewing Euler angles or converting output quaternion values to euler angles myself makes no difference.

Use case: The IMU is mounted to a robot sailboat, I am looking for accuracy in orientation, it is OK if the response is slow (~0.25 s). The environment is magnetically quite clean, no vibration, but some low magnitude and 'smooth' accelerations from waves, etc.

The sensor is configured from defaults (U72A firmware revision):

  • quaternion mode on
  • no mag updates (the roll and pitch should be estimated from accel only)
  • magnetometer process variance: 50 (an attempt to use more magnetometer in orientation estimate)

I have calibrated the magnetometer following instructions from Redshift and CH robotics ~6 times - ensuring a match between sensor temperature during operation and calibration (so temperature dependency is less likely to be issue?). The calibration numbers are close to each other, suggesting this part is working OK. The processed mag values are between 0-1. I have used other IMUs with magnetometers in the area with better success, suggesting the mag field here is OK enough for yaw estimation (the environment is OK).

I have set the process variance for the rate gyros to 0. This reduced the drift considerably from much worse results previously - I believe this effectively 'turns off the rate gyros' - but I cannot be totally sure as I have been unable to find documentation that explains these parameters. The lack of fast response that the gyros would give is OK for my application.

Interestingly enough, the roll and pitch drift when the boat is sitting on the table. If I understand correctly, without 'mag updates' and process variance for rate gyros set to 0, the pitch and roll should be only estimated from accelerometers (gravity) - thus I am perplexed why the roll and pitch drift? All other kalman filters I've used converge on the correct value rather than accumulate some bias - as appears to be happening?

Resetting the extended kalman filter produces the correct value for ~10-20 s, until it drifts. Thus, I have programmed by boat to continuously reset the EKF every 10 seconds . . a regretfully hacky solution . . this is likely not how the system was designed to function and produces step changes upon each EKF reset.

  1. is there a way to 'turn off' or restrain the accumulation of bias in the EKF?
  2. any other tips or hints to help reduce the drift and make the sensor more usable?

I've been unable to find any documentation for the filter settings. Thank you for any help!

edit retag flag offensive close merge delete

Comments

We also recently acquired a UM7. Our unit had badly misaligned accel axes. We had to upgrade to the U72B firmware and perform a calibration to rotate the axes to the correct position to prevent our continuous drift. Contact Redshift labs with your issue, they were greatly helpful to us.

ufr3c_tjc gravatar image ufr3c_tjc  ( 2017-12-19 23:38:13 -0500 )edit

Also, the way Kalman filters work, I'd expect that setting the process variance rate of the gyros to zero will actually cause the filter to trust their measurements much more, rather than reject them. If this improved your estimate, then it points to the accelerometer being the problem I think.

ufr3c_tjc gravatar image ufr3c_tjc  ( 2017-12-19 23:42:13 -0500 )edit

2 Answers

Sort by ยป oldest newest most voted
1

answered 2018-01-16 15:05:18 -0500

tbar gravatar image

updated 2018-01-16 15:10:00 -0500

Thanks for the comments! To report on some progress and perhaps help anyone whom has the same issue:

The primary issue with my UM7 was strong accelerometer bias. The sensitivity ('gain') was slightly incorrect as well, but much less so. To calibrate the bias, I attached the IMU to a construction level, and measured the processed accelerometer values in various orientations relative to gravity to ensure the accelerometer was reading 1 g (or -1 g) in every axis when the axis was parallel to gravity, and 0 when perpendicular to gravity.

The final calibrations were:

  • Cabx0: -0.08890597
  • Caby0: -0.132
  • Cabz0: -0.15
  • Casx0: 0.00024414
  • Casy0: 0.000243
  • Casz0: 0.000238

I reset all the other parameters to the factory reset configuration.

The pitch and roll are solid, the yaw still drifts, but there are usable measurements (< 10 deg error) for approximately 10 minutes before I need to reset the EKF. A major improvement from before.

edit flag offensive delete link more

Comments

Where did you find out about these other calibration parameters? And how did you set them? I've got a similar issue where the accelerator gains/bias appear to be off.

fergs gravatar image fergs  ( 2018-03-31 23:54:45 -0500 )edit

In the serial interface software, click the configuration tab, press the 'read' button to read the present config. Check 'show advanced settings' and then scroll down. Adjust parameters. Press 'RAM' to write to ram, and 'FLASH' to write to flash so the parameters persist when imu is turned off

tbar gravatar image tbar  ( 2018-04-01 23:49:39 -0500 )edit
0

answered 2018-01-16 16:30:50 -0500

FWIW, we also encountered severe yaw drift issues with newer UM7 firmware and solved them by downgrading to an older one as described in this Q/A. While the yaw drift is low enough as to not adversly affect performance most of the time, sometimes it is noticably higher than "normal" on start or reset, which is very unpleasant behavior.

edit flag offensive delete link more

Comments

Thanks, I'll look into this, I also have noticed issues with startup, it seems to take 5 minutes or so for everything to warm up and become more stable.

tbar gravatar image tbar  ( 2018-01-16 22:46:08 -0500 )edit

Question Tools

1 follower

Stats

Asked: 2017-12-10 21:26:32 -0500

Seen: 1,376 times

Last updated: Jan 16 '18