Continue to Site

Welcome to EDAboard.com

Welcome to our site! EDAboard.com is an international Electronics Discussion Forum focused on EDA software, circuits, schematics, books, theory, papers, asic, pld, 8051, DSP, Network, RF, Analog Design, PCB, Service Manuals... and a whole lot more! To participate you need to register. Registration is free. Click here to register now.

Humidity and temperature measurment

Status
Not open for further replies.

venkates2218

Full Member level 6
Joined
Sep 30, 2016
Messages
354
Helped
1
Reputation
2
Reaction score
1
Trophy points
1,298
Activity points
4,306
I like to built an humidity and temperature controller using DHT22 sensor.
I this sensor their is only one data pin which used to connect with the controller...
By connecting one pin to the controller how to read the both humidity and temperature..?
 

Hi,

A simple internet serach brings a lot of results. With textual description and code examples.

Klaus
 

DHT22 uses One Wire Protocol to Communicate. If your Compiler has One Wire library then you can use it else you have to write your own One Wire library.

Which Compiler are you using ?

You should pull-up the One Wire Communication pin to 5V using a 4.7k resistor.

After reading the data which contains both temperature and humidity data you have to split them and use them.
 

Hi,

A simple internet serach brings a lot of results. With textual description and code examples.

Klaus

I searched in google I found lot of tutorials but they used inbuilt libraries in arduino and they measured temperature and humidity.
I like to use PIC18F4520 controller.

- - - Updated - - -

- - - Updated - - -

DHT22 uses One Wire Protocol to Communicate. If your Compiler has One Wire library then you can use it else you have to write your own One Wire library.

Which Compiler are you using ?

You should pull-up the One Wire Communication pin to 5V using a 4.7k resistor.

After reading the data which contains both temperature and humidity data you have to split them and use them.

I'm using PIC18F4520 with MPLAB X IDE 3.36 compiler.

Each data comes one by one like 1st data is temperature and 2nd data is humidity like that or something else..?

- - - Updated - - -

DHT22 uses One Wire Protocol to Communicate. If your Compiler has One Wire library then you can use it else you have to write your own One Wire library.

Which Compiler are you using ?

You should pull-up the One Wire Communication pin to 5V using a 4.7k resistor.

After reading the data which contains both temperature and humidity data you have to split them and use them.

I'm using PIC18F4520 with MPLAB X IDE 3.36 compiler.

Each data comes one by one like 1st data is temperature and 2nd data is humidity like that or something else..?
 

Hi,

you didn´t mention PIC in your first post.
Anyway, an internet search for "DHT22 PIC" gives more than you need to make it work: Documents, example code, application notes (even original Microchip ones), even youtube tutorials.

And if you just look at the arduino code, then you will have 80% of information, and the complete program flow.

Each data comes one by one like 1st data is temperature and 2nd data is humidity like that or something else..?
No one of us will know these things better than the datasheet.

--> I don´t see the need for a "global question" about DHT22 with PIC communication. Read the datasheets and go through the internet informations.
Then you are welcome to ask elaborated, detailed questions. Show us what you have done so far. Refer to documents.

Klaus
 

DHT22 is old massive sensor with poor accuracy and weird interface. I prefer bosch's BMP180/280
 

Hi,

I once tested HTU21D.
The first results were good.

Klaus
 

The accuracy of DHT22 is rather low, one can build an indicator rather measuring device using that sensor. I did good experience with Honeywell HIH-6130/6131
 

hello,

I tested a DTH22 AM2302 during any days, with loggin data..

This One Wire Sensor has problem of delay for reading bit , if interval of measurement is to short ..
With interval of 500mS , i get 2% error ( on >15000 measures), due to bit reading timeout delay ( with a timeout of 25µS !)
specsheet data page 7 :
*Collecting period should be : >2 second.

i modifiied my acquisition periode to 2000mS => No more error..
Accuracy seems correct ..
 

DTH22 is a decent sensor for those who are starting with microcontrollers and sensors, I used it a lot because is also cheap and very easy to implement
 

Status
Not open for further replies.

Similar threads

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Back
Top