Main Page   Modules   Namespace List   Class Hierarchy   Alphabetical List   Compound List   File List   Namespace Members   Compound Members   File Members   Related Pages  

OSCAR::FKPosition Class Reference
[ForwardKinematics]

#include <FKPosition.h>

Inheritance diagram for OSCAR::FKPosition:

Inheritance graph
[legend]
List of all members.

Public Methods

 FKPosition (const String &DHfilename, OSCARError &err=DUMMY_ERROR(noError), const String &name=String(""))
 FKPosition (const DHData &dhParams, OSCARError &err=DUMMY_ERROR(noError), const String &name=String(""))
 FKPosition (const FKPosition &fkp)
FKPosition & operator= (const FKPosition &fkp)
const XformGetHandPose (const Vector &jointVector)
const XformGetLocalTransformation (unsigned int jointNo) const
const XformGetLocalTransformation (unsigned int jointNo, const Vector &jointVector)
const XformGetGlobalTransformation (unsigned int jointNo) const
const XformGetGlobalTransformation (unsigned int jointNo, const Vector &jointVector)
const XformGetAllLocalTransformations () const
const XformGetAllLocalTransformations (const Vector &jointVector)
const XformGetAllGlobalTransformations () const
const XformGetAllGlobalTransformations (const Vector &jointVector)
virtual ~FKPosition ()

Protected Methods

virtual void calculateTransformations (const Vector &input_vector)
virtual void calculateLinkTransformation (int joint_no, double joint_value)
virtual void calculateLinkToBaseTransformations (const Vector &input_vector)
void makeToolPointAdjustment (void)
void makeRobotPoseAdjustment (void)
void initialize (void)

Protected Attributes

double * cosalpha
double * sinalpha
double * costheta
double * sintheta
XformlocalTransformations
XformlinkToBase

Detailed Description

Author:
Chetan Kapoor FKPosition implements a generalized forward position solution that uses DH parameters to formulate it. Using this class, the user can get all the local and global transformation matrices for each link and the end effector of the robot. Also, the base frame and the tool frame of the robot can also be set. Use this class to convert input joint positions (in radians for angles) into end effector position and orientations.


Constructor & Destructor Documentation

OSCAR::FKPosition::FKPosition const String   DHfilename,
OSCARError   err = DUMMY_ERROR(noError),
const String   name = String("")
 

Constructor for FKPosition.

Use this constructor to Construct an FKPosition object from DHParameters supplied in a datafile

Returns:
This method does not return any values. Error information is returned in the 'err' argument.
Parameters:
DHfilename String object that specifies the name and path of the file that contains the DH parameters.
err OSCARError pointer that holds the value of the error code that was generated when the constructor was called. If this error was not 'noError' you can call GetError() to get the details of the error code.
name Name assigned to object
Exceptions:
FileNotFound #FileNotFound
badFileData badFileData
dhParamsIllFormed dhParamsIllFormed

OSCAR::FKPosition::FKPosition const DHData   dhParams,
OSCARError   err = DUMMY_ERROR(noError),
const String   name = String("")
 

Second Constructor for FKPosition.

Use this constructor to Construct an FKPosition object from DHParameters supplied in an DHData object.

Returns:
This method does not return any values. Error information is returned in the 'err' argument.
Parameters:
dhParams An DHData object that holds the DH parameters for the robot in whose forward position solution needs to be computed
err A pointer to OSCARError that holds the value of the error code that was generated when the constructor was called. If this error was not 'noError' you can call GetError() to get the details of the error code.
name Name you want to assign to the object
Exceptions:
dhParamsIllFormed dhParamsIllFormed

OSCAR::FKPosition::FKPosition const FKPosition &    fkp
 

Copy Constructor for FKPosition.

Use this method to construct an FKPosition object from an existing FKPosition object.

Returns:
This method does not return any values.
Parameters:
fkp An FKPosition object that will be used to initialize this new object.

virtual OSCAR::FKPosition::~FKPosition   [virtual]
 


Member Function Documentation

virtual void OSCAR::FKPosition::calculateLinkToBaseTransformations const Vector   input_vector [protected, virtual]
 

virtual void OSCAR::FKPosition::calculateLinkTransformation int    joint_no,
double    joint_value
[protected, virtual]
 

virtual void OSCAR::FKPosition::calculateTransformations const Vector   input_vector [protected, virtual]
 

const Xform* OSCAR::FKPosition::GetAllGlobalTransformations const Vector   jointVector
 

This method returns a pointer to the global transformation matrices. All the global transformation matrices are computer for the input joint vector jointVector.

Returns:
A pointer to the global transformation matrices array. Array size is DOF + 1. The last xform is associated with the tool point. A 0 is returned if there is an error.
Parameters:
jointVector A vector holding the joint positions for which the forward position solution has to be computed.

