Skip to main content

A minimal implementation for taking temperature and humidity readings with the DHT20 sensor

Project description

dht20-sensor

Code for taking readings with the DHT20 temperature humidity sensor using I2C.

This is the most basic working implementation that suits my needs. It doesn't handle sensor initialisation.

Example Usage

import time

from dht20_sensor.sensor import DHT20Sensor

if __name__ == "__main__":
    sensor = DHT20Sensor()

    while True:
        t, h = sensor.read()
        print(t)
        print(h)
        time.sleep(2)

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

dht20_sensor-0.0.2.tar.gz (14.5 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

dht20_sensor-0.0.2-py3-none-any.whl (14.9 kB view details)

Uploaded Python 3

File details

Details for the file dht20_sensor-0.0.2.tar.gz.

File metadata

  • Download URL: dht20_sensor-0.0.2.tar.gz
  • Upload date:
  • Size: 14.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.1 CPython/3.9.2

File hashes

Hashes for dht20_sensor-0.0.2.tar.gz
Algorithm Hash digest
SHA256 936b021dbd6a69caaa61aa349597648c6c2a77822b9cf2bd8ff0ecfdfe253b54
MD5 ff62dbd64689a14ba759c021fc226ee7
BLAKE2b-256 f1c1fc33f96266eb8f3d157ec3384e0057ea8f40bb56e5c5c556662048daec15

See more details on using hashes here.

File details

Details for the file dht20_sensor-0.0.2-py3-none-any.whl.

File metadata

  • Download URL: dht20_sensor-0.0.2-py3-none-any.whl
  • Upload date:
  • Size: 14.9 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.1 CPython/3.9.2

File hashes

Hashes for dht20_sensor-0.0.2-py3-none-any.whl
Algorithm Hash digest
SHA256 0b47cf60516674ea5506f9fa6fcf26bc5a259a322318e115379a9c66c3b81a23
MD5 639a332a0d034f9ae2360a491328607d
BLAKE2b-256 370a6d26c67474ff8cf84605463d5943e20a66b0eadfe64e96a2fe58613d824f

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page