{"id":19606271,"url":"https://github.com/seeed-studio/seeed_python_dht","last_synced_at":"2026-03-07T13:02:56.174Z","repository":{"id":57465288,"uuid":"201206942","full_name":"Seeed-Studio/Seeed_Python_DHT","owner":"Seeed-Studio","description":"The python3 code is to read the humidity and temperature from the sensor.","archived":false,"fork":false,"pushed_at":"2025-01-08T09:02:44.000Z","size":13,"stargazers_count":10,"open_issues_count":0,"forks_count":3,"subscribers_count":13,"default_branch":"master","last_synced_at":"2025-07-01T23:04:14.345Z","etag":null,"topics":["arduino","arduino-library","grove","humidity-sensor","temperature-sensor"],"latest_commit_sha":null,"homepage":"","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/Seeed-Studio.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE","code_of_conduct":"CODE_OF_CONDUCT.md","threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2019-08-08T07:49:21.000Z","updated_at":"2025-01-08T09:02:48.000Z","dependencies_parsed_at":"2025-01-08T21:02:32.629Z","dependency_job_id":null,"html_url":"https://github.com/Seeed-Studio/Seeed_Python_DHT","commit_stats":{"total_commits":8,"total_committers":3,"mean_commits":"2.6666666666666665","dds":0.625,"last_synced_commit":"b5ec0ec59c3f316ebae164451ade55e60027376b"},"previous_names":[],"tags_count":1,"template":false,"template_full_name":null,"purl":"pkg:github/Seeed-Studio/Seeed_Python_DHT","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Seeed-Studio%2FSeeed_Python_DHT","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Seeed-Studio%2FSeeed_Python_DHT/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Seeed-Studio%2FSeeed_Python_DHT/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Seeed-Studio%2FSeeed_Python_DHT/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Seeed-Studio","download_url":"https://codeload.github.com/Seeed-Studio/Seeed_Python_DHT/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Seeed-Studio%2FSeeed_Python_DHT/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":263047660,"owners_count":23405280,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["arduino","arduino-library","grove","humidity-sensor","temperature-sensor"],"created_at":"2024-11-11T10:04:04.885Z","updated_at":"2026-03-07T13:02:56.154Z","avatar_url":"https://github.com/Seeed-Studio.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Seeed DHT\n\nThis is a powerful sister version of our Grove - Temperature\u0026Humidity Sensor Pro. It has more complete and accurate performance than the basic version. The detecting range of this sensor is 5% RH - 99% RH, and -40°C - 80°C. And its accuracy reaches up to 2% RH and 0.5°C. A professional choice for applications that have relatively strict requirements.\n\nThis code is for\n- [Grove - Temperature\u0026Humidity Sensor Pro](https://www.seeedstudio.com/Grove-Temperature%26Humidity-Sensor-Pro%EF%BC%88AM2302%EF%BC%89-p-838.html)\n- [Grove - Temperature \u0026 Humidity Sensor (DHT11)](https://www.seeedstudio.com/Grove-Temperature-Humidity-Sensor-DHT1-p-745.html)\n- Grove - Temp \u0026 Humi Sensor v1.0 (DHT10)\n\n# Dependencies\nThis driver depends on:\n- [***grove.py***](https://github.com/Seeed-Studio/grove.py)\n\nThis is easy to install with the following command.\n ```\ncurl -sL https://github.com/Seeed-Studio/grove.py/raw/master/install.sh | sudo bash -s -\n ```\n## Installing from PyPI\n\nOn supported GNU/Linux systems like the Raspberry Pi, you can install the driver locally from PyPI. To install for current user:\n```\npip3 install seeed-python-dht\n```\nTo install system-wide (this may be required in some cases):\n```\nsudo pip3 install seeed-python-dht\n```\nTo install in a virtual environment in your current project:\n```\nmkdir project-name \u0026\u0026 cd project-name\npython3 -m venv .env\nsource .env/bin/activate\npip3 install seeed-python-dht\n```\n\n## Usage Notes\n\n#### for DHT11,DHT22\nFirst, Check the corresponding gpio number of the board:\n```\npi@raspberrypi:~/Seeed_Python_DHT $ grove_gpio\nHat Name = 'Grove Base Hat RPi'\n\u003cpin\u003e could be one of below values in the pin column for GPIO function\n   And connect the device to corresponding slot\n==============\n pin | slot\n==============\n  5  | D5   \n 12  | PWM  \n 16  | D16  \n 18  | D18  \n 22  | D22  \n 24  | D24  \n 26  | D26 \n```\nNext, initialize the sersor object:\n```python\nimport seeed_dht\n# for DHT11 the type is '11', for DHT22 the type is '22'\nsensor = seeed_dht.DHT(\"11\", 12)\n```\n\n#### for DHT10\nDHT10 uses i2c protocol, So there is no need to specify an extra pin.  \nJust add contents below:\n```python\nimport seeed_dht\n# for DHT11 the type is '11', for DHT22 the type is '22'\nsensor = seeed_dht.DHT(\"10\")\n```\n\n## Reading from the Sensor\nTo read from the sensor:\n```\nhumi, temp = sensor.read()\nprint('DHT{0}, humidity {1:.1f}%, temperature {2:.1f}*'.format(sensor.dht_type, humi, temp))\n```\n\n## Contributing\nIf you have any good suggestions or comments, you can send issues or PR us.","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fseeed-studio%2Fseeed_python_dht","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fseeed-studio%2Fseeed_python_dht","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fseeed-studio%2Fseeed_python_dht/lists"}