Example #1
0
        public App()
        {
            InitializePeripherals();
            InitializeWebServer();

            HumidityLogs = new ArrayList();
            HumidityLogs = MicroSDController.Load();
        }
Example #2
0
        private void OnTimerInterrupt(object state)
        {
            HumidityLogs.Add(new HumidityLog()
            {
                Date     = _rtc.CurrentDateTime.ToString("hh:mm tt dd/MMM/yyyy"),
                Humidity = (int)_humiditySensor.Read()
            });

            MicroSDController.Save(HumidityLogs);

            Thread _animationThread = new Thread(() =>
            {
                _rgbPwmLed.StartBlink(Netduino.Foundation.Color.Blue);
                Thread.Sleep(1000);
                _rgbPwmLed.SetColor(Netduino.Foundation.Color.Green);
            });

            _animationThread.Start();
        }