ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | ros @ Robotics Stack Exchange |
1 | initial version |
As far as I know there is no out of the box tf
/tf2
function that does that in ros2.
However, you can easily achieve that with a simple helper function e.g.:
auto createQuaternionMsgFromYaw(double yaw)
{
tf2::Quaternion q;
q.setRPY(0, 0, yaw);
return tf2::toMsg(q);
}