ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | ros @ Robotics Stack Exchange |
1 | initial version |
As a noob i always are happy if a "nice" answer is provided. One, that can be copy-pasted. Because most likely someone will find this question when searching for a solution for a similar problem. So, if i'm correct, this should do the required trick:
Both ways this is needed at the very beginning of the code:
#include <tf/transform_datatypes.h>
msg -> TF:
quaternionMsgToTF(quat_msg , quat_tf);
tf -> msg
quaternionTFToMsg(quat_tf , quat_msg);
Basically this is exactly what the answer above includes, just as a line of code for everyone who isn't (jet) able to read the code provided by the link.