Skip to content

Commit

Permalink
Add create_own_container argument to ros_gz_spawn_model.launch.py (#622)
Browse files Browse the repository at this point in the history
Signed-off-by: Aarav Gupta <[email protected]>
  • Loading branch information
Amronos authored Oct 25, 2024
1 parent a4d00a9 commit e8a3ec5
Showing 1 changed file with 10 additions and 1 deletion.
11 changes: 10 additions & 1 deletion ros_gz_sim/launch/ros_gz_spawn_model.launch.py
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@ def generate_launch_description():
bridge_name = LaunchConfiguration('bridge_name')
config_file = LaunchConfiguration('config_file')
container_name = LaunchConfiguration('container_name')
create_own_container = LaunchConfiguration('create_own_container')
namespace = LaunchConfiguration('namespace')
use_composition = LaunchConfiguration('use_composition')
use_respawn = LaunchConfiguration('use_respawn')
Expand Down Expand Up @@ -58,12 +59,18 @@ def generate_launch_description():
description='Name of container that nodes will load in if use composition',
)

declare_create_own_container_cmd = DeclareLaunchArgument(
'create_own_container',
default_value='False',
description='Whether we should start a ROS container when using composition.',
)

declare_namespace_cmd = DeclareLaunchArgument(
'namespace', default_value='', description='Top-level namespace'
)

declare_use_composition_cmd = DeclareLaunchArgument(
'use_composition', default_value='True', description='Use composed bringup if True'
'use_composition', default_value='False', description='Use composed bringup if True'
)

declare_use_respawn_cmd = DeclareLaunchArgument(
Expand Down Expand Up @@ -113,6 +120,7 @@ def generate_launch_description():
launch_arguments=[('bridge_name', bridge_name),
('config_file', config_file),
('container_name', container_name),
('create_own_container', create_own_container),
('namespace', namespace),
('use_composition', use_composition),
('use_respawn', use_respawn),
Expand Down Expand Up @@ -143,6 +151,7 @@ def generate_launch_description():
ld.add_action(declare_bridge_name_cmd)
ld.add_action(declare_config_file_cmd)
ld.add_action(declare_container_name_cmd)
ld.add_action(declare_create_own_container_cmd)
ld.add_action(declare_namespace_cmd)
ld.add_action(declare_use_composition_cmd)
ld.add_action(declare_use_respawn_cmd)
Expand Down

0 comments on commit e8a3ec5

Please sign in to comment.