2025-07-07 10:27 PM
I am trying to interface DHT22 sensor with STM32F411RE board. When initially I interfaced I was able to see data (i.e., Temp and Humidity) I am giving 3.3v power supply, data pin connected to PA0 ground and set clock frequency to 50MHZ using Internal oscillator. But when now I am trying to check values, I am not able to get values I haven't change anything in code still I am facing this issue. The code is stuck in while loop of DHT22_response function where it is waiting for pin to be low. I have attached coding file please can anyone help me regarding this??
2025-07-08 3:34 AM
Hello @Reva1605,
Have you tried connecting a pull-up resistor to the data line? Without it, the DHT11 may not be able to pull the line HIGH.
Best regards,
2025-07-08 4:48 AM
Yes tried connecting pull-up resistor of value 4.7k still not working
2025-07-08 5:36 AM - edited 2025-07-08 5:37 AM
So, to understand correctly, you created a project and added the functions to interface with the DHT22 sensor. Initially, it worked, but after rebuilding and testing the project again, it got stuck in the DHT22_response
function? Have you tried supplying 5V to the sensor or using a different GPIO pin instead of the wakeup pin PA0?
2025-07-08 6:46 AM
Welcome to the forum.
Please see How to write your question to maximize your chances to find a solution for best results.
In particular, please describe: