MovingLegs Class Reference

#include <MovingLegs.h>

List of all members.

Public Member Functions

 MovingLegs ()
virtual ~MovingLegs ()
virtual OStatus DoInit (const OSystemEvent &event)
virtual OStatus DoStart (const OSystemEvent &event)
virtual OStatus DoStop (const OSystemEvent &event)
virtual OStatus DoDestroy (const OSystemEvent &event)
void NotifyCommand (const ONotifyEvent &event)
void ReadyMove (const OReadyEvent &event)
 MovingLegs ()
virtual ~MovingLegs ()
virtual OStatus DoInit (const OSystemEvent &event)
virtual OStatus DoStart (const OSystemEvent &event)
virtual OStatus DoStop (const OSystemEvent &event)
virtual OStatus DoDestroy (const OSystemEvent &event)
void Ready (const OReadyEvent &event)

Public Attributes

OSubject * subject [numOfSubject]
OObserver * observer [numOfObserver]
OSubject * subject [numOfSubject]
OObserver * observer [numOfObserver]

Private Member Functions

void OpenPrimitives ()
void NewCommandVectorData ()
void SetJointGain ()
MovingResult AdjustDiffJointValue ()
MovingResult MoveToBroadBase ()
MovingResult MoveToSleeping ()
RCRegion * FindFreeRegion ()
void SetJointValue (RCRegion *rgn, int idx, double start, double end)
void OpenPrimitives ()
void NewCommandVectorData ()
void SetJointGain ()
MovingResult AdjustDiffJointValue ()
MovingResult MoveToBroadBase ()
MovingResult MoveToSleeping ()
RCRegion * FindFreeRegion ()
void SetJointValue (RCRegion *rgn, int idx, double start, double end)

Private Attributes

MovingLegsState movingLegsState
OPrimitiveID jointID [NUM_JOINTS]
RCRegion * region [NUM_COMMAND_VECTOR]
RCRegion * region [NUM_COMMAND_VECTOR]

Static Private Attributes

const size_t NUM_JOINTS = 12
const size_t NUM_COMMAND_VECTOR = 2
const word J1_PGAIN = 0x0016
const word J1_IGAIN = 0x0004
const word J1_DGAIN = 0x0008
const word J2_PGAIN = 0x0014
const word J2_IGAIN = 0x0004
const word J2_DGAIN = 0x0006
const word J3_PGAIN = 0x0023
const word J3_IGAIN = 0x0004
const word J3_DGAIN = 0x0005
const word PSHIFT = 0x000e
const word ISHIFT = 0x0002
const word DSHIFT = 0x000f
const int BROADBASE_MAX_COUNTER = 48
const int SLEEPING_MAX_COUNTER = 48


Constructor & Destructor Documentation

MovingLegs::MovingLegs  ) 
 

Definition at line 20 of file BallTrackingHead/MovingLegs2/MovingLegs.cc.

References jointID, MLS_IDLE, and region.

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

Definition at line 90 of file BallTrackingHead/MovingLegs2/MovingLegs.h.

MovingLegs::MovingLegs  ) 
 

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

Definition at line 90 of file MovingLegs/MovingLegs/MovingLegs.h.


Member Function Documentation

MovingResult MovingLegs::AdjustDiffJointValue  )  [private]
 

MovingResult MovingLegs::AdjustDiffJointValue  )  [private]
 

Definition at line 219 of file BallTrackingHead/MovingLegs2/MovingLegs.cc.

References GetJointValue(), jointID, region, SetJointValue(), and subject.

Referenced by NotifyCommand(), Ready(), and ReadyMove().

virtual OStatus MovingLegs::DoDestroy const OSystemEvent &  event  )  [virtual]
 

OStatus MovingLegs::DoDestroy const OSystemEvent &  event  )  [virtual]
 

Definition at line 71 of file BallTrackingHead/MovingLegs2/MovingLegs.cc.

virtual OStatus MovingLegs::DoInit const OSystemEvent &  event  )  [virtual]
 

OStatus MovingLegs::DoInit const OSystemEvent &  event  )  [virtual]
 

Definition at line 27 of file BallTrackingHead/MovingLegs2/MovingLegs.cc.

References NewCommandVectorData(), and OpenPrimitives().

virtual OStatus MovingLegs::DoStart const OSystemEvent &  event  )  [virtual]
 

OStatus MovingLegs::DoStart const OSystemEvent &  event  )  [virtual]
 

Definition at line 47 of file BallTrackingHead/MovingLegs2/MovingLegs.cc.

