ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | ros @ Robotics Stack Exchange
Ask Your Question
0

active/connected rostopics to terminal list or file

asked 2017-01-31 11:12:58 -0600

roboticom314 gravatar image

Is there a way to get the active or connected (i.e. excluding leaf topics) ROS topics as a list to the terminal or a text file? The topics can limited to only the active topics from rqt_graph but are there any methods the rostopic or rosnode (or combination of the two) commands can generate a list? Can rqt_graph save the active topics or log them?

edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted
0

answered 2017-01-31 13:20:05 -0600

AndyZe gravatar image
rostopic list -s

gives a list of subscribed, active topics. To save the list,

rostopic list -s > activeTopics.txt

Will save the list in your current directory. I don't see an easy way to do the same with nodes, though.

edit flag offensive delete link more

Comments

1

That works thanks. I always had assumed that the -s option was for all subscriptions regardless of connection state. I verified using rqt_graph that it's only the connected topics.

roboticom314 gravatar image roboticom314  ( 2017-01-31 14:37:02 -0600 )edit

Question Tools

2 followers

Stats

Asked: 2017-01-31 11:12:58 -0600

Seen: 209 times

Last updated: Jan 31 '17