BeoSub Ballast Class - responsible for the lower level movement of the Sub. More...
#include <BeoSub/BeoSubBallast.H>
Public Member Functions | |
BeoSubBallast (OptionManager &mgr, const std::string &descrName="BeoSubBallast", const std::string &tagName="BeoSubBallast") | |
Constructor. | |
void | setBeoChip (nub::soft_ref< BeoChip > &bc) |
Set our BeoChip. | |
~BeoSubBallast () | |
Destructor. | |
void | mechanicalInitialize () |
Initialize the ballast by probing its endpoints. | |
void | set (const float val, const bool blocking=false) |
Set to a given fill level, between 0.0 (empty) and 1.0 (full). | |
float | get () const |
Get the current level, between 0.0 (empty) and 1.0 (full). | |
int | getPulses () const |
Get the current level, in number of pulses. | |
void | input (const int val) |
Something changed on the BeoChip's inputs. | |
bool | moving () const |
Are we moving? | |
Protected Attributes | |
NModelParam< int > | itsPulsesPerFill |
how many pulses per full travel? | |
NModelParam< int > | itsOutRed |
BeoChip digital out number for red wire. | |
NModelParam< int > | itsOutWhite |
BeoChip digital out number for wht wire. | |
NModelParam< int > | itsInYellow |
BeoChip keyboard in number for yellow wire. | |
NModelParam< int > | itsInWhite |
BeoChip keyboard in number for yellow wire. |
BeoSub Ballast Class - responsible for the lower level movement of the Sub.
This is the class that does the actual workhorse of moving ballast This class gets instantiated in BeoSub constructor.
Definition at line 51 of file BeoSubBallast.H.
BeoSubBallast::BeoSubBallast | ( | OptionManager & | mgr, | |
const std::string & | descrName = "BeoSubBallast" , |
|||
const std::string & | tagName = "BeoSubBallast" | |||
) |
BeoSubBallast::~BeoSubBallast | ( | ) |
Destructor.
Definition at line 64 of file BeoSubBallast.C.
float BeoSubBallast::get | ( | ) | const |
Get the current level, between 0.0 (empty) and 1.0 (full).
Definition at line 126 of file BeoSubBallast.C.
References NModelParam< T >::getVal(), and itsPulsesPerFill.
int BeoSubBallast::getPulses | ( | ) | const |
Get the current level, in number of pulses.
Definition at line 135 of file BeoSubBallast.C.
void BeoSubBallast::input | ( | const int | val | ) |
Something changed on the BeoChip's inputs.
Definition at line 144 of file BeoSubBallast.C.
References NModelParam< T >::getVal(), itsInWhite, itsInYellow, and itsPulsesPerFill.
void BeoSubBallast::mechanicalInitialize | ( | ) |
Initialize the ballast by probing its endpoints.
Definition at line 106 of file BeoSubBallast.C.
bool BeoSubBallast::moving | ( | ) | const |
Are we moving?
Definition at line 329 of file BeoSubBallast.C.
void BeoSubBallast::set | ( | const float | val, | |
const bool | blocking = false | |||
) |
Set to a given fill level, between 0.0 (empty) and 1.0 (full).
Definition at line 70 of file BeoSubBallast.C.
References nub::soft_ref< T >::get(), NModelParam< T >::getVal(), and itsPulsesPerFill.
void BeoSubBallast::setBeoChip | ( | nub::soft_ref< BeoChip > & | bc | ) |
Set our BeoChip.
Definition at line 60 of file BeoSubBallast.C.
NModelParam<int> BeoSubBallast::itsInWhite [protected] |
BeoChip keyboard in number for yellow wire.
Definition at line 90 of file BeoSubBallast.H.
Referenced by input().
NModelParam<int> BeoSubBallast::itsInYellow [protected] |
BeoChip keyboard in number for yellow wire.
Definition at line 89 of file BeoSubBallast.H.
Referenced by input().
NModelParam<int> BeoSubBallast::itsOutRed [protected] |
BeoChip digital out number for red wire.
Definition at line 87 of file BeoSubBallast.H.
NModelParam<int> BeoSubBallast::itsOutWhite [protected] |
BeoChip digital out number for wht wire.
Definition at line 88 of file BeoSubBallast.H.
NModelParam<int> BeoSubBallast::itsPulsesPerFill [protected] |
how many pulses per full travel?
Definition at line 86 of file BeoSubBallast.H.