4 from launch
import LaunchDescription
5 from launch.substitutions
import TextSubstitution
6 from launch.substitutions
import LaunchConfiguration
7 from launch_ros.actions
import Node
8 from launch.actions
import DeclareLaunchArgument
9 from ament_index_python
import get_package_share_directory
14 mvsimDir = get_package_share_directory(
"mvsim")
18 world_file_launch_arg = DeclareLaunchArgument(
19 "world_file", default_value=TextSubstitution(
20 text=os.path.join(mvsimDir,
'mvsim_tutorial',
'demo_warehouse.world.xml')))
24 executable=
'mvsim_node',
28 os.path.join(mvsimDir,
'mvsim_tutorial',
29 'mvsim_ros2_params.yaml'),
31 "world_file": LaunchConfiguration(
'world_file'),
41 '-d', [os.path.join(mvsimDir,
'mvsim_tutorial',
'demo_warehouse_ros2.rviz')]]
44 return LaunchDescription([
45 world_file_launch_arg,
def generate_launch_description()