How to solve 'roslaunch file contains multiple nodes named [/r_arm_controller/joint_trajectory_generator].' ? [closed]

asked 2012-08-06 05:48:45 -0600

sam gravatar image

updated 2012-08-06 22:26:07 -0600

I followed PR2 Plugs Itself In.

I run:

  ira@ira-K42JP:~$ export ROBOT=sim
  ira@ira-K42JP:~$ roslaunch pr2_plugs_gazebo_demo pr2_plugs_demo.launch
  ... logging to /home/ira/.ros/log/4bd9fc80-dfdb-11e1-b17e-485d60bf89ef/roslaunch-ira-K42JP-9908.log
  Checking log directory for disk usage. This may take awhile.
  Press Ctrl-C to interrupt
  Done checking log file disk usage. Usage is <1GB.

  roslaunch file contains multiple nodes named [/r_arm_controller/joint_trajectory_generator].
  Please check all <node> 'name' attributes to make sure they are unique.
  Also check that $(anon id) use different ids.
  ira@ira-K42JP:~$

How to solve it?

Thank you~


pr2_plugs_demo.launch:

  <launch>

     <!-- Set params for sim -->
    <param name="detect_wall_norm/sim" value="True" type="bool"/>
    <param name="detect_outlet/sim" value="True" type="bool"/>

    <param name="r_gripper_controller/gripper_action_node/stall_velocity_threshold" value="0.01" type="double"/>

    <!-- Start PR and load the plug and outlet in the world -->
    <include file="$(find pr2_plugs_gazebo_demo)/launch/pr2_plug_outlet.launch"/>

    <!-- Start the plugs app -->
    <include file="$(find pr2_plugs_actions)/launch/plug_actions.launch"/>

    <!-- ik action -->
    <node pkg="pr2_arm_move_ik" type="arm_ik" name="r_arm_ik" output="screen">
      <param name="joint_trajectory_action" value="r_arm_controller/joint_trajectory_generator" />
      <param name="arm" value="r" />
      <param name="free_angle" value="2" />
      <param name="search_discretization" value="0.01" />
      <param name="ik_timeout" value="5.0" />
    </node>

    <!-- Trajectory generator -->
    <node pkg="joint_trajectory_generator" type="joint_trajectory_generator" output="screen" 
          name="joint_trajectory_generator" ns="r_arm_controller" >
      <param name="max_acc" value="2.0" />
      <param name="max_vel" value="2.5" />
    </node>
    <node pkg="joint_trajectory_generator" type="joint_trajectory_generator" output="screen" 
          name="joint_trajectory_generator" ns="l_arm_controller" >
      <param name="max_acc" value="2.0" />
      <param name="max_vel" value="2.5" />
    </node>

    <!-- tuckarm action -->
    <node pkg="pr2_tuck_arms_action" type="tuck_arms.py" name="tuck_arms_action" output="screen">
      <param name="r_joint_trajectory_action" value="r_arm_controller/joint_trajectory_generator" />
      <param name="l_joint_trajectory_action" value="l_arm_controller/joint_trajectory_generator" />
      <param name="move_duration" value="0.0" />
    </node>

    <!-- navstack -->
    <include file="$(find pr2_2dnav)/pr2_2dnav.launch" />

    <!-- plugs web adaptor -->
    <node pkg="pr2_plugs_actions" type="recharge_web_adaptor.py" name="recharge_web_adaptor" />
  </launch>
edit retag flag offensive reopen merge delete

Closed for the following reason question is not relevant or outdated by tfoote
close date 2015-04-05 20:37:45.826605

Comments

Can you copy your launch file? It seems like some nodes have the same name

pmarinplaza gravatar image pmarinplaza  ( 2012-08-06 05:52:06 -0600 )edit

Please check all <node> 'name' attributes to make sure they are unique.

dornhege gravatar image dornhege  ( 2012-08-06 06:43:39 -0600 )edit

I have edited my original post. It use the different namespace 'r_arm_controller' and 'l_arm_controller'. What caused the problem? thank you~

sam gravatar image sam  ( 2012-08-06 22:27:47 -0600 )edit

Ok you are starting 2 equall nodes with different namespace and still return error? In my experience with this kind of troubles, I start looking inside the others includes like pr2_2dnav.launch plug_actions.launch, etc. It is posible you are starting the same nodes. Try this and tell us something

pmarinplaza gravatar image pmarinplaza  ( 2012-08-07 10:50:31 -0600 )edit

I try to run pr2_2dnav.launch and plug_actions.launch, and it seems normal. Nothing similar wrong or errors. How to solve it? Thank you~

sam gravatar image sam  ( 2012-08-08 04:29:27 -0600 )edit