const Xform* OSCAR::FKPosition::GetAllGlobalTransformations   const
 

This method returns a pointer to an array of Xform's that holds the global tranformation matrices (size=DOF+1 of the robot). These global transformations were computed during the last call to any of the other methods with a joint vector as the argument.

Returns:
A pointer to the global transformation matrices array. Array size is DOF + 1. The last xform is associated with the tool point.

const Xform* OSCAR::FKPosition::GetAllLocalTransformations const Vector   jointVector
 

This method returns a pointer to the array of local transformation matrices. All the local transformation matrices are computer for the input joint vector jointVector.

Returns:
A pointer to the array of local transformation matrices of size DOF.
Parameters:
jointVector A vector holding the joint positions for which the forward position solution has to be computed.

const Xform* OSCAR::FKPosition::GetAllLocalTransformations   const
 

This method returns a pointer to an array of Xform's that holds the local tranformation matrices (size=DOF of the robot). These local transformations were computed during the last call to any of the other methods with a joint vector as the argument.

Returns:
A pointer to the local transformation matrices array.

const Xform* OSCAR::FKPosition::GetGlobalTransformation unsigned int    jointNo,
const Vector   jointVector
 

This method returns a pointer to the global transformation matrix for the jointNo joint. All the global transformation matrices are computed for the input joint vector jointVector.

Returns:
A pointer to the global transformation matrix.
Parameters:
jointNo The number of the link for which the global transformation matrix is desired. Valid values for this are 0 to DOF. If jointNo is DOF, then the global transformation matrix associated. with the tool point is returned. For last link, give jointNo = DOF -1
jointVector A vector holding the joint positions for which the forward position solution has to be completed.

const Xform* OSCAR::FKPosition::GetGlobalTransformation unsigned int    jointNo const
 

This method returns a pointer to the global transformation matrix for the jointNo joint. This global transformation was computed during the last call to any of the methods with a joint vector as the argument.

Returns:
A pointer to the local transformation matrix.
Parameters:
jointNo The number of the link for which the global transformation matrix is desired. Valid values for this are 0 to DOF. If jointNo is DOF, then the global transformation matrix associated. with the tool point is returned. For last link, give jointNo = DOF -1

const Xform* OSCAR::FKPosition::GetHandPose const Vector   jointVector [virtual]
 

Method to Compute the forward position solution for the last link (or tool point) of a robot.

Use this to compute the tool point position and orientation

Returns:
Returns a const pointer to an Xform that holds the tool point (or last link) transformation matrix expressed in the base frame. If there is an error in this method a 0 should be returned.
Parameters:
jointVector A vector containing the joint angles (in radians) or joint positions at which the forward position solution needs to be computed. The size of this vector should be equal to the DOF of the robot. If this is not the case, a 0 is returned. Call GetError() to get detailed error information
Exceptions:
argumentSizeMismatch argumentSizeMismatch

Implements OSCAR::FKPositionBase.

const Xform* OSCAR::FKPosition::GetLocalTransformation unsigned int    jointNo,
const Vector   jointVector
 

This method returns a pointer to the local transformation matrix for the jointNo joint. All the local transformation matrices are computed for the input joint vector jointVector.

Returns:
A pointer to the local transformation matrix.
Parameters:
jointNo The number of the link for which the local transformation matrix is desired.
jointVector A vector holding the joint positions for which the forward position solution has to be completed.

const Xform* OSCAR::FKPosition::GetLocalTransformation unsigned int    jointNo const
 

This method returns a pointer to the local transformation matrix for the jointNo joint. This local transformation was computed during the last call to any of the other methods with a joint vector argument.

Returns:
A pointer to the local transformation matrix.
Parameters:
jointNo The number of the link for which the local transformation matrix is desired.

void OSCAR::FKPosition::initialize void    [protected]
 

void OSCAR::FKPosition::makeRobotPoseAdjustment void    [protected]
 

void OSCAR::FKPosition::makeToolPointAdjustment void    [protected]
 

FKPosition& OSCAR::FKPosition::operator= const FKPosition &    fkp
 

operator = for FKPosition

Use this method to copy an FKPosition object into another FKPosition object.

Returns:
This method does not return any values.
Parameters:
fkp An FKPosition object that will be used for copying.


Member Data Documentation

double* OSCAR::FKPosition::cosalpha [protected]
 

double* OSCAR::FKPosition::costheta [protected]
 

Xform* OSCAR::FKPosition::linkToBase [protected]
 

Xform* OSCAR::FKPosition::localTransformations [protected]
 

double * OSCAR::FKPosition::sinalpha [protected]
 

double * OSCAR::FKPosition::sintheta [protected]
 


The documentation for this class was generated from the following file:
RRG Homepage OSCAR Overview OSCAR Tutorials Simulations