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

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

#define DescendBehaviorName "descend"

/*
CLASS 
Descend

DESCRIPTION
Drive the vehicle to specified depth.
Terminate when the vehicle is at specified depth, or below specified
minAltitude.

Attribute         Type               Meaning
---------         ----               -------
horizontalMode    HorizontalMode     Either "heading", "rudder" or "waypoint"
horizontal        Float              Commanded horizontal value
pitch             Angle              Commanded pitch
speed             Float              Commanded speed
maxDepth          Float              End behavior when below this depth
minAltitude       Float              End behavior when below this altitude
dropDescentWeight Boolean            Drop descent weight at finish
dropAscentWeight  Boolean            Drop ascent weight at finish

AUTHOR
Tom O'Reilly
*/

class Descend : public Behavior {

public:

  Descend();

  virtual ~Descend();

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

  virtual Boolean shouldBehaviorStart( void );

protected:

  double _pitch;
  double _horizontal;
  double _speed;
  double _maxDepth;
  double _minAltitude;
  Boolean _dropDescentWeight;
  Boolean _dropAscentWeight;

  DynamicControlIF::HorizontalMode _horizontalMode;
};



#endif
