Python base class to create infinite loop to work with sensors.
Project description
Generic Python base class to create infinite loop to work with different sensors connected to Raspberry Pi. Project contains also extended Python base class with MQTT support.
RPi.Sensor library is stable in terms of running as a base class. Sensor logic and additional functionality before and after sensor measurement should be implemented in child objects anyway… But there are new features developed (and bug fixed as they are found) so it is recommended always use the latest version.
If you want to see example of implemented sensors, have a look at my other RPi repo.
Installation
Install the latest released version using pip:
pip install https://github.com/ricco386/RPi.Sensor/zipball/master
Alternatively install latest released version from pypi:
pip install --upgrade RPi.Sensor
Make sure all dependencies (listed below) are installed (done automatically when installing via pip)
Dependencies:
Usage
Inherit Sensor object or MqttSensor.
Main purpose of the sensor object is to run infinite loop for reading from the sensors. Object has build in basic functionality to terminate the infinite loop correctly (uppon CTRL+C or kill signal), basic logging etc.
Intention is to have ability to easily run some code before (or after) reading the sensor, this is is skeleton that doesnt do any logic and should be used only as a base for building the interactions with the sensors.
If you want to see example of implemented sensors, have a look at my other RPi repo.
If you find a security vulnerability please read through SECURITY.rst file and report it responsibly. All other issues and feature requests report via Github issue tracker.
License
For more information see the LICENSE file.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
File details
Details for the file RPi.Sensor-0.5.3.tar.gz
.
File metadata
- Download URL: RPi.Sensor-0.5.3.tar.gz
- Upload date:
- Size: 8.1 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.2.0 pkginfo/1.5.0.1 requests/2.24.0 setuptools/41.2.0 requests-toolbelt/0.9.1 tqdm/4.48.0 CPython/3.8.3
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 27ac91db0b7c7952c1a2d43b75c3897a1ac4c7245dbfd6005f2e1c3e63ac5a61 |
|
MD5 | e088396ccdbf355ffa8f7193c657ac1d |
|
BLAKE2b-256 | b005cb8507dbf25de6d0bb51799ac773ecc10cef154262b1c9b03b2696a2e609 |
File details
Details for the file RPi.Sensor-0.5.3-py3-none-any.whl
.
File metadata
- Download URL: RPi.Sensor-0.5.3-py3-none-any.whl
- Upload date:
- Size: 11.2 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.2.0 pkginfo/1.5.0.1 requests/2.24.0 setuptools/41.2.0 requests-toolbelt/0.9.1 tqdm/4.48.0 CPython/3.8.3
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | e61120377cb02c87310573ecc5d871f6bd821b9f94aec01de71b90a50c987d17 |
|
MD5 | 524ebf9770eb4637e972da52196dbc66 |
|
BLAKE2b-256 | cdd18d92abd8ad56ec99009ff23615756d2f782d85ad604732cf7ce836303a1c |