rostopic echo with launch file
Hello,
I would like to do something like this
rostopic echo -p /mytopic > outputfile.txt
with the launch file
Hence, I wrote this in the launch file
<node name="output_topic1" pkg="rostopic" type="rostopic" output="screen" args="echo -p /mytopic > outputfile.txt">
</node>
However, it doesn't work and give me an error like this
Usage: rostopic echo [options] /topic
rostopic: error: you may only specify one input topic
[output_topic1-8] process has died [pid 11643, exit code 2, cmd /opt/ros/groovy/lib/rostopic/rostopic echo -p /mytopic > outputfile.txt __name:=output_topic1 __log:=/home/user/.ros/log/edae921e-f970-11e2-be82-14feb5b7467c/output_topic1-8.log].
log file: /home/user/.ros/log/edae921e-f970-11e2-be82-14feb5b7467c/output_topic1-8*.log