#include <DHT.h>
#include <DHT_U.h>
DHT dht(2,DHT22);
void setup() {
// put your setup code here, to run once:
Serial.begin(9600);
dht.begin();
}
void loop() {
delay(2000);
float h=dht.readHumidity();
Serial.println(h);
}
#include <DHT.h>
#include <DHT_U.h>
DHT dht(2,DHT22);
void setup() {
// put your setup code here, to run once:
Serial.begin(9600);
dht.begin();
}
void loop() {
delay(2000);
float h=dht.readHumidity();
Serial.println(h);
}