{"id":13894202,"url":"https://github.com/RobTillaart/DHTlib","last_synced_at":"2025-07-17T09:31:06.964Z","repository":{"id":45381369,"uuid":"276180244","full_name":"RobTillaart/DHTlib","owner":"RobTillaart","description":"Arduino library for DHT temperature and humidity sensor. AVR optimized","archived":false,"fork":false,"pushed_at":"2024-04-13T08:58:39.000Z","size":30,"stargazers_count":25,"open_issues_count":0,"forks_count":8,"subscribers_count":4,"default_branch":"master","last_synced_at":"2024-11-19T06:33:13.302Z","etag":null,"topics":["arduino","humidity","temperature"],"latest_commit_sha":null,"homepage":"","language":"C++","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/RobTillaart.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":".github/FUNDING.yml","license":"LICENSE","code_of_conduct":null,"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},"funding":{"github":"RobTillaart","custom":"https://www.paypal.me/robtillaart"}},"created_at":"2020-06-30T18:37:23.000Z","updated_at":"2024-10-06T23:00:44.000Z","dependencies_parsed_at":"2024-04-13T09:52:41.211Z","dependency_job_id":"e8b15226-fee1-412b-bc1d-397121edb26a","html_url":"https://github.com/RobTillaart/DHTlib","commit_stats":null,"previous_names":[],"tags_count":7,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/RobTillaart%2FDHTlib","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/RobTillaart%2FDHTlib/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/RobTillaart%2FDHTlib/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/RobTillaart%2FDHTlib/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/RobTillaart","download_url":"https://codeload.github.com/RobTillaart/DHTlib/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":226248197,"owners_count":17595158,"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","humidity","temperature"],"created_at":"2024-08-06T18:01:26.378Z","updated_at":"2024-11-24T23:30:14.802Z","avatar_url":"https://github.com/RobTillaart.png","language":"C++","funding_links":["https://github.com/sponsors/RobTillaart","https://www.paypal.me/robtillaart"],"categories":["C++"],"sub_categories":[],"readme":"\n[![Arduino CI](https://github.com/RobTillaart/DHTlib/workflows/Arduino%20CI/badge.svg)](https://github.com/marketplace/actions/arduino_ci)\n[![Arduino-lint](https://github.com/RobTillaart/DHTlib/actions/workflows/arduino-lint.yml/badge.svg)](https://github.com/RobTillaart/DHTlib/actions/workflows/arduino-lint.yml)\n[![JSON check](https://github.com/RobTillaart/DHTlib/actions/workflows/jsoncheck.yml/badge.svg)](https://github.com/RobTillaart/DHTlib/actions/workflows/jsoncheck.yml)\n[![GitHub issues](https://img.shields.io/github/issues/RobTillaart/DHTlib.svg)](https://github.com/RobTillaart/DHTlib/issues)\n\n[![License: MIT](https://img.shields.io/badge/license-MIT-green.svg)](https://github.com/RobTillaart/DHTlib/blob/master/LICENSE)\n[![GitHub release](https://img.shields.io/github/release/RobTillaart/DHTlib.svg?maxAge=3600)](https://github.com/RobTillaart/DHTlib/releases)\n[![PlatformIO Registry](https://badges.registry.platformio.org/packages/robtillaart/library/DHTlib.svg)](https://registry.platformio.org/libraries/robtillaart/DHTlib)\n\n\n# DHTlib\n\nArduino library for DHT temperature and humidity sensor. AVR optimized\n\n\n## Description\n\nThe DHT11, 21, 22, 33 and 44 are relative inexpensive sensors for measuring temperature and humidity.\n\nThis library can be used for reading both values from these DHT sensors.\nThe DHT11 only returns integers (e.g. 20) and does not support negative values.\nThe others are quite similar and provide one decimal digit (e.g. 20.2)\nThe hardware pins of the sensors and handshake are identical so ideal to combine in one lib.\n\nThe library (0.1.13 version) is confirmed to work on:\n\n- UNO (tested myself)\n- 2009 (tested myself)\n- MEGA2560\n- DUE\n- attiny85 @8MHz\n- Digistump Digix @ 84 MHz\n\nLater 0.1.xx versions are optimized for AVR only.\n\nMore information - http://playground.arduino.cc/Main/DHTLib -\n\nFor latest version for the DHT, check https://github.com/RobTillaart/DHTNEW\n\n\n## DHT PIN layout from left to right\n\n| Front |      | Description   |\n|:------|:----:|:--------------|\n| pin 1 |      | VCC           |\n| pin 2 |      | DATA          |\n| pin 3 |      | Not Connected |\n| pin 4 |      | GND           |\n\n\n## Interface\n\n```cpp\n#include \"dht.h\"\n```\n\n\n#### Constructor\n\n- **dht()** Constructor\n\n\n#### Read functions per type\n\n- **int8_t read11(uint8_t pin)**\n- **int8_t read(uint8_t pin)**\n- **int8_t read12(uint8_t pin)**\n\n- **inline int8_t read21(uint8_t pin)**\n- **inline int8_t read22(uint8_t pin)**\n- **inline int8_t read33(uint8_t pin)**\n- **inline int8_t read44(uint8_t pin)**\n- **inline int8_t read2301(uint8_t pin)**\n- **inline int8_t read2302(uint8_t pin)**\n- **inline int8_t read2303(uint8_t pin)**\n- **inline int8_t read2320(uint8_t pin)**\n- **inline int8_t read2322(uint8_t pin)**\n\n- **float humidity** public class variable to access last read humidity.\n- **float temperature** public class variable to access last read temperature.\n\n\n#### Enable / disable interrupts\n\n- **bool getDisableIRQ()**\n- **void setDisableIRQ(bool b )**\n\n\n## Operational\n\nSee examples\n\n\n## Versions\n\n- See changelog.md\n- See DHTNEW or DHTStable library for latest stable version for all platforms.\n\n\n## Future\n\n#### Must\n\n- improve documentation\n\n#### Should\n\n- separate history versions CHANGELOG.md file ?\n\n#### Could\n\n- improve unit tests\n  - constants\n- move non public part of #defines to .cpp\n\n#### Wont\n\n- updates only on request basis (bugs)\n\n\n## Support\n\nIf you appreciate my libraries, you can support the development and maintenance.\nImprove the quality of the libraries by providing issues and Pull Requests, or\ndonate through PayPal or GitHub sponsors.\n\nThank you,\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FRobTillaart%2FDHTlib","html_url":"https://awesome.ecosyste.ms/projects/github.com%2FRobTillaart%2FDHTlib","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FRobTillaart%2FDHTlib/lists"}