-
Notifications
You must be signed in to change notification settings - Fork 17
IK Service Example
The IK Test example shows the very basics of calling the on-robot Inverse-Kinematics (IK) Service to obtain a joint angles solution for a given endpoint Cartesian point & orientation.
From an RSDK shell, run the ik_test.py demo from the inverse_kinematics package, with an argument of 'left' or 'right' arm, Ex:
bash $ rosrun inverse_kinematics ik_test.py left
The test will call the IK Service for a hard-coded Cartesian Pose for the given arm. The response will then be printed to the screen with the found joint solution and a True/False if the solution is a valid configuration for Baxter's arm.
The 'inverse_kinematics' test code is an example of how to communicate with a robot-side ROS node that provides an Inverse-Kinematics (IK) service. Normal arm control is done using joint angles or states; for instance, position joint control allows the user to set the position in radians for each shoulder, elbow, and wrist joint. Often in robotics manipulation, it can be useful to work in the Cartesian space of the arm's endpoint. Inverse Kinematics is used to convert between the Cartesian (x,y,z, roll, pitch, yaw) space representation, to actual controllable 7-DOF joint states.
The example script simply calls the service for a canonical Cartesian point + orientation for either the left or right arm and as such merely provides the most basic example of how to use this service. Note that we provide this service just to have some out of the box method for IK. The complicated nature of 7-DOF Inverse Kinematics control, usually means the best IK implementations are customized for a specific use case. The node is not a complete Cartesian control solution, just a rudimentary solver exposed for convenience in elementary situations.
For anything needing high-performance IK, it makes a lot more sense to implement it on the development machine.
For more information on Arm Control, see Using the Arms.
See the API Reference page for details.
- IK Solver Service:
/sdk/robot/limb/<limb>/solve_ik_position
None used.
For common issues using examples with Baxter, check out the Troubleshooting page.
© 2008-2013 Rethink Robotics. All rights reserved.