コード例 #1
0
        // posljemo podatke na spletno stran
        private void Poslji(object sender, RoutedEventArgs e)
        {
            ConnectTheDotsSensor sensor = ctdHelper.sensors.Find(item => item.measurename == "Temperature");

            sensor.value     = temperatura;
            sensor.alerttype = opozorilo;
            sensor.message   = sporocilo;
            ctdHelper.SendSensorData(sensor);
        }
コード例 #2
0
 public void SendSensorData(ConnectTheDotsSensor sensor)
 {
     sensor.timecreated = DateTime.UtcNow.ToString("o");
     sendMessage(sensor.ToJson());
 }