# mission timer set to 120% of estimated time of mission
#define DEEP_YOYO_MIN_DEPTH 950
#define DEEP_YOYO_MAX_DEPTH 1050
#define MISSION_SPEED 1.75
# start at amphitheater center
#define START_LAT 28.8543
#define START_LON -88.2648
#define LEG_1_HDG 215
#define NORTH_LAT 28.8611
#define SOUTH_LAT 28.8476
#define NS300_LON -88.2684
#define NS400_LON -88.2674
#define NS500_LON -88.2663
#define NS600_LON -88.2653
#define NS700_LON -88.2643
#define NS800_LON -88.2633
#define NS900_LON -88.2622
#define NS1000_LON -88.2612
#define TARGET1_LAT 28.850267
#define TARGET1_LON -88.266516
#define TARGET2_LAT 28.858083
#define TARGET2_LON -88.263121
#define TARGET3_LAT 28.850917
#define TARGET3_LON -88.262417

behavior missionTimer {
timeOut = 18000;
}

# depth envelope set to commanded + 5 m, abort at commanded + 10
behavior depthEnvelope {
 minDepth = 0;
 maxDepth     = 1050;
 abortDepth   = 1100;
}

behavior getgps {
duration = 600;
minHits = 300;
abortOnTimeout = True;
}

behavior ascend {
duration  = 2700;
horizontalMode   = rudder;
horizontal       = 5;
pitch            = 45;
speed            = 1.75;
endDepth         = 2;
}

behavior acousticUpdate {
duration = 1;
dummy = 1;
}

behavior waypoint_yoyo {
latitude     = SOUTH_LAT;
longitude     = NS1000_LON;
captureRadius = 10;
duration     = 1200;
speed        = 1.75;
minDepth       = DEEP_YOYO_MIN_DEPTH;
maxDepth       = DEEP_YOYO_MAX_DEPTH;
maxCycles      = 3000;
}

behavior acousticUpdate {
duration = 1;
dummy = 1;
}

behavior waypoint_yoyo {
latitude     = NORTH_LAT;
longitude     = NS1000_LON;
captureRadius = 10;
duration     = 1200;
speed        = 1.75;
minDepth       = DEEP_YOYO_MIN_DEPTH;
maxDepth       = DEEP_YOYO_MAX_DEPTH;
maxCycles      = 3000;
}

behavior acousticUpdate {
duration = 1;
dummy = 1;
}

behavior waypoint_yoyo {
latitude     = NORTH_LAT;
longitude     = NS900_LON;
captureRadius = 10;
duration     = 1200;
speed        = 1.75;
minDepth       = DEEP_YOYO_MIN_DEPTH;
maxDepth       = DEEP_YOYO_MAX_DEPTH;
maxCycles      = 3000;
}

behavior ArmTheGulper
{
  duration = 5;
  gulper9 = 1;
}

behavior FireTheGulper {
	duration = 2;
	gulperToFire = 8;
}

behavior waypoint_yoyo {
latitude     = TARGET3_LAT;
longitude     = TARGET3_LON;
captureRadius = 10;
duration     = 1200;
speed        = 1.75;
minDepth       = DEEP_YOYO_MIN_DEPTH;
maxDepth       = DEEP_YOYO_MAX_DEPTH;
maxCycles      = 3000;
}

behavior waypoint_yoyo {
latitude     = SOUTH_LAT;
longitude     = NS900_LON;
captureRadius = 10;
duration     = 1200;
speed        = 1.75;
minDepth       = DEEP_YOYO_MIN_DEPTH;
maxDepth       = DEEP_YOYO_MAX_DEPTH;
maxCycles      = 3000;
}

behavior acousticUpdate {
duration = 1;
dummy = 1;
}

behavior waypoint_yoyo {
latitude     = SOUTH_LAT;
longitude     = NS800_LON;
captureRadius = 10;
duration     = 1200;
speed        = 1.75;
minDepth       = DEEP_YOYO_MIN_DEPTH;
maxDepth       = DEEP_YOYO_MAX_DEPTH;
maxCycles      = 3000;
}

behavior acousticUpdate {
duration = 1;
dummy = 1;
}

behavior FireTheGulper {
	duration = 2;
	gulperToFire = 7;
}

