Accéder au contenu principal

Measure Temperature / Humidity and Heat Index using DHT 21 (AM 2301) + Arduino + LCD


Hello, today we have another Temperature and Humidity sensor to test it’s from the DHT serie, I already did a tutorial about DHT 11 DHT 22 and AM 2320 sensors, wiring and simple reading and also using LCD i²c screen.


It’s a digital sensor with capacitive humidity sensing and already calibrated, the module is said to have a high performance 8 bit chip to ensure the correct reading and transmitting the data, but as you can see in the video my module doesn’t have good humidity reading, as I said it takes very long time to comeback from 99% to normal reading which is 50%-60% here where I live, I may have a bad sensor, although it shows correct values before I blow on it to test it…



Range: According to the datasheet




The module can be powered by both 3.3V or 5V and the data pins goes to a digital pin here I choosed 2, the module can already have 3 wires (RED/BLACK/YELLOW) for (Vcc/GND/Signal) or you can open it inside to check the wiring.


And here’s the wiring in case you want to add an LCD i2c screen, you can power the module by 3.3V and the LCD with 5V if you want or power them both from 5V.


Install the libraries and here you go !!


  • The first code I tried is just the example from the library it works with various DHTs
  • The second code works with LCD i2c screen : –Download Celsius code here

Download Fahrenheit code here

That’s it, If you have any problem contact me.



Yassine Tout afficher

Electronics, Automation engineering student... I try to share my little experience with other electronics amateur.


Entrez vos coordonnées ci-dessous ou cliquez sur une icône pour vous connecter:


Vous commentez à l'aide de votre compte Déconnexion /  Changer )

Photo Google

Vous commentez à l'aide de votre compte Google. Déconnexion /  Changer )

Image Twitter

Vous commentez à l'aide de votre compte Twitter. Déconnexion /  Changer )

Photo Facebook

Vous commentez à l'aide de votre compte Facebook. Déconnexion /  Changer )

Connexion à %s

%d blogueurs aiment cette page :