Prometheus exporter for the Airthings Waveplus air sensor, based on their library
This worked for me on a raspberry pi 3.
$ sudo systemctl start hciuart
$ sudo bluetoothctl
[bluetooth]# power on
[bluetooth]# show
...
Powered: yes
...
$ sudo apt install python-pip libglib2.0-dev
$ sudo pip2 install bluepy==1.2.0 prometheus_client
A raspberry pi has more than enough compute to run a prometheus instance, this exporter, and plenty more. See the example config file.
$ prometheus --config.file example_prometheus_config.yml
usage: waveplus_exporter.py [-h] [--port [PORT]] [--bind [BIND]] [--periodseconds [PERIODSECONDS]] --serialnumber [SERIALNUMBER]
optional arguments:
-h, --help show this help message and exit
--port [PORT] The TCP port to listen on (default: 9744)
--bind [BIND] The interface/IP to bind to (default: 0.0.0.0)
--periodseconds [PERIODSECONDS] number of seconds to wait between sampling (default: 60)
Grafana dashboard
The original reader from Airthings uses the MIT License, and so does this.