SDS011 Library
Project description
sds011lib
sds011lib
is a fully-typed, nearly-complete, python 3.8+ library for interacting with the SDS011 Air Quality Sensor.
The full documentation is available at https://timorme.github.io/sds011lib/
Installation
pip install sds011lib
Quickstart
from sds011lib import SDS011QueryReader
from serial import Serial
# Setup a query-mode reader on /dev/ttyUSB0
sensor = SDS011QueryReader(ser_dev=Serial('/dev/ttyUSB0', timeout=2))
# Read some data!
aqi = sensor.query()
print(aqi.pm25)
print(aqi.pm10)
# Put the device to sleep
sensor.sleep()
# Wake it back up
sensor.wake()
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
sds011lib-0.2.1.tar.gz
(8.2 kB
view hashes)
Built Distribution
Close
Hashes for sds011lib-0.2.1-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | ffe5d1b3da85e00c925ad78de0b9ce291d7d98c51715c30ea22d91fc56cbbcea |
|
MD5 | e41c15937af4d79807600a8cdc1f65fa |
|
BLAKE2b-256 | 8b74dd9b89425a7538dcb5c6a217586831ab6f97ee751bf5f3558809b27af75c |