Home | Tutorials | Wiki | Issues
Ask Your Question

[UUV Simulator] Including robot into a Gazebo world

asked 2018-05-11 13:05:41 -0500

hbaqueiro gravatar image

updated 2018-05-14 08:58:59 -0500

Hey everyone,

(I'm a beginner to ROS, Gazebo and UUV Simulator) I am doing the tutorial of UUV Simulator and in the section "Configuring the thruster manager for a new vehicle" I am getting the following error when I try to include my vehicle into the world:

baqueiro@baqueiro-Latitude-E6430:~/catkin_ws$ roslaunch baqtronic_description upload.launch 
... logging to /home/baqueiro/.ros/log/136ecaac-5522-11e8-9ca6-f01faf1d30a4/roslaunch-baqueiro-Latitude-E6430-12866.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.

xacro: Traditional processing is deprecated. Switch to --inorder processing!
To check for compatibility of your document, use option --check-order.
For more infos, see http://wiki.ros.org/xacro#Processing_Order
XML parsing error: not well-formed (invalid token): line 4, column 8
when processing file: /home/baqueiro/catkin_ws/src/baqtronic_description/urdf/snippets.xacro
included from: /home/baqueiro/catkin_ws/src/baqtronic_description/urdf/base.xacro
included from: /home/baqueiro/catkin_ws/src/baqtronic_description/robots/default.xacro

Check that:
 - Your XML is well-formed
 - You have the xacro xmlns declaration: xmlns:xacro="http://www.ros.org/wiki/xacro"
Invalid <param> tag: Cannot load command parameter [robot_description]: command [/opt/ros/kinetic/share/xacro/xacro.py '/home/baqueiro/catkin_ws/src/baqtronic_description/robots/default.xacro' debug:=0 namespace:=baqtronic] returned with code [2]. 

Param xml is <param command="$(find xacro)/xacro.py '$(find baqtronic_description)/robots/$(arg mode).xacro' debug:=$(arg debug) namespace:=$(arg namespace)" name="robot_description"/>
The traceback for the exception was written to the log file

I'm using ROS Kinetic and Gazebo 9. Can anyone help me? Thanks in advance :)

Edit: Below my snippets.xacro:

<?xml version="1.0"?>

<robot xmlns:xacro="http://www.ros.org/wiki/xacro">

<xacro:property name="prop_mesh_file" value="file://$(find baqtronic_description)/meshes/propeller.dae"/>

<xacro:macro name="thruster_macro" params="robot_namespace thruster_id *origin">

Dummy link as place holder for the thruster frame,
since thrusters can often be inside the collision geometry
of the vehicle and may cause internal collisions if set otherwise
<link name="${robot_namespace}/thruster_${thruster_id}">

      <mesh filename="${prop_mesh_file}" scale="1 1 1" />

    <mass value="0.001" />
    <origin xyz="0 0 0" rpy="0 0 0"/>
    <inertia ixx="0.000000017" ixy="0.0" ixz="0.0"
           iyy="0.000000017" iyz="0.0"
           izz="0.000000017" />

<!-- Joint between thruster link and vehicle base link -->
<joint name="${robot_namespace}/thruster_${thruster_id}_joint" type="continuous">
  <xacro:insert_block name="origin" />
  <axis xyz="1 0 0" />
  <parent link="${robot_namespace}/base_link" />
  <child link="${robot_namespace}/thruster_${thruster_id}" />

  <!-- Thruster ROS plugin -->
  <plugin name="${robot_namespace}_${thruster_id}_thruster_model" filename="libthruster_ros_plugin.so">
    <!-- Name of the thruster link -->

    <!-- Name of the joint between thruster and vehicle base link -->

    <!-- Make the thruster aware of its id -->

    <!-- Gain of the input command signal -->

    <!-- Maximum allowed input value for the input signal for thruster unit -->

    <!-- Minimum allowed value for the input signal for thruster unit -->

    <!-- Minimum and maximum thrust ...
edit retag flag offensive close merge delete


Could you add your snippets.xacro file to the question?

Raskkii gravatar imageRaskkii ( 2018-05-14 02:12:08 -0500 )edit

I've edited the question to add the snippets.xacro

hbaqueiro gravatar imagehbaqueiro ( 2018-05-14 08:57:43 -0500 )edit

1 Answer

Sort by ยป oldest newest most voted

answered 2018-05-14 09:05:44 -0500

Raskkii gravatar image

updated 2018-05-14 09:11:04 -0500

You've included your prop_mesh_file incorrectly. So do the following change:

<xacro:property name="prop_mesh_file" value="file://$(find baqtronic_description)/meshes/propeller.dae"/>

Change it to:

<xacro:property name="prop_mesh_file" value="package://baqtronic_description/meshes/propeller.dae"/>


I think the $(find.. should work too, it's just the file:// that breaks it, it's not needed at all. So you can also try:

<xacro:property name="prop_mesh_file" value="$(find baqtronic_description)/meshes/propeller.dae"/>
edit flag offensive delete link more


They don't work. It turns out that the file baqtronic_description/meshes/propeller.dae doesn't exist. It is not created by the command rosrun uuv_assistants create_new_robot_model --robot_name baqtronic. The folder structure is as shown in the tutorial: https://uuvsimulator.github.io/tutorials/create_new_vehicle.html

hbaqueiro gravatar imagehbaqueiro ( 2018-05-14 10:56:05 -0500 )edit
Login/Signup to Answer

Question Tools

1 follower


Asked: 2018-05-11 13:05:41 -0500

Seen: 66 times

Last updated: May 14