Hello,
I'm relatively new to the world of coding and arduino. I have a robot set up with an LCD screen (20x4) that I'm trying to set up to say 'Hello World'. I keep getting error messages when I attempt to initialize the LCD. The following is my code and error message:
#include "LiquidCrystal.h"
#include <Wire.h>
#define I2C_ADDR 0x3F // Define I2C Address where the PCF8574A is
#define BACKLIGHT_PIN 3
#define En_pin 2
#define Rw_pin 1
#define Rs_pin 0
#define D4_pin 4
#define D5_pin 5
#define D6_pin 6
#define D7_pin 7
// initialize the library with the numbers of the interface pins
LiquidCrystal lcd(I2C_ADDR,En_pin,Rw_pin,Rs_pin,D4_pin,D5_pin,D6_pin,D7_pin);
void setup() {
// set up the LCD's number of columns and rows:
lcd.begin(20, 4);
// Print a message to the LCD.
lcd.print("hello, world!");
}
void loop() {
// set the cursor to column 0, line 1
// (note: line 1 is the second row, since counting begins with 0):
lcd.setCursor(0, 1);
// print the number of seconds since reset:
lcd.print(millis() / 1000);
}
Error message:
Hello_World:15:76: error: no matching function for call to 'LiquidCrystal::LiquidCrystal(int, int, int, int, int, int, int, int)'
LiquidCrystal lcd(I2C_ADDR,En_pin,Rw_pin,Rs_pin,D4_pin,D5_pin,D6_pin,D7_pin);
Any help would be greatly appreciated!
^