/****************************************************************************/
/* Copyright (c) 2000 MBARI                                                 */
/* MBARI Proprietary Information. All rights reserved.                      */
/****************************************************************************/
/* Summary  :                                                               */
/* Filename : Launch.h                                                      */
/* Author   :                                                               */
/* Project  :                                                               */
/* Version  : 1.0                                                           */
/* Created  : 02/07/2000                                                    */
/* Modified :                                                               */
/* Archived :                                                               */
/****************************************************************************/
/* Modification History:                                                    */
/****************************************************************************/
#ifndef _LAUNCH_H
#define _LAUNCH_H

#include "ourTypes.h"
#include "Behavior.h"

#define LaunchBehaviorName "launch"

/*
CLASS 
Launch

DESCRIPTION
Command zero rudder and fixed elevator until vehicle reaches depth or 
time has expired.

Plan is to use this behavior as a trigger for the thruster to come on
when an operator pushes down.

Attribute         Type               Meaning
---------         ----               -------
elevator          Angle              Commanded elevator
speed             Float              Commanded speed
finalDepth        Float              End when below this depth
abortOnDepth      Boolean            Should the behavior abort the mission
                                     if it times out before reaching depth?

AUTHOR
Tom O'Reilly
*/
class Launch : public Behavior {

public:

  Launch();

  virtual ~Launch();

  virtual void execute();
  virtual Boolean validInput();

  virtual Boolean shouldBehaviorStart();

protected:

  double _speed;
  double _elevator;
  double _finalDepth;

  Boolean _abortOnTimeout;

  double _timeout;
};



#endif