virtual OStatus MovingLegs::DoStop const OSystemEvent &  event  )  [virtual]
 

OStatus MovingLegs::DoStop const OSystemEvent &  event  )  [virtual]
 

Definition at line 58 of file BallTrackingHead/MovingLegs2/MovingLegs.cc.

References movingLegsState.

RCRegion* MovingLegs::FindFreeRegion  )  [private]
 

RCRegion * MovingLegs::FindFreeRegion  )  [private]
 

Definition at line 311 of file BallTrackingHead/MovingLegs2/MovingLegs.cc.

References region.

Referenced by MoveToBroadBase(), and MoveToSleeping().

MovingResult MovingLegs::MoveToBroadBase  )  [private]
 

MovingResult MovingLegs::MoveToBroadBase  )  [private]
 

Definition at line 238 of file BallTrackingHead/MovingLegs2/MovingLegs.cc.

References BROADBASE_ANGLE, FindFreeRegion(), GetJointValue(), jointID, MOVING_FINISH, SetJointValue(), and subject.

Referenced by Ready(), and ReadyMove().

MovingResult MovingLegs::MoveToSleeping  )  [private]
 

MovingResult MovingLegs::MoveToSleeping  )  [private]
 

Definition at line 280 of file BallTrackingHead/MovingLegs2/MovingLegs.cc.

References BROADBASE_ANGLE, FindFreeRegion(), MOVING_FINISH, SetJointValue(), SLEEPING_ANGLE, and subject.

Referenced by Ready(), and ReadyMove().

void MovingLegs::NewCommandVectorData  )  [private]
 

void MovingLegs::NewCommandVectorData  )  [private]
 

Definition at line 161 of file BallTrackingHead/MovingLegs2/MovingLegs.cc.

References jointID, NUM_JOINTS, and region.

Referenced by DoInit().

void MovingLegs::NotifyCommand const ONotifyEvent &  event  ) 
 

Definition at line 78 of file BallTrackingHead/MovingLegs2/MovingLegs.cc.

References AdjustDiffJointValue(), BTH_INVALID_ARG, movingLegsState, observer, subject, and BallTrackingHeadCommand::type.

void MovingLegs::OpenPrimitives  )  [private]
 

void MovingLegs::OpenPrimitives  )  [private]
 

Definition at line 148 of file BallTrackingHead/MovingLegs2/MovingLegs.cc.

References jointID.

Referenced by DoInit().

void MovingLegs::Ready const OReadyEvent &  event  ) 
 

Definition at line 82 of file MovingLegs/MovingLegs/MovingLegs.cc.

References AdjustDiffJointValue(), MoveToBroadBase(), MoveToSleeping(), movingLegsState, MovingResult, and SetJointGain().

void MovingLegs::ReadyMove const OReadyEvent &  event  ) 
 

Definition at line 104 of file BallTrackingHead/MovingLegs2/MovingLegs.cc.

References AdjustDiffJointValue(), BTH_SUCCESS, MoveToBroadBase(), MoveToSleeping(), movingLegsState, MovingResult, SetJointGain(), and subject.

void MovingLegs::SetJointGain  )  [private]
 

void MovingLegs::SetJointGain  )  [private]
 

Definition at line 193 of file BallTrackingHead/MovingLegs2/MovingLegs.cc.

References DSHIFT, ISHIFT, J1_DGAIN, J1_IGAIN, J1_PGAIN, J2_DGAIN, J2_IGAIN, J2_PGAIN, J3_DGAIN, J3_IGAIN, J3_PGAIN, jointID, and PSHIFT.

Referenced by Ready(), and ReadyMove().

void MovingLegs::SetJointValue RCRegion *  rgn,
int  idx,
double  start,
double  end
[private]
 

void MovingLegs::SetJointValue RCRegion *  rgn,
int  idx,
double  start,
double  end
[private]
 

Definition at line 321 of file BallTrackingHead/MovingLegs2/MovingLegs.cc.

References jointID.

Referenced by AdjustDiffJointValue(), MoveToBroadBase(), and MoveToSleeping().


Member Data Documentation

const int MovingLegs::BROADBASE_MAX_COUNTER = 48 [static, private]
 

Definition at line 132 of file MovingLegs/MovingLegs/MovingLegs.h.

const word MovingLegs::DSHIFT = 0x000f [static, private]
 

Definition at line 130 of file MovingLegs/MovingLegs/MovingLegs.h.

Referenced by SetJointGain().

const word MovingLegs::ISHIFT = 0x0002 [static, private]
 

Definition at line 129 of file MovingLegs/MovingLegs/MovingLegs.h.

