moveit IKFast plugin working with demo.launch not working with move_group_interface
I am working with 7DOF Barrett WAM and have created the IKFast plugin using URDF. I tested the plugin using demo.launch and everything works fine. I am also able to use the interactive marker.
The IKFast plugin was also tested before integration with MoveIt! using ikastdemo.cpp, the result was good.
I also set a value for each joint and asked KDL solver and IKFast to solve forward kinematics and then inverse kinematics. I believe the IKFast plugin is working fine since the results of KDL and IKFast are the same, as shown below, the only difference of the inverse kinematics solution is wam/shoulder_yaw_joint, which is reasonable for a redundant manipulator (set the 3rd joint free when I created the IKFast). The rest looks fine.
**IKFAST:**
[ INFO] [1428970205.913659853]: Joint(set) wam/wam_fixed_joint: 0.000000
[ INFO] [1428970205.913681942]: Joint(set) wam/base_yaw_joint: -1.281158
[ INFO] [1428970205.913708099]: Joint(set) wam/shoulder_pitch_joint: 1.658700
[ INFO] [1428970205.913732104]: Joint(set) wam/shoulder_yaw_joint: -2.247921
[ INFO] [1428970205.913758343]: Joint(set) wam/elbow_pitch_joint: 0.219933
[ INFO] [1428970205.913785120]: Joint(set) wam/wrist_yaw_joint: 1.160293
[ INFO] [1428970205.913810199]: Joint(set) wam/wrist_pitch_joint: -1.387798
[ INFO] [1428970205.913832614]: Joint(set) wam/palm_yaw_joint: -0.044969
[ INFO] [1428970205.913894368]: Translation: -0.735978
-0.160909
0.580133
[ INFO] [1428970205.913994440]: Rotation: 0.237783 0.432643 -0.869643
0.411344 0.766221 0.493662
0.879918 -0.475107 0.00422984
[ INFO] [1428970205.920762528]: Joint(IK) wam/wam_fixed_joint: -0.000000
[ INFO] [1428970205.920799765]: Joint(IK) wam/base_yaw_joint: -1.281158
[ INFO] [1428970205.920830629]: Joint(IK) wam/shoulder_pitch_joint: 1.658700
[ INFO] [1428970205.920856726]: Joint(IK) wam/shoulder_yaw_joint: -0.600000
[ INFO] [1428970205.920881040]: Joint(IK) wam/elbow_pitch_joint: 0.219933
[ INFO] [1428970205.920907838]: Joint(IK) wam/wrist_yaw_joint: 1.160293
[ INFO] [1428970205.920929596]: Joint(IK) wam/wrist_pitch_joint: -1.387798
[ INFO] [1428970205.920953596]: Joint(IK) wam/palm_yaw_joint: -0.044969
**KDL:**
[ INFO] [1428970281.101417384]: Joint(set) wam/wam_fixed_joint: 0.000000
[ INFO] [1428970281.101440046]: Joint(set) wam/base_yaw_joint: -1.281158
[ INFO] [1428970281.101466399]: Joint(set) wam/shoulder_pitch_joint: 1.658700
[ INFO] [1428970281.101492322]: Joint(set) wam/shoulder_yaw_joint: -2.247921
[ INFO] [1428970281.101514999]: Joint(set) wam/elbow_pitch_joint: 0.219933
[ INFO] [1428970281.101538865]: Joint(set) wam/wrist_yaw_joint: 1.160293
[ INFO] [1428970281.101561124]: Joint(set) wam/wrist_pitch_joint: -1.387798
[ INFO] [1428970281.101583497]: Joint(set) wam/palm_yaw_joint: -0.044969
[ INFO] [1428970281.101652882]: Translation: -0.735978
-0.160909
0.580133
[ INFO] [1428970281.101756504]: Rotation: 0.237783 0.432643 -0.869643
0.411344 0.766221 0.493662
0.879918 -0.475107 0.00422984
[ INFO] [1428970281.102042516]: Joint(IK) wam/wam_fixed_joint: 0.000000
[ INFO] [1428970281.102078929]: Joint(IK) wam/base_yaw_joint: -1.281158
[ INFO] [1428970281.102105266]: Joint(IK) wam/shoulder_pitch_joint: 1.658700
[ INFO] [1428970281.102128559]: Joint(IK) wam/shoulder_yaw_joint: -0.900000
[ INFO] [1428970281.102151188]: Joint(IK) wam/elbow_pitch_joint: 0.219933
[ INFO] [1428970281.102175909]: Joint(IK) wam/wrist_yaw_joint: 1.160293
[ INFO] [1428970281.102203092]: Joint(IK) wam/wrist_pitch_joint: -1.387798
[ INFO] [1428970281.102230072]: Joint(IK) wam/palm_yaw_joint: -0.044969
However, when I tried to use move_group, the planner always says RRTConnect: Unable to sample any valid states for ...
Dear Huitan, I'm currently trying to work on Barrett Wam too, but I didn't find the package on Moveit wiki, would mind telling me where do you get the wam package ?
Check out JHU repository following this https://github.com/jhu-lcsr (credit goes to JHU). MoveIt! configuration files generated by setupAssistant are under the tab "barrett_moveit". Robot urdf files are under "barrett_model". You need both to work with the arm. Look at PR2 when you have questions.
Hi Huitan, that's exactly what I did, so basically I just download these two packages, put them in my barrett_ws workspace, and then used catkin_make to compile them. However when I tried to launch the demo file, only the arm showed in the Rviz, but the hand was not shown.
Would you mind leaving me you e-mail address ? So I can ask you more about how you configure as well as work with this stuff. THX !
Have a look at your urdf to see what you included and what part you did not. If the hand is not included, then that is what you need to do. The readme file in the "barrett_model" repository may be helpful.
Also please open a new thread when you ask a new question. Besides ROS answers, MoveIt! mailing list is where you can ask questions.