Hallo ich habe versucht das Beispiel zu compilieren dies bricht immer mit dem Fehler ab.Im Internationalen Forum gibt es einen Beitrag der glaube ich meinem Fehler ähnlich ist. Bug in LCD_I2C library .
Ist es gefordert bei lcd.begin in die Klammern etwas einzugeben wenn ja was .
cols rows charsize
mit dem scanner l2c sehe ich den Teilnehmer 0x27
/**
* Displays text sent over the serial port (e.g. from the Serial Monitor) on
* an attached LCD.
*/
#include <Wire.h>
#include <LiquidCrystal_I2C.h>
// Set the LCD address to 0x27 for a 16 chars and 2 line display
LiquidCrystal_I2C lcd(0x27, 16, 2);
void setup()
{
lcd.begin();
lcd.backlight();
// Initialize the serial port at a speed of 9600 baud
Serial.begin(9600);
}
void loop()
{
// If characters arrived over the serial port...
if (Serial.available()) {
// Wait a bit for the entire message to arrive
delay(100);
// Clear the screen
lcd.clear();
// Write all characters received with the serial port to the LCD.
while (Serial.available() > 0) {
lcd.write(Serial.read());
}
}
}
Die Fehlermeldung ist bis zur absoluten Unkenntlichkeit verstümmelt.
Da ist doch ein button auf dem steht: Fehlermeldung kopieren!
Mach das.
Und dann in Codetags hier einwerfen.
Ansonsten könnte es alles mögliche sein.
Ich sehe nur, dass .begin() mindestens 2 Werte erwartet.
Aber woher die kommen steht in der lib, zu der ein link fehlt.
/home/walter/Arduino/sketch_LCD/sketch_LCD.ino: In function 'void setup()':
/home/walter/Arduino/sketch_LCD/sketch_LCD.ino:13:12: error: no matching function for call to 'LiquidCrystal_I2C::begin()'
lcd.begin();
^
In file included from /home/walter/Arduino/sketch_LCD/sketch_LCD.ino:6:0:
/home/walter/Arduino/libraries/LiquidCrystal_I2C/LiquidCrystal_I2C.h:58:8: note: candidate: void LiquidCrystal_I2C::begin(uint8_t, uint8_t, uint8_t)
void begin(uint8_t cols, uint8_t rows, uint8_t charsize = LCD_5x8DOTS );
^~~~~
/home/walter/Arduino/libraries/LiquidCrystal_I2C/LiquidCrystal_I2C.h:58:8: note: candidate expects 3 arguments, 0 provided
exit status 1
Compilation error: no matching function for call to 'LiquidCrystal_I2C::begin()'
/tmp/.arduinoIDE-unsaved202524-16581-1swbuwh.kzoy/sketch_mar4a/sketch_mar4a.ino: In function 'void setup()':
/tmp/.arduinoIDE-unsaved202524-16581-1swbuwh.kzoy/sketch_mar4a/sketch_mar4a.ino:10:12: error: no matching function for call to 'LiquidCrystal_I2C::begin()'
lcd.begin();
^
In file included from /tmp/.arduinoIDE-unsaved202524-16581-1swbuwh.kzoy/sketch_mar4a/sketch_mar4a.ino:2:0:
/home/walter/Arduino/libraries/LiquidCrystal_I2C/LiquidCrystal_I2C.h:58:8: note: candidate: void LiquidCrystal_I2C::begin(uint8_t, uint8_t, uint8_t)
void begin(uint8_t cols, uint8_t rows, uint8_t charsize = LCD_5x8DOTS );
^~~~~
/home/walter/Arduino/libraries/LiquidCrystal_I2C/LiquidCrystal_I2C.h:58:8: note: candidate expects 3 arguments, 0 provided
exit status 1
Compilation error: no matching function for call to 'LiquidCrystal_I2C::begin()'
Sieht für mich gleich aus ?
Dies ist der Versuch Hello World
Moin,
probier mal folgenden Code aus den Beispielen der Libary:
//YWROBOT
//Compatible with the Arduino IDE 1.0
//Library version:1.1
#include <Wire.h>
#include <LiquidCrystal_I2C.h>
LiquidCrystal_I2C lcd(0x27,20,4); // set the LCD address to 0x27 for a 16 chars and 2 line display
void setup()
{
lcd.init(); // initialize the lcd
lcd.init();
// Print a message to the LCD.
lcd.backlight();
lcd.setCursor(3,0);
lcd.print("Hello, world!");
lcd.setCursor(2,1);
lcd.print("Ywrobot Arduino!");
lcd.setCursor(0,2);
lcd.print("Arduino LCM IIC 2004");
lcd.setCursor(2,3);
lcd.print("Power By Ec-yuan!");
}
void loop()
{
}
Kopier doch nicht das Beispiel hier rein. Entweder hat er es oder nicht.
Bedenke, dass es Leute gibt, die aufm Handy durchscrollen und das nicht zuordnen können...