|
| 1 | +ur_description |
| 2 | +============== |
| 3 | + |
| 4 | +This package contains the kinematic and visual description of Universal Robots manipulators for ROS |
| 5 | +2. |
| 6 | + |
| 7 | +Structure of the repository |
| 8 | +--------------------------- |
| 9 | + |
| 10 | +As the kinematics of all models is roughly the same and varies only in the meshes, the DH |
| 11 | +parameters and the physical parameters, the description uses xacro macros in order to make it reuse |
| 12 | +as much as possible. This way it is less likely that errors are introduced in one of the models. |
| 13 | + |
| 14 | +Therefore, the description is split up into multiple URDF/XACRO files: |
| 15 | + |
| 16 | +- ``urdf/ur_macro.xacro`` - macro file with UR-manipulator description. This file is usually included into external projects to visualize and configure UR manipulators properly. An example how to use this macro is in ``urdf/ur.urdf.xacro`` file. |
| 17 | +- ``urdf/ur.urdf.xacro`` - an example scene where the robot is standing alone without any |
| 18 | + environment. This is obviously not a real-life example, as the robot has to be mounted somewhere. |
| 19 | + |
| 20 | +The kinematic description itself uses config files to get parametrized to the correct robot model. |
| 21 | + |
| 22 | +.. image:: structure.svg |
| 23 | + :alt: Structure of the description's parametrization |
| 24 | + |
| 25 | +Basically, the description can be modified using configuration values stored in four files: |
| 26 | + - ``config/urXX/default_kinematics.yaml`` - This contains the calibration values as they can be |
| 27 | + extracted from the robot. Changing these values with the one extracted from a real robot will |
| 28 | + result in a description matching the real robot exactly (w.r.t the ``tool0`` frame). It is highly |
| 29 | + recommended to use matching kinematic values in real-world applications. |
| 30 | + - ``config/urXX/joint_limits.yaml`` - If you'd like to further restrict the robot's joint limits, |
| 31 | + these limits can be modified there. |
| 32 | + - ``config/urXX/physical_parameters.yaml`` - Everything regarding physics simulation parameters |
| 33 | + (e.g. inertia poses and values) can be tuned here. |
| 34 | + - ``config/urXX/visual_parameters.yaml`` - Some users change certain visual aspects, e.g. replacing |
| 35 | + the cap on the wrist_3_link. This config file specifies which meshes (both, visual and collision) |
| 36 | + should be used. |
| 37 | + |
| 38 | +The four configuration files have to be passed to ``ur_macro.xacro`` (more specific to the macro |
| 39 | +defined in that file) which is done inside the ``ur.urdf.xacro``. Contents of the files are parsed |
| 40 | +inside ``inc/ur_common.xacro``. |
| 41 | + |
| 42 | +Arguments that have to be passed to the main ``ur.urdf.xacro`` file are: |
| 43 | + - kinematics_params - Filename to the ``default_kinematics.yaml`` (or equivalent specific kinematics) file |
| 44 | + - joint_limit_params - Filename to the ``joint_limits.yaml`` file |
| 45 | + - physical_params - Filename to the ``physical_parameters.yaml`` file |
| 46 | + - visual_params - Filename to the ``visual_params.yaml`` file |
| 47 | + |
| 48 | +The launchfile ``launch/view_ur.launch.py`` abstracts these four parameters to one ``ur_type`` argument |
| 49 | +which will basically replace the ``urXX`` part of the paths as shown in the picture above. |
| 50 | + |
| 51 | +ros2_control integration |
| 52 | +^^^^^^^^^^^^^^^^^^^^^^^^ |
| 53 | + |
| 54 | +`ros2_control <https://control.ros.org>`_ uses the robot_description in order to describe the |
| 55 | +robot's control structure. Since this will vary for the respective control method (Driver for real |
| 56 | +robot, Gazebo simulation, mock_hardware simulation, etc.) this is kept inside the respective control repository. This |
| 57 | +repository provides macros for including the common control description (Joints with their |
| 58 | +interfaces) as well as an example using mock hardware. |
| 59 | + |
| 60 | +- ``urdf/ros2_control_mock_hardware.xacro`` - xacro providing the control description for |
| 61 | + mock_hardware. |
| 62 | +- ``urdf/ur_mocked.urdf.xacro`` - an example for a controlled robot consisting of the kinematic |
| 63 | + description and the control description. |
| 64 | +- ``urdf/inc/ur_joint_control.xacro`` - macro for describing the joints' control structure. |
| 65 | +- ``urdf/inc/ur_sensors.xacro`` - macro for describing the robot's sensors for ros2_control |
| 66 | + |
| 67 | +Creating your own description including this description |
| 68 | +-------------------------------------------------------- |
| 69 | + |
| 70 | +In real-world applications you will most probably have a more complex description consisting of more objects than just the robot. It is recommended to create a separate ROS package containing this particular description. Inside this description you could also store your robot-specific kinematics parameters file. |
| 71 | + |
| 72 | +See the `custom workcell example <https://github.com/UniversalRobots/Universal_Robots_ROS2_Tutorials/tree/main/my_robot_cell/my_robot_cell_description>`_ as an example for integrating this description in your own scene description. |
0 commit comments