behavior waypoint_yoyo {
latitude     = TARGET3_LAT;
longitude     = NS800_LON;
captureRadius = 10;
duration     = 1200;
speed        = 1.75;
minDepth       = DEEP_YOYO_MIN_DEPTH;
maxDepth       = DEEP_YOYO_MAX_DEPTH;
maxCycles      = 3000;
}

behavior ArmTheGulper
{
  duration = 5;
  gulper6 = 1;
}

behavior FireTheGulper {
	duration = 2;
	gulperToFire = 5;
}

behavior waypoint_yoyo {
latitude     = TARGET2_LAT;
longitude     = TARGET2_LON;
captureRadius = 10;
duration     = 1200;
speed        = 1.75;
minDepth       = DEEP_YOYO_MIN_DEPTH;
maxDepth       = DEEP_YOYO_MAX_DEPTH;
maxCycles      = 3000;
}

behavior acousticUpdate {
duration = 1;
dummy = 1;
}

behavior waypoint_yoyo {
latitude     = NORTH_LAT;
longitude     = NS800_LON;
captureRadius = 10;
duration     = 1200;
speed        = 1.75;
minDepth       = DEEP_YOYO_MIN_DEPTH;
maxDepth       = DEEP_YOYO_MAX_DEPTH;
maxCycles      = 3000;
}

behavior acousticUpdate {
duration = 1;
dummy = 1;
}

behavior waypoint_yoyo {
latitude     = NORTH_LAT;
longitude     = NS700_LON;
captureRadius = 10;
duration     = 1200;
speed        = 1.75;
minDepth       = DEEP_YOYO_MIN_DEPTH;
maxDepth       = DEEP_YOYO_MAX_DEPTH;
maxCycles      = 3000;
}

behavior FireTheGulper {
	duration = 2;
	gulperToFire = 4;
}

behavior waypoint_yoyo {
latitude     = TARGET2_LAT;
longitude     = NS700_LON;
captureRadius = 10;
duration     = 1200;
speed        = 1.75;
minDepth       = DEEP_YOYO_MIN_DEPTH;
maxDepth       = DEEP_YOYO_MAX_DEPTH;
maxCycles      = 3000;
}

behavior acousticUpdate {
duration = 1;
dummy = 1;
}

behavior waypoint_yoyo {
latitude     = SOUTH_LAT;
longitude     = NS700_LON;
captureRadius = 10;
duration     = 1200;
speed        = 1.75;
minDepth       = DEEP_YOYO_MIN_DEPTH;
maxDepth       = DEEP_YOYO_MAX_DEPTH;
maxCycles      = 3000;
}

behavior acousticUpdate {
duration = 1;
dummy = 1;
}

behavior waypoint_yoyo {
latitude     = SOUTH_LAT;
longitude     = NS600_LON;
captureRadius = 10;
duration     = 1200;
speed        = 1.75;
minDepth       = DEEP_YOYO_MIN_DEPTH;
maxDepth       = DEEP_YOYO_MAX_DEPTH;
maxCycles      = 3000;
}

behavior FireTheGulper {
	duration = 2;
	gulperToFire = 3;
}

behavior waypoint_yoyo {
latitude     = TARGET1_LAT;
longitude     = NS600_LON;
captureRadius = 10;
duration     = 1200;
speed        = 1.75;
minDepth       = DEEP_YOYO_MIN_DEPTH;
maxDepth       = DEEP_YOYO_MAX_DEPTH;
maxCycles      = 3000;
}

behavior acousticUpdate {
duration = 1;
dummy = 1;
}

behavior waypoint_yoyo {
latitude     = NORTH_LAT;
longitude     = NS600_LON;
captureRadius = 10;
duration     = 1200;
speed        = 1.75;
minDepth       = DEEP_YOYO_MIN_DEPTH;
maxDepth       = DEEP_YOYO_MAX_DEPTH;
maxCycles      = 3000;
}

behavior acousticUpdate {
duration = 1;
dummy = 1;
}

behavior waypoint_yoyo {
latitude     = NORTH_LAT;
longitude     = NS500_LON;
captureRadius = 10;
duration     = 1200;
speed        = 1.75;
minDepth       = DEEP_YOYO_MIN_DEPTH;
maxDepth       = DEEP_YOYO_MAX_DEPTH;
maxCycles      = 3000;
}

