This is a Windows 10 IoT core client application for the InfluxData IoT Pet Store Demo.
In general, it reads data from supported sensors, calculates average values and send it to an InfluxDb 2.0 behind the Pet Store server. It also reads 24h statistic data (min, mean, max) for each measurement. InfluxDb 2.0 communication is done with the help of InfluxDb 2.0 .NET Client
Application consists of 3 main modules:
- Background Job - Handles all of the logic: Subcribing with Petsore Server, read sensor values, writing to db and read statistical data from db.
- UWP GUI application - Displays measured and statistical data and allows configuration of the background job
- .NET Core console application - displays measured and statistical data in console. Allows also configuration.
- Dowload latest binaries from the releases
- Goto the Windows 10 IoT Core web console
- In the
Apps
section use Choose File and select PetStoreClientBackgroundApplication__arm_Debug.appxbundle - Check
Allow me to select framework packages
- Press
Install
. - On the next page add following file available also in releases:
Microsoft.NET.Native.Runtime.2.2.appx
- press
Next
- Wait couple of seconds and
PetStoreClientBackgroundApplication
will be shown in the app list - Change switch to be have the job autostart.
- Install either
PetStoreUWPClient_<lastest-version>_arm_Debug.appxbundle
or usePetStoreConsoleClient
to change location and view measured data.
- Mount device:
net use r: \\<device-ip>\c$
- Check log at:
r:\Data\USERS\DefaultAccount\AppData\Local\Packages\PetStoreClientBackgroundApplication-uwp_yazx2sj32dc22\LocalState\MetroLogs
BME280 and BMP180 are low power compact air temperature, humidity and pressure sensors from Bosch (BMP180 does't measure relative humidity). They communicate over I2C, so connect it to I2C of RPI:
- GND to (GND)
- SDA to RPI GPIO pin 3 (I2C SDA)
- SDC to RPI GPIO pin 5 (I2C SDC)
- VIN to RPI GPIO pin 1 (VCC)
DHT 22 is a temperature and humidity sensor communicating over proprietary 1 wire protocol. As it requires precice micro seconds timing, the communication with Rasperry Pi is not reliable. Windows 10 IoT core has a lot of bacground activities which makes this difficult.