BeoSubTwoBal Class Reference

Definition and access functions for the BeoSub. More...

#include <BeoSub/BeoSubTwoBal.H>

Inheritance diagram for BeoSubTwoBal:
Inheritance graph
[legend]
Collaboration diagram for BeoSubTwoBal:
Collaboration graph
[legend]

List of all members.

Public Member Functions

Constructors and Destructors

 BeoSubTwoBal (OptionManager &mgr)
 Constructor.
 ~BeoSubTwoBal ()
 Destructor.
Low-level access functions

void thrust (const float leftval, const float rightval, const bool blocking=false)
 Activate the thrusters.
void getThrusters (float &leftval, float &rightval)
 Get the current thruster settings.
void setLFballast (const float val, const bool blocking=false)
 Set the left-front ballast. Value is between 0.0 (empty) and 1.0 (full).
void setLRballast (const float val, const bool blocking=false)
 Set the left-rear ballast. Value is between 0.0 (empty) and 1.0 (full).
void setRFballast (const float val, const bool blocking=false)
 Set the right-front ballast. Value is between 0.0 (empty) and 1.0 (full).
void setRRballast (const float val, const bool blocking=false)
 Set the right-rear ballast. Value is between 0.0 (empty) and 1.0 (full).
void setBallasts (const float lf, const float lr, const float rf, const float rr, const bool blocking=false)
 Set all ballasts.
float getLFballast ()
 Get the left-front ballast. Value is between 0.0 (empty) and 1.0 (full).
float getLRballast ()
 Get the left-rear ballast. Value is between 0.0 (empty) and 1.0 (full).
float getRFballast ()
 Get the right-front ballast. Value is between 0.0 (empty) and 1.0 (full).
float getRRballast ()
 Get the right-rear ballast. Value is between 0.0 (empty) and 1.0 (full).
void getBallasts (float &lf, float &lr, float &rf, float &rr)
 Get all ballasts.
void dropMarker (const bool blocking=false)
 Drop a marker.
Image< PixRGB< byte > > grabImage (const enum BeoSubCamera cam)
 Grab a an image from one of the cameras.

Protected Member Functions

void start1 ()
 get started, before our subcomponents start
void start2 ()
 get started, after our subcomponents have started

Protected Attributes

NModelParam< int > itsLeftThrusterServoNum
 servo num for left thruster
NModelParam< int > itsRightThrusterServoNum
 servo num for right thruster
nub::soft_ref< HMR3300itsHMR3300
 compass for heading
nub::soft_ref< BeoChipitsBeoLeft
nub::soft_ref< BeoChipitsBeoRight
 our left and rt beochips
rutz::shared_ptr< BeoSubListeneritsBeoLisLeft
rutz::shared_ptr< BeoSubListeneritsBeoLisRight
 listeners
BeoSubSensor< float > itsDepthSensor
 our depth sensor data
nub::soft_ref< BeoSubBallastitsLFballast
nub::soft_ref< BeoSubBallastitsLRballast
nub::soft_ref< BeoSubBallastitsRFballast
nub::soft_ref< BeoSubBallastitsRRballast
 our 4 ballasts
nub::soft_ref< BeoSubIMUitsIMU
 our IMU
nub::soft_ref< IEEE1394grabberitsCameraFront
nub::soft_ref< IEEE1394grabberitsCameraDown
nub::soft_ref< IEEE1394grabberitsCameraUp
 our three cameras
float itsThrustLeft
float itsThrustRight
 our current thruster settings

Friends

class BeoSubListener

Detailed Description

Definition and access functions for the BeoSub.

BeoSub is an autonomous visually-guided submarine. This class impoements the highl-evel functionality, relying on low-level drivers to handle motor activation, compass reading, etc

Definition at line 60 of file BeoSubTwoBal.H.


Constructor & Destructor Documentation

BeoSubTwoBal::BeoSubTwoBal ( OptionManager mgr  ) 
BeoSubTwoBal::~BeoSubTwoBal (  ) 

Destructor.

Definition at line 156 of file BeoSubTwoBal.C.


Member Function Documentation

void BeoSubTwoBal::dropMarker ( const bool  blocking = false  )  [virtual]

Drop a marker.

Implements BeoSub.

void BeoSubTwoBal::getBallasts ( float &  lf,
float &  lr,
float &  rf,
float &  rr 
)

Get all ballasts.

float BeoSubTwoBal::getLFballast (  ) 

Get the left-front ballast. Value is between 0.0 (empty) and 1.0 (full).

