behavior missionTimer
{
  timeOut = 12403;
}
#
# Depth Envelope
#
behavior depthEnvelope
{
  minDepth = 0; #Meters
  maxDepth = 520; #Meters
  abortDepth = 525; #Meters
  minAltitude = 40.0; #Meters
  abortAltitude = 30.0; #Meters
}
# acquire gps fix
behavior getgps {
duration = 30;
minHits = 2;
abortOnTimeout = False;
}
behavior ascend
{
  duration = 30; #Seconds
  horizontalMode = rudder; #Mode
  horizontal = -3; #Degrees; 
  pitch = 30; #Degrees
  speed = 0; #Meters/sec
  endDepth = 2; #Meters
}
behavior CARL
{
  id = 108;
  duration = 1;
  record = 0;
  homeIris = 1;
  lightSwitch = 0;
}
behavior ascend
{
  duration = 30; #Seconds
  horizontalMode = rudder; #Mode
  horizontal = -3; #Degrees; 
  pitch = 30; #Degrees
  speed = 0; #Meters/sec
  endDepth = 5; #Meters
}
behavior CARL
{
  id = 110;
  clipname = 1;
  duration = 1;
  record = 1;
  fstop = 561;
}
#23. End 6.
behavior waypoint
{
  duration = 30;
  depth = 500;
  speed = 0;
  latitude =   36.696197;
  longitude = -122.049837;
}
behavior CARL
{
  id = 110;
  clipname = 1;
  duration = 1;
  record = 1;
  fstop = 561;
}
#22. Begin 6.
behavior waypoint
{
  duration = 30;
  depth = 500;
  speed = 0;
  latitude =   36.696197;
  longitude = -122.053310;
}
#21. Turn, stabilize, setup.
behavior waypoint
{
  duration = 30;
  depth = 500;
  speed = 0;
  latitude =   36.696197;
  longitude = -122.056671;
}
behavior CARL
{
  id = 110;
  lightSwitch = 1;
  fstop = 31;
  clipname = 1;
  duration = 1;
  record = 1;
}
#20. Dive.
behavior waypoint
{
  duration = 30;
  depth = 500;
  speed = 0;
  latitude =   36.696227;
  longitude = -122.058314;
}
behavior CARL
{
  id = 108;
  duration = 1;
  record = 0;
  homeIris = 1;
  lightSwitch = 0;
}
#19. End 5.
behavior waypoint
{
  duration = 30;
  depth = 400;
  speed = 0;
  latitude =   36.695687;
  longitude = -122.056746;
}
behavior CARL
{
  id=124;
  clipname = 1;
  duration = 1;
  fstop = 561;
}
#18. Start 5
behavior waypoint
{
  duration = 30;
  depth = 400;
  speed = 0;
  latitude =   36.695687;
  longitude = -122.053273;
}
#17. Turn, stabilize, setup.
behavior waypoint
{
  duration = 30;
  depth = 400;
  speed = 0;
  latitude =   36.695687;
  longitude = -122.049800;
}
behavior CARL
{
  id = 110;
  lightSwitch = 1;
  fstop = 31;
  clipname = 1;
  duration = 1;
  record = 1;
}
#16. Dive.
behavior waypoint
{
  duration = 30;
  depth = 400;
  speed = 0;
  latitude =   36.695687;
  longitude = -122.048231;
}
behavior CARL
{
  id = 108;
  duration = 1;
  record = 0;
  homeIris = 1;
  lightSwitch = 0;
}
#15.  End 4
behavior waypoint
{
  duration = 30;
  depth = 300;
  speed = 0;
  latitude =   36.696288;
  longitude = -122.049949;
}
behavior CARL
{
  id = 119;
  duration = 1;
  clipname = 1;
  fstop = 561;
}
#14. Start 4
behavior waypoint
{
  duration = 30;
  depth = 300;
  speed = 0;
  latitude =   36.696288;
  longitude = -122.053310;
}
#13. Turn, stabilize, set up.
behavior waypoint
{
  duration = 30;
  depth = 300;
  speed = 0;
  latitude =   36.696288;
  longitude = -122.056783;
}
behavior CARL
{
  id = 110;
  lightSwitch = 1;
  fstop = 31;
  clipname = 1;
  duration = 1;
  record = 1;
}
#12. Dive. 
behavior waypoint
{
  duration = 30;
  depth = 300;
  speed = 0;
  latitude =   36.696288;
  longitude = -122.058352;
}
behavior CARL
{
  id = 108;
  duration = 1;
  record = 0;
  homeIris = 1;
  lightSwitch = 0;
}
#11. End 3.
behavior waypoint
{
  duration = 30;
  depth = 200;
  speed = 0;
  latitude =   36.695777;
  longitude = -122.056746;
}
behavior CARL
{
  id = 113;
  duration = 1;
  clipname = 1;
  fstop = 561;
}
#Ten. Start 3
behavior waypoint
{
  duration = 30;
  depth = 200;
  speed = 0;
  latitude =   36.695747;
  longitude = -122.053422;
}
#Nine.  Turn, stabilize, and set up.
behavior waypoint
{
  duration = 30;
  depth = 200;
  speed = 0;
  latitude =   36.695747;
  longitude = -122.049837;
}
behavior CARL
{
  id = 110;
  lightSwitch = 1;
  fstop = 31;
  clipname = 1;
  duration = 1;
  record = 1;
}
#Eight. Dive.
behavior waypoint
{
  duration = 30;
  depth = 200;
  speed = 0;
  latitude =   36.695747;
  longitude = -122.048269;
}
behavior CARL
{
  id = 108;
  duration = 1;
  record = 0;
  homeIris = 1;
  lightSwitch = 0;
}
#Seven End 2
behavior waypoint
{
  duration = 30;
  depth = 100;
  speed = 0;
  latitude =   36.696378;
  longitude = -122.050061;
}
behavior CARL
{
   id=107;
   duration = 1;
   clipname = 1;
   fstop = 561;
}
#Six Begin segment 2
behavior waypoint
{
  duration = 30;
  depth = 100;
  speed = 0;
  latitude =   36.696378;
  longitude = -122.053422;
}
#Five. Turn, stabilize, and set up for the next segment.
behavior waypoint
{
  duration = 30;
  depth = 100;
  speed = 0;
  latitude =   36.696378;
  longitude = -122.056895;
}
behavior CARL
{
  id = 110;
  lightSwitch = 1;
  fstop = 31;
  clipname = 1;
  duration = 1;
  record = 1;
}
#Four.  Descend.  
behavior waypoint
{
  duration = 30;
  depth = 100;
  speed = 0;
  latitude =   36.696378;
  longitude = -122.058464;
}
behavior CARL
{
  id = 108;
  duration = 1;
  record = 0;
  lightSwitch = 0;
  homeIris = 1;
}
#Three.  End Segment.
behavior waypoint
{
  duration = 30;
  depth = 50;
  speed = 0;
  latitude =   36.695867;
  longitude = -122.056858;
}
behavior CARL
{
  id=106;
  duration = 1;
  clipname = 1;
  fstop = 561;
}
#Two
behavior waypoint
{
  latitude =   36.695837;
  longitude = -122.053422;
  duration = 30;
  depth = 50;
  speed = 0;
}
behavior CARL
{
  id = 104;
  fstop = 31;
  brightness = 90;
  lightSwitch = 1;
  clipname = 1;
  duration = 1;
  record = 1;
}
#One.  Start the Segment.
behavior waypoint
{
 duration = 30;
 depth = 50;
 speed = 0;
 latitude =   36.695837;
 longitude = -122.049837;
}
behavior descend
{
horizontalMode = rudder;
horizontal = 3.0;
pitch = -35.000000;
speed = 000000;
maxDepth = 48;
minAltitude = 50.000000;
duration = 30;
}
behavior waypoint
{
 duration = 30;
 depth = 10;
 speed = 0;
 latitude =   36.696197;
 longitude = -122.048381;
}
#
# Descend and transit to starting waypoint.
behavior descend {
horizontalMode = heading;
horizontal = 90.0;
pitch = -30;
speed = 0;
maxDepth = 8;
duration = 30;
minAltitude = 30;
}
# setpoint on surface to gather momentum
behavior setpoint {
duration = 30;
heading = 90.0;
speed = 0;
verticalMode = pitch;
pitch = 0;
}
#
# Begin recording on the surface
#
behavior CARL
{
  id = 101;
  clipname = 1;
  record = 1;
  duration = 1;
  fstop = 561;
}
# acquire gps fix
behavior getgps {
duration = 30;
minHits = 2;
abortOnTimeout = False;
}
#
# Bring up the lights and close the iris since we're on the surface
#
behavior CARL
{
  id = 99;
  lightSwitch = 1;
  brightness = 90;
  duration = 1;
  homeIris = 1;
}
