public MeadowApp() { InitHardware(); Console.WriteLine($"Temp: {sensor.Temperature}"); Console.WriteLine($"Humidity: {sensor.Humidity}"); sensor.StartUpdating(); }
public MeadowApp() { try { Console.WriteLine("Initialising SHT31D..."); sensor = new Sht31D(Device.CreateI2cBus()); sensor.Updated += Sensor_Updated; sensor.StartUpdating(); } catch (Exception ex) { Console.WriteLine(ex.Message); } }