Hello,
please feel free to use and share the HDT22 driver / library for ESP32
https://github.com/gosouth/DHT22
The code works fine, however it needs some work in a function called 'getSignalLevel( )'. I'm looking for a good method to measure a pulse width. Something with interrupt blocking... If someone has a good idea, please let me know.
chao
DHT22 library for ESP32
-
- Posts: 9764
- Joined: Thu Nov 26, 2015 4:08 am
Re: DHT22 library for ESP32
Use the RMT peripheral; it's perfect for signals like this and should be able to receive the DHT22 signal all on its own. It can trigger an interrupt afterwards, and you can use that to un-block a task that decodes the temp/humidity from it and passes it on.
Who is online
Users browsing this forum: No registered users and 55 guests