How to run ik_openrave.py with my URDF file?
I am trying to run OpenRave's IK service with my URDF file for the Katana 450 6M90A arm, running diamondback. The URDF file can be found in the katana_description package. Here is what I did:
rosrun xacro xacro.py katana.urdf.xacro > katana6m90a.urdf
rosrun collada_urdf urdf_to_collada katana6m90a.urdf katana6m90a.dae
rosrun orrosplanning ik_openrave.py --scene="katana6m90a.dae"
The last command very briefly shows the viewer displaying my arm model, then quits with the following output:
[openravepy_int.cpp:3267] viewer qtcoin successfully attached
initializing, please wait for ready signal...
Traceback (most recent call last):
File "/home/martin/ros/stacks/openrave_planning/orrosplanning/ik_openrave.py", line 60, in <module>
robot = env.GetRobots()[0]
IndexError: list index out of range
Running ik_openrave.py
without parameters works and displays the PR2 model. What am I doing wrong?
EDIT: Thanks Antons, now I get one step further. Using this xml file...
<Robot name="katana6m90a" file="katana6m90a.dae">
<Manipulator name="arm">
<base>katana_base_link</base>
<effector>katana_gripper_tool_frame</effector>
<joints>katana_l_finger_joint katana_r_finger_joint</joints>
<closingdirection>-1 -1</closingdirection>
<direction>0 0 1</direction>
<translation>0 0 0</translation>
</Manipulator>
</Robot>
... I get:
[openravepy_int.cpp:3272] viewer qtcoin successfully attached
initializing, please wait for ready signal...
[xmlreaders.cpp:2331] Failed to find manipulator base katana_base_link
[xmlreaders.cpp:2323] Failed to find manipulator end effector katana_gripper_tool_frame
[Robot.cpp:2320] manipulator arm has undefined base and end effector links
[Robot.cpp:2329] could not find gripper joint katana_l_finger_joint for manipulator arm
[Robot.cpp:2329] could not find gripper joint katana_r_finger_joint for manipulator arm
terminate called after throwing an instance of 'OpenRAVE::openrave_exception'
what(): openrave (Assert): [/usr/include/boost/smart_ptr/shared_ptr.hpp:418] -> T* boost::shared_ptr< <template-parameter-1-1> >::operator->() const [with T = OpenRAVE::KinBody::Link], expr: px != 0
[1] 25820 abort (core dumped) rosrun orrosplanning ik_openrave.py --scene="katana6m90a.robot.xml"
I had a look at your wubble_description and tried to figure out what I was doing wrong, but no luck. Any more ideas? :-)