Homepage
Demos
Overview
Downloads
Dev. Resources
Reference
Credits

TailWagMC Class Reference

#include <TailWagMC.h>

Inheritance diagram for TailWagMC:

Inheritance graph
[legend]
List of all members.

Detailed Description

A simple motion command for wagging the tail - you can specify period, magnitude, and tilt.

Definition at line 14 of file TailWagMC.h.

Public Member Functions

 TailWagMC ()
 constructor
 TailWagMC (unsigned int cyc_period, float cyc_magnitude)
 constructor
virtual ~TailWagMC ()
 destructor
virtual int updateOutputs ()
 is called once per update cycle, can do any processing you need to change your priorities or set output commands on the MotionManager
virtual int isDirty ()
 not used by MotionManager at the moment, but could be used to reduce recomputation, and you may find it useful
virtual int isAlive ()
 used to prune "dead" motions from the MotionManager
void setPeriod (unsigned int p)
 sets the period of time between swings, in milliseconds
unsigned int getPeriod ()
 gets the period of time between swings, in milliseconds
void setMagnitude (double mag)
 sets the magnitude of swings, in radians
double getMagnitude ()
 gets the magnitude of swings, in radians
void setTilt (double r)
 sets the tilt of the tail while wagging, in radians
void unsetTilt ()
 makes the tilt control unspecified, will let something else control tilt
double getTilt ()
 sets the tilt of the tail while wagging, in radians
void setActive (bool a)
 turns the tail wagger on or off
bool getActive ()
 returns true if this is currently trying to wag the tail

Protected Attributes

unsigned int period
 period of time between swings, in milliseconds
double magnitude
 magnitude of swings, in radians
bool active
 true if this is currently trying to wag the tail
OutputCmd tilt
 holds current setting for the tilt joint
OutputCmd pans [NumFrames]
 holds commands for planning ahead the wagging


Constructor & Destructor Documentation

TailWagMC::TailWagMC  )  [inline]
 

constructor

Definition at line 17 of file TailWagMC.h.

TailWagMC::TailWagMC unsigned int  cyc_period,
float  cyc_magnitude
[inline]
 

constructor

Definition at line 19 of file TailWagMC.h.

virtual TailWagMC::~TailWagMC  )  [inline, virtual]
 

destructor

Definition at line 21 of file TailWagMC.h.


Member Function Documentation

bool TailWagMC::getActive  )  [inline]
 

returns true if this is currently trying to wag the tail

Definition at line 51 of file TailWagMC.h.

double TailWagMC::getMagnitude  )  [inline]
 

gets the magnitude of swings, in radians

Definition at line 46 of file TailWagMC.h.

unsigned int TailWagMC::getPeriod  )  [inline]
 

gets the period of time between swings, in milliseconds

Definition at line 44 of file TailWagMC.h.

double TailWagMC::getTilt  )  [inline]
 

sets the tilt of the tail while wagging, in radians

Definition at line 49 of file TailWagMC.h.

virtual int TailWagMC::isAlive  )  [inline, virtual]
 

used to prune "dead" motions from the MotionManager

note that a motion could be "paused" or inactive and therefore not dirty, but still alive, biding its time to "strike" ;)

Returns:
zero if the motion is still processing, non-zero otherwise

Implements MotionCommand.

Definition at line 41 of file TailWagMC.h.

virtual int TailWagMC::isDirty  )  [inline, virtual]
 

not used by MotionManager at the moment, but could be used to reduce recomputation, and you may find it useful

Returns:
zero if none of the commands have changed since last getJointCmd(), else non-zero

Implements MotionCommand.

Definition at line 40 of file TailWagMC.h.

void TailWagMC::setActive bool  a  )  [inline]
 

turns the tail wagger on or off

Definition at line 50 of file TailWagMC.h.

void TailWagMC::setMagnitude double  mag  )  [inline]
 

sets the magnitude of swings, in radians

Definition at line 45 of file TailWagMC.h.

void TailWagMC::setPeriod unsigned int  p  )  [inline]
 

sets the period of time between swings, in milliseconds

Definition at line 43 of file TailWagMC.h.

void TailWagMC::setTilt double  r  )  [inline]
 

sets the tilt of the tail while wagging, in radians

Definition at line 47 of file TailWagMC.h.

void TailWagMC::unsetTilt  )  [inline]
 

makes the tilt control unspecified, will let something else control tilt

Definition at line 48 of file TailWagMC.h.

virtual int TailWagMC::updateOutputs  )  [inline, virtual]
 

is called once per update cycle, can do any processing you need to change your priorities or set output commands on the MotionManager

Returns:
zero if no changes were made, non-zero otherwise
See also:
RobotInfo::NumFrames

RobotInfo::FrameTime

Implements MotionCommand.

Definition at line 22 of file TailWagMC.h.


Member Data Documentation

bool TailWagMC::active [protected]
 

true if this is currently trying to wag the tail

Definition at line 56 of file TailWagMC.h.

Referenced by getActive(), isDirty(), setActive(), and updateOutputs().

double TailWagMC::magnitude [protected]
 

magnitude of swings, in radians

Definition at line 55 of file TailWagMC.h.

Referenced by getMagnitude(), setMagnitude(), and updateOutputs().

OutputCmd TailWagMC::pans[NumFrames] [protected]
 

holds commands for planning ahead the wagging

Definition at line 58 of file TailWagMC.h.

Referenced by updateOutputs().

unsigned int TailWagMC::period [protected]
 

period of time between swings, in milliseconds

Definition at line 54 of file TailWagMC.h.

Referenced by getPeriod(), setPeriod(), and updateOutputs().

OutputCmd TailWagMC::tilt [protected]
 

holds current setting for the tilt joint

Definition at line 57 of file TailWagMC.h.

Referenced by getTilt(), setTilt(), unsetTilt(), and updateOutputs().


The documentation for this class was generated from the following file:

Tekkotsu v2.4.1
Generated Tue Aug 16 16:35:10 2005 by Doxygen 1.4.4