Created
March 26, 2021 15:15
-
-
Save yemreeke/4b650d30975eee779e4ad7d0786119dc to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <LiquidCrystal_I2C.h> | |
#include <Wire.h> | |
#include <DHT.h> | |
LiquidCrystal_I2C lcd(0x27, 16, 2); | |
#define DHTPIN 3 | |
DHT dht(DHTPIN, DHT11); | |
void setup() { | |
dht.begin(); | |
lcd.begin(); | |
} | |
void loop() { | |
int nem = dht.readHumidity(); | |
float sicaklik = dht.readTemperature(); | |
lcd.clear(); | |
lcd.setCursor(0,0); | |
lcd.print("Sicaklik: "); | |
lcd.print(sicaklik); | |
lcd.setCursor(0,1); | |
lcd.print("Nem Orani: %"); | |
lcd.print(nem); | |
delay(1000); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment