Skip to content
Snippets Groups Projects
README.md 2.41 KiB
Newer Older
Shaun Edwards's avatar
Shaun Edwards committed
universal_robot
===============

This repository provides ROS support for the universal robots.  This repo holds source code for all versions > groovy.  For those versions <= groovy see: hg https://kforge.ros.org/ros_industrial/universal_robot
karlyeurl's avatar
karlyeurl committed

karlyeurl's avatar
karlyeurl committed
To check that the package works with a UR5, set up a catkin workspace and clone the repository into the src/ folder. It should look like ~/catkin_ws/src/universal_robot. Don't forget to source the setup file ($ source ~/catkin_ws/devel/setup.*sh), then use catkin_make to compile.
ipa-fxm's avatar
ipa-fxm committed
The following will show the commands needed to bringup either REAL or SIMULATED robots.
Both robots (ur5 and ur10) can be used in the same way. Simply replace the prefix accordingly.
For each command use a new terminal (don't forget to source the setup shell files)!

To bring up the REAL robot, run:

ipa-fxm's avatar
ipa-fxm committed
```roslaunch ur_bringup ur5.launch robot_ip:=IP_OF_THE_ROBOT```
ipa-fxm's avatar
ipa-fxm committed

To bring up the SIMULATED robots, run:

ipa-fxm's avatar
ipa-fxm committed
```roslaunch ur_gazebo ur5.launch```
ipa-fxm's avatar
ipa-fxm committed

A simple test script that moves the robot to predefined positions can be executed like this:

ipa-fxm's avatar
ipa-fxm committed
```roscd ur_driver; ./test_move.py```
ipa-fxm's avatar
ipa-fxm committed

ipa-fxm's avatar
ipa-fxm committed
BEWARE:
Remember that you should always have your hands on the big red button in case there is something in the way, or anything unexcpected happens.



Additionally, you can use MoveIt! to control the robot.
ipa-fxm's avatar
ipa-fxm committed
For setting up the MoveIt! nodes to allow motion planning with the REAL robot, run:

ipa-fxm's avatar
ipa-fxm committed
```roslaunch ur5_moveit_config ur5_moveit_planning_execution.launch```
ipa-fxm's avatar
ipa-fxm committed

For setting up the MoveIt! nodes to allow motion planning with the SIMULATED robot, run:
ipa-fxm's avatar
ipa-fxm committed

ipa-fxm's avatar
ipa-fxm committed
```roslaunch ur5_moveit_config ur5_moveit_planning_execution.launch sim:=true```
ipa-fxm's avatar
ipa-fxm committed

ipa-fxm's avatar
ipa-fxm committed
In order to be able to use RViz to trigger Planning Request using the MoveIt! Plugin for RViz, run:
ipa-fxm's avatar
ipa-fxm committed

ipa-fxm's avatar
ipa-fxm committed
```roslaunch ur5_moveit_config moveit_rviz.launch config:=true```
ipa-fxm's avatar
ipa-fxm committed

NOTE: 
ipa-fxm's avatar
ipa-fxm committed
As MoveIt! seems to have difficulties with finding plans for the UR with joint limits [-2pi, 2pi], there is a joint_limited version using joint limits [-pi,pi]. In order to use this joint limited version, simply use the launch file arguments 'limited':
ipa-fxm's avatar
ipa-fxm committed

ipa-fxm's avatar
ipa-fxm committed
```roslaunch ur_bringup ur5.launch limited:=true robot_ip:=IP_OF_THE_ROBOT```
ipa-fxm's avatar
ipa-fxm committed

ipa-fxm's avatar
ipa-fxm committed
OR
ipa-fxm's avatar
ipa-fxm committed

ipa-fxm's avatar
ipa-fxm committed
```roslaunch ur_gazebo ur5.launch limited:=true```
ipa-fxm's avatar
ipa-fxm committed

ipa-fxm's avatar
ipa-fxm committed
```roslaunch ur5_moveit_config ur5_moveit_planning_execution.launch limited:=true```
ipa-fxm's avatar
ipa-fxm committed

ipa-fxm's avatar
ipa-fxm committed
OR
ipa-fxm's avatar
ipa-fxm committed

ipa-fxm's avatar
ipa-fxm committed
```roslaunch ur5_moveit_config ur5_moveit_planning_execution.launch limited:=true sim:=true```
ipa-fxm's avatar
ipa-fxm committed

ipa-fxm's avatar
ipa-fxm committed
```roslaunch ur5_moveit_config moveit_rviz.launch config:=true```
ipa-fxm's avatar
ipa-fxm committed