using System;
using Microsoft.SPOT;
using System.Text;

namespace SWModules
{
    public static class EngrLiterals
    {

        public enum ColumnNums
        {
            //First the prefix for all records
            dateTime = 0,
            state,
            comment,
            //Then the verbosity level 0 stuff
            pressure,
            bellowsPosition,
            pumpMilliamps,
            pumpVolts,
            pumpUWatts,
            pumpMilliSeconds,
            pumpUCoulombs,
            pumpMilliJoules,

            hotelMilliamps,
            hotelVolts,
            hotelUWatts,
            hotelMilliSeconds,
            hotelUCoulombs,
            hotelMilliJoules,

            pumpMotor,

            //CTD Stuff
            CTDTemp, CTDSalinity,
            SBE41Pressure, SBE41LPFPressure, SBE41LPFVelocity, SBE41DiffVelocity, SBE41Diff2Velocity, SBE41Slope, CTDSamplePeriod,
            //PTH Stuff
            LPS331Pressure, LPS331Temperature, SHT21Humidity, SHT21Temperature,
            //PID stuff
            PID_SP, PID_PV, PID_y1, PID_y2, PID_I, PID_v, PID_u, PID_uCPS, PID_h,
            //Science data
            FLBB,
            TOpt, TPhase, RPhase,
            NO3,
            pH,
            OCRText, OCRCh1, OCRCh2, OCRCh3, OCRCh4,
            //GPS Stuff
            GPS,
            //Iridium Modem Stuff
            IModem,
            //Other stuff
            Msc,
            lastColumn,
        }

