Tekkotsu Homepage | Demos | Overview | Downloads | Dev. Resources | Reference | Credits |
IKThreeLink Class ReferencePerforms analytical solution for position control of a variety of three or fewer link configurations. More...
Inheritance diagram for IKThreeLink:
Detailed DescriptionPerforms analytical solution for position control of a variety of three or fewer link configurations. Link configurations must conform to one of these patterns (R=revolute joint, P=prismatic joint):
Orientation solutions are not supported (yet?) Solutions will degrade gracefully when out of reach, either effector range or joint limit, and should return the closest possible solution. Definition at line 23 of file IKThreeLink.h.
Constructor & Destructor Documentation
constructor Definition at line 26 of file IKThreeLink.h. Member Function Documentation
forwards to either computeFirstLinkRevolute() or computeFirstLinkPrismatic() based on curlink Definition at line 41 of file IKThreeLink.h. Referenced by solve().
sets the angle of curlink based directly on the projected angle of the objective minus the projected angle of the effector point (Plink) Definition at line 175 of file IKThreeLink.cc. Referenced by computeFirstLink().
sets the angle of curlink based directly on the projected angle of the objective minus the projected angle of the effector point (Plink) Definition at line 152 of file IKThreeLink.cc. Referenced by computeFirstLink().
solves for a prismatic link, pass the objective distance squared, the "neck" distance squared, and the inner product of the neck angle, i.e. inner = neck·linkZ = neckD · 1 · cos(neckAng) Definition at line 506 of file IKThreeLink.cc. Referenced by computeSecondLinkPrismatic(), and computeThirdLinkPrismatic().
forwards to either computeSecondLinkRevolute() or computeSecondLinkPrismatic() based on curlink Definition at line 54 of file IKThreeLink.h. Referenced by solve().
sets the length of curlink based on the distance of the objective point, projecting about parent link's z axis (which will be set from computeFirstLink()) First link will perform some rotation, this function needs to set the distance to match the projection of the objective into the plane of rotation. Very similar to computeThirdLinkPrismatic() except how this projection is done (no ring of motion) Definition at line 305 of file IKThreeLink.cc. Referenced by computeSecondLink().
sets the angle of curlink based on the elevation of the objective point vs effector point, projecting about parent link's z axis (which will be set from computeFirstLink()) assumes that z axis of parent frame and current frame are either parallel or orthogonal todo: would be nice if this could handle intermediary angles... currently anything not parallel is assumed to be orthogonal Definition at line 186 of file IKThreeLink.cc. Referenced by computeSecondLink().
forwards to either computeThirdLinkRevolute() or computeThirdLinkPrismatic() based on curlink Definition at line 67 of file IKThreeLink.h. Referenced by solve().
sets the length of curlink based on length of thigh (distance from curlink to parent origin), the angle between the parent and effector point, and the distance from parent to objective. This version is intended mainly for solving to have a pan-tilt camera look at a point in space. The camera is the third link, and should be marked as prismatic. There can be immobile frames between this and the tilt joint, as we often want a specific configuration of x and y axes to match image coordinates. Z must point out of the camera, toward the scene. Plink is ignored. This only solves for the z axis, and that must intersect the pan axis. (The math gets really hairy if the camera is not aligned to a radial from the pan joint.) The approach is similar to computeThirdLinkRevolute(), using
Definition at line 476 of file IKThreeLink.cc. Referenced by computeThirdLink().
sets the angle of curlink based on length of thigh (distance from curlink to parent origin), and distance from curlink to effector point, to achieve desired distance from parent to effector. We'll compute the knee angle first, using:
Two knee (curlink) configurations are supported: parallel to parLink (where parLink.d can be bundled as a z offset of the effector) or parallel to grandparent, with parLink.r==0. In the former case, the parent link's origin forms a ring about the grandparent's link of radius parLink.r. It is the distance of the objective to the ring (or just the center point when parLink.r==0) that curlink must match the effector's distance. Definition at line 341 of file IKThreeLink.cc. Referenced by computeThirdLink(). ensures that t is in the range ±π (upper boundary may not be inclusive...?) Definition at line 83 of file IKThreeLink.h. Referenced by computeFirstLinkRevolute(), computeSecondLinkRevolute(), and computeThirdLinkRevolute().
searches eff parents to assign remain mobile joints into links Definition at line 137 of file IKThreeLink.cc. Referenced by solve().
Solve to get an 'effector' (pEff, oriEff, relative to link following j) to a solution of pTgt, oriTgt (or at least a local minimum).
Implements IKSolver. Definition at line 14 of file IKThreeLink.cc. Referenced by step().
Move an 'effector' (pEff, oriEff, relative to link following j) towards a solution of pTgt, oriTgt (or at least a local minimum). pDist and oriDist specifies the maximum distance to move towards each solution; posPri and oriPri specify relative weighting of each solution in case they are mutually exclusive Implements IKSolver. Definition at line 117 of file IKThreeLink.cc. Member Data Documentation
holds the class name, set via registration with the DeviceDriver registry Definition at line 92 of file IKThreeLink.h.
roundoff for numerical error (probably should split this for angular vs. linear values) Definition at line 36 of file IKThreeLink.h. Referenced by computeFirstLinkRevolute(), computeSecondLinkRevolute(), computeThirdLinkRevolute(), and solve().
set to true if there is another solution within range Definition at line 87 of file IKThreeLink.h. Referenced by computeSecondLinkRevolute(), computeThirdLinkRevolute(), and solve().
alternative angle for knee Definition at line 88 of file IKThreeLink.h. Referenced by computeSecondLinkRevolute(), computeThirdLinkRevolute(), and solve().
there are two knee solutions, this will choose the non-default solution. Definition at line 85 of file IKThreeLink.h. Referenced by solve(). The documentation for this class was generated from the following files: |
Tekkotsu v5.1CVS |
Generated Mon May 9 04:59:09 2016 by Doxygen 1.6.3 |