summaryrefslogtreecommitdiff
path: root/esp/DHT11.ino
diff options
context:
space:
mode:
authorGustavoeklund01 <eklundgu@gmail.com>2025-10-27 19:15:23 -0300
committerGustavoeklund01 <eklundgu@gmail.com>2025-10-27 19:15:23 -0300
commit4008253dfd2005da102f6da06389268ecef152f6 (patch)
treed8e7efa5262fcd212a0a30d647dcf12eb742fab2 /esp/DHT11.ino
parentf8b53f993ac61e470bcc1ee321c16a0657cf161d (diff)
conciliação dos sensores do esp32
Diffstat (limited to 'esp/DHT11.ino')
-rw-r--r--esp/DHT11.ino26
1 files changed, 0 insertions, 26 deletions
diff --git a/esp/DHT11.ino b/esp/DHT11.ino
deleted file mode 100644
index e0f0342..0000000
--- a/esp/DHT11.ino
+++ /dev/null
@@ -1,26 +0,0 @@
-#include "DHT.h"
-#define DHTPIN 32
-#define DHTTYPE DHT11
-
-DHT dht(DHTPIN, DHTTYPE);
-
-void setup() {
- Serial.begin(115200);
- dht.begin();
- Serial.println("Teste sensor DHT11 Temperatura e humidade");
-}
-void loop(){
- float h = dht.readHumidity();
- float t = dht.readTemperature();
-
- if (isnan(h) || isnan(t)){
- Serial.println("ERRO de leitura");
- return;
- }
- Serial.print("Humidade: ");
- Serial.print(h);
- Serial.print("% | Temperatura:");
- Serial.print(t);
- Serial.println(" °C");
- delay(2000);
-} \ No newline at end of file