I am using ros melodic on ubuntu18. I was following the tutorials on tf2, so after going through the broadcaster and listener, the start demo launch file is not launching the listener node. What is even weirder to me is that it works (without giving an error) when I launch the file directly from the folder i.e.
roslaunch start_demo.launch
instead of
roslaunch learning_tf2 start_demo.launch
Here is my launch file
<launch>
<node pkg="turtlesim" type="turtlesim_node" name="sim"/>
<node pkg="turtlesim" type="turtle_teleop_key" name="teleop" output="screen"/>
<node name="turtle1_tf2_broadcaster" pkg="learning_tf2" type="turtle_tf2_broadcaster.py" respawn="false" output="screen" >
<param name="turtle" type="string" value="turtle1" />
</node>
<node name="turtle2_tf2_broadcaster" pkg="learning_tf2" type="turtle_tf2_broadcaster.py" respawn="false" output="screen" >
<param name="turtle" type="string" value="turtle2" />
</node>
<node name="turtle_listener" pkg="learning_tf2" type="turtle_tf2_listener.py" output="screen"/></launch>
I have done things like deleting my devel and build folders, running catkin_make, sourcing setup.bash, but still the same issue. Am I missing something here? When I run from the folder directly:
NODES
/
sim (turtlesim/turtlesim_node)
teleop (turtlesim/turtle_teleop_key)
turtle1_tf2_broadcaster (learning_tf2/turtle_tf2_broadcaster.py)
turtle2_tf2_broadcaster (learning_tf2/turtle_tf2_broadcaster.py)
turtle_listener (learning_tf2/turtle_tf2_listener.py)
When I reference through package:
NODES
/
sim (turtlesim/turtlesim_node)
teleop (turtlesim/turtle_teleop_key)
turtle1_tf2_broadcaster (learning_tf2/turtle_tf2_broadcaster.py)
turtle2_tf2_broadcaster (learning_tf2/turtle_tf2_broadcaster.py)
It's the same launch file! What am I missing here?
Originally posted by pravardhan on ROS Answers with karma: 38 on 2020-05-09
Post score: 0
Original comments
Comment by gvdhoorn on 2020-05-10:
It would help if you could show the verbatim output of both roslaunch start_demo.launch
and roslaunch learning_tf2 start_demo.launch
.