DHT22 Negative temperature

Hi guys,
If someone could help it would be much apreciated.I am using DHT22 sensor for my weather station for temperature and humidity reading.Humidity works fine,but for temperature,after it drops and becomes negative the value reported is something like -3273 …Could it be because of the library?
i am using #include <DHT.h> .

#define DHTPIN 2 // what pin we’re connected to
#define DHTTYPE DHT22 // DHT 22 (AM2302)
DHT dht(DHTPIN, DHTTYPE); //// Initialize DHT sensor for normal 16mhz Arduino
int tempint;
temp= dht.readTemperature();
tempint = (int) temp;

much apreciated

Please edit your post to include the complete program, surrounded by code tags.

If you're located in parts of the U.S. right now, that could be a real temperature reading... :confused:


...but seriously ... your code is incomplete. Where is the variable temp defined, for example?

This topic was automatically closed 120 days after the last reply. New replies are no longer allowed.