- First, run the following to install
libtinyxml2-devon your system.
sudo apt-get install libtinyxml2-dev
- I assume you have already configured your
catkin_wsworkspace, if not Google how to configure your catkin workspace. - Go to
catkin_ws/srcand clone theor_urdfrepository from here. Note that this is a forked version because I changed something to the build destination of the plugin. I have created a pull request but as of now has not yet been approved. Have a look here and if the pull request is merged and closed, then go ahead and clone theor_urdffrom the original repository. - Clone also the
openrave_catkinfrom here in yourcatkin_ws/src. - Once you clone the
or_urdfandopenrave_catkinin yourcatkin_ws/srcthen go tocatkin_wsand runcatkin_make. - You should see a successful message at the end of the build process.
- In your
~/.bashrcfile add the following line:
export OPENRAVE_PLUGINS=$OPENRAVE_PLUGINS:~/catkin_ws/devel/share/openrave-0.9/plugins
- Verify the successful installation of the plugin using the following:
- Run
source ~/.bashrc openrave -listplugins- You should see URDF under module category. If you see URDF in there then you are good to go!
- Run
I have the urdf and srdf files for UR5 robot stored in the
repository here if you want to try.
from openravepy import *
env = Environment()
env.SetViewer('qtcoin')
urdf_module = RaveCreateModule(env, 'urdf')
urdf_path = "package://ur5controller/ur5_description/urdf/clearpath_ridgeback__ur5__robotiq_two_finger_gripper.urdf"
srdf_path = "package://ur5controller/ur5_description/srdf/clearpath_ridgeback__ur5__robotiq_two_finger_gripper.srdf"
with env:
ur5_name = urdf_module.SendCommand('LoadURI {} {}'.format(urdf_path,
srdf_path))
robot = self.env.GetRobot(ur5_name)