Ask Your Question
0

Orientation from wheel based odometry vs IMU

asked 2018-04-26 06:23:18 -0500

rsmitha gravatar image

updated 2018-04-26 06:25:20 -0500

Hi,

I have run some tests using the jackal and ros indigo. I collected the "x,y,z,w" values for the orientation from the wheel based odometry. These are quaternion representations of the orientation of the jackal.

Similar values are printed for the IMU as well. Here are some values which I logged:

//odometry orientation
[ INFO] [1524638957.013930930]:robotorn:x,y,z,w=0.000000,0.000000,0.037674,0.999290 

 //Imu orientation
[ INFO] [1524638957.013949804]:robotimu:x,y,z=0.000690,-0.000165,-0.987262

Why are the IMU values negative as compared to those of the odometry? Which should we consider while making our calculations?

Regards, rsmitha.

edit retag flag offensive close merge delete

Comments

You are comparing the values between a quaternion and euler angles ?

Delb gravatar imageDelb ( 2018-04-26 07:00:08 -0500 )edit

Hi @Delb, I am comparing quaternions for odometry and imu. I did not capture the'w' value for the imu as I forgot to add it to the ROS INFO list.

rsmitha gravatar imagersmitha ( 2018-04-26 07:05:05 -0500 )edit

I find quaternions pretty hard to compare without straight up plotting / drawing them or converting to euler angles. Which one you should use will depend on your application requirements & the quality of the IMU you're using (e.g., is it the onboard IMU?).

stevejp gravatar imagestevejp ( 2018-04-26 07:15:27 -0500 )edit

Hi.@stevejp, I am using the onboard imu.

rsmitha gravatar imagersmitha ( 2018-04-26 07:30:23 -0500 )edit

and what is your application / goal?

stevejp gravatar imagestevejp ( 2018-04-26 07:37:01 -0500 )edit

1 Answer

Sort by ยป oldest newest most voted
1

answered 2018-04-26 07:23:40 -0500

Delb gravatar image

It's because of how quaternions are maid, here is a little tool to see the evolution of the values of Euler angles and quaternion, you could see that (in Euler angles) for x=y=z=0 you can either have the w=1 or -1 (yet it's the same orientation).

For your calculations you should consider the most precise one. Odometry can be wrong if your robot drift, but usually you combine the wheel based odometry and the IMU to have the best value.

edit flag offensive delete link more

Comments

Hi @Delb, thanks for the visualisation link. Its great. If I have just the x,y,z values for the imu orientation and I wish to calculate the angle, would it be possible to do so without the 'w'? This is so I can plot orintation change for imu values. Regards, rsmitha.

rsmitha gravatar imagersmitha ( 2018-04-26 07:36:17 -0500 )edit

Why don't you have the w ? If the IMU generates a quaternion then you can directly use the functions from the answers of #q50113

Delb gravatar imageDelb ( 2018-04-26 07:42:53 -0500 )edit

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools

1 follower

Stats

Asked: 2018-04-26 06:23:18 -0500

Seen: 164 times

Last updated: Apr 26 '18