-
Notifications
You must be signed in to change notification settings - Fork 11
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Just DHT-timeout #1
Comments
Sorry, I'm very outdated, I need to remember what I did... What version of ESP-IDF are you using? I used ESP-IDF v2.1. I think CPU Crystal frequency changed, so timing returning in getSignalLevel () may be different. I don't like this logic. It needs some interrupt blocking / priority to ensure it runs in realtime. |
I had similar issues, using an ESP32-CAM module. Got it solved by making sure the pin I was using was correctly configured as gpio by calling "gpio_pad_select_gpio" before using the DHT-library. |
The problem is the time! the 1uS delay is not a real 1uS delay (verified with oscilloscope) . This means you have to "calibrate" your timing". I reviewed the rotine to read the low and high level and it works better. |
Trying with current esp-idf (End Feb. 2018), this code is not running as expected. Output produced:
=== Reading DHT ===␍␊
[08:13:21:124] DHT: Sensor Timeout␍␊
[08:13:21:124] ␍␊
[08:13:21:124] Hum 0.0␍␊
[08:13:21:124] Tmp 0.0
Sensor is connected to GPIO15, working well with Arduino-Library, but not with this one. Only adaption made: Change DHT_main.c:23 into "setDHTgpio( 15 );".
The text was updated successfully, but these errors were encountered: