Skip to content

Commit

Permalink
Add ROBOT_NAMESPACE env
Browse files Browse the repository at this point in the history
  • Loading branch information
rafal-gorecki committed Oct 3, 2024
1 parent 577a59e commit 8d8d3a1
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
6 changes: 3 additions & 3 deletions joy2twist/launch/gamepad_controller.launch.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,15 +4,15 @@
from launch import LaunchDescription
from launch.actions import DeclareLaunchArgument, IncludeLaunchDescription
from launch.launch_description_sources import PythonLaunchDescriptionSource
from launch.substitutions import LaunchConfiguration, PathJoinSubstitution
from launch.substitutions import EnvironmentVariable, LaunchConfiguration, PathJoinSubstitution


def generate_launch_description():
namespace = LaunchConfiguration("namespace")
declare_namespace_arg = DeclareLaunchArgument(
"namespace",
default_value="",
description="Namespace for all topics and tfs",
default_value=EnvironmentVariable("ROBOT_NAMESPACE", default_value=""),
description="Add namespace to all launched nodes.",
)

joy2twist_cfg_path = PathJoinSubstitution(
Expand Down
6 changes: 3 additions & 3 deletions joy2twist/launch/joy2twist.launch.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,15 +3,15 @@

from launch import LaunchDescription
from launch.actions import DeclareLaunchArgument
from launch.substitutions import LaunchConfiguration, PathJoinSubstitution
from launch.substitutions import EnvironmentVariable, LaunchConfiguration, PathJoinSubstitution


def generate_launch_description():
namespace = LaunchConfiguration("namespace")
declare_namespace_arg = DeclareLaunchArgument(
"namespace",
default_value="",
description="Namespace for all topics and tfs",
default_value=EnvironmentVariable("ROBOT_NAMESPACE", default_value=""),
description="Add namespace to all launched nodes.",
)

joy2twist_cfg_path = PathJoinSubstitution(
Expand Down

0 comments on commit 8d8d3a1

Please sign in to comment.