Ask Your Question

Quaternion problem !?

asked 2016-05-04 09:50:37 -0500

assil gravatar image


I have a problem with this function: geometry_msgs::Quaternion odom_quat= tf::createQuaternionMsgFromYaw(th);

when I give the input value "th" in degree it functions and the robot turns but with bad precision. And when I give the input in radians it doesn't function at all !!!

I don't know where's the problem !

Any suggestion please !


edit retag flag offensive close merge delete


You could edit this question to provide a bit more context, otherwise, I'm guessing people will not be able to help you.

jarvisschultz gravatar image jarvisschultz  ( 2016-05-04 11:30:30 -0500 )edit

1 Answer

Sort by ยป oldest newest most voted

answered 2016-05-04 11:29:54 -0500

This function definitely takes its input in radians. I just tested it with a few different yaw angles and the geometry_msgs::Quaternion created produced the expected values. I'm guessing the issue lies with your robot, its interfaces, or its controllers.

edit flag offensive delete link more

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


Asked: 2016-05-04 09:50:37 -0500

Seen: 158 times

Last updated: May 04 '16