error in urdf file
Hi,
I'm working on a project where I have to write a urdf file to describe a tool. The robot description is already completed and I only have to write the urdf file of my tool and include it in the robot description. Furthermore I have to include another already existing tool into my description and position it accordingly.
So far I have written the urdf file and a launch file to test the urdf in rviz. They are in a package that includes the package.xml file and CMakeList.txt file (these should be fine) as well as a folder with the mesh stl file.
This is my urdf file:
<?xml version="1.0"?>
<robot name="grinding_tool" xmlns:xacro="http://www.ros.org/wiki/xacro">
<xacro:include filename="$(find compliant_tool)/compliant_tool_description/urdf_src/compliant_tool.urdf.xacro" />
<!-- Useful definitions -->
<xacro:property name="meshes_path"
value="package://grinding_tool/meshes"/>
<xacro:property name="meshes_scale"
value="0.001 0.001 0.001"/>
<xacro:macro name="grinding_tool" params="parent_name ee_link_name">
<joint name="assembly_world" type="fixed">
<origin xyz="0 0 0" rpy="0 0 0"/>
<parent link="world"/>
<child link="assembly _tool"/>
</joint>
<link name="assembly_tool">
<visual>
<geometry>
<mesh filename="${meshes_path}/assembly.stl" scale="${meshes_scale}"/>
</geometry>
<material name="gray">
<color rgba="${105/255} ${105/255} ${105/255} 1.0"/>
</material>
</visual>
<collision>
<origin xyz="0 0 0" rpy="0 0 0"/>
<geometry>
<box size="0.42 0.17 0.15"/>
</geometry>
</collision>
<inertial>
<origin xyz="0 0 0" rpy="0 0 0"/>
<mass value="3.3"/>
<inertia ixx="0.0019"
ixy="0" iyy="0.072"
ixz="0" iyz="0" izz="0.074"/>
</inertial>
</link>
<xacro:grinding_tool prefix="" joint_limited="true"/>
<!-- postioning the compliant tool in the grinding tool urdf, compliant tool uses ${parent_name} as base line-->
<joint name="comp_grind_link" type="fixed">
<parent link="assembly_tool"/>
<child link="${parent_name}"/>
<origin xyz="0 0 0" rpy="0 0 0"/>
</joint>
<gazebo reference="tool">
<mu1 value="200.0"/>
<mu2 value="100.0"/>
<kp value="10000000.0" />
<kd value="1.0" />
<material>Gazebo/Grey</material>
</gazebo>
<gazebo>
<plugin name="gazebo_ros_control" filename="libgazebo_ros_control.so">
<robotNamespace>/</robotNamespace>
</plugin>
</gazebo>
</robot>
And the launch file I used is from this website: https://industrial-training-master.readthedocs.io/en/melodic/_source/session3/Workcell-XACRO.html
<?xml version="1.0" encoding="UTF-8"?>
<launch>
<arg name="gui" default="true"/>
<param name="robot_description" command="cat '$(find grinding_tool)/urdf_src/grinding_tool2.urdf.xacro'"/>
<node name="robot_state_publisher" pkg="robot_state_publisher" type="robot_state_publisher"/>
<node name="joint_state_publisher" pkg="joint_state_publisher" type="joint_state_publisher">
<param name="use_gui" value="$(arg gui)"/>
</node>
<node name="rviz" pkg="rviz" type="rviz" if="$(arg gui)"/>
</launch>
When I launch it get an error : error reading end tag and in rviz it says that there is no tf data ...