Skip to content

Commit

Permalink
Added right condition to wibotic_connector_can
Browse files Browse the repository at this point in the history
Signed-off-by: Jakub Delicat <jakub.delicat@husarion.com>
  • Loading branch information
delihus committed Nov 5, 2024
1 parent 6e96685 commit 12ed571
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions panther_docking/launch/docking.launch.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@

from launch import LaunchDescription
from launch.actions import DeclareLaunchArgument, IncludeLaunchDescription
from launch.conditions import IfCondition
from launch.launch_description_sources import PythonLaunchDescriptionSource
from launch.substitutions import (
EnvironmentVariable,
Expand Down Expand Up @@ -62,7 +63,7 @@ def generate_launch_description():
use_wibotic_info = LaunchConfiguration("use_wibotic_info")
declare_use_wibotic_info_arg = DeclareLaunchArgument(
"use_wibotic_info",
default_value="False",
default_value="True",
description="Whether Wibotic information is used",
choices=[True, False, "True", "False", "true", "false", "1", "0"],
)
Expand Down Expand Up @@ -137,7 +138,8 @@ def generate_launch_description():
executable="wibotic_connector_can",
namespace=namespace,
emulate_tty=True,
condition=PythonExpression(["'false' if '", use_sim, "' else '", use_wibotic_info, "'"]),
arguments=["--ros-args", "--log-level", log_level, "--log-level", "rcl:=INFO"],
condition=IfCondition(PythonExpression(["not ", use_sim, " and ", use_wibotic_info])),
)

return LaunchDescription(
Expand Down

0 comments on commit 12ed571

Please sign in to comment.