Add URDF model for table and SDF world configuration

- Created a new URDF file for the table model, including links for the table frame, wood palette, robot palette, cabinet frame, and cabinet, along with their respective visual and collision properties.
- Defined joints to connect the various components of the table model.
- Added a new SDF file for the simulation world, setting up the environment with physics properties, a ground plane, and lighting.
This commit is contained in:
Даниил Грабарь
2026-04-08 16:38:59 +10:00
parent 45e134e116
commit f474d330ad
9 changed files with 4402 additions and 21 deletions
+234
View File
@@ -0,0 +1,234 @@
<?xml version="1.0"?>
<robot name="robo_table">
<link name="world"/>
<link name="table_frame">
<inertial>
<origin xyz="0.0 0.0 0.0" rpy="0.0 0.0 0.0"/>
<mass value="30"/>
<inertia ixx="1.0" ixy="0.0" ixz="0.0"
iyy="1.0" iyz="0.0" izz="1.0"/>
</inertial>
<visual>
<origin xyz="0.0 0.0 0.0" rpy="0.0 0.0 0.0"/>
<geometry>
<mesh filename="package://iiwa_description/resource/meshes/table/TableFrame.obj"/>
</geometry>
<material name="table_metal">
<color rgba="0.57 0.57 0.57 1.0"/>
</material>
</visual>
<collision>
<origin xyz="0.0 0.0 0.395" rpy="0.0 0.0 0.0"/>
<geometry>
<box size="1.28 1.08 0.79"/>
</geometry>
</collision>
</link>
<gazebo reference="table_frame">
<visual>
<material>
<ambient>0.55 0.55 0.58 1</ambient>
<diffuse>0.65 0.65 0.68 1</diffuse>
<specular>0.3 0.3 0.3 1</specular>
<pbr><metal><roughness>0.6</roughness><metalness>0.4</metalness></metal></pbr>
</material>
</visual>
</gazebo>
<link name="wood_palete">
<inertial>
<origin xyz="0.0 0.0 0.0" rpy="0.0 0.0 0.0"/>
<mass value="10.0"/>
<inertia ixx="0.5" ixy="0.0" ixz="0.0"
iyy="0.5" iyz="0.0" izz="0.5"/>
</inertial>
<visual name="top_surface">
<origin xyz="0.0 0.0 0.0" rpy="0.0 0.0 0.0"/>
<geometry><box size="1.28 1.08 0.02"/></geometry>
<material name="table_top">
<color rgba="0.92 0.92 0.92 1.0"/>
</material>
</visual>
<visual name="border_front">
<origin xyz="0.0 0.53 0.005" rpy="0.0 0.0 0.0"/>
<geometry><box size="1.28 0.02 0.014"/></geometry>
<material name="orange_border"><color rgba="1.0 0.38 0.0 1.0"/></material>
</visual>
<visual name="border_back">
<origin xyz="0.0 -0.53 0.005" rpy="0.0 0.0 0.0"/>
<geometry><box size="1.28 0.02 0.014"/></geometry>
<material name="orange_border"><color rgba="1.0 0.38 0.0 1.0"/></material>
</visual>
<visual name="border_left">
<origin xyz="0.63 0.0 0.005" rpy="0.0 0.0 0.0"/>
<geometry><box size="0.02 1.04 0.014"/></geometry>
<material name="orange_border"><color rgba="1.0 0.38 0.0 1.0"/></material>
</visual>
<visual name="border_right">
<origin xyz="-0.63 0.0 0.005" rpy="0.0 0.0 0.0"/>
<geometry><box size="0.02 1.04 0.014"/></geometry>
<material name="orange_border"><color rgba="1.0 0.38 0.0 1.0"/></material>
</visual>
<collision>
<origin xyz="0.0 0.0 0.0" rpy="0.0 0.0 0.0"/>
<geometry><box size="1.28 1.08 0.02"/></geometry>
</collision>
</link>
<gazebo reference="wood_palete">
<visual name="top_surface">
<material>
<ambient>0.92 0.92 0.92 1</ambient>
<diffuse>0.95 0.95 0.95 1</diffuse>
<specular>0.1 0.1 0.1 1</specular>
</material>
</visual>
<visual name="border_front">
<material><ambient>1.0 0.38 0.0 1</ambient><diffuse>1.0 0.38 0.0 1</diffuse><specular>0.3 0.15 0.0 1</specular></material>
</visual>
<visual name="border_back">
<material><ambient>1.0 0.38 0.0 1</ambient><diffuse>1.0 0.38 0.0 1</diffuse><specular>0.3 0.15 0.0 1</specular></material>
</visual>
<visual name="border_left">
<material><ambient>1.0 0.38 0.0 1</ambient><diffuse>1.0 0.38 0.0 1</diffuse><specular>0.3 0.15 0.0 1</specular></material>
</visual>
<visual name="border_right">
<material><ambient>1.0 0.38 0.0 1</ambient><diffuse>1.0 0.38 0.0 1</diffuse><specular>0.3 0.15 0.0 1</specular></material>
</visual>
<collision>
<surface>
<friction><ode><mu>0.3</mu><mu2>0.3</mu2></ode></friction>
</surface>
</collision>
</gazebo>
<link name="robot_palete">
<inertial>
<origin xyz="0.0 0.0 0.0" rpy="0.0 0.0 0.0"/>
<mass value="3"/>
<inertia ixx="0.1" ixy="0.0" ixz="0.0"
iyy="0.1" iyz="0.0" izz="0.1"/>
</inertial>
<visual>
<origin xyz="0.0 0.0 0.0" rpy="0.0 0.0 0.0"/>
<geometry>
<mesh filename="package://iiwa_description/resource/meshes/table/PlateUnderRobot.obj"/>
</geometry>
<material name="table_metal"><color rgba="0.57 0.57 0.57 1.0"/></material>
</visual>
<collision>
<origin xyz="0.0 0.0 0.0" rpy="0.0 0.0 0.0"/>
<geometry><box size="0.47 0.4 0.01"/></geometry>
</collision>
</link>
<gazebo reference="robot_palete">
<visual>
<material>
<ambient>0.55 0.55 0.58 1</ambient>
<diffuse>0.65 0.65 0.68 1</diffuse>
<specular>0.3 0.3 0.3 1</specular>
<pbr><metal><roughness>0.6</roughness><metalness>0.4</metalness></metal></pbr>
</material>
</visual>
</gazebo>
<link name="cabinet_frame">
<inertial>
<origin xyz="0.0 0.0 0.0" rpy="0.0 0.0 0.0"/>
<mass value="5.0"/>
<inertia ixx="0.2" ixy="0.0" ixz="0.0"
iyy="0.2" iyz="0.0" izz="0.2"/>
</inertial>
<visual>
<origin xyz="0.0 0.0 0.0" rpy="1.57 0.0 1.57"/>
<geometry>
<mesh filename="package://iiwa_description/resource/meshes/table/CabinetFrame.obj"/>
</geometry>
<material name="table_metal"><color rgba="0.57 0.57 0.57 1.0"/></material>
</visual>
</link>
<gazebo reference="cabinet_frame">
<visual>
<material>
<ambient>0.55 0.55 0.58 1</ambient>
<diffuse>0.65 0.65 0.68 1</diffuse>
<specular>0.3 0.3 0.3 1</specular>
<pbr><metal><roughness>0.6</roughness><metalness>0.4</metalness></metal></pbr>
</material>
</visual>
</gazebo>
<link name="cabinet">
<inertial>
<origin xyz="0.0 0.0 0.0" rpy="0.0 0.0 0.0"/>
<mass value="15.0"/>
<inertia ixx="0.5" ixy="0.0" ixz="0.0"
iyy="0.5" iyz="0.0" izz="0.5"/>
</inertial>
<visual>
<origin xyz="0.0 0.31 0.0" rpy="1.57 0.0 -1.57"/>
<geometry>
<mesh filename="package://iiwa_description/resource/meshes/table/ElectricCabinet.obj"/>
</geometry>
<material name="cabinet_dark"><color rgba="0.2 0.2 0.22 1.0"/></material>
</visual>
<collision>
<origin xyz="-0.12 0 0.4" rpy="1.57 0.0 1.57"/>
<geometry><box size="0.65 0.83 0.32"/></geometry>
</collision>
</link>
<gazebo reference="cabinet">
<visual>
<material>
<ambient>0.18 0.18 0.20 1</ambient>
<diffuse>0.22 0.22 0.24 1</diffuse>
<specular>0.5 0.5 0.5 1</specular>
<pbr><metal><roughness>0.3</roughness><metalness>0.7</metalness></metal></pbr>
</material>
</visual>
</gazebo>
<!-- ═══ Джойнты ═══ -->
<joint name="world_frame" type="fixed">
<origin xyz="0.0 0.0 0.0" rpy="0.0 0.0 0.0"/>
<parent link="world"/>
<child link="table_frame"/>
</joint>
<joint name="frame_palete" type="fixed">
<origin xyz="0.0 0.0 0.79" rpy="0.0 0.0 0.0"/>
<parent link="table_frame"/>
<child link="wood_palete"/>
</joint>
<joint name="paletes" type="fixed">
<origin xyz="-0.263 0.0 0.02" rpy="0.0 0.0 0.0"/>
<parent link="wood_palete"/>
<child link="robot_palete"/>
</joint>
<joint name="frames" type="fixed">
<origin xyz="-0.66 0.0 0.09" rpy="0.0 0.0 0.0"/>
<parent link="table_frame"/>
<child link="cabinet_frame"/>
</joint>
<joint name="cabinets" type="fixed">
<origin xyz="-0.022 0 0.2" rpy="0.0 0.0 0.0"/>
<parent link="cabinet_frame"/>
<child link="cabinet"/>
</joint>
</robot>