DUNE: Uniform Navigational Environment  2016.09.0
Maneuver::Multiplexer::PopUp Class Reference

Detailed Description

PopUp maneuver.

Public Member Functions

 PopUp (Maneuvers::Maneuver *task, PopUpArgs *args)
 
 ~PopUp (void)
 
void elevate (float z_value, unsigned z_units)
 
void goUp (void)
 
void goDown (void)
 
void startStationKeeping (void)
 
bool isSKeepTooFar (const IMC::EstimatedState *state)
 
void onStart (const IMC::PopUp *maneuver)
 
void onVehicleMedium (const IMC::VehicleMedium *msg)
 
void onGpsFix (const IMC::GpsFix *msg)
 
void onEstimatedState (const IMC::EstimatedState *msg)
 
void onPathControlState (const IMC::PathControlState *pcs)
 
void onStateReport (void)
 
void computeETA (void)
 
bool useCurr (void)
 
bool mustWait (void)
 
bool mustKeep (void)
 
- Public Member Functions inherited from Maneuver::Multiplexer::MuxedManeuver< IMC::PopUp, PopUpArgs >
 MuxedManeuver (Maneuvers::Maneuver *task, PopUpArgs *args)
 
 MuxedManeuver (Maneuvers::Maneuver *task)
 
virtual ~MuxedManeuver (void)
 
void start (const IMC::Maneuver *maneuver)
 
- Public Member Functions inherited from Maneuver::Multiplexer::AbstractMux
 AbstractMux (Maneuvers::Maneuver *task)
 
virtual ~AbstractMux (void)
 
virtual void onBrake (const IMC::Brake *msg)
 

Additional Inherited Members

- Protected Attributes inherited from Maneuver::Multiplexer::MuxedManeuver< IMC::PopUp, PopUpArgs >
PopUpArgsm_args
 
- Protected Attributes inherited from Maneuver::Multiplexer::AbstractMux
Maneuvers::Maneuver * m_task
 

Constructor & Destructor Documentation

Maneuver::Multiplexer::PopUp::PopUp ( Maneuvers::Maneuver *  task,
PopUpArgs args 
)
inline

Default constructor.

Parameters
[in]taskpointer to Maneuver task
[in]argspopup arguments
Maneuver::Multiplexer::PopUp::~PopUp ( void  )
inline

Destructor.

Member Function Documentation

void Maneuver::Multiplexer::PopUp::computeETA ( void  )
inline

Compute ETA.

References Maneuver::Multiplexer::AbstractMux::m_task.

Referenced by onStateReport().

void Maneuver::Multiplexer::PopUp::elevate ( float  z_value,
unsigned  z_units 
)
inline

Start elevating up or down.

Parameters
[in]z_valuevalue of z to where we're elevating
[in]z_unitsunits for the z reference

References Maneuver::Multiplexer::PopUpArgs::elev_radius, Maneuver::Multiplexer::MuxedManeuver< IMC::PopUp, PopUpArgs >::m_args, and Maneuver::Multiplexer::AbstractMux::m_task.

Referenced by goDown(), and goUp().

void Maneuver::Multiplexer::PopUp::goDown ( void  )
inline

Go down to the maneuver's z reference.

References elevate().

Referenced by onEstimatedState(), and onGpsFix().

void Maneuver::Multiplexer::PopUp::goUp ( void  )
inline

Go up to the surface.

References elevate().

Referenced by onPathControlState(), and onStart().

bool Maneuver::Multiplexer::PopUp::isSKeepTooFar ( const IMC::EstimatedState *  state)
inline

Check if the station keeping maneuver's center is too far.

Parameters
[in]statepointer to EstimatedState message
Returns
true if the center is indeed too far

References Maneuver::Multiplexer::PopUpArgs::elev_radius, Maneuver::Multiplexer::MuxedManeuver< IMC::PopUp, PopUpArgs >::m_args, and Maneuver::Multiplexer::PopUpArgs::max_sk_dist.

Referenced by onEstimatedState().

bool Maneuver::Multiplexer::PopUp::mustKeep ( void  )
inline

Must station keep while at surface.

Returns
true if position must be kept at surface

Referenced by onStart(), and onVehicleMedium().

bool Maneuver::Multiplexer::PopUp::mustWait ( void  )
inline

Must wait some time at surface.

Returns
true if must wait when surface has been reached

Referenced by onGpsFix(), and onStart().

void Maneuver::Multiplexer::PopUp::onEstimatedState ( const IMC::EstimatedState *  msg)
inlinevirtual

On message EstimatedState.

Parameters
[in]msgpointer to EstimatedState message

Reimplemented from Maneuver::Multiplexer::AbstractMux.

References goDown(), isSKeepTooFar(), Maneuver::Multiplexer::AbstractMux::m_task, and startStationKeeping().

void Maneuver::Multiplexer::PopUp::onGpsFix ( const IMC::GpsFix *  msg)
inlinevirtual
void Maneuver::Multiplexer::PopUp::onPathControlState ( const IMC::PathControlState *  pcs)
inlinevirtual

On PathControlState message.

Parameters
[in]pcspointer to PathControlState message

Reimplemented from Maneuver::Multiplexer::AbstractMux.

References goUp(), and Maneuver::Multiplexer::AbstractMux::m_task.

void Maneuver::Multiplexer::PopUp::onStart ( const IMC::PopUp *  maneuver)
inlinevirtual

Start maneuver function.

Parameters
[in]maneuverrows maneuver message

Implements Maneuver::Multiplexer::MuxedManeuver< IMC::PopUp, PopUpArgs >.

References goUp(), Maneuver::Multiplexer::AbstractMux::m_task, mustKeep(), mustWait(), and useCurr().

void Maneuver::Multiplexer::PopUp::onStateReport ( void  )
inlinevirtual

On state report.

Reimplemented from Maneuver::Multiplexer::AbstractMux.

References computeETA().

void Maneuver::Multiplexer::PopUp::onVehicleMedium ( const IMC::VehicleMedium *  msg)
inlinevirtual
void Maneuver::Multiplexer::PopUp::startStationKeeping ( void  )
inline
bool Maneuver::Multiplexer::PopUp::useCurr ( void  )
inline

Will use current position.

Returns
true if must use current waypoint

Referenced by onStart().

Collaboration diagram for Maneuver::Multiplexer::PopUp:
Collaboration graph