#include "DHT.h"
const int luz1 = 16;
const int luz2 = 17;
#define DHTPIN 19 /* informações do sensor */
#define DHTTYPE DHT22 /* Tipo de sensor DHT22 */
DHT dht(DHTPIN, DHTTYPE, 15);
void setup() {
// put your setup code here, to run once:
Serial.begin(115200);
dht.begin();
pinMode(luz1, OUTPUT);
pinMode(luz2, OUTPUT);
}
void loop() {
// put your main code here, to run repeatedly:
Serial.println(dht.readTemperature());
digitalWrite(luz1, HIGH);
digitalWrite(luz2, LOW);
delay(1000); // this speeds up the simulation
digitalWrite(luz1, LOW);
digitalWrite(luz2, HIGH);
delay(1000);
}