ur_moveit_config
This package contains an example MoveIt! configuration for Universal Robots arms. Since the default description contains only the arm, this MoveIt! configuration package also only contains the arm without any objects around it. In a real-world scenario it is recommended to create a robot_description modelling the robot with its surroundings (e.g. table where it is mounted on, objects in its environment, etc.) and to generate a scenario_moveit_config package from that description as explained in the Custom workcell tutorial.
Usage
With a running driver (real hardware, URSim or mocked hardware), simply start the MoveIt! interaction using
ros2 launch ur_moveit_config ur_moveit.launch.py ur_type:=ur5e launch_rviz:=true
Now you should be able to use the MoveIt Plugin in rviz2 to plan and execute trajectories with the robot as explained here.
Note
The MoveIt configuration provided here has Trajectory Execution Monitoring (TEM) disabled, as the Scaled Joint Trajectory Controller may cause trajectories to be executed at a lower velocity than they were originally planned by MoveIt. MoveIt’s TEM however is not aware of this deliberate slow-down due to scaling and will in most cases unnecessarily (and unexpectedly) abort goals.
Until this incompatibility is resolved, the default value for execution_duration_monitoring
is set to false. Users who wish to temporarily (re)enable TEM at runtime (for use with
other, non-scaling controllers) can do so using the ROS 2 parameter services supported by
MoveIt.
trajectory_execution:
allowed_execution_duration_scaling: 1.2
allowed_goal_duration_margin: 0.5
allowed_start_tolerance: 0.01
execution_duration_monitoring: false # May lead to unexpectedly aborted goals with scaled JTC
Note
The MoveIt configuration does contain a joint_limits.yaml file as it is autogenerated by the
MoveIt Setup Assistant. The joint limits overwrite / augment the ones from the description. This
means that any limits defined here that are also defined in the URDF will be used from the
moveit_config joint_limits.yaml in the context of MoveIt motion planning.
One way to interpret this is that the URDF describes the hardware’s limits, while the
moveit_config provides limits on an application / planning level.
Note
This example loads its description from the running robot_state_publisher and thus needs a running driver / robot_state_publisher to be able to load the robot_description. This is not the default that the moveit_configs_builder expects, but we think that this is less error-prone and easier to use than having to specify the description to load that should match the one used by the driver. This will produce a couple of warnings at startup:
WARNING:root:Cannot infer URDF from `/opt/ros/lyrical/share/ur_moveit_config`. -- using config/ur.urdf
WARNING:root:Cannot infer SRDF from `/opt/ros/lyrical/share/ur_moveit_config`. -- using config/ur.srdf
WARNING:root:"File /opt/ros/lyrical/share/ur_moveit_config/config/ur.urdf doesn't exist"
WARNING:root:The robot description will be loaded from /robot_description topic
Those are expected and can be ignored. The fallback in the last line is the one actually desired.