Merhabalar arduino ile yeni tanistim sitedeki yeniden baslayanlar uygulamalarini tamamladiktan sonra internette gordum normal hayatta kullanabilecegim projeler yapmak istiyorum. http://www.geeetech.com/wiki/index.php/Electric\_thermometer\_by\_using\_DHT11\_sensor\_module Buradaki uygulamayi yapmak istiyorum Kodu yazinca derlemede sketch_mar27a.ino:1:17: error: DHT.h: No such file or directory sketch_mar27a:5: error: ‘DHT’ does not name a type sketch_mar27a.ino: In function ‘void setup()’: sketch_mar27a:10: error: ‘dht’ was not declared in this scope sketch_mar27a.ino: In function ‘void loop()’: sketch_mar27a:13: error: ‘dht’ was not declared in this scope dht11.h kutuphanesini ekleyip #include “DHT.h” satirini #include .<.dht11.h.>.noktalamalar yok duzelttikten sonra sketch_mar27a:5: error: 'DHT' does not name a type sketch_mar27a.ino: In function 'void setup()': sketch_mar27a:10: error: 'dht' was not declared in this scope sketch_mar27a.ino: In function 'void loop()': sketch_mar27a:13: error: 'dht' was not declared in this scope sketch_mar27a:20: error: expected}’ at end of input sketch_mar27a:20: error: expected `}’ at end of input buradan sonrasini cozemiyorum aslinda istegim dst11 ile olcum yapip lcd panelde gostermek burayi gecebilirsem rf haberlesme ile veriyi baska yere tasimak
kod içinde tanımlamalarıda düzeltmeniz gerekebilir. DHT yazan yerleri dht11 yapmak gibi http://arduino.cc/forum/index.php/topic,155449.0.html adresindeki en üstteki mesajda verilen koda bakıp kodunuzu kontrol edin.
DHT leri dht11 yapmak sorunu cozmedi adresteki kodun icindende cikamadim 3-5 yerden soyle birseyler derledim include <wire.h>
include <dht11.h> // dht11 kütüphanesini ekliyoruz.
include “RTClib.h”
include <liquidcrystal.h>
define DHT11PIN 7 // DHT11PIN olarak Dijital 2’yi belirliyoruz.
LiquidCrystal lcd(12, 11, 5, 4, 3, 2);
RTC_DS1307 RTC;
dht11 DHT11;
float tempC = 0; // variable for holding Celcius temp (floating for decimal points precision)
float tempf = 0; // variable for holding Fareghneit temp
int tempPin = 0; // Declaring the Analog input to be 0 (A0) of Arduino board.
float samples[8]; // array to hold 8 samples for Average temp calculation
float maxi = 0,mini = 100; // max/min temperature variables with initial values. LM35 in simple setup only measures Temp above 0.
void setup () {
Wire.begin();
RTC.begin();
lcd.begin(16, 2);
lcd.setCursor(0, 0); // set LCD cursor position (column, row)
lcd.print(" ZaferCelik “); // print text to LCD
lcd.setCursor(0, 1);
lcd.print(“Arduino project”);
delay(5000); // wait 500ms
lcd.clear(); // clear LCD display
lcd.setCursor(0, 0);
lcd.print(” Proje1 “);
lcd.setCursor(0, 1);
lcd.print(” Digital Monitor ");
delay(5000);
lcd.clear();
}
void loop () {
DateTime now = RTC.now();
int chk = DHT11.read(DHT11PIN);
lcd.clear();
lcd.setCursor(0, 0);
lcd.print(now.day(), DEC);
lcd.print(‘/’);
lcd.print(now.month(), DEC);
lcd.print(‘/’);
lcd.print(now.year(), DEC);
lcd.setCursor(11, 0);
lcd.print(‘C’);
lcd.setCursor(12, 0);
lcd.print((float)DHT11.temperature, 2);
lcd.setCursor(0, 1);
lcd.print(now.hour(), DEC);
lcd.print(‘:’);
lcd.print(now.minute(), DEC);
lcd.print(‘:’);
lcd.print(now.second(), DEC);
lcd.setCursor(11, 1);
lcd.print(‘%’);
lcd.setCursor(12, 1);
lcd.print((float)DHT11.humidity, 2);
delay(1000);
}
Bu oldu
http://b1303.hizliresim.com/17/x/lkujv.jpg
</liquidcrystal.h></dht11.h></wire.h>
Ben de aynı proje üzerinde çalışıyorum birçok sitede araştırma yaptım ama derlemede hata veriyor.
---------------- include <dht11.h>
define DHT11PIN 7
include <liquidcrystal.h>
LiquidCrystal lcd(12, 11, 5, 4, 3, 2);
void setup()
{
Serial.begin(9600);
lcd.begin(16, 2);
lcd.print(?FTY Project?);
delay(500);
}
void loop()
{
int chk = DHT11.read(DHT11PIN);
lcd.setCursor(0,0); //1.satır için yazdırılır.
lcd.print("Sicaklik ?C= ");
lcd.print((float)DHT11.temperature);
lcd.setCursor(0,1); //2.satır için yazdırılır.
lcd.print("Nem % = ");
lcd.print((float)DHT11.humidity);
delay(1000);
}
</liquidcrystal.h></dht11.h>
dht11 Time Out Error veriyor.
Time out ise zaman aşımına uğramıştır. Yani şöyle açıklıyayım arduino sensörden belli sürede veri alması gerekir. Eğer veriyi alamazsa zaman aşımına uğrar. Hem bu sensörden bilgi okumak basit, sensörünüzde bi sıkıntı olabilir. http://arduinoturkiye.com/dht11-sicaklik-ve-nem-sensorunun-arduino-ile-kullanimi/ bu linke bakın bide eğer daha önce bakmadıysanız. Linkte hazır bir örnek var ve dht11 kütüphaneside var. Buna rağmen sıkıntı yaşıyorsanız yorum olarak yazarsınız elimizden geldiğince yardımcı olmaya çalışırız. Kolay gelsin