From cfca4fbc4188324db0521ca18f225aa56f1b278e Mon Sep 17 00:00:00 2001 From: maditavomstein Date: Wed, 22 Jan 2025 15:38:51 +0100 Subject: [PATCH 01/16] renamed update_rate.yaml --- .../config/{update_rate.yaml => ur20_update_rate.yaml} | 0 1 file changed, 0 insertions(+), 0 deletions(-) rename my_robot_cell/my_robot_cell_control/config/{update_rate.yaml => ur20_update_rate.yaml} (100%) diff --git a/my_robot_cell/my_robot_cell_control/config/update_rate.yaml b/my_robot_cell/my_robot_cell_control/config/ur20_update_rate.yaml similarity index 100% rename from my_robot_cell/my_robot_cell_control/config/update_rate.yaml rename to my_robot_cell/my_robot_cell_control/config/ur20_update_rate.yaml From 0c764243c382dab4f335512050377e4f9b78015d Mon Sep 17 00:00:00 2001 From: maditavomstein Date: Wed, 22 Jan 2025 15:52:01 +0100 Subject: [PATCH 02/16] added ur20 in ...control/config because ur_control.launch.py will look for those in runtime_config_package and description_package which is my_robot_cell_control in our case; more ur_types could be added --- .../config/ur20/default_kinematics.yaml | 44 +++++++ .../config/ur20/joint_limits.yaml | 77 +++++++++++ .../config/ur20/physical_parameters.yaml | 122 ++++++++++++++++++ .../config/ur20/visual_parameters.yaml | 97 ++++++++++++++ 4 files changed, 340 insertions(+) create mode 100644 my_robot_cell/my_robot_cell_control/config/ur20/default_kinematics.yaml create mode 100644 my_robot_cell/my_robot_cell_control/config/ur20/joint_limits.yaml create mode 100644 my_robot_cell/my_robot_cell_control/config/ur20/physical_parameters.yaml create mode 100644 my_robot_cell/my_robot_cell_control/config/ur20/visual_parameters.yaml diff --git a/my_robot_cell/my_robot_cell_control/config/ur20/default_kinematics.yaml b/my_robot_cell/my_robot_cell_control/config/ur20/default_kinematics.yaml new file mode 100644 index 0000000..db20fd9 --- /dev/null +++ b/my_robot_cell/my_robot_cell_control/config/ur20/default_kinematics.yaml @@ -0,0 +1,44 @@ +kinematics: + shoulder: + x: 0 + y: 0 + z: 0.23630000000000001 + roll: -0 + pitch: 0 + yaw: -0 + upper_arm: + x: 0 + y: 0 + z: 0 + roll: 1.570796327 + pitch: 0 + yaw: -0 + forearm: + x: -0.86199999999999999 + y: 0 + z: 0 + roll: -0 + pitch: 0 + yaw: -0 + wrist_1: + x: -0.72870000000000001 + y: 0 + z: 0.20100000000000001 + roll: -0 + pitch: 0 + yaw: -0 + wrist_2: + x: 0 + y: -0.1593 + z: -3.2672976162492252e-11 + roll: 1.570796327 + pitch: 0 + yaw: -0 + wrist_3: + x: 0 + y: 0.15429999999999999 + z: -3.1647459019915597e-11 + roll: 1.5707963265897931 + pitch: 3.1415926535897931 + yaw: 3.1415926535897931 + hash: calib_4890363623803256388 diff --git a/my_robot_cell/my_robot_cell_control/config/ur20/joint_limits.yaml b/my_robot_cell/my_robot_cell_control/config/ur20/joint_limits.yaml new file mode 100644 index 0000000..0d4b0fb --- /dev/null +++ b/my_robot_cell/my_robot_cell_control/config/ur20/joint_limits.yaml @@ -0,0 +1,77 @@ +# Joints limits +# +# Sources: +# +# - Universal Robots e-Series, User Manual, UR20, Version 5.14 +# https://s3-eu-west-1.amazonaws.com/ur-support-site/203281/706-276-00_UR20_User_Manual_en_Global.pdf +joint_limits: + shoulder_pan_joint: + # acceleration limits are not publicly available + has_acceleration_limits: false + has_effort_limits: true + has_position_limits: true + has_velocity_limits: true + max_effort: 738.0 + max_position: !degrees 360.0 + max_velocity: !degrees 120.0 + min_position: !degrees -360.0 + shoulder_lift_joint: + # acceleration limits are not publicly available + has_acceleration_limits: false + has_effort_limits: true + has_position_limits: true + has_velocity_limits: true + max_effort: 738.0 + max_position: !degrees 360.0 + max_velocity: !degrees 120.0 + min_position: !degrees -360.0 + elbow_joint: + # acceleration limits are not publicly available + has_acceleration_limits: false + has_effort_limits: true + has_position_limits: true + has_velocity_limits: true + max_effort: 433.0 + # we artificially limit this joint to half its actual joint position limit + # to avoid (MoveIt/OMPL) planning problems, as due to the physical + # construction of the robot, it's impossible to rotate the 'elbow_joint' + # over more than approx +- 1 pi (the shoulder lift joint gets in the way). + # + # This leads to planning problems as the search space will be divided into + # two sections, with no connections from one to the other. + # + # Refer to https://github.com/ros-industrial/universal_robot/issues/265 for + # more information. + max_position: !degrees 180.0 + max_velocity: !degrees 150.0 + min_position: !degrees -180.0 + wrist_1_joint: + # acceleration limits are not publicly available + has_acceleration_limits: false + has_effort_limits: true + has_position_limits: true + has_velocity_limits: true + max_effort: 107.0 + max_position: !degrees 360.0 + max_velocity: !degrees 210.0 + min_position: !degrees -360.0 + wrist_2_joint: + # acceleration limits are not publicly available + has_acceleration_limits: false + has_effort_limits: true + has_position_limits: true + has_velocity_limits: true + max_effort: 107.0 + max_position: !degrees 360.0 + max_velocity: !degrees 210.0 + min_position: !degrees -360.0 + wrist_3_joint: + # acceleration limits are not publicly available + has_acceleration_limits: false + has_effort_limits: true + has_position_limits: true + has_velocity_limits: true + max_effort: 107.0 + max_position: !degrees 360.0 + max_velocity: !degrees 210.0 + min_position: !degrees -360.0 diff --git a/my_robot_cell/my_robot_cell_control/config/ur20/physical_parameters.yaml b/my_robot_cell/my_robot_cell_control/config/ur20/physical_parameters.yaml new file mode 100644 index 0000000..71e7314 --- /dev/null +++ b/my_robot_cell/my_robot_cell_control/config/ur20/physical_parameters.yaml @@ -0,0 +1,122 @@ +# Physical parameters + +offsets: + shoulder_offset: 0.260 # measured from model + elbow_offset: 0.043 # measured from model + +inertia_parameters: + # taken from https://www.universal-robots.com/articles/ur/application-installation/dh-parameters-for-calculations-of-kinematics-and-dynamics/ + base_mass: 4.0 # This mass might be incorrect + shoulder_mass: 16.343 + upper_arm_mass: 29.632 + forearm_mass: 7.879 + wrist_1_mass: 3.054 + wrist_2_mass: 3.126 + wrist_3_mass: 0.926 + + shoulder_radius: x0.060 # FROM UR5 CURRENTLY NOT USED ANYMORE + upper_arm_radius: x0.054 # FROM UR5 CURRENTLY NOT USED ANYMORE + elbow_radius: x0.060 # FROM UR5 CURRENTLY NOT USED ANYMORE + forearm_radius: x0.040 # FROM UR5 CURRENTLY NOT USED ANYMORE + wrist_radius: x0.045 # FROM UR5 CURRENTLY NOT USED ANYMORE + + links: + base: + radius: 0.075 + length: 0.038 + + center_of_mass: + shoulder_cog: + x: 0.0 # model.x + y: -0.0062 # -model.z + z: -0.061 # model.y + upper_arm_cog: + x: -0.3394 # model.x - upperarm_length + y: 0.0 # model.y + z: 0.2098 # model.z + forearm_cog: + x: -0.4053 # model.x - forearm_length + y: 0.0 # model.y + z: 0.0604 # model.z + wrist_1_cog: + x: 0.0 # model.x + y: -0.0393 # -model.z + z: -0.0026 # model.y + wrist_2_cog: + x: 0.0 # model.x + y: 0.0379 # model.z + z: -0.0024 # -model.y + wrist_3_cog: + x: 0.0 # model.x + y: 0.0 # model.y + z: -0.0293 # model.z + + rotation: + shoulder: + roll: 1.570796326794897 + pitch: 0 + yaw: 0 + upper_arm: + roll: 0 + pitch: 0 + yaw: 0 + forearm: + roll: 0 + pitch: 0 + yaw: 0 + wrist_1: + roll: 1.570796326794897 + pitch: 0 + yaw: 0 + wrist_2: + roll: -1.570796326794897 + pitch: 0 + yaw: 0 + wrist_3: + roll: 0 + pitch: 0 + yaw: 0 + + tensor: + shoulder: + ixx: 0.08866 + ixy: -0.00011 + ixz: -0.00011 + iyy: 0.07632 + iyz: 0.00720 + izz: 0.08418 + upper_arm: + ixx: 0.14670 + ixy: 0.00019 + ixz: -0.05163 + iyy: 4.66590 + iyz: 0.00004 + izz: 4.63480 + forearm: + ixx: 0.02612 + ixy: -0.00005 + ixz: -0.02898 + iyy: 0.75763 + iyz: -0.00001 + izz: 0.75327 + wrist_1: + ixx: 0.00555 + ixy: -0.00001 + ixz: -0.00002 + iyy: 0.00537 + iyz: 0.00036 + izz: 0.00402 + wrist_2: + ixx: 0.00586 + ixy: -0.00001 + ixz: -0.00002 + iyy: 0.00578 + iyz: -0.00037 + izz: 0.00427 + wrist_3: + ixx: 0.00092 + ixy: 0.0 + ixz: 0.0 + iyy: 0.00091 + iyz: 0.0 + izz: 0.00117 diff --git a/my_robot_cell/my_robot_cell_control/config/ur20/visual_parameters.yaml b/my_robot_cell/my_robot_cell_control/config/ur20/visual_parameters.yaml new file mode 100644 index 0000000..8e896dd --- /dev/null +++ b/my_robot_cell/my_robot_cell_control/config/ur20/visual_parameters.yaml @@ -0,0 +1,97 @@ +# Visualisation + +mesh_files: + base: + visual: + mesh: + package: ur_description + path: meshes/ur20/visual/base.dae + material: + name: "LightGrey" + color: "0.7 0.7 0.7 1.0" + collision: + mesh: + package: ur_description + path: meshes/ur20/collision/base.stl + + shoulder: + visual: + mesh: + package: ur_description + path: meshes/ur20/visual/shoulder.dae + material: + name: "LightGrey" + color: "0.7 0.7 0.7 1.0" + collision: + mesh: + package: ur_description + path: meshes/ur20/collision/shoulder.stl + + upper_arm: + visual: + mesh: + package: ur_description + path: meshes/ur20/visual/upperarm.dae + material: + name: "LightGrey" + color: "0.7 0.7 0.7 1.0" + collision: + mesh: + package: ur_description + path: meshes/ur20/collision/upperarm.stl + mesh_files: + + forearm: + visual: + mesh: + package: ur_description + path: meshes/ur20/visual/forearm.dae + material: + name: "LightGrey" + color: "0.7 0.7 0.7 1.0" + collision: + mesh: + package: ur_description + path: meshes/ur20/collision/forearm.stl + + wrist_1: + visual: + mesh: + package: ur_description + path: meshes/ur20/visual/wrist1.dae + material: + name: "LightGrey" + color: "0.7 0.7 0.7 1.0" + collision: + mesh: + package: ur_description + path: meshes/ur20/collision/wrist1.stl + visual_offset: -0.0775 + + wrist_2: + visual: + mesh: + package: ur_description + path: meshes/ur20/visual/wrist2.dae + material: + name: "LightGrey" + color: "0.7 0.7 0.7 1.0" + collision: + mesh: + package: ur_description + path: meshes/ur20/collision/wrist2.stl + visual_offset: -0.0749 + + wrist_3: + visual: + mesh: + package: ur_description + path: meshes/ur20/visual/wrist3.dae + material: + name: "LightGrey" + color: "0.7 0.7 0.7 1.0" + collision: + mesh: + package: ur_description + path: meshes/ur20/collision/wrist3.stl + visual_offset: -0.07 From 2f314698ebdb90af600a1a987d793724929e8457 Mon Sep 17 00:00:00 2001 From: maditavomstein Date: Wed, 22 Jan 2025 16:03:01 +0100 Subject: [PATCH 03/16] changed launch files according to ur_driver, ur_Description and ros2 humble (all installed via apt) --- .../launch/rsp.launch.py | 161 ----------------- .../launch/start_robot.launch.py | 164 +++++++++++++----- 2 files changed, 119 insertions(+), 206 deletions(-) delete mode 100644 my_robot_cell/my_robot_cell_control/launch/rsp.launch.py diff --git a/my_robot_cell/my_robot_cell_control/launch/rsp.launch.py b/my_robot_cell/my_robot_cell_control/launch/rsp.launch.py deleted file mode 100644 index 59823a2..0000000 --- a/my_robot_cell/my_robot_cell_control/launch/rsp.launch.py +++ /dev/null @@ -1,161 +0,0 @@ -# Copyright (c) 2024 FZI Forschungszentrum Informatik -# -# Redistribution and use in source and binary forms, with or without -# modification, are permitted provided that the following conditions are met: -# -# * Redistributions of source code must retain the above copyright -# notice, this list of conditions and the following disclaimer. -# -# * Redistributions in binary form must reproduce the above copyright -# notice, this list of conditions and the following disclaimer in the -# documentation and/or other materials provided with the distribution. -# -# * Neither the name of the {copyright_holder} nor the names of its -# contributors may be used to endorse or promote products derived from -# this software without specific prior written permission. -# -# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" -# AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE -# IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE -# ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE -# LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR -# CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF -# SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS -# INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN -# CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) -# ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE -# POSSIBILITY OF SUCH DAMAGE. - -# -# Author: Felix Exner - -from launch_ros.actions import Node -from launch_ros.substitutions import FindPackageShare - -from launch import LaunchDescription -from launch.actions import DeclareLaunchArgument -from launch.substitutions import ( - Command, - FindExecutable, - LaunchConfiguration, - PathJoinSubstitution, -) - - -def generate_launch_description(): - ur_type = LaunchConfiguration("ur_type") - robot_ip = LaunchConfiguration("robot_ip") - - use_mock_hardware = LaunchConfiguration("use_mock_hardware") - mock_sensor_commands = LaunchConfiguration("mock_sensor_commands") - - headless_mode = LaunchConfiguration("headless_mode") - - kinematics_parameters_file = LaunchConfiguration("kinematics_parameters_file") - - # Load description with necessary parameters - robot_description_content = Command( - [ - PathJoinSubstitution([FindExecutable(name="xacro")]), - " ", - PathJoinSubstitution( - [ - FindPackageShare("my_robot_cell_control"), - "urdf", - "my_robot_cell_controlled.urdf.xacro", - ] - ), - " ", - "robot_ip:=", - robot_ip, - " ", - "ur_type:=", - ur_type, - " ", - "kinematics_parameters_file:=", - kinematics_parameters_file, - " ", - "use_mock_hardware:=", - use_mock_hardware, - " ", - "mock_sensor_commands:=", - mock_sensor_commands, - " ", - "headless_mode:=", - headless_mode, - ] - ) - robot_description = {"robot_description": robot_description_content} - - declared_arguments = [] - # UR specific arguments - declared_arguments.append( - DeclareLaunchArgument( - "ur_type", - description="Typo/series of used UR robot.", - choices=[ - "ur3", - "ur3e", - "ur5", - "ur5e", - "ur10", - "ur10e", - "ur16e", - "ur20", - "ur30", - ], - default_value="ur20", - ) - ) - declared_arguments.append( - DeclareLaunchArgument( - "robot_ip", description="IP address by which the robot can be reached." - ) - ) - declared_arguments.append( - DeclareLaunchArgument( - "kinematics_parameters_file", - default_value=PathJoinSubstitution( - [ - FindPackageShare("my_robot_cell_control"), - "config", - "my_robot_calibration.yaml", - ] - ), - description="The calibration configuration of the actual robot used.", - ) - ) - declared_arguments.append( - DeclareLaunchArgument( - "use_mock_hardware", - default_value="false", - description="Start robot with mock hardware mirroring command to its states.", - ) - ) - declared_arguments.append( - DeclareLaunchArgument( - "mock_sensor_commands", - default_value="false", - description="Enable mock command interfaces for sensors used for simple simulations. " - "Used only if 'use_mock_hardware' parameter is true.", - ) - ) - declared_arguments.append( - DeclareLaunchArgument( - "headless_mode", - default_value="false", - description="Enable headless mode for robot control", - ) - ) - - return LaunchDescription( - declared_arguments - + [ - Node( - package="robot_state_publisher", - executable="robot_state_publisher", - output="both", - parameters=[robot_description], - ), - ] - ) diff --git a/my_robot_cell/my_robot_cell_control/launch/start_robot.launch.py b/my_robot_cell/my_robot_cell_control/launch/start_robot.launch.py index 9da26ae..4762952 100644 --- a/my_robot_cell/my_robot_cell_control/launch/start_robot.launch.py +++ b/my_robot_cell/my_robot_cell_control/launch/start_robot.launch.py @@ -1,23 +1,15 @@ -from launch_ros.actions import Node -from launch_ros.parameter_descriptions import ParameterFile from launch_ros.substitutions import FindPackageShare - from launch import LaunchDescription from launch.actions import DeclareLaunchArgument, IncludeLaunchDescription from launch.launch_description_sources import PythonLaunchDescriptionSource -from launch.conditions import IfCondition from launch.substitutions import ( - Command, - FindExecutable, LaunchConfiguration, PathJoinSubstitution, - TextSubstitution, ) def generate_launch_description(): - ur_type = LaunchConfiguration("ur_type") - robot_ip = LaunchConfiguration("robot_ip") + # declare arguments declared_arguments = [] declared_arguments.append( DeclareLaunchArgument( @@ -47,41 +39,123 @@ def generate_launch_description(): declared_arguments.append( DeclareLaunchArgument("launch_rviz", default_value="true", description="Launch RViz?") ) - - return LaunchDescription( - declared_arguments - + [ - IncludeLaunchDescription( - PythonLaunchDescriptionSource( - [ - PathJoinSubstitution( - [ - FindPackageShare("ur_robot_driver"), - "launch", - "ur_control.launch.py", - ] - ) - ] - ), - launch_arguments={ - "ur_type": ur_type, - "robot_ip": robot_ip, - "tf_prefix": [LaunchConfiguration("ur_type"), "_"], - "rviz_config_file": PathJoinSubstitution( - [ - FindPackageShare("my_robot_cell_description"), - "rviz", - "urdf.rviz", - ] - ), - "description_launchfile": PathJoinSubstitution( - [ - FindPackageShare("my_robot_cell_control"), - "launch", - "rsp.launch.py", - ] - ), - }.items(), + declared_arguments.append( + DeclareLaunchArgument( + "use_fake_hardware", + default_value="false", + description="Start robot with fake hardware mirroring command to its states.", + ) + ) + declared_arguments.append( + DeclareLaunchArgument( + "fake_sensor_commands", + default_value="false", + description="Enable fake command interfaces for sensors used for simple simulations. " + "Used only if 'use_fake_hardware' parameter is true.", + ) + ) + declared_arguments.append( + DeclareLaunchArgument( + "runtime_config_package", + default_value="my_robot_cell_control", + description="package in which .yaml are", + ) + ) + declared_arguments.append( + DeclareLaunchArgument( + "controllers_file", + default_value="controllers_editable.yaml", + description="name of controllers .yaml", + ) + ) + declared_arguments.append( + DeclareLaunchArgument( + "description_package", + default_value="my_robot_cell_control", + description="description package", + ) + ) + declared_arguments.append( + DeclareLaunchArgument( + "description_file", + default_value="my_robot_cell_controlled.urdf.xacro", + description="URDF/XACRO description file with the robot.", + ) + ) + declared_arguments.append( + DeclareLaunchArgument( + "kinematics_params_file", + default_value=PathJoinSubstitution( + [ + FindPackageShare(LaunchConfiguration("runtime_config_package")), + "config", + "my_robot_calibration.yaml", + ] ), - ] + description="The calibration configuration of the actual robot used.", + ) ) + declared_arguments.append( + DeclareLaunchArgument( + "initial_joint_controller", + default_value="scaled_joint_trajectory_controller", + description="Initially loaded robot controller.", + choices=[ + "scaled_joint_trajectory_controller", + "joint_trajectory_controller", + "forward_velocity_controller", + "forward_position_controller", + ], + ) + ) + declared_arguments.append( + DeclareLaunchArgument( + "activate_joint_controller", + default_value="true", + description="Activate loaded joint controller.", + ) + ) + declared_arguments.append( + DeclareLaunchArgument( + "headless_mode", + default_value="false", + description="Enable headless mode for robot control", + ) + ) + + # initialize arguments + ur_type = LaunchConfiguration("ur_type") + robot_ip = LaunchConfiguration("robot_ip") + launch_rviz = LaunchConfiguration("launch_rviz") + use_fake_hardware = LaunchConfiguration("use_fake_hardware") + fake_sensor_commands = LaunchConfiguration("fake_sensor_commands") + runtime_config_package = LaunchConfiguration("runtime_config_package") + controllers_file = LaunchConfiguration("controllers_file") + description_package = LaunchConfiguration("description_package") + description_file = LaunchConfiguration("description_file") + kinematics_params_file = LaunchConfiguration("kinematics_params_file") + initial_joint_controller = LaunchConfiguration("initial_joint_controller") + activate_joint_controller = LaunchConfiguration("activate_joint_controller") + headless_mode = LaunchConfiguration("headless_mode") + + base_launch = IncludeLaunchDescription( + PythonLaunchDescriptionSource([PathJoinSubstitution([FindPackageShare("ur_robot_driver"),"launch"]), "/ur_control.launch.py"]), + launch_arguments={ + "ur_type": ur_type, + "robot_ip": robot_ip, + "tf_prefix": [LaunchConfiguration("ur_type"), "_"], + "launch_rviz": launch_rviz, + "use_fake_hardware": use_fake_hardware, + "fake_sensor_commands": fake_sensor_commands, + "runtime_config_package": runtime_config_package, + "controllers_file": controllers_file, + "description_package": description_package, + "description_file": description_file, + "kinematics_params_file": kinematics_params_file, + "initial_joint_controller": initial_joint_controller, + "activate_joint_controller": activate_joint_controller, + "headless_mode": headless_mode, + }.items(), + ) + + return LaunchDescription(declared_arguments + [base_launch]) From 961b712b2f34327fc006cc002fa66d21b4e0e05c Mon Sep 17 00:00:00 2001 From: maditavomstein Date: Wed, 22 Jan 2025 17:25:35 +0100 Subject: [PATCH 04/16] adaptions for humble --- README.md | 3 +- .../my_robot_cell_control/CMakeLists.txt | 3 +- .../config/ros2_controllers.yaml | 6 + .../launch/start_robot.launch.py | 2 +- .../my_robot_cell_control/package.xml | 3 +- .../my_robot_cell_control/rviz/urdf.rviz | 257 ++++++++++++++++++ .../urdf/my_robot_cell_controlled.urdf.xacro | 30 +- .../urdf/my_robot_cell_macro.xacro | 1 + 8 files changed, 287 insertions(+), 18 deletions(-) create mode 100644 my_robot_cell/my_robot_cell_control/rviz/urdf.rviz diff --git a/README.md b/README.md index b92ed51..fc12458 100644 --- a/README.md +++ b/README.md @@ -3,8 +3,7 @@ This package contains tutorials around the ROS 2 packages for Universal Robots. ## Getting started To use the tutorials from this repository, please make sure to [install ROS -2](https://docs.ros.org/en/rolling/Installation.html) on your system. Currently, only ROS Jazzy and -Rolling are supported. +2](https://docs.ros.org/en/humble/Installation.html) on your system. With that, please create a workspace, clone this repo into the workspace, install the dependencies and build the workspace. diff --git a/my_robot_cell/my_robot_cell_control/CMakeLists.txt b/my_robot_cell/my_robot_cell_control/CMakeLists.txt index 05ab80e..cb6120d 100644 --- a/my_robot_cell/my_robot_cell_control/CMakeLists.txt +++ b/my_robot_cell/my_robot_cell_control/CMakeLists.txt @@ -2,9 +2,10 @@ cmake_minimum_required(VERSION 3.8) project(my_robot_cell_control) find_package(ament_cmake REQUIRED) +find_package(rclcpp REQUIRED) install( - DIRECTORY launch config urdf + DIRECTORY launch config urdf rviz DESTINATION share/${PROJECT_NAME} ) diff --git a/my_robot_cell/my_robot_cell_control/config/ros2_controllers.yaml b/my_robot_cell/my_robot_cell_control/config/ros2_controllers.yaml index edd5e3f..05faf10 100644 --- a/my_robot_cell/my_robot_cell_control/config/ros2_controllers.yaml +++ b/my_robot_cell/my_robot_cell_control/config/ros2_controllers.yaml @@ -21,6 +21,12 @@ controller_manager: forward_position_controller: type: position_controllers/JointGroupPositionController + ur_configuration_controller: + type: ur_controllers/URConfigurationController + +ur_configuration_controller: + ros__parameters: + tf_prefix: "ur20_" speed_scaling_state_broadcaster: ros__parameters: diff --git a/my_robot_cell/my_robot_cell_control/launch/start_robot.launch.py b/my_robot_cell/my_robot_cell_control/launch/start_robot.launch.py index 4762952..7faa243 100644 --- a/my_robot_cell/my_robot_cell_control/launch/start_robot.launch.py +++ b/my_robot_cell/my_robot_cell_control/launch/start_robot.launch.py @@ -64,7 +64,7 @@ def generate_launch_description(): declared_arguments.append( DeclareLaunchArgument( "controllers_file", - default_value="controllers_editable.yaml", + default_value="ros2_controllers.yaml", description="name of controllers .yaml", ) ) diff --git a/my_robot_cell/my_robot_cell_control/package.xml b/my_robot_cell/my_robot_cell_control/package.xml index af4c00b..059a0c0 100644 --- a/my_robot_cell/my_robot_cell_control/package.xml +++ b/my_robot_cell/my_robot_cell_control/package.xml @@ -8,8 +8,9 @@ BSD-3-Clause ament_cmake + rclcpp - + rclcpp joint_state_broadcaster joint_trajectory_controller position_controllers diff --git a/my_robot_cell/my_robot_cell_control/rviz/urdf.rviz b/my_robot_cell/my_robot_cell_control/rviz/urdf.rviz new file mode 100644 index 0000000..e6b74d0 --- /dev/null +++ b/my_robot_cell/my_robot_cell_control/rviz/urdf.rviz @@ -0,0 +1,257 @@ +Panels: + - Class: rviz_common/Displays + Help Height: 87 + Name: Displays + Property Tree Widget: + Expanded: + - /RobotModel1 + - /TF1 + - /TF1/Tree1 + Splitter Ratio: 0.5 + Tree Height: 637 + - Class: rviz_common/Views + Expanded: + - /Current View1 + Name: Views + Splitter Ratio: 0.5 +Visualization Manager: + Class: "" + Displays: + - Alpha: 0.5 + Cell Size: 1 + Class: rviz_default_plugins/Grid + Color: 160; 160; 164 + Enabled: true + Line Style: + Line Width: 0.029999999329447746 + Value: Lines + Name: Grid + Normal Cell Count: 0 + Offset: + X: 0 + Y: 0 + Z: 0 + Plane: XY + Plane Cell Count: 10 + Reference Frame: + Value: true + - Alpha: 1 + Class: rviz_default_plugins/RobotModel + Collision Enabled: false + Description File: "" + Description Source: Topic + Description Topic: + Depth: 5 + Durability Policy: Volatile + History Policy: Keep Last + Reliability Policy: Reliable + Value: /robot_description + Enabled: true + Links: + All Links Enabled: true + Expand Joint Details: false + Expand Link Details: false + Expand Tree: false + Link Tree Style: Links in Alphabetic Order + monitor: + Alpha: 1 + Show Axes: false + Show Trail: false + Value: true + robot_mount: + Alpha: 1 + Show Axes: false + Show Trail: false + table: + Alpha: 1 + Show Axes: false + Show Trail: false + Value: true + ur20_base: + Alpha: 1 + Show Axes: false + Show Trail: false + ur20_base_link: + Alpha: 1 + Show Axes: false + Show Trail: false + ur20_base_link_inertia: + Alpha: 1 + Show Axes: false + Show Trail: false + Value: true + ur20_flange: + Alpha: 1 + Show Axes: false + Show Trail: false + ur20_forearm_link: + Alpha: 1 + Show Axes: false + Show Trail: false + Value: true + ur20_ft_frame: + Alpha: 1 + Show Axes: false + Show Trail: false + ur20_shoulder_link: + Alpha: 1 + Show Axes: false + Show Trail: false + Value: true + ur20_tool0: + Alpha: 1 + Show Axes: false + Show Trail: false + ur20_upper_arm_link: + Alpha: 1 + Show Axes: false + Show Trail: false + Value: true + ur20_wrist_1_link: + Alpha: 1 + Show Axes: false + Show Trail: false + Value: true + ur20_wrist_2_link: + Alpha: 1 + Show Axes: false + Show Trail: false + Value: true + ur20_wrist_3_link: + Alpha: 1 + Show Axes: false + Show Trail: false + Value: true + wall: + Alpha: 1 + Show Axes: false + Show Trail: false + Value: true + world: + Alpha: 1 + Show Axes: false + Show Trail: false + Mass Properties: + Inertia: false + Mass: false + Name: RobotModel + TF Prefix: "" + Update Interval: 0 + Value: true + Visual Enabled: true + - Class: rviz_default_plugins/TF + Enabled: true + Frame Timeout: 15 + Frames: + All Enabled: true + monitor: + Value: true + robot_mount: + Value: true + table: + Value: true + ur20_base: + Value: true + ur20_base_link: + Value: true + ur20_base_link_inertia: + Value: true + ur20_flange: + Value: true + ur20_forearm_link: + Value: true + ur20_ft_frame: + Value: true + ur20_shoulder_link: + Value: true + ur20_tool0: + Value: true + ur20_upper_arm_link: + Value: true + ur20_wrist_1_link: + Value: true + ur20_wrist_2_link: + Value: true + ur20_wrist_3_link: + Value: true + wall: + Value: true + world: + Value: true + Marker Scale: 1 + Name: TF + Show Arrows: true + Show Axes: true + Show Names: false + Tree: + world: + table: + monitor: + {} + robot_mount: + ur20_base_link: + ur20_base: + {} + ur20_base_link_inertia: + ur20_shoulder_link: + ur20_upper_arm_link: + ur20_forearm_link: + ur20_wrist_1_link: + ur20_wrist_2_link: + ur20_wrist_3_link: + ur20_flange: + ur20_tool0: + {} + ur20_ft_frame: + {} + wall: + {} + Update Interval: 0 + Value: true + Enabled: true + Global Options: + Background Color: 48; 48; 48 + Fixed Frame: world + Frame Rate: 30 + Name: root + Tools: + - Class: rviz_default_plugins/MoveCamera + Transformation: + Current: + Class: rviz_default_plugins/TF + Value: true + Views: + Current: + Class: rviz_default_plugins/Orbit + Distance: 4.839867115020752 + Enable Stereo Rendering: + Stereo Eye Separation: 0.05999999865889549 + Stereo Focal Distance: 1 + Swap Stereo Eyes: false + Value: false + Focal Point: + X: 0.8393054604530334 + Y: 0.6853293776512146 + Z: 1.452785611152649 + Focal Shape Fixed Size: true + Focal Shape Size: 0.05000000074505806 + Invert Z Axis: false + Name: Current View + Near Clip Distance: 0.009999999776482582 + Pitch: 0.16000038385391235 + Target Frame: + Value: Orbit (rviz) + Yaw: 4.324998378753662 + Saved: ~ +Window Geometry: + Displays: + collapsed: false + Height: 1412 + Hide Left Dock: false + Hide Right Dock: false + QMainWindow State: 000000ff00000000fd0000000100000000000001ad0000052efc0200000002fb000000100044006900730070006c006100790073010000003b0000030f000000c700fffffffb0000000a00560069006500770073010000035000000219000000a000ffffff0000084d0000052e00000004000000040000000800000008fc0000000100000002000000010000000a0054006f006f006c00730100000000ffffffff0000000000000000 + Views: + collapsed: false + Width: 2560 + X: 1920 + Y: 0 diff --git a/my_robot_cell/my_robot_cell_control/urdf/my_robot_cell_controlled.urdf.xacro b/my_robot_cell/my_robot_cell_control/urdf/my_robot_cell_controlled.urdf.xacro index d55fa1d..e2e914a 100644 --- a/my_robot_cell/my_robot_cell_control/urdf/my_robot_cell_controlled.urdf.xacro +++ b/my_robot_cell/my_robot_cell_control/urdf/my_robot_cell_controlled.urdf.xacro @@ -3,23 +3,27 @@ - - + + + + - - - - + + + + - - + + + + @@ -27,8 +31,8 @@ @@ -39,13 +43,13 @@ diff --git a/my_robot_cell/my_robot_cell_description/urdf/my_robot_cell_macro.xacro b/my_robot_cell/my_robot_cell_description/urdf/my_robot_cell_macro.xacro index 5681339..0d9ac63 100644 --- a/my_robot_cell/my_robot_cell_description/urdf/my_robot_cell_macro.xacro +++ b/my_robot_cell/my_robot_cell_description/urdf/my_robot_cell_macro.xacro @@ -89,6 +89,7 @@ kinematics_parameters_file="${kinematics_parameters_file}" physical_parameters_file="${physical_parameters_file}" visual_parameters_file="${visual_parameters_file}" + generate_ros2_control_tag="false" > From 2139e1dfcf8ad49bee05919aa1f9db468a6dac67 Mon Sep 17 00:00:00 2001 From: maditavomstein Date: Mon, 27 Jan 2025 14:25:01 +0100 Subject: [PATCH 05/16] added controller and changed rviz file name --- .../config/ros2_controllers.yaml | 30 +++++++++++++++++++ .../rviz/{urdf.rviz => view_robot.rviz} | 0 2 files changed, 30 insertions(+) rename my_robot_cell/my_robot_cell_control/rviz/{urdf.rviz => view_robot.rviz} (100%) diff --git a/my_robot_cell/my_robot_cell_control/config/ros2_controllers.yaml b/my_robot_cell/my_robot_cell_control/config/ros2_controllers.yaml index 05faf10..a925d05 100644 --- a/my_robot_cell/my_robot_cell_control/config/ros2_controllers.yaml +++ b/my_robot_cell/my_robot_cell_control/config/ros2_controllers.yaml @@ -24,6 +24,9 @@ controller_manager: ur_configuration_controller: type: ur_controllers/URConfigurationController + joint_trajectory_controller: + type: joint_trajectory_controller/JointTrajectoryController + ur_configuration_controller: ros__parameters: tf_prefix: "ur20_" @@ -98,3 +101,30 @@ forward_position_controller: - ur20_wrist_1_joint - ur20_wrist_2_joint - ur20_wrist_3_joint + +joint_trajectory_controller: + ros__parameters: + joints: + - ur20_shoulder_pan_joint + - ur20_shoulder_lift_joint + - ur20_elbow_joint + - ur20_wrist_1_joint + - ur20_wrist_2_joint + - ur20_wrist_3_joint + command_interfaces: + - position + state_interfaces: + - position + - velocity + state_publish_rate: 100.0 + action_monitor_rate: 20.0 + allow_partial_joints_goal: false + constraints: + stopped_velocity_tolerance: 0.2 + goal_time: 0.0 + ur20_shoulder_pan_joint: { trajectory: 0.2, goal: 0.1 } + ur20_shoulder_lift_joint: { trajectory: 0.2, goal: 0.1 } + ur20_elbow_joint: { trajectory: 0.2, goal: 0.1 } + ur20_wrist_1_joint: { trajectory: 0.2, goal: 0.1 } + ur20_wrist_2_joint: { trajectory: 0.2, goal: 0.1 } + ur20_wrist_3_joint: { trajectory: 0.2, goal: 0.1 } diff --git a/my_robot_cell/my_robot_cell_control/rviz/urdf.rviz b/my_robot_cell/my_robot_cell_control/rviz/view_robot.rviz similarity index 100% rename from my_robot_cell/my_robot_cell_control/rviz/urdf.rviz rename to my_robot_cell/my_robot_cell_control/rviz/view_robot.rviz From b2e11c8b902cd1812de08a78054494057872ecf1 Mon Sep 17 00:00:00 2001 From: maditavomstein Date: Mon, 27 Jan 2025 14:32:52 +0100 Subject: [PATCH 06/16] removed controller --- .../config/ros2_controllers.yaml | 30 ------------------- 1 file changed, 30 deletions(-) diff --git a/my_robot_cell/my_robot_cell_control/config/ros2_controllers.yaml b/my_robot_cell/my_robot_cell_control/config/ros2_controllers.yaml index a925d05..05faf10 100644 --- a/my_robot_cell/my_robot_cell_control/config/ros2_controllers.yaml +++ b/my_robot_cell/my_robot_cell_control/config/ros2_controllers.yaml @@ -24,9 +24,6 @@ controller_manager: ur_configuration_controller: type: ur_controllers/URConfigurationController - joint_trajectory_controller: - type: joint_trajectory_controller/JointTrajectoryController - ur_configuration_controller: ros__parameters: tf_prefix: "ur20_" @@ -101,30 +98,3 @@ forward_position_controller: - ur20_wrist_1_joint - ur20_wrist_2_joint - ur20_wrist_3_joint - -joint_trajectory_controller: - ros__parameters: - joints: - - ur20_shoulder_pan_joint - - ur20_shoulder_lift_joint - - ur20_elbow_joint - - ur20_wrist_1_joint - - ur20_wrist_2_joint - - ur20_wrist_3_joint - command_interfaces: - - position - state_interfaces: - - position - - velocity - state_publish_rate: 100.0 - action_monitor_rate: 20.0 - allow_partial_joints_goal: false - constraints: - stopped_velocity_tolerance: 0.2 - goal_time: 0.0 - ur20_shoulder_pan_joint: { trajectory: 0.2, goal: 0.1 } - ur20_shoulder_lift_joint: { trajectory: 0.2, goal: 0.1 } - ur20_elbow_joint: { trajectory: 0.2, goal: 0.1 } - ur20_wrist_1_joint: { trajectory: 0.2, goal: 0.1 } - ur20_wrist_2_joint: { trajectory: 0.2, goal: 0.1 } - ur20_wrist_3_joint: { trajectory: 0.2, goal: 0.1 } From 98f8579c20b895dba7c5fc1c7488639d63477193 Mon Sep 17 00:00:00 2001 From: maditavomstein Date: Wed, 5 Feb 2025 17:07:04 +0100 Subject: [PATCH 07/16] removed rclcpp --- my_robot_cell/my_robot_cell_control/CMakeLists.txt | 1 - my_robot_cell/my_robot_cell_control/package.xml | 2 -- 2 files changed, 3 deletions(-) diff --git a/my_robot_cell/my_robot_cell_control/CMakeLists.txt b/my_robot_cell/my_robot_cell_control/CMakeLists.txt index cb6120d..e218b1c 100644 --- a/my_robot_cell/my_robot_cell_control/CMakeLists.txt +++ b/my_robot_cell/my_robot_cell_control/CMakeLists.txt @@ -2,7 +2,6 @@ cmake_minimum_required(VERSION 3.8) project(my_robot_cell_control) find_package(ament_cmake REQUIRED) -find_package(rclcpp REQUIRED) install( DIRECTORY launch config urdf rviz diff --git a/my_robot_cell/my_robot_cell_control/package.xml b/my_robot_cell/my_robot_cell_control/package.xml index 059a0c0..5c70cfe 100644 --- a/my_robot_cell/my_robot_cell_control/package.xml +++ b/my_robot_cell/my_robot_cell_control/package.xml @@ -8,9 +8,7 @@ BSD-3-Clause ament_cmake - rclcpp - rclcpp joint_state_broadcaster joint_trajectory_controller position_controllers From beef7179c01e78ec0d191e1dc09a7ce3b665ee78 Mon Sep 17 00:00:00 2001 From: maditavomstein Date: Thu, 6 Feb 2025 11:27:47 +0100 Subject: [PATCH 08/16] changed xacro:arg name for kinematics_params, physical_params and visual_params to make it match the arguments handed over by ur_control.launch.py // otherwise default values were used --- .../urdf/my_robot_cell_controlled.urdf.xacro | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-) diff --git a/my_robot_cell/my_robot_cell_control/urdf/my_robot_cell_controlled.urdf.xacro b/my_robot_cell/my_robot_cell_control/urdf/my_robot_cell_controlled.urdf.xacro index e2e914a..43a0e4d 100644 --- a/my_robot_cell/my_robot_cell_control/urdf/my_robot_cell_controlled.urdf.xacro +++ b/my_robot_cell/my_robot_cell_control/urdf/my_robot_cell_controlled.urdf.xacro @@ -11,9 +11,9 @@ - - - + + + @@ -25,6 +25,7 @@ + @@ -32,13 +33,14 @@ parent="world" ur_type="$(arg ur_type)" joint_limits_parameters_file="$(arg joint_limit_params)" - kinematics_parameters_file="$(arg kinematics_params_file)" - physical_parameters_file="$(arg physical_parameters_file)" - visual_parameters_file="$(arg visual_parameters_file)" + kinematics_parameters_file="$(arg kinematics_params)" + physical_parameters_file="$(arg physical_params)" + visual_parameters_file="$(arg visual_params)" > + Date: Sun, 9 Feb 2025 14:05:39 +0100 Subject: [PATCH 09/16] kinematics_hash now automatically read from kinematics_params --- .../urdf/my_robot_cell_controlled.urdf.xacro | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/my_robot_cell/my_robot_cell_control/urdf/my_robot_cell_controlled.urdf.xacro b/my_robot_cell/my_robot_cell_control/urdf/my_robot_cell_controlled.urdf.xacro index 43a0e4d..07dbd23 100644 --- a/my_robot_cell/my_robot_cell_control/urdf/my_robot_cell_controlled.urdf.xacro +++ b/my_robot_cell/my_robot_cell_control/urdf/my_robot_cell_controlled.urdf.xacro @@ -22,9 +22,10 @@ - - - + + + + @@ -45,7 +46,7 @@ Date: Mon, 10 Feb 2025 10:40:35 +0100 Subject: [PATCH 10/16] Use --unsafe for check-yaml Otherwise the xacro-specific !degrees tag will not be accepted. --- .pre-commit-config.yaml | 1 + 1 file changed, 1 insertion(+) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 7d0a411..5367a27 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -8,6 +8,7 @@ repos: - id: check-merge-conflict - id: check-symlinks - id: check-yaml + args: ['--unsafe'] - id: end-of-file-fixer - id: mixed-line-ending - id: trailing-whitespace From 2ed467a906f197eee081cdc92695e736af950ccd Mon Sep 17 00:00:00 2001 From: Felix Exner Date: Mon, 10 Feb 2025 10:40:43 +0100 Subject: [PATCH 11/16] Code formatting --- .../my_robot_cell_control/launch/start_robot.launch.py | 7 ++++++- .../urdf/my_robot_cell_controlled.urdf.xacro | 4 ++-- 2 files changed, 8 insertions(+), 3 deletions(-) diff --git a/my_robot_cell/my_robot_cell_control/launch/start_robot.launch.py b/my_robot_cell/my_robot_cell_control/launch/start_robot.launch.py index 7faa243..71a879a 100644 --- a/my_robot_cell/my_robot_cell_control/launch/start_robot.launch.py +++ b/my_robot_cell/my_robot_cell_control/launch/start_robot.launch.py @@ -139,7 +139,12 @@ def generate_launch_description(): headless_mode = LaunchConfiguration("headless_mode") base_launch = IncludeLaunchDescription( - PythonLaunchDescriptionSource([PathJoinSubstitution([FindPackageShare("ur_robot_driver"),"launch"]), "/ur_control.launch.py"]), + PythonLaunchDescriptionSource( + [ + PathJoinSubstitution([FindPackageShare("ur_robot_driver"), "launch"]), + "/ur_control.launch.py", + ] + ), launch_arguments={ "ur_type": ur_type, "robot_ip": robot_ip, diff --git a/my_robot_cell/my_robot_cell_control/urdf/my_robot_cell_controlled.urdf.xacro b/my_robot_cell/my_robot_cell_control/urdf/my_robot_cell_controlled.urdf.xacro index 07dbd23..adf736e 100644 --- a/my_robot_cell/my_robot_cell_control/urdf/my_robot_cell_controlled.urdf.xacro +++ b/my_robot_cell/my_robot_cell_control/urdf/my_robot_cell_controlled.urdf.xacro @@ -8,7 +8,7 @@ - + @@ -25,7 +25,7 @@ - + From dc6b8b251795683cb8a51db95e41a46ee07fd56e Mon Sep 17 00:00:00 2001 From: Felix Exner Date: Mon, 17 Mar 2025 15:02:13 +0000 Subject: [PATCH 12/16] Update sphinx docs --- my_robot_cell/doc/build_moveit_config.rst | 2 +- my_robot_cell/doc/start_ur_driver.rst | 43 ++++--------------- .../.setup_assistant | 19 +------- .../CMakeLists.txt | 9 +++- .../launch/move_group.launch.py | 4 +- .../launch/moveit_rviz.launch.py | 4 +- .../launch/setup_assistant.launch.py | 4 +- .../my_robot_cell_moveit_config/package.xml | 5 +-- 8 files changed, 23 insertions(+), 67 deletions(-) diff --git a/my_robot_cell/doc/build_moveit_config.rst b/my_robot_cell/doc/build_moveit_config.rst index 13a336d..9eebc17 100644 --- a/my_robot_cell/doc/build_moveit_config.rst +++ b/my_robot_cell/doc/build_moveit_config.rst @@ -129,7 +129,7 @@ First, we need to start a robot, simulated or real. If you start a real robot, m .. code-block:: bash # You can switch to real hardware if you prefer - ros2 launch my_robot_cell_control start_robot.launch.py use_mock_hardware:=true + ros2 launch my_robot_cell_control start_robot.launch.py use_fake_hardware:=true Second, we can start the move_group node by running the launch file the setup assistant created for us: diff --git a/my_robot_cell/doc/start_ur_driver.rst b/my_robot_cell/doc/start_ur_driver.rst index 1e24ede..f8294c2 100644 --- a/my_robot_cell/doc/start_ur_driver.rst +++ b/my_robot_cell/doc/start_ur_driver.rst @@ -23,8 +23,8 @@ This URDF is very similar to the one we have already assembled. We simply need t .. literalinclude:: ../my_robot_cell_control/urdf/my_robot_cell_controlled.urdf.xacro :language: xml - :start-at: - :end-at: + :start-at: + :end-at: :caption: my_robot_cell_control/urdf/my_robot_cell_controlled.urdf.xacro @@ -33,7 +33,7 @@ define the necessary arguments that need to be passed to the macro, .. literalinclude:: ../my_robot_cell_control/urdf/my_robot_cell_controlled.urdf.xacro :language: xml :start-at: - :end-at: + :end-at: :caption: my_robot_cell_control/urdf/my_robot_cell_controlled.urdf.xacro @@ -57,39 +57,12 @@ For now, we just copy the default one for the ur20. cp $(ros2 pkg prefix ur_description)/share/ur_description/config/ur20/default_kinematics.yaml \ my_robot_cell_control/config/my_robot_calibration.yaml - -Create robot_state_publisher launchfile ---------------------------------------- - -To use the custom controlled description, we need to generate a launchfile loading that description -(Since it contains less / potentially different) arguments than the "default" one. In that -launchfile we need to start a ``robot_state_publisher`` (RSP) node that will get the description as a -parameter and redistribute it via the ``robot_description`` topic: - -.. literalinclude:: ../my_robot_cell_control/launch/rsp.launch.py - :language: py - :start-after: # Author: Felix Exner - :linenos: - :caption: my_robot_cell_control/launch/rsp.launch.py - -With this we could start our workcell using - -.. code-block:: bash - - ros2 launch ur_robot_driver ur_control.launch.py \ - description_launchfile:=$(ros2 pkg prefix my_robot_cell_control)/share/my_robot_cell_control/launch/rsp.launch.py \ - use_mock_hardware:=true \ - robot_ip:=123 \ - ur_type:=ur20 \ - rviz_config_file:=$(ros2 pkg prefix my_robot_cell_description)/share/my_robot_cell_description/rviz/urdf.rviz \ - tf_prefix:=ur20_ - Create start_robot launchfile ----------------------------- -Since the command above is obviously not very convenient to start our robot, we wrap that into another -launchfile that includes the ``ur_control.launch.py`` launchfile with the correct description -launchfile and prefix: +To launch a controlled robot with our custom description, we need to generate a launchfile. We +include the ``ur_control.launch.py`` file from the driver and set its parameters to match our +custom workcell. .. literalinclude:: ../my_robot_cell_control/launch/start_robot.launch.py :language: py @@ -100,7 +73,7 @@ With that we can start the robot using .. code-block:: bash - ros2 launch my_robot_cell_control start_robot.launch.py use_mock_hardware:=true + ros2 launch my_robot_cell_control start_robot.launch.py use_fake_hardware:=true Testing everything ------------------ @@ -121,7 +94,7 @@ We can start the system in a mocked simulation .. code-block:: bash #start the driver with mocked hardware - ros2 launch my_robot_cell_control start_robot.launch.py use_mock_hardware:=true + ros2 launch my_robot_cell_control start_robot.launch.py use_fake_hardware:=true Or to use it with a real robot: diff --git a/my_robot_cell/my_robot_cell_moveit_config/.setup_assistant b/my_robot_cell/my_robot_cell_moveit_config/.setup_assistant index 8f9e05b..7243624 100644 --- a/my_robot_cell/my_robot_cell_moveit_config/.setup_assistant +++ b/my_robot_cell/my_robot_cell_moveit_config/.setup_assistant @@ -6,20 +6,5 @@ moveit_setup_assistant_config: relative_path: config/my_robot_cell.srdf package_settings: author_name: Felix Exner - author_email: exner@fzi.de - generated_timestamp: 1713785068 - control_xacro: - command: - - position - state: - - position - - velocity - modified_urdf: - xacros: - - control_xacro - control_xacro: - command: - - position - state: - - position - - velocity + author_email: urfeex@universal-robots.com + generated_timestamp: 1742223443 \ No newline at end of file diff --git a/my_robot_cell/my_robot_cell_moveit_config/CMakeLists.txt b/my_robot_cell/my_robot_cell_moveit_config/CMakeLists.txt index 39624b6..fc24ced 100644 --- a/my_robot_cell/my_robot_cell_moveit_config/CMakeLists.txt +++ b/my_robot_cell/my_robot_cell_moveit_config/CMakeLists.txt @@ -5,7 +5,12 @@ find_package(ament_cmake REQUIRED) ament_package() -install(DIRECTORY launch DESTINATION share/${PROJECT_NAME} - PATTERN "setup_assistant.launch" EXCLUDE) +if(EXISTS "${CMAKE_CURRENT_SOURCE_DIR}/launch") + install( + DIRECTORY launch + DESTINATION share/${PROJECT_NAME} + PATTERN "setup_assistant.launch" EXCLUDE) +endif() + install(DIRECTORY config DESTINATION share/${PROJECT_NAME}) install(FILES .setup_assistant DESTINATION share/${PROJECT_NAME}) diff --git a/my_robot_cell/my_robot_cell_moveit_config/launch/move_group.launch.py b/my_robot_cell/my_robot_cell_moveit_config/launch/move_group.launch.py index b4c36d1..81c013d 100644 --- a/my_robot_cell/my_robot_cell_moveit_config/launch/move_group.launch.py +++ b/my_robot_cell/my_robot_cell_moveit_config/launch/move_group.launch.py @@ -3,7 +3,5 @@ def generate_launch_description(): - moveit_config = MoveItConfigsBuilder( - "my_robot_cell", package_name="my_robot_cell_moveit_config" - ).to_moveit_configs() + moveit_config = MoveItConfigsBuilder("my_robot_cell", package_name="my_robot_cell_moveit_config").to_moveit_configs() return generate_move_group_launch(moveit_config) diff --git a/my_robot_cell/my_robot_cell_moveit_config/launch/moveit_rviz.launch.py b/my_robot_cell/my_robot_cell_moveit_config/launch/moveit_rviz.launch.py index f701508..9fbae6c 100644 --- a/my_robot_cell/my_robot_cell_moveit_config/launch/moveit_rviz.launch.py +++ b/my_robot_cell/my_robot_cell_moveit_config/launch/moveit_rviz.launch.py @@ -3,7 +3,5 @@ def generate_launch_description(): - moveit_config = MoveItConfigsBuilder( - "my_robot_cell", package_name="my_robot_cell_moveit_config" - ).to_moveit_configs() + moveit_config = MoveItConfigsBuilder("my_robot_cell", package_name="my_robot_cell_moveit_config").to_moveit_configs() return generate_moveit_rviz_launch(moveit_config) diff --git a/my_robot_cell/my_robot_cell_moveit_config/launch/setup_assistant.launch.py b/my_robot_cell/my_robot_cell_moveit_config/launch/setup_assistant.launch.py index d3d8f9c..6a9cf5a 100644 --- a/my_robot_cell/my_robot_cell_moveit_config/launch/setup_assistant.launch.py +++ b/my_robot_cell/my_robot_cell_moveit_config/launch/setup_assistant.launch.py @@ -3,7 +3,5 @@ def generate_launch_description(): - moveit_config = MoveItConfigsBuilder( - "my_robot_cell", package_name="my_robot_cell_moveit_config" - ).to_moveit_configs() + moveit_config = MoveItConfigsBuilder("my_robot_cell", package_name="my_robot_cell_moveit_config").to_moveit_configs() return generate_setup_assistant_launch(moveit_config) diff --git a/my_robot_cell/my_robot_cell_moveit_config/package.xml b/my_robot_cell/my_robot_cell_moveit_config/package.xml index 5924d78..f22a034 100644 --- a/my_robot_cell/my_robot_cell_moveit_config/package.xml +++ b/my_robot_cell/my_robot_cell_moveit_config/package.xml @@ -6,7 +6,7 @@ An automatically generated package with all the configuration and launch files for using the my_robot_cell with the MoveIt Motion Planning Framework - Felix Exner + Felix Exner BSD-3-Clause @@ -14,7 +14,7 @@ https://github.com/ros-planning/moveit2/issues https://github.com/ros-planning/moveit2 - Felix Exner + Felix Exner ament_cmake @@ -38,7 +38,6 @@ rviz2 rviz_common rviz_default_plugins - xacro From fcea1b7d76de56b2b11d63ca4b13d3a1d14963be Mon Sep 17 00:00:00 2001 From: Felix Exner Date: Mon, 17 Mar 2025 16:05:48 +0100 Subject: [PATCH 13/16] Fix formatting --- my_robot_cell/my_robot_cell_moveit_config/.setup_assistant | 2 +- .../my_robot_cell_moveit_config/launch/move_group.launch.py | 4 +++- .../my_robot_cell_moveit_config/launch/moveit_rviz.launch.py | 4 +++- .../launch/setup_assistant.launch.py | 4 +++- 4 files changed, 10 insertions(+), 4 deletions(-) diff --git a/my_robot_cell/my_robot_cell_moveit_config/.setup_assistant b/my_robot_cell/my_robot_cell_moveit_config/.setup_assistant index 7243624..d139bcf 100644 --- a/my_robot_cell/my_robot_cell_moveit_config/.setup_assistant +++ b/my_robot_cell/my_robot_cell_moveit_config/.setup_assistant @@ -7,4 +7,4 @@ moveit_setup_assistant_config: package_settings: author_name: Felix Exner author_email: urfeex@universal-robots.com - generated_timestamp: 1742223443 \ No newline at end of file + generated_timestamp: 1742223443 diff --git a/my_robot_cell/my_robot_cell_moveit_config/launch/move_group.launch.py b/my_robot_cell/my_robot_cell_moveit_config/launch/move_group.launch.py index 81c013d..b4c36d1 100644 --- a/my_robot_cell/my_robot_cell_moveit_config/launch/move_group.launch.py +++ b/my_robot_cell/my_robot_cell_moveit_config/launch/move_group.launch.py @@ -3,5 +3,7 @@ def generate_launch_description(): - moveit_config = MoveItConfigsBuilder("my_robot_cell", package_name="my_robot_cell_moveit_config").to_moveit_configs() + moveit_config = MoveItConfigsBuilder( + "my_robot_cell", package_name="my_robot_cell_moveit_config" + ).to_moveit_configs() return generate_move_group_launch(moveit_config) diff --git a/my_robot_cell/my_robot_cell_moveit_config/launch/moveit_rviz.launch.py b/my_robot_cell/my_robot_cell_moveit_config/launch/moveit_rviz.launch.py index 9fbae6c..f701508 100644 --- a/my_robot_cell/my_robot_cell_moveit_config/launch/moveit_rviz.launch.py +++ b/my_robot_cell/my_robot_cell_moveit_config/launch/moveit_rviz.launch.py @@ -3,5 +3,7 @@ def generate_launch_description(): - moveit_config = MoveItConfigsBuilder("my_robot_cell", package_name="my_robot_cell_moveit_config").to_moveit_configs() + moveit_config = MoveItConfigsBuilder( + "my_robot_cell", package_name="my_robot_cell_moveit_config" + ).to_moveit_configs() return generate_moveit_rviz_launch(moveit_config) diff --git a/my_robot_cell/my_robot_cell_moveit_config/launch/setup_assistant.launch.py b/my_robot_cell/my_robot_cell_moveit_config/launch/setup_assistant.launch.py index 6a9cf5a..d3d8f9c 100644 --- a/my_robot_cell/my_robot_cell_moveit_config/launch/setup_assistant.launch.py +++ b/my_robot_cell/my_robot_cell_moveit_config/launch/setup_assistant.launch.py @@ -3,5 +3,7 @@ def generate_launch_description(): - moveit_config = MoveItConfigsBuilder("my_robot_cell", package_name="my_robot_cell_moveit_config").to_moveit_configs() + moveit_config = MoveItConfigsBuilder( + "my_robot_cell", package_name="my_robot_cell_moveit_config" + ).to_moveit_configs() return generate_setup_assistant_launch(moveit_config) From a811bd0b47564472c3660e77b3d614612561175e Mon Sep 17 00:00:00 2001 From: Felix Exner Date: Tue, 18 Mar 2025 12:07:47 +0000 Subject: [PATCH 14/16] Add missing controllers --- .../config/ros2_controllers.yaml | 69 +++++++++++++++++-- 1 file changed, 63 insertions(+), 6 deletions(-) diff --git a/my_robot_cell/my_robot_cell_control/config/ros2_controllers.yaml b/my_robot_cell/my_robot_cell_control/config/ros2_controllers.yaml index 05faf10..c14e495 100644 --- a/my_robot_cell/my_robot_cell_control/config/ros2_controllers.yaml +++ b/my_robot_cell/my_robot_cell_control/config/ros2_controllers.yaml @@ -12,6 +12,9 @@ controller_manager: force_torque_sensor_broadcaster: type: force_torque_sensor_broadcaster/ForceTorqueSensorBroadcaster + joint_trajectory_controller: + type: joint_trajectory_controller/JointTrajectoryController + scaled_joint_trajectory_controller: type: ur_controllers/ScaledJointTrajectoryController @@ -24,6 +27,18 @@ controller_manager: ur_configuration_controller: type: ur_controllers/URConfigurationController + force_mode_controller: + type: ur_controllers/ForceModeController + + freedrive_mode_controller: + type: ur_controllers/FreedriveModeController + + passthrough_trajectory_controller: + type: ur_controllers/PassthroughTrajectoryController + + tcp_pose_broadcaster: + type: pose_broadcaster/PoseBroadcaster + ur_configuration_controller: ros__parameters: tf_prefix: "ur20_" @@ -50,6 +65,33 @@ force_torque_sensor_broadcaster: frame_id: ur20_tool0 topic_name: ft_data +joint_trajectory_controller: + ros__parameters: + joints: + - $(var tf_prefix)shoulder_pan_joint + - $(var tf_prefix)shoulder_lift_joint + - $(var tf_prefix)elbow_joint + - $(var tf_prefix)wrist_1_joint + - $(var tf_prefix)wrist_2_joint + - $(var tf_prefix)wrist_3_joint + command_interfaces: + - position + state_interfaces: + - position + - velocity + state_publish_rate: 100.0 + action_monitor_rate: 20.0 + allow_partial_joints_goal: false + constraints: + stopped_velocity_tolerance: 0.2 + goal_time: 0.0 + $(var tf_prefix)shoulder_pan_joint: {trajectory: 0.2, goal: 0.1} + $(var tf_prefix)shoulder_lift_joint: {trajectory: 0.2, goal: 0.1} + $(var tf_prefix)elbow_joint: {trajectory: 0.2, goal: 0.1} + $(var tf_prefix)wrist_1_joint: {trajectory: 0.2, goal: 0.1} + $(var tf_prefix)wrist_2_joint: {trajectory: 0.2, goal: 0.1} + $(var tf_prefix)wrist_3_joint: {trajectory: 0.2, goal: 0.1} + scaled_joint_trajectory_controller: ros__parameters: joints: @@ -70,12 +112,12 @@ scaled_joint_trajectory_controller: constraints: stopped_velocity_tolerance: 0.2 goal_time: 0.0 - ur20_shoulder_pan_joint: { trajectory: 0.2, goal: 0.1 } - ur20_shoulder_lift_joint: { trajectory: 0.2, goal: 0.1 } - ur20_elbow_joint: { trajectory: 0.2, goal: 0.1 } - ur20_wrist_1_joint: { trajectory: 0.2, goal: 0.1 } - ur20_wrist_2_joint: { trajectory: 0.2, goal: 0.1 } - ur20_wrist_3_joint: { trajectory: 0.2, goal: 0.1 } + ur20_shoulder_pan_joint: {trajectory: 0.2, goal: 0.1} + ur20_shoulder_lift_joint: {trajectory: 0.2, goal: 0.1} + ur20_elbow_joint: {trajectory: 0.2, goal: 0.1} + ur20_wrist_1_joint: {trajectory: 0.2, goal: 0.1} + ur20_wrist_2_joint: {trajectory: 0.2, goal: 0.1} + ur20_wrist_3_joint: {trajectory: 0.2, goal: 0.1} speed_scaling_interface_name: ur20_speed_scaling/speed_scaling_factor forward_velocity_controller: @@ -98,3 +140,18 @@ forward_position_controller: - ur20_wrist_1_joint - ur20_wrist_2_joint - ur20_wrist_3_joint + +force_mode_controller: + ros__parameters: + tf_prefix: "$(var tf_prefix)" + +freedrive_mode_controller: + ros__parameters: + tf_prefix: "$(var tf_prefix)" + +tcp_pose_broadcaster: + ros__parameters: + frame_id: $(var tf_prefix)base + pose_name: $(var tf_prefix)tcp_pose + tf: + child_frame_id: $(var tf_prefix)tool0_controller From adcc7e4b4faf5137aa917e839d82ca5c7d3cb233 Mon Sep 17 00:00:00 2001 From: Felix Exner Date: Tue, 18 Mar 2025 12:21:54 +0000 Subject: [PATCH 15/16] Do not duplicate controllers.yaml --- .../config/ros2_controllers.yaml | 157 ------------------ .../config/ur20_update_rate.yaml | 3 - .../launch/start_robot.launch.py | 19 +-- 3 files changed, 1 insertion(+), 178 deletions(-) delete mode 100644 my_robot_cell/my_robot_cell_control/config/ros2_controllers.yaml delete mode 100644 my_robot_cell/my_robot_cell_control/config/ur20_update_rate.yaml diff --git a/my_robot_cell/my_robot_cell_control/config/ros2_controllers.yaml b/my_robot_cell/my_robot_cell_control/config/ros2_controllers.yaml deleted file mode 100644 index c14e495..0000000 --- a/my_robot_cell/my_robot_cell_control/config/ros2_controllers.yaml +++ /dev/null @@ -1,157 +0,0 @@ -controller_manager: - ros__parameters: - joint_state_broadcaster: - type: joint_state_broadcaster/JointStateBroadcaster - - io_and_status_controller: - type: ur_controllers/GPIOController - - speed_scaling_state_broadcaster: - type: ur_controllers/SpeedScalingStateBroadcaster - - force_torque_sensor_broadcaster: - type: force_torque_sensor_broadcaster/ForceTorqueSensorBroadcaster - - joint_trajectory_controller: - type: joint_trajectory_controller/JointTrajectoryController - - scaled_joint_trajectory_controller: - type: ur_controllers/ScaledJointTrajectoryController - - forward_velocity_controller: - type: velocity_controllers/JointGroupVelocityController - - forward_position_controller: - type: position_controllers/JointGroupPositionController - - ur_configuration_controller: - type: ur_controllers/URConfigurationController - - force_mode_controller: - type: ur_controllers/ForceModeController - - freedrive_mode_controller: - type: ur_controllers/FreedriveModeController - - passthrough_trajectory_controller: - type: ur_controllers/PassthroughTrajectoryController - - tcp_pose_broadcaster: - type: pose_broadcaster/PoseBroadcaster - -ur_configuration_controller: - ros__parameters: - tf_prefix: "ur20_" - -speed_scaling_state_broadcaster: - ros__parameters: - state_publish_rate: 100.0 - tf_prefix: "ur20_" - -io_and_status_controller: - ros__parameters: - tf_prefix: "ur20_" - -force_torque_sensor_broadcaster: - ros__parameters: - sensor_name: ur20_tcp_fts_sensor - state_interface_names: - - force.x - - force.y - - force.z - - torque.x - - torque.y - - torque.z - frame_id: ur20_tool0 - topic_name: ft_data - -joint_trajectory_controller: - ros__parameters: - joints: - - $(var tf_prefix)shoulder_pan_joint - - $(var tf_prefix)shoulder_lift_joint - - $(var tf_prefix)elbow_joint - - $(var tf_prefix)wrist_1_joint - - $(var tf_prefix)wrist_2_joint - - $(var tf_prefix)wrist_3_joint - command_interfaces: - - position - state_interfaces: - - position - - velocity - state_publish_rate: 100.0 - action_monitor_rate: 20.0 - allow_partial_joints_goal: false - constraints: - stopped_velocity_tolerance: 0.2 - goal_time: 0.0 - $(var tf_prefix)shoulder_pan_joint: {trajectory: 0.2, goal: 0.1} - $(var tf_prefix)shoulder_lift_joint: {trajectory: 0.2, goal: 0.1} - $(var tf_prefix)elbow_joint: {trajectory: 0.2, goal: 0.1} - $(var tf_prefix)wrist_1_joint: {trajectory: 0.2, goal: 0.1} - $(var tf_prefix)wrist_2_joint: {trajectory: 0.2, goal: 0.1} - $(var tf_prefix)wrist_3_joint: {trajectory: 0.2, goal: 0.1} - -scaled_joint_trajectory_controller: - ros__parameters: - joints: - - ur20_shoulder_pan_joint - - ur20_shoulder_lift_joint - - ur20_elbow_joint - - ur20_wrist_1_joint - - ur20_wrist_2_joint - - ur20_wrist_3_joint - command_interfaces: - - position - state_interfaces: - - position - - velocity - state_publish_rate: 100.0 - action_monitor_rate: 20.0 - allow_partial_joints_goal: false - constraints: - stopped_velocity_tolerance: 0.2 - goal_time: 0.0 - ur20_shoulder_pan_joint: {trajectory: 0.2, goal: 0.1} - ur20_shoulder_lift_joint: {trajectory: 0.2, goal: 0.1} - ur20_elbow_joint: {trajectory: 0.2, goal: 0.1} - ur20_wrist_1_joint: {trajectory: 0.2, goal: 0.1} - ur20_wrist_2_joint: {trajectory: 0.2, goal: 0.1} - ur20_wrist_3_joint: {trajectory: 0.2, goal: 0.1} - speed_scaling_interface_name: ur20_speed_scaling/speed_scaling_factor - -forward_velocity_controller: - ros__parameters: - joints: - - ur20_shoulder_pan_joint - - ur20_shoulder_lift_joint - - ur20_elbow_joint - - ur20_wrist_1_joint - - ur20_wrist_2_joint - - ur20_wrist_3_joint - interface_name: velocity - -forward_position_controller: - ros__parameters: - joints: - - ur20_shoulder_pan_joint - - ur20_shoulder_lift_joint - - ur20_elbow_joint - - ur20_wrist_1_joint - - ur20_wrist_2_joint - - ur20_wrist_3_joint - -force_mode_controller: - ros__parameters: - tf_prefix: "$(var tf_prefix)" - -freedrive_mode_controller: - ros__parameters: - tf_prefix: "$(var tf_prefix)" - -tcp_pose_broadcaster: - ros__parameters: - frame_id: $(var tf_prefix)base - pose_name: $(var tf_prefix)tcp_pose - tf: - child_frame_id: $(var tf_prefix)tool0_controller diff --git a/my_robot_cell/my_robot_cell_control/config/ur20_update_rate.yaml b/my_robot_cell/my_robot_cell_control/config/ur20_update_rate.yaml deleted file mode 100644 index 66ef3d7..0000000 --- a/my_robot_cell/my_robot_cell_control/config/ur20_update_rate.yaml +++ /dev/null @@ -1,3 +0,0 @@ -controller_manager: - ros__parameters: - update_rate: 500 # Hz diff --git a/my_robot_cell/my_robot_cell_control/launch/start_robot.launch.py b/my_robot_cell/my_robot_cell_control/launch/start_robot.launch.py index 71a879a..8d5e0e4 100644 --- a/my_robot_cell/my_robot_cell_control/launch/start_robot.launch.py +++ b/my_robot_cell/my_robot_cell_control/launch/start_robot.launch.py @@ -54,20 +54,6 @@ def generate_launch_description(): "Used only if 'use_fake_hardware' parameter is true.", ) ) - declared_arguments.append( - DeclareLaunchArgument( - "runtime_config_package", - default_value="my_robot_cell_control", - description="package in which .yaml are", - ) - ) - declared_arguments.append( - DeclareLaunchArgument( - "controllers_file", - default_value="ros2_controllers.yaml", - description="name of controllers .yaml", - ) - ) declared_arguments.append( DeclareLaunchArgument( "description_package", @@ -87,7 +73,7 @@ def generate_launch_description(): "kinematics_params_file", default_value=PathJoinSubstitution( [ - FindPackageShare(LaunchConfiguration("runtime_config_package")), + FindPackageShare("my_robot_cell_control"), "config", "my_robot_calibration.yaml", ] @@ -129,7 +115,6 @@ def generate_launch_description(): launch_rviz = LaunchConfiguration("launch_rviz") use_fake_hardware = LaunchConfiguration("use_fake_hardware") fake_sensor_commands = LaunchConfiguration("fake_sensor_commands") - runtime_config_package = LaunchConfiguration("runtime_config_package") controllers_file = LaunchConfiguration("controllers_file") description_package = LaunchConfiguration("description_package") description_file = LaunchConfiguration("description_file") @@ -152,8 +137,6 @@ def generate_launch_description(): "launch_rviz": launch_rviz, "use_fake_hardware": use_fake_hardware, "fake_sensor_commands": fake_sensor_commands, - "runtime_config_package": runtime_config_package, - "controllers_file": controllers_file, "description_package": description_package, "description_file": description_file, "kinematics_params_file": kinematics_params_file, From 9018758874c0341bfa4ca4be808ca2fc958582e0 Mon Sep 17 00:00:00 2001 From: Felix Exner Date: Wed, 19 Mar 2025 07:39:31 +0000 Subject: [PATCH 16/16] Update urdf file captions --- my_robot_cell/doc/assemble_urdf.rst | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/my_robot_cell/doc/assemble_urdf.rst b/my_robot_cell/doc/assemble_urdf.rst index 1ea58e0..6ead4fc 100644 --- a/my_robot_cell/doc/assemble_urdf.rst +++ b/my_robot_cell/doc/assemble_urdf.rst @@ -57,7 +57,7 @@ The workcell macro is defined in the following manner: .. literalinclude:: ../my_robot_cell_description/urdf/my_robot_cell_macro.xacro :language: xml :linenos: - :caption: my_robot_cell_description/urdf/my_robot_cell_macro.urdf.xacro + :caption: my_robot_cell_description/urdf/my_robot_cell_macro.xacro This macro provides an example of what a custom workcell could resemble. Your workspace will likely vary from this one. Please feel free to modify this portion of the URDF to match your own setup. In @@ -72,7 +72,7 @@ macro. In this example, we chose to create a link named **robot_mount**. :start-at: :end-at: :linenos: - :caption: my_robot_cell_description/urdf/my_robot_cell.urdf.xacro + :caption: my_robot_cell_description/urdf/my_robot_cell.xacro After that we are finally able to actually **create the robot arm** by calling the macro. @@ -81,7 +81,7 @@ After that we are finally able to actually **create the robot arm** by calling t :start-at: :linenos: - :caption: my_robot_cell_description/urdf/my_robot_cell.urdf.xacro + :caption: my_robot_cell_description/urdf/my_robot_cell.xacro Note that the **origin** argument is transmitted in a different manner than the other arguments.