Ejemplo n.º 1
0
    public override AnalogPatternBuilder GetAnalogPattern()
    {
        AnalogPatternBuilder p = new AnalogPatternBuilder((int)Parameters["PatternLength"]);



        p.AddChannel("MWGeneratorAM");



        p.AddAnalogValue("MWGeneratorAM", 0, (double)Parameters["MWStartPower"]);

        //Ramp the power linearly by ramping the dBm logarhythmically{
        p.AddLinFromDbRamp("MWGeneratorAM", (int)Parameters["MWStartTime"], 100000, (double)Parameters["MWOnPower"]);
        p.AddLinFromDbRamp("MWGeneratorAM", (int)Parameters["MWRampDownTime"], 5000, (double)Parameters["MWFinalPower"]);
        //}

        //Ramp the dBm linearly{
        //p.AddLinearRamp("MWGeneratorAM", 90000,100,(double)Parameters["MWOnPower"]-6.0);//switch to quarter of the input power over 10ms
        //p.AddLinearRamp("MWGeneratorAM", 90100, 400, (double)Parameters["MWOnPower"]);
        //p.AddLinearRamp("MWGeneratorAM",135000,500,(double)Parameters["MWFinalPower"]);
        //}

        //p.AddAnalogValue("TopTrappingCoilcurrent", 90000, 0.0);
        //p.AddAnalogValue("BottomTrappingCoilcurrent", 90000,0.0);


        p.SwitchAllOffAtEndOfPatternExcept(new string[] { "MWGeneratorAM" });
        return(p);
    }