Analyzing ROS messages
Is there a command that will allow me to see what is stored in specific messages? I know rxgraph shows where everything is going but is there something similar to what is being sent?
ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | Q&A answers.ros.org |
Is there a command that will allow me to see what is stored in specific messages? I know rxgraph shows where everything is going but is there something similar to what is being sent?
You can use rostopic
to print the contents of a message to standard output. For example,
rostopic echo /camera/image_raw
will echo the full contents of the /camera/image_raw
topic. If the message contains binary data, such as with Image
, this will likely cause problems with your terminal emulator. In those cases it is useful to only echo the fields of interest:
rostopic echo /camera/image_raw/width /camera/image_raw/height
I don't believe that there is a graphical (rx
...) analog rostopic
.
The rosmsg tool will show you all of the fields available for a given message type. For example, to see all of the fields available in the nav_msgs/Odometry message type, you would use the following:
rosmsg show nav_msgs/Odometry
Note that that page shows how you can use this to easily get the fields available on a given topic using something like:
rostopic type <topic_name> | rosmsg show
rxbag --record /topic
will allow you to see what's stored in messages published on a topic. You can view the contents textually, plot numerical values, or view image messages.
Please start posting anonymously - your entry will be published after you log in or create a new account.
Asked: 2011-03-17 07:14:32 -0500
Seen: 1,365 times
Last updated: Mar 17 '11
Cannot load message class for [robot_position/mymsg]. Are your messages built?
How to publish and subscribe to the list consisting of many tuples?
Is there a way to publish service::request/response
"Are your messages built?" error from echoing that message (Groovy)
Echo own messages on remote ROS master
appropriate message for teleop node to control an quadrotor
usb_cam camera frame rate, and rostopic
ERROR: Cannot load message class for [*]. Are your messages built? (Indigo)