示例#1
0
        public void Initialize()
        {
            Heater1 = new HeatElement3000W(PortHeater1);
            Heater1.Start();

            Heater2 = new HeatElement3000W(PortHeater2);
            Heater2.Start();
        }
示例#2
0
        public void Initialize()
        {
            var blinker = new LedBlinker();
            blinker.Start();

            Heater1 = new HeatElement3000W(PortHeater1);
            Heater1.Start();

            Heater2 = new HeatElement3000W(PortHeater2);
            Heater2.Start();

        }
示例#3
0
        public BrewData(PT100Reader tempReader1, PT100Reader tempReader2, HeatElement3000W heater1, HeatElement3000W heater2)
        {
            Config = new Config();
            Config.SaveConfig();

            TempReader1 = tempReader1;
            TempReader2 = tempReader2;
            Heater1 = heater1;
            Heater2 = heater2;

            MashPID = new PID.PID(Config.MashPIDKp, Config.MashPIDKi, Config.MashPIDKd, Config.StrikeTemperature, tempReader1, Heater1);
            SpargePID = new PID.PID(Config.SpargePIDKp, Config.SpargePIDKi, Config.SpargePIDKd, Config.SpargePIDKd, tempReader2, Heater2);

            //Load the actual time and date from the time-chip
            TimeChip = new DS3231();

            var currentTime = TimeChip.GetDateTime();

            var dt = new DateTime(currentTime.Year, currentTime.Month, currentTime.Day, currentTime.Hour, currentTime.Minute, currentTime.Second);

            Microsoft.SPOT.Hardware.Utility.SetLocalTime(dt);
            MashStartTime = DateTime.Now.AddHours(1).AddMinutes(40);
        }