Skip to content

Commit

Permalink
Fixed the bug where we could only launch from src
Browse files Browse the repository at this point in the history
We could only launch launch_sim.launch.py from /src directory as the path were relative
  • Loading branch information
VincidaB committed Jan 12, 2024
1 parent f7dcd42 commit 7f36031
Show file tree
Hide file tree
Showing 10 changed files with 1,019 additions and 5 deletions.
2 changes: 1 addition & 1 deletion src/ezbot_descr_simul/launch/launch_sim.launch.py
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ def generate_launch_description():
DeclareLaunchArgument(
'world',
#default_value=[os.path.join('ezbot_gazebo','worlds','table2024.world'), ''],
default_value=[os.path.join(get_package_share_directory("ezbot_gazebo"), 'worlds', 'table2024.world'), ''],
default_value=[os.path.join(get_package_share_directory("ezbot_gazebo"), 'worlds', 'table2024Poteaux.world'), ''],
description='SDF world file'),
rsp,
gazebo,
Expand Down
5 changes: 5 additions & 0 deletions src/ezbot_gazebo/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -28,4 +28,9 @@ install(DIRECTORY worlds/
DESTINATION share/${PROJECT_NAME}/worlds/
)

install(DIRECTORY models/
DESTINATION $ENV{HOME}/.gazebo/models/
)


ament_package()
14 changes: 14 additions & 0 deletions src/ezbot_gazebo/models/Table2024/materials/scripts/table.material
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
material tableMat/Diffuse
{
receive_shaddows off
technique
{
pass
{
texture_unit
{
texture table.png
}
}
}
}
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
11 changes: 11 additions & 0 deletions src/ezbot_gazebo/models/Table2024/model.config
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
<?xml version="1.0" ?>
<model>
<name>Table_2024</name>
<version>1.0</version>
<sdf version="1.7">model.sdf</sdf>
<author>
<name>Vincent Belpois</name>
<email>[email protected]</email>
</author>
<description>Table for the 2024 Coupe de France de Robotique and EuroBot</description>
</model>
99 changes: 99 additions & 0 deletions src/ezbot_gazebo/models/Table2024/model.sdf
Original file line number Diff line number Diff line change
@@ -0,0 +1,99 @@
<?xml version='1.0'?>
<sdf version='1.7'>
<model name='Table_2024'>
<static>true</static>
<link name='link_0'>
<gravity>0</gravity>
<inertial>
<inertia>
<ixx>0.166667</ixx>
<ixy>0</ixy>
<ixz>0</ixz>
<iyy>0.166667</iyy>
<iyz>0</iyz>
<izz>0.166667</izz>
</inertia>
</inertial>
<pose>0 0 0 0 -0 0</pose>
<visual name='visual'>
<pose>0 0 0 0 -0 0</pose>
<geometry>
<mesh>
<uri>table2024.dae</uri>
<scale>1 1 1</scale>
</mesh>
</geometry>
<material>
<lighting>1</lighting>
<script>
<uri>materials/scripts</uri>
<uri>materials/textures</uri>
<name>tableMat/Diffuse</name>
<name>Gazebo/Grey</name>
</script>
<shader type='pixel'/>
</material>
<transparency>0</transparency>
<cast_shadows>1</cast_shadows>
</visual>
<collision name='collision'>
<laser_retro>0</laser_retro>
<max_contacts>10</max_contacts>
<pose>0 0 0 0 -0 0</pose>
<geometry>
<mesh>
<uri>table2024.dae</uri>
<scale>1 1 1</scale>
</mesh>
</geometry>
<surface>
<friction>
<ode>
<mu>1</mu>
<mu2>1</mu2>
<fdir1>0 0 0</fdir1>
<slip1>0</slip1>
<slip2>0</slip2>
</ode>
<torsional>
<coefficient>1</coefficient>
<patch_radius>0</patch_radius>
<surface_radius>0</surface_radius>
<use_patch_radius>1</use_patch_radius>
<ode>
<slip>0</slip>
</ode>
</torsional>
</friction>
<bounce>
<restitution_coefficient>0</restitution_coefficient>
<threshold>1e+06</threshold>
</bounce>
<contact>
<collide_without_contact>0</collide_without_contact>
<collide_without_contact_bitmask>1</collide_without_contact_bitmask>
<collide_bitmask>1</collide_bitmask>
<ode>
<soft_cfm>0</soft_cfm>
<soft_erp>0.2</soft_erp>
<kp>1e+13</kp>
<kd>1</kd>
<max_vel>0.01</max_vel>
<min_depth>0</min_depth>
</ode>
<bullet>
<split_impulse>1</split_impulse>
<split_impulse_penetration_threshold>-0.01</split_impulse_penetration_threshold>
<soft_cfm>0</soft_cfm>
<soft_erp>0.2</soft_erp>
<kp>1e+13</kp>
<kd>1</kd>
</bullet>
</contact>
</surface>
</collision>
</link>
<static>0</static>
<allow_auto_disable>1</allow_auto_disable>
</model>
</sdf>
138 changes: 138 additions & 0 deletions src/ezbot_gazebo/models/Table2024/table2024.dae

Large diffs are not rendered by default.

Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
8 changes: 4 additions & 4 deletions src/ezbot_gazebo/worlds/table2024.world
Original file line number Diff line number Diff line change
Expand Up @@ -61,15 +61,15 @@
<pose>0 0 0 0 -0 0</pose>
<geometry>
<mesh>
<uri>../../../gazebo/Table2024/table2024.dae</uri>
<uri>model://Table2024/table2024.dae</uri>
<scale>1 1 1</scale>
</mesh>
</geometry>
<material>
<lighting>1</lighting>
<script>
<uri>../../../gazebo/Table2024/materials/scripts</uri>
<uri>../../../gazebo/Table2024/materials/textures</uri>
<uri>model://Table2024/materials/scripts</uri>
<uri>model://Table2024/materials/textures</uri>
<name>tableMat/Diffuse</name>
<name>Gazebo/Grey</name>
</script>
Expand All @@ -84,7 +84,7 @@
<pose>0 0 0 0 -0 0</pose>
<geometry>
<mesh>
<uri>../../../gazebo/Table2024/table2024.dae</uri>
<uri>model://Table2024/table2024.dae</uri>
<scale>1 1 1</scale>
</mesh>
</geometry>
Expand Down
Loading

0 comments on commit 7f36031

Please sign in to comment.