BreakAwayDOF Class Reference

#include <dof.h>

Inheritance diagram for BreakAwayDOF:
Inheritance graph
[legend]

List of all members.

Public Member Functions

virtual bool accumulateMove (double q1, double *jointVals, int *stoppedJoints)
 Takes breakaway into account.
 BreakAwayDOF (BreakAwayDOF *original)
 BreakAwayDOF ()
virtual bool computeStaticJointTorques (double *jointTorques, double dofForce=-1)
 Applies breakaway torques.
virtual void getJointValues (double *jointVals) const
 Takes breakaway into account.
virtual double getSaveVal () const
 Returns the breakaway value rather than the current value.
Type getType () const
 Returns the type of this DOF.
void initDOF (Robot *myRobot, const std::list< Joint * > &jList)
 Initializes breakaway flags.
virtual bool readFromStream (QTextStream &stream)
 Also reads in the breakaway status.
virtual bool readParametersFromXml (const TiXmlElement *root)
 Also reads in the breakaway torque level.
virtual void reset ()
 Clears all breakaway flags, re-enages all joints.
virtual void updateFromJointValues (const double *jointVals=NULL)
 Looks at a joint that's not in breakaway.
virtual void updateVal (double q1)
 Sets breakaway values if breakaway has occured.
virtual bool writeToStream (QTextStream &stream)
 Also writes the breakaway status.
 ~BreakAwayDOF ()

Private Attributes

double mBreakAwayTorque
 The level of torque that a breakaway joint applies before disengaging.
double * mBreakAwayValues
 Saves the breakaway values for disengaged joints.
int * mInBreakAway
 Marks which joints controlled by this DOF are disengaged.

Detailed Description

The BreakAwayDOF is a model of the Barrett Hand finger DOFs. If a proximal joint is stopped by contact, the transmission breaks away from that joint and distal joints continue to close. However, a joint that has been disengaged is only re-engaged when the DOF goes back to the value that is had when the joint was disengaged.

Dynamically, breakaway happens when a torque limit on breakaway joints is exceeded. We take that into account in the static joint torque computation. However, for the moment, the dynamics engine does not take that into account.

This class assumes that breakaway only function in one direction, towards the max value of the dof. In real life this is true, as the barrett hand disengages finger joints only when the finger is closing. In simulation, this also helps because it removes any ambiguity when you have to decide what the dof value is based only on joint values.

Definition at line 328 of file dof.h.


Constructor & Destructor Documentation

BreakAwayDOF::BreakAwayDOF (  )  [inline]

Definition at line 340 of file dof.h.

BreakAwayDOF::BreakAwayDOF ( BreakAwayDOF original  )  [inline]

Definition at line 341 of file dof.h.

BreakAwayDOF::~BreakAwayDOF (  ) 

Definition at line 502 of file dof.cpp.


Member Function Documentation

bool BreakAwayDOF::accumulateMove ( double  q1,
double *  jointVals,
int *  stoppedJoints 
) [virtual]

Takes breakaway into account.

If proximal joints are stopped or in breakaway, distal joints continue to close when the dof is moving in the positive direction.

Reimplemented from RigidDOF.

Definition at line 544 of file dof.cpp.

bool BreakAwayDOF::computeStaticJointTorques ( double *  jointTorques,
double  dofForce = -1 
) [virtual]

Applies breakaway torques.

We assume that any joint that is in breakaway is applying exactly the breakaway torque. This is probably not accurate, as after breakaway occurs, the joint is disengaged. But it is accurate in the sense that no joint can apply more than the breakaway torque.

Reimplemented from RigidDOF.

Definition at line 720 of file dof.cpp.

void BreakAwayDOF::getJointValues ( double *  jointVals  )  const [virtual]

Takes breakaway into account.

Each joint is either in breakaway, or connected to the dof value by it's static ratio.

Reimplemented from RigidDOF.

Definition at line 526 of file dof.cpp.

double BreakAwayDOF::getSaveVal (  )  const [virtual]

Returns the breakaway value rather than the current value.

Returns the smallest breakaway value of all the joints of this DOF.

Reimplemented from DOF.

Definition at line 664 of file dof.cpp.

Type BreakAwayDOF::getType (  )  const [inline, virtual]

Returns the type of this DOF.

Reimplemented from RigidDOF.

Definition at line 339 of file dof.h.

void BreakAwayDOF::initDOF ( Robot myRobot,
const std::list< Joint * > &  jList 
) [virtual]

Initializes breakaway flags.

Reimplemented from DOF.

Definition at line 508 of file dof.cpp.

bool BreakAwayDOF::readFromStream ( QTextStream &  stream  )  [virtual]

Also reads in the breakaway status.

Reimplemented from DOF.

Definition at line 679 of file dof.cpp.

bool BreakAwayDOF::readParametersFromXml ( const TiXmlElement root  )  [virtual]

Also reads in the breakaway torque level.

Reimplemented from DOF.

Definition at line 700 of file dof.cpp.

void BreakAwayDOF::reset (  )  [virtual]

Clears all breakaway flags, re-enages all joints.

Clears all the breakaway flags, effectively re-engaging all joints.

Reimplemented from RigidDOF.

Definition at line 638 of file dof.cpp.

void BreakAwayDOF::updateFromJointValues ( const double *  jointVals = NULL  )  [virtual]

Looks at a joint that's not in breakaway.

For this type of dof, the value of any joint that is not in breakaway can give us the value of the dof.

Reimplemented from RigidDOF.

Definition at line 616 of file dof.cpp.

void BreakAwayDOF::updateVal ( double  q1  )  [virtual]

Sets breakaway values if breakaway has occured.

Reimplemented from RigidDOF.

Definition at line 590 of file dof.cpp.

bool BreakAwayDOF::writeToStream ( QTextStream &  stream  )  [virtual]

Also writes the breakaway status.

Reimplemented from DOF.

Definition at line 647 of file dof.cpp.


Member Data Documentation

The level of torque that a breakaway joint applies before disengaging.

Definition at line 336 of file dof.h.

double* BreakAwayDOF::mBreakAwayValues [private]

Saves the breakaway values for disengaged joints.

Definition at line 334 of file dof.h.

Marks which joints controlled by this DOF are disengaged.

Definition at line 332 of file dof.h.


The documentation for this class was generated from the following files:
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines


graspit
Author(s):
autogenerated on Wed Jan 25 11:00:19 2012