How can I run rqt_plot with topics from launchfile?
I have the following launchfile.
<launch>
<group ns='Axel'>
<node pkg='quad_control' name='coverage_planner' type='coverage_planner.py'/>
<node pkg='quad_control' name='planar_integrator' type='planar_integrator.py'/>
<node pkg='rqt_plot' name='rqt_plot' type='rqt_plot' args='/Axel/pose/x:y:theta'/>
<param name='others_names' type='str' value='Bo Calle David'/>
</group>
</launch>
I expected that rqt_plot
would be running with the topics that I specified in the args
field.
But no, it runs with whatever topic it was running when it was launched the previous time.
How can I make rqt_plot
run from launchfile with the topics of my choice?
Asked by antonio on 2016-05-08 05:41:49 UTC
Answers
I don't have a direct answer to your question and I suspect you've already found an answer in the last 2 years but for the sake of anyone else looking at this it is possible to save an rqt perspective with the topics from your launch file. Ironically this same functionality may be what is causing rqt_plot to remember previous sessions.
Asked by Taylor Cooper on 2018-04-03 00:56:33 UTC
Comments
I will place this here for future reference. The syntax used in the original question is incorrect. I did not check the codebase in 2016/2018 but in 2021, the syntax for specifying topics is as follows:
rosrun rqt_plot rqt_plot /<ROBOT_NS>/joint_states/effort[0] /<ROBOT2_NS>/joint_states/effort[0]
This can be seen by looking at the code of the rqt_plot/plot.py##L114 plugin. As a result, the correct syntax for doing this form a launch file:
<node pkg="rqt_plot" type="rqt_plot" output="screen" name="rqt_plot" args="/<ROBOT_NS>/joint_states/effort[0] /<ROBOT2_NS>/joint_states/effort[0]"/>
Asked by rickstaa on 2021-11-28 08:28:35 UTC
Comments