Referenced by SetJointGain().

const word MovingLegs::J1_DGAIN = 0x0008 [static, private]
 

Definition at line 118 of file MovingLegs/MovingLegs/MovingLegs.h.

Referenced by SetJointGain().

const word MovingLegs::J1_IGAIN = 0x0004 [static, private]
 

Definition at line 117 of file MovingLegs/MovingLegs/MovingLegs.h.

Referenced by SetJointGain().

const word MovingLegs::J1_PGAIN = 0x0016 [static, private]
 

Definition at line 116 of file MovingLegs/MovingLegs/MovingLegs.h.

Referenced by SetJointGain().

const word MovingLegs::J2_DGAIN = 0x0006 [static, private]
 

Definition at line 122 of file MovingLegs/MovingLegs/MovingLegs.h.

Referenced by SetJointGain().

const word MovingLegs::J2_IGAIN = 0x0004 [static, private]
 

Definition at line 121 of file MovingLegs/MovingLegs/MovingLegs.h.

Referenced by SetJointGain().

const word MovingLegs::J2_PGAIN = 0x0014 [static, private]
 

Definition at line 120 of file MovingLegs/MovingLegs/MovingLegs.h.

Referenced by SetJointGain().

const word MovingLegs::J3_DGAIN = 0x0005 [static, private]
 

Definition at line 126 of file MovingLegs/MovingLegs/MovingLegs.h.

Referenced by SetJointGain().

const word MovingLegs::J3_IGAIN = 0x0004 [static, private]
 

Definition at line 125 of file MovingLegs/MovingLegs/MovingLegs.h.

Referenced by SetJointGain().

const word MovingLegs::J3_PGAIN = 0x0023 [static, private]
 

Definition at line 124 of file MovingLegs/MovingLegs/MovingLegs.h.

Referenced by SetJointGain().

OPrimitiveID MovingLegs::jointID [private]
 

Definition at line 136 of file MovingLegs/MovingLegs/MovingLegs.h.

Referenced by AdjustDiffJointValue(), MoveToBroadBase(), MovingLegs(), NewCommandVectorData(), OpenPrimitives(), SetJointGain(), and SetJointValue().

MovingLegsState MovingLegs::movingLegsState [private]
 

Definition at line 135 of file MovingLegs/MovingLegs/MovingLegs.h.

Referenced by DoStop(), NotifyCommand(), Ready(), and ReadyMove().

const size_t MovingLegs::NUM_COMMAND_VECTOR = 2 [static, private]
 

Definition at line 114 of file MovingLegs/MovingLegs/MovingLegs.h.

const size_t MovingLegs::NUM_JOINTS = 12 [static, private]
 

Definition at line 113 of file MovingLegs/MovingLegs/MovingLegs.h.

Referenced by NewCommandVectorData().

OObserver* MovingLegs::observer[numOfObserver]
 

Definition at line 93 of file MovingLegs/MovingLegs/MovingLegs.h.

OObserver* MovingLegs::observer[numOfObserver]
 

Definition at line 93 of file BallTrackingHead/MovingLegs2/MovingLegs.h.

Referenced by NotifyCommand().

const word MovingLegs::PSHIFT = 0x000e [static, private]
 

Definition at line 128 of file MovingLegs/MovingLegs/MovingLegs.h.

Referenced by SetJointGain().

RCRegion* MovingLegs::region[NUM_COMMAND_VECTOR] [private]
 

Definition at line 137 of file MovingLegs/MovingLegs/MovingLegs.h.

RCRegion* MovingLegs::region[NUM_COMMAND_VECTOR] [private]
 

Definition at line 138 of file BallTrackingHead/MovingLegs2/MovingLegs.h.

Referenced by AdjustDiffJointValue(), FindFreeRegion(), MovingLegs(), and NewCommandVectorData().

const int MovingLegs::SLEEPING_MAX_COUNTER = 48 [static, private]
 

Definition at line 133 of file MovingLegs/MovingLegs/MovingLegs.h.

OSubject* MovingLegs::subject[numOfSubject]
 

Definition at line 92 of file MovingLegs/MovingLegs/MovingLegs.h.

OSubject* MovingLegs::subject[numOfSubject]
 

Definition at line 92 of file BallTrackingHead/MovingLegs2/MovingLegs.h.

Referenced by AdjustDiffJointValue(), MoveToBroadBase(), MoveToSleeping(), NotifyCommand(), and ReadyMove().


The documentation for this class was generated from the following files:
Generated on Sun Dec 2 23:04:34 2007 for openSDK by  doxygen 1.3.9.1