float BeoSubTwoBal::getLRballast (  ) 

Get the left-rear ballast. Value is between 0.0 (empty) and 1.0 (full).

float BeoSubTwoBal::getRFballast (  ) 

Get the right-front ballast. Value is between 0.0 (empty) and 1.0 (full).

float BeoSubTwoBal::getRRballast (  ) 

Get the right-rear ballast. Value is between 0.0 (empty) and 1.0 (full).

void BeoSubTwoBal::getThrusters ( float &  leftval,
float &  rightval 
)

Get the current thruster settings.

Definition at line 200 of file BeoSubTwoBal.C.

References itsThrustRight.

Image< PixRGB<byte> > BeoSubTwoBal::grabImage ( const enum BeoSubCamera  cam  ) 

Grab a an image from one of the cameras.

void BeoSubTwoBal::setBallasts ( const float  lf,
const float  lr,
const float  rf,
const float  rr,
const bool  blocking = false 
)

Set all ballasts.

Definition at line 220 of file BeoSubTwoBal.C.

References itsRRballast.

Referenced by start2().

void BeoSubTwoBal::setLFballast ( const float  val,
const bool  blocking = false 
)

Set the left-front ballast. Value is between 0.0 (empty) and 1.0 (full).

Definition at line 204 of file BeoSubTwoBal.C.

void BeoSubTwoBal::setLRballast ( const float  val,
const bool  blocking = false 
)

Set the left-rear ballast. Value is between 0.0 (empty) and 1.0 (full).

Definition at line 208 of file BeoSubTwoBal.C.

void BeoSubTwoBal::setRFballast ( const float  val,
const bool  blocking = false 
)

Set the right-front ballast. Value is between 0.0 (empty) and 1.0 (full).

Definition at line 212 of file BeoSubTwoBal.C.

void BeoSubTwoBal::setRRballast ( const float  val,
const bool  blocking = false 
)

Set the right-rear ballast. Value is between 0.0 (empty) and 1.0 (full).

Definition at line 216 of file BeoSubTwoBal.C.

References itsRRballast.

void BeoSubTwoBal::start1 (  )  [protected, virtual]

get started, before our subcomponents start

Reimplemented from BeoSub.

Definition at line 160 of file BeoSubTwoBal.C.

References itsCameraUp.

void BeoSubTwoBal::start2 (  )  [protected, virtual]

get started, after our subcomponents have started

Reimplemented from ModelComponent.

Definition at line 169 of file BeoSubTwoBal.C.

References itsBeoRight, and setBallasts().

void BeoSubTwoBal::thrust ( const float  leftval,
const float  rightval,
const bool  blocking = false 
)

Activate the thrusters.

Values should be between -1.0 (full reverse) and 1.0 (full forward), 0.0 being no motion

Definition at line 186 of file BeoSubTwoBal.C.

References NModelParam< T >::getVal(), itsBeoRight, itsLeftThrusterServoNum, itsRightThrusterServoNum, and itsThrustRight.


Member Data Documentation

listeners

Definition at line 154 of file BeoSubTwoBal.H.

Referenced by BeoSubTwoBal().

our left and rt beochips

Definition at line 152 of file BeoSubTwoBal.H.

Referenced by BeoSubTwoBal(), start2(), and thrust().

our three cameras

Definition at line 163 of file BeoSubTwoBal.H.

Referenced by BeoSubTwoBal(), and start1().

our depth sensor data

Definition at line 156 of file BeoSubTwoBal.H.

compass for heading

Definition at line 150 of file BeoSubTwoBal.H.

Referenced by BeoSubTwoBal().

our IMU

Definition at line 161 of file BeoSubTwoBal.H.

Referenced by BeoSubTwoBal().

servo num for left thruster

Definition at line 147 of file BeoSubTwoBal.H.

Referenced by thrust().

servo num for right thruster

Definition at line 148 of file BeoSubTwoBal.H.

Referenced by thrust().

our 4 ballasts

Definition at line 158 of file BeoSubTwoBal.H.

Referenced by BeoSubTwoBal(), setBallasts(), and setRRballast().

float BeoSubTwoBal::itsThrustRight [protected]

our current thruster settings

Definition at line 166 of file BeoSubTwoBal.H.

Referenced by getThrusters(), and thrust().


The documentation for this class was generated from the following files:
Generated on Sun May 8 08:43:08 2011 for iLab Neuromorphic Vision Toolkit by  doxygen 1.6.3