A little overdue, but never too late for an announcement I guess .
I’ve written a small rviz utility that can handle a /robot_description
topic within ROS 1 rviz:
Think of migrating to ROS 2? Why not do it step by step!
In ROS 2 there are no global parameters anymore, so /robot_description
became a topic. And this would even make sense for ROS 1 as now you can modify your description on the fly!
Little is holding you back from using a /robot_description
topic already in ROS 1, just launch a minimal node like this:
#!/usr/bin/env python3
import rospy
from std_msgs.msg import String
rospy.init_node("robot_description_publisher")
pub = rospy.Publisher("robot_description", String, latch=True, queue_size=1)
pub.publish(rospy.get_param("robot_description"))
rospy.spin()
Optionally (if you want the dynamic part in ROS 1 already), you can subscribe to the topic instead of listening to the parameter:
void robot_description_cb(const std_msgs::String::ConstPtr & msg)
{
ROS_INFO("Received new robot description");
urdf::Model model;
model.initString(msg->data);
Only thing remaining: rviz
cannot display it . A PR was rejected, hence the creation of this package
.
Just add it to your workspace and rviz supports the /robot_description
topic as well. We’ve prepared and migrated several robots (ours and customers) like this already.
Best part: you can already start using rviz2 because topics transparently go through the ros1_bridge!