added luftdaten

This commit is contained in:
2017-11-15 10:44:47 +01:00
parent 7d6e24d264
commit c373fca876
7 changed files with 22 additions and 0 deletions

View File

@@ -14,6 +14,9 @@ Monitor some parameters of Freifunk routers
## heating ## heating
Some heating rules, based on a time schedule, presence and TV status. Some heating rules, based on a time schedule, presence and TV status.
## luftdaten
Monitor some parameters of Luftdaten.info sensors
## presence ## presence
Wifi Presence - Detect a person with his/her smartphone entering or leaving the wireless home network (based on a Fritzbox and two DD-WRT based access points). Wifi Presence - Detect a person with his/her smartphone entering or leaving the wireless home network (based on a Fritzbox and two DD-WRT based access points).

View File

@@ -0,0 +1 @@
JSON.parse(input).sensors['3'].lastMeasurement.value;

View File

@@ -0,0 +1 @@
JSON.parse(input).sensors['2'].lastMeasurement.value;

10
luftdaten/README.md Normal file
View File

@@ -0,0 +1,10 @@
# Luftdaten.info
Monitor particulate matter, temperature and humidity parameters of [Luftdaten](http://luftdaten.info) sensors.
I run a [Luftdaten](http://luftdaten.info) particulate matter sensor and use [openSenseMap](https://opensensemap.org) to collect data from it to display and use in openHAB.
First you need to register your sensor with openSenseMap. You can access the data of your sensor through a JSON file. All you need is the box id of your sensor as described [here](https://github.com/sensebox/OpenSenseMap-API/wiki/API-Dokumentation).
* **luftdaten.items**: Put this file into your */etc/openhab2/items* directory and modify it for your specific setup. Maybe everything suits your needs, but you need to enter the correct box id for your sensor like described [here](https://github.com/sensebox/OpenSenseMap-API/wiki/API-Dokumentation).
* **DHT22_\*.js**: Put these files into your */etc/openhab2/transform* directory.
* **SDS011_\*.js**: Put these files into your */etc/openhab2/transform* directory.

1
luftdaten/SDS011_PM10.js Normal file
View File

@@ -0,0 +1 @@
JSON.parse(input).sensors['0'].lastMeasurement.value;

1
luftdaten/SDS011_PM25.js Normal file
View File

@@ -0,0 +1 @@
JSON.parse(input).sensors['1'].lastMeasurement.value;

View File

@@ -0,0 +1,5 @@
Number SDS011_PM10 "PM10 [%s]" { http="<[https://api.opensensemap.org/boxes/1234567890abcdefabcdefabc:60000:JS(SDS011_PM10.js)]" }
Number SDS011_PM25 "PM2.5 [%s]" { http="<[https://api.opensensemap.org/boxes/1234567890abcdefabcdefabc:60000:JS(SDS011_PM25.js)]" }
Number DHT22_Temperatur "Temperatur [%.1f °C]" { http="<[https://api.opensensemap.org/boxes/1234567890abcdefabcdefabc:60000:JS(DHT22_Temperatur.js)]" }
Number DHT22_Luftfeuchtigkeit "Luftfeuchtigkeit [%.1f %%]" { http="<[https://api.opensensemap.org/boxes/1234567890abcdefabcdefabc:60000:JS(DHT22_Luftfeuchtigkeit.js)]" }