        public static void CreateEngrHeaderLines(StringBuilder[] columnName, StringBuilder[] columnType)
        {
            columnName[(int)ColumnNums.dateTime].Append("STX\tDate\tTime");
            columnType[(int)ColumnNums.dateTime].Append("text\ttext\ttext");
            columnName[(int)ColumnNums.state].Append("State");
            columnType[(int)ColumnNums.state].Append(Literals.text);
            columnName[(int)ColumnNums.comment].Append("Comment");
            columnType[(int)ColumnNums.comment].Append(Literals.text);
            columnName[(int)ColumnNums.pressure].Append("Pressure");
            columnType[(int)ColumnNums.pressure].Append(Literals.decZero);
            columnName[(int)ColumnNums.bellowsPosition].Append("BelPos");
            columnType[(int)ColumnNums.bellowsPosition].Append(Literals.decZero);

            columnName[(int)ColumnNums.GPS].Append("GPS");
            columnType[(int)ColumnNums.GPS].Append(Literals.text);
            columnName[(int)ColumnNums.IModem].Append("IridModem");
            columnType[(int)ColumnNums.IModem].Append(Literals.text);

            columnName[(int)ColumnNums.LPS331Pressure].Append("LPS331Press");
            columnType[(int)ColumnNums.LPS331Pressure].Append(Literals.decZero);
            columnName[(int)ColumnNums.LPS331Temperature].Append("LPS331Temp");
            columnType[(int)ColumnNums.LPS331Temperature].Append(Literals.decZero);
            columnName[(int)ColumnNums.SHT21Humidity].Append("SHT21Humid");
            columnType[(int)ColumnNums.SHT21Humidity].Append(Literals.decZero);
            columnName[(int)ColumnNums.SHT21Temperature].Append("SHT21Temp");
            columnType[(int)ColumnNums.SHT21Temperature].Append(Literals.decZero);

            columnName[(int)ColumnNums.CTDTemp].Append("CTDTemp");
            columnType[(int)ColumnNums.CTDTemp].Append(Literals.text);
            columnName[(int)ColumnNums.CTDSalinity].Append("CTDSal");
            columnType[(int)ColumnNums.CTDSalinity].Append(Literals.text);

            columnName[(int)ColumnNums.FLBB].Append("FLBB");
            columnType[(int)ColumnNums.FLBB].Append(Literals.text);

            columnName[(int)ColumnNums.TOpt].Append("Topt");
            columnType[(int)ColumnNums.TOpt].Append(Literals.text);
            columnName[(int)ColumnNums.TPhase].Append("Tphase");
            columnType[(int)ColumnNums.TPhase].Append(Literals.text);
            columnName[(int)ColumnNums.RPhase].Append("Rphase");
            columnType[(int)ColumnNums.RPhase].Append(Literals.text);

            columnName[(int)ColumnNums.NO3].Append("NO3");
            columnType[(int)ColumnNums.NO3].Append(Literals.text);
            columnName[(int)ColumnNums.pH].Append("pHVrs");
            columnType[(int)ColumnNums.pH].Append(Literals.text);

            columnName[(int)ColumnNums.OCRText].Append("OCRtext");
            columnType[(int)ColumnNums.OCRText].Append(Literals.text);
            columnName[(int)ColumnNums.OCRCh1].Append("OCRCh1");
            columnType[(int)ColumnNums.OCRCh1].Append(Literals.decZero);
            columnName[(int)ColumnNums.OCRCh2].Append("OCRCh2");
            columnType[(int)ColumnNums.OCRCh2].Append(Literals.decZero);
            columnName[(int)ColumnNums.OCRCh3].Append("OCRCh3");
            columnType[(int)ColumnNums.OCRCh3].Append(Literals.decZero);
            columnName[(int)ColumnNums.OCRCh4].Append("OCRCH4");
            columnType[(int)ColumnNums.OCRCh4].Append(Literals.decZero);

            columnName[(int)ColumnNums.SBE41Pressure].Append("RawPress");
            columnType[(int)ColumnNums.SBE41Pressure].Append(Literals.decZero);
            columnName[(int)ColumnNums.SBE41LPFPressure].Append("LPFPress");
            columnType[(int)ColumnNums.SBE41LPFPressure].Append(Literals.decZero);
            columnName[(int)ColumnNums.SBE41LPFVelocity].Append("LPFVel");
            columnType[(int)ColumnNums.SBE41LPFVelocity].Append(Literals.decZero);
            columnName[(int)ColumnNums.SBE41DiffVelocity].Append("DiffVel");
            columnType[(int)ColumnNums.SBE41DiffVelocity].Append(Literals.decZero);
            columnName[(int)ColumnNums.SBE41Diff2Velocity].Append("Diff2Vel");
            columnType[(int)ColumnNums.SBE41Diff2Velocity].Append(Literals.decZero);
            columnName[(int)ColumnNums.SBE41Slope].Append("SlopeLPFPress.");
            columnType[(int)ColumnNums.SBE41Slope].Append(Literals.decZero);
            columnName[(int)ColumnNums.CTDSamplePeriod].Append("CTDSamplePeriod");
            columnType[(int)ColumnNums.CTDSamplePeriod].Append(Literals.decZero);

            columnName[(int)ColumnNums.PID_SP].Append("pidSP");
            columnType[(int)ColumnNums.PID_SP].Append(Literals.decZero);
            columnName[(int)ColumnNums.PID_PV].Append("pidPV");
            columnType[(int)ColumnNums.PID_PV].Append(Literals.decZero);
            columnName[(int)ColumnNums.PID_y1].Append("pidY1");
            columnType[(int)ColumnNums.PID_y1].Append(Literals.decZero);
            columnName[(int)ColumnNums.PID_y2].Append("pidY2");
            columnType[(int)ColumnNums.PID_y2].Append(Literals.decZero);
            columnName[(int)ColumnNums.PID_I].Append("pidI");
            columnType[(int)ColumnNums.PID_I].Append(Literals.decZero);
            columnName[(int)ColumnNums.PID_v].Append("pid_v");
            columnType[(int)ColumnNums.PID_v].Append(Literals.decZero);
            columnName[(int)ColumnNums.PID_u].Append("pid_u");
            columnType[(int)ColumnNums.PID_u].Append(Literals.decZero);
            columnName[(int)ColumnNums.PID_uCPS].Append("pid_uCPS");
            columnType[(int)ColumnNums.PID_uCPS].Append(Literals.decZero);
            columnName[(int)ColumnNums.PID_h].Append("pid_h");
            columnType[(int)ColumnNums.PID_h].Append(Literals.decZero);

            columnName[(int)ColumnNums.pumpMilliamps].Append("PumpMilliamps");
            columnType[(int)ColumnNums.pumpMilliamps].Append(Literals.decZero);
            columnName[(int)ColumnNums.pumpVolts].Append("PumpVolts");
            columnType[(int)ColumnNums.pumpVolts].Append(Literals.decZero);
            columnName[(int)ColumnNums.pumpUWatts].Append("PumpUWatts");
            columnType[(int)ColumnNums.pumpUWatts].Append(Literals.decZero);
            columnName[(int)ColumnNums.pumpMilliSeconds].Append("PumpMilliSeconds");
            columnType[(int)ColumnNums.pumpMilliSeconds].Append(Literals.decZero);
            columnName[(int)ColumnNums.pumpUCoulombs].Append("PumpUCoulombs");
            columnType[(int)ColumnNums.pumpUCoulombs].Append(Literals.decZero);
            columnName[(int)ColumnNums.pumpMilliJoules].Append("PumpMilliJoules");
            columnType[(int)ColumnNums.pumpMilliJoules].Append(Literals.decZero);

            columnName[(int)ColumnNums.hotelMilliamps].Append("HotelMilliamps");
            columnType[(int)ColumnNums.hotelMilliamps].Append(Literals.decZero);
            columnName[(int)ColumnNums.hotelVolts].Append("HotelVolts");
            columnType[(int)ColumnNums.hotelVolts].Append(Literals.decZero);
            columnName[(int)ColumnNums.hotelUWatts].Append("HotelVolts");
            columnType[(int)ColumnNums.hotelUWatts].Append(Literals.decZero);
            columnName[(int)ColumnNums.hotelMilliSeconds].Append("PumpMilliSeconds");
            columnType[(int)ColumnNums.hotelMilliSeconds].Append(Literals.decZero);
            columnName[(int)ColumnNums.hotelUCoulombs].Append("HotelCoulombs");
            columnType[(int)ColumnNums.hotelUCoulombs].Append(Literals.decZero);
            columnName[(int)ColumnNums.hotelMilliJoules].Append("HotelJoules");
            columnType[(int)ColumnNums.hotelMilliJoules].Append(Literals.decZero);

            columnName[(int)ColumnNums.Msc].Append("MSC");
            columnType[(int)ColumnNums.Msc].Append(Literals.text);

            columnName[(int)ColumnNums.pumpMotor].Append("pumpMotor Msg");
            columnType[(int)ColumnNums.pumpMotor].Append(Literals.text);

        }
    }
}
