Skip to content

Commit

Permalink
Rajout du spawn de la table dans le launchfile
Browse files Browse the repository at this point in the history
  • Loading branch information
Thiefish committed Dec 22, 2023
1 parent 1109846 commit 720529e
Show file tree
Hide file tree
Showing 2 changed files with 21 additions and 7 deletions.
18 changes: 16 additions & 2 deletions src/ezbot_descr_simul/launch/launch_sim.launch.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,9 @@

from launch import LaunchDescription
from launch.actions import IncludeLaunchDescription
from launch.actions import DeclareLaunchArgument
import launch_ros.actions
from launch.substitutions import LaunchConfiguration
from launch.launch_description_sources import PythonLaunchDescriptionSource

from launch_ros.actions import Node
Expand Down Expand Up @@ -35,14 +38,25 @@ def generate_launch_description():
# Run the spawner node from the gazebo_ros package. The entity name doesn't really matter if you only have a single robot.
spawn_entity = Node(package='gazebo_ros', executable='spawn_entity.py',
arguments=['-topic', 'robot_description',
'-entity', 'EzBot'],
'-entity', 'EzBot',
'-x','1.0',
'-y','-1.0',
'-z', '1.0' ],
output='screen')

#joystick = IncludeLaunchDescription(
# PythonLaunchDescriptionSource([os.path.join(
# get_package_share_directory(package_name),'launch','joystick.launch.py'
# )]), launch_arguments={'use_sim_time': 'true'}.items())


# Launch them all!
return LaunchDescription([
DeclareLaunchArgument(
'world',
default_value=[os.path.join('ezbot_gazebo','worlds','table2024.world'), ''],
description='SDF world file'),
rsp,
gazebo,
spawn_entity,
spawn_entity
])
10 changes: 5 additions & 5 deletions src/ezbot_gazebo/worlds/table2024.world
Original file line number Diff line number Diff line change
Expand Up @@ -56,20 +56,20 @@
<izz>0.166667</izz>
</inertia>
</inertial>
<pose>0 0 0 0 -0 0</pose>
<pose>-1 -1 0 0 -0 0</pose>
<visual name='visual'>
<pose>0 0 0 0 -0 0</pose>
<geometry>
<mesh>
<uri>/home/vincent/ezBot/gazebo/Table2024/table2024.dae</uri>
<uri>../../../gazebo/Table2024/table2024.dae</uri>
<scale>1 1 1</scale>
</mesh>
</geometry>
<material>
<lighting>1</lighting>
<script>
<uri>/home/vincent/ezBot/gazebo/Table2024/materials/scripts</uri>
<uri>/home/vincent/ezBot/gazebo/Table2024/materials/textures</uri>
<uri>../../../gazebo/Table2024/materials/scripts</uri>
<uri>../../../gazebo/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>/home/vincent/ezBot/gazebo/Table2024/table2024.dae</uri>
<uri>../../../gazebo/Table2024/table2024.dae</uri>
<scale>1 1 1</scale>
</mesh>
</geometry>
Expand Down

0 comments on commit 720529e

Please sign in to comment.