using System; using Microsoft.SPOT; namespace abstractState { public class configFile { public const double SOSetBellowsPosition = 65.0; public const int SOSetBellowsJV = 40000; public const double exitAnchorPressureThreshold = 5.0; public static TimeSpan instrumentSamplePeriod = new TimeSpan(0, 5, 0); public const double approachVel = 0.02; //SBE41 stuff public const int SBE41SamplePeriod = 3000; //msec public const double maxPressure = 120.0; //dBar public const int cpPressureCutoff = 1; //CP mode stops below this pressure in deciBars public static bool CPMode = true; //Puts SBE41 in CP mode during ascend state only //Emergency Ascend (EA) stuff public const int EAJV = 30000; public const double bellowsEAPosition = bellowsUpperLimit - 1.0; //Buoyancy control stuff public const double surfacePressure = 0.35; public const double bellowsLowerLimit = 23.9; public const double bellowsUpperLimit = 69.9; //autoballast (AB) stuff public const double ABSetBellowsPosition = 59.0; public const int ABSetBellowsJV = 20000; public const int ABRetractJV = 5000; public const double ABVelocityThreshold = -0.02; public const double ABPressureThreshold = 0.2; //Anchor stuff public const double deanchorVelocityThreshold = 0.007; public const int deanchorJV = 10000; //Buoyancy control holdVelocity constants public const double KPlatVel = 80.0, //Constant for P term of PID TiPlatVel = 50000.0, // Time constant for I term of PID (in denominator, bigger values less I term in output TdPlatVel = 10.0, // Time constant for D term of PID TfPlatVel = 2.0, // Derivative filter time constant TtPlatVel = 100.0, // Anti-windup time constant BPlatVel = 1.0, // Setpoint weight uLowPlatVel = -3000.0 / 60.0, // minimum possible output (RPS) uHighPlatVel = 3000.0 / 60.0, // maximum possible output (RPS) hPlatVel = SBE41SamplePeriod / 1000.0; // Sample period (seconds) //Buoyancy control holdPressure constants public const double KPressure = 0.6, //Constant for P term of PID TiPressure = 1000000.0, // Time constant for I term of PID (in denominator, bigger values less I term in output TdPressure = 0.2, // Time constant for D term of PID TfPressure = 2.0, // Derivative filter time constant TtPressure = 1000000.0, // Anti-windup time constant BPressure = 1.0, // Setpoint weight uLowPressure = -3000.0 / 60.0, // minimum possible output (RPS) uHighPressure = 3000.0 / 60.0, // maximum possible output (RPS) hPressure = SBE41SamplePeriod / 1000.0; // Sample period (seconds) } }