behavior ArmTheGulper
{
  duration = 5;
  gulper2 = 1;
}

behavior FireTheGulper {
	duration = 2;
	gulperToFire = 1;
}

behavior waypoint_yoyo {
latitude     = TARGET1_LAT;
longitude     = TARGET1_LON;
captureRadius = 10;
duration     = 1200;
speed        = 1.75;
minDepth       = DEEP_YOYO_MIN_DEPTH;
maxDepth       = DEEP_YOYO_MAX_DEPTH;
maxCycles      = 3000;
}

behavior acousticUpdate {
duration = 1;
dummy = 1;
}

behavior waypoint_yoyo {
latitude     = SOUTH_LAT;
longitude     = NS500_LON;
captureRadius = 10;
duration     = 1200;
speed        = 1.75;
minDepth       = DEEP_YOYO_MIN_DEPTH;
maxDepth       = DEEP_YOYO_MAX_DEPTH;
maxCycles      = 3000;
}

behavior acousticUpdate {
duration = 1;
dummy = 1;
}

behavior waypoint_yoyo {
latitude     = SOUTH_LAT;
longitude     = NS400_LON;
captureRadius = 10;
duration     = 1200;
speed        = 1.75;
minDepth       = DEEP_YOYO_MIN_DEPTH;
maxDepth       = DEEP_YOYO_MAX_DEPTH;
maxCycles      = 3000;
}

#fire gulper 0 here
behavior FireTheGulper {
	duration = 2;
	gulperToFire = 0;
}

behavior waypoint_yoyo {
latitude     = TARGET1_LAT;
longitude     = NS400_LON;
captureRadius = 10;
duration     = 1200;
speed        = 1.75;
minDepth       = DEEP_YOYO_MIN_DEPTH;
maxDepth       = DEEP_YOYO_MAX_DEPTH;
maxCycles      = 3000;
}

behavior acousticUpdate {
duration = 1;
dummy = 1;
}

behavior waypoint_yoyo {
latitude     = NORTH_LAT;
longitude     = NS400_LON;
captureRadius = 10;
duration     = 1200;
speed        = 1.75;
minDepth       = DEEP_YOYO_MIN_DEPTH;
maxDepth       = DEEP_YOYO_MAX_DEPTH;
maxCycles      = 3000;
}


behavior acousticUpdate {
duration = 1;
dummy = 1;
}

behavior waypoint_yoyo {
latitude     = NORTH_LAT;
longitude     = NS300_LON;
captureRadius = 10;
duration     = 1200;
speed        = 1.75;
minDepth       = DEEP_YOYO_MIN_DEPTH;
maxDepth       = DEEP_YOYO_MAX_DEPTH;
maxCycles      = 3000;
}


behavior acousticUpdate {
duration = 1;
dummy = 1;
}

behavior waypoint_yoyo {
latitude     = SOUTH_LAT;
longitude     = NS300_LON;
captureRadius = 10;
duration     = 1800;
speed        = 1.75;
minDepth       = DEEP_YOYO_MIN_DEPTH;
maxDepth       = DEEP_YOYO_MAX_DEPTH;
maxCycles      = 3000;
}

behavior acousticUpdate {
duration = 1;
dummy = 1;
}

behavior waypoint_yoyo {
latitude     = START_LAT;
longitude     = START_LON;
captureRadius = 10;
duration     = 1200;
speed        = 1.75;
minDepth       = DEEP_YOYO_MIN_DEPTH;
maxDepth       = DEEP_YOYO_MAX_DEPTH;
maxCycles      = 3000;
}

behavior StartSurvey {
duration = 300;
}

behavior acousticUpdate {
duration = 1;
dummy = 1;
}

behavior descend {
horizontalMode   = rudder;
horizontal      = 5;
pitch        = -30;
speed        = MISSION_SPEED;
maxDepth     = 950;
duration     = 2100;
}

behavior acousticUpdate {
duration = 1;
dummy = 1;
}

# Descend behavior to 5 meters
behavior descend {
horizontalMode   = heading;
horizontal      = 90;
pitch        = -15;
speed        = 1.8;
maxDepth     = 5;
duration     = 120;
}


# setpoint on surface to gather momentum
behavior setpoint {
duration     = 60;
heading      = 90;
speed        = MISSION_SPEED;
verticalMode = pitch;
pitch        = 0;
}



