Skip to content

Commit f16ae2a

Browse files
authored
Port configuration (#835)
Added possibility to change the reverse_port, script_sender_port and trajectory_port
1 parent 3311cf8 commit f16ae2a

File tree

1 file changed

+34
-2
lines changed

1 file changed

+34
-2
lines changed

ur_robot_driver/launch/ur_control.launch.py

Lines changed: 34 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -71,6 +71,9 @@ def launch_setup(context, *args, **kwargs):
7171
tool_voltage = LaunchConfiguration("tool_voltage")
7272
reverse_ip = LaunchConfiguration("reverse_ip")
7373
script_command_port = LaunchConfiguration("script_command_port")
74+
reverse_port = LaunchConfiguration("reverse_port")
75+
script_sender_port = LaunchConfiguration("script_sender_port")
76+
trajectory_port = LaunchConfiguration("trajectory_port")
7477

7578
joint_limit_params = PathJoinSubstitution(
7679
[FindPackageShare(description_package), "config", ur_type, "joint_limits.yaml"]
@@ -181,6 +184,15 @@ def launch_setup(context, *args, **kwargs):
181184
"script_command_port:=",
182185
script_command_port,
183186
" ",
187+
"reverse_port:=",
188+
reverse_port,
189+
" ",
190+
"script_sender_port:=",
191+
script_sender_port,
192+
" ",
193+
"trajectory_port:=",
194+
trajectory_port,
195+
" ",
184196
]
185197
)
186198
robot_description = {"robot_description": robot_description_content}
@@ -576,8 +588,28 @@ def generate_launch_description():
576588
DeclareLaunchArgument(
577589
"script_command_port",
578590
default_value="50004",
579-
description="Port that will be opened to forward script commands from the driver to the robot",
591+
description="Port that will be opened to forward URScript commands to the robot.",
592+
)
593+
)
594+
declared_arguments.append(
595+
DeclareLaunchArgument(
596+
"reverse_port",
597+
default_value="50001",
598+
description="Port that will be opened to send cyclic instructions from the driver to the robot controller.",
599+
)
600+
)
601+
declared_arguments.append(
602+
DeclareLaunchArgument(
603+
"script_sender_port",
604+
default_value="50002",
605+
description="The driver will offer an interface to query the external_control URScript on this port.",
606+
)
607+
)
608+
declared_arguments.append(
609+
DeclareLaunchArgument(
610+
"trajectory_port",
611+
default_value="50003",
612+
description="Port that will be opened for trajectory control.",
580613
)
581614
)
582-
583615
return LaunchDescription(declared_arguments + [OpaqueFunction(function=launch_setup)])

0 commit comments

Comments
 (0)