#include "DHTesp.h"
DHTesp dhtSensor;
TempAndHumidity data;
const int DHT_PIN = 15;
void setup() {
// put your setup code here, to run once:
Serial.begin(115200);
dhtSensor.setup(DHT_PIN, DHTesp::DHT22);
Serial.println("Hello, ESP32!");
}
void loop() {
data = dhtSensor.getTempAndHumidity();
Serial.println("Humi" + String(data.humidity));
Serial.println("Temp" + String(data.temperature));
//Serial.println("------");
// put your main code here, to run repeatedly:
delay(1000); // this speeds up the simulation
}