Skip to content

Instantly share code, notes, and snippets.

@parzibyte
Last active February 17, 2020 17:19
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save parzibyte/1bc18a08801446743f873f7c812e2610 to your computer and use it in GitHub Desktop.
Save parzibyte/1bc18a08801446743f873f7c812e2610 to your computer and use it in GitHub Desktop.
#define PIN_CONEXION D8// A cuál pin está conectado el lector
#define TIPO_SENSOR DHT22 // Puede ser DHT11 también
DHT sensor(PIN_CONEXION, TIPO_SENSOR);
float humedad, temperaturaEnGradosCelsius = 0;
int ultimaVezLeido = 0;
long milisegundosDeEsperaParaLeer = 2000; // 2 segundos
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment