Commit 08433109 authored by Guilhem Saurel's avatar Guilhem Saurel

load ur 3/5 with or without its gripper

parent c53499ee
......@@ -236,8 +236,9 @@ def loadICub(reduced=True):
return robot
def loadUR(robot=5, limited=False):
URDF_FILENAME = "ur%i%s_robot.urdf" % (robot, "_joint_limited" if limited else '')
def loadUR(robot=5, limited=False, gripper=False):
assert (not (gripper and (robot == 10 or limited)))
URDF_FILENAME = "ur%i%s_%s.urdf" % (robot, "_joint_limited" if limited else '', 'gripper' if gripper else 'robot')
URDF_SUBPATH = "/ur_description/urdf/" + URDF_FILENAME
modelPath = getModelPath(URDF_SUBPATH)
return RobotWrapper.BuildFromURDF(modelPath + URDF_SUBPATH, [modelPath])
......
......@@ -101,6 +101,18 @@ class UR5Test(RobotTestCase):
RobotTestCase.NV = 6
class UR5LimitedTest(RobotTestCase):
RobotTestCase.ROBOT = example_robot_data.loadUR(limited=True)
RobotTestCase.NQ = 6
RobotTestCase.NV = 6
class UR5GripperTest(RobotTestCase):
RobotTestCase.ROBOT = example_robot_data.loadUR(gripper=True)
RobotTestCase.NQ = 6
RobotTestCase.NV = 6
class KinovaTest(RobotTestCase):
RobotTestCase.ROBOT = example_robot_data.loadKinova()
RobotTestCase.NQ = 9
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment