Skip to content

Commit 70b5803

Browse files
authored
ur_moveit_config: Do not change default controller when using fake hardware (#1237)
1 parent 3accd7f commit 70b5803

File tree

1 file changed

+1
-12
lines changed

1 file changed

+1
-12
lines changed

ur_moveit_config/launch/ur_moveit.launch.py

Lines changed: 1 addition & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -43,15 +43,13 @@
4343
FindExecutable,
4444
LaunchConfiguration,
4545
PathJoinSubstitution,
46-
OrSubstitution,
4746
)
4847

4948

5049
def launch_setup(context, *args, **kwargs):
5150

5251
# Initialize Arguments
5352
ur_type = LaunchConfiguration("ur_type")
54-
use_fake_hardware = LaunchConfiguration("use_fake_hardware")
5553
safety_limits = LaunchConfiguration("safety_limits")
5654
safety_pos_margin = LaunchConfiguration("safety_pos_margin")
5755
safety_k_position = LaunchConfiguration("safety_k_position")
@@ -179,9 +177,7 @@ def launch_setup(context, *args, **kwargs):
179177
# Trajectory Execution Configuration
180178
controllers_yaml = load_yaml("ur_moveit_config", "config/controllers.yaml")
181179
# the scaled_joint_trajectory_controller does not work on fake hardware
182-
change_controllers = context.perform_substitution(
183-
OrSubstitution(use_fake_hardware, use_sim_time)
184-
)
180+
change_controllers = context.perform_substitution(use_sim_time)
185181
if change_controllers == "true":
186182
controllers_yaml["scaled_joint_trajectory_controller"]["default"] = False
187183
controllers_yaml["joint_trajectory_controller"]["default"] = True
@@ -287,13 +283,6 @@ def generate_launch_description():
287283
choices=["ur3", "ur3e", "ur5", "ur5e", "ur10", "ur10e", "ur16e", "ur20", "ur30"],
288284
)
289285
)
290-
declared_arguments.append(
291-
DeclareLaunchArgument(
292-
"use_fake_hardware",
293-
default_value="false",
294-
description="Indicate whether robot is running with fake hardware mirroring command to its states.",
295-
)
296-
)
297286
declared_arguments.append(
298287
DeclareLaunchArgument(
299288
"safety_limits",

0 commit comments

Comments
 (0)