GreenPonik_OneWire_DS18B20.py Library for Raspberry pi
This is the sample code for read temperature with DS18B20 sensor on One Wire bus.
The script auto-detect the 1W file and parse it to find the temperature value.
Table of Contents
- GreenPonik_OneWire_DS18B20.py Library for Raspberry pi
- Table of Contents
- Installation
- Methods
- Examples
- Credits
Installation
> git clone https://github.com/GreenPonik/GreenPonik_OneWire_DS18B20.git
from GreenPonik_OneWire_DS18B20.GreenPonik_OneWire_DS18B20 import read_temps
Methods
"""
Get temperatues in celcius and fahrenheit
"""
def read_temps():
Example
import time
from GreenPonik_OneWire_DS18B20.GreenPonik_OneWire_DS18B20 import read_temps
if __name__ == "__main__":
while True:
# read both celcius and fahrenheit temperatures
temperatures = read_temps()
print("celcius temp %.3f" % temperatures[0])
print("fahrenheit temp %.3f" % temperatures[1])
time.sleep(1)
pass
Credits
Write by Mickael Lehoux, from GreenPonik, 2019
Metadata
Release files for greenponik-onewire-ds18b20 0.0.1
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| greenponik-onewire-ds18b20-0.0.1.tar.gz | 4.8 kB | Without provenance | Details for greenponik-onewire-ds18b20-0.0.1.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| greenponik_onewire_ds18b20-0.0.1-py3-none-any.whl | Python 3 | none | any | Details for greenponik_onewire_ds18b20-0.0.1-py3-none-any.whl |
Total release size: 7.0 kB
Release files / greenponik-onewire-ds18b20-0.0.1.tar.gz
| Download URL | greenponik-onewire-ds18b20-0.0.1.tar.gz |
|---|---|
| Size | 4.8 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
3f2e783077fafffe3d43a6c2fbe3b157459b05f5c46565f56ba9a347cc277eb9
|
|
BLAKE2b-256 checksum How to use checksums |
64e227e210a851350459cdcf0b1b0006256689c22f48253a96ee80f2e899139f
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is 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
|
Release files / greenponik_onewire_ds18b20-0.0.1-py3-none-any.whl
| Download URL | greenponik_onewire_ds18b20-0.0.1-py3-none-any.whl |
|---|---|
| Size | 2.2 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
3fd9b02cf8c55beff63532a7f9d621c4268157a773f7c7c4919a9cfa20562b88
|
|
BLAKE2b-256 checksum How to use checksums |
5daf3934a6c186d68d5540373c012891b1343b27ef5fb8c9df670e6040b39926
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is 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
|
Security for greenponik-onewire-ds18b20 0.0.1
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.