Hello everybody!
I have a problem... I'm trying run this code in my arduino UNO with a LCD with ic2 connection, but the LCD turn on and turn off but does't display text... What's the problem??? My code is this:
#include <LiquidCrystal_I2C.h>
#include <Wire.h>
// Set the LCD address to 0x27 for a 16 chars and 2 line display
//LiquidCrystal_I2C lcd(0x3F,16,2); // Usa el ic2Scanner para saber qué dirección es
#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
int n = 1;
LiquidCrystal_I2C lcd(I2C_ADDR,En_pin,Rw_pin,Rs_pin,D4_pin,D5_pin,D6_pin,D7_pin);
void setup()
{
// initialize the LCD
lcd.begin(16,2);
lcd.setBacklightPin(BACKLIGHT_PIN,POSITIVE);
lcd.setBacklight(HIGH);
lcd.home (); // go home
lcd.print("jejejej");
lcd.setCursor (0,1); // go to the 2nd line
lcd.print("holalala");
lcd.print("Iteration No: ");
}
void loop()
{
// Backlight on/off every 3 seconds
lcd.setCursor (14,3); // go col 14 of line 3
lcd.print(n++,DEC);
lcd.setBacklight(LOW); // Backlight off
delay(10);
lcd.setBacklight(HIGH); // Backlight on
delay(3000);
}
I'm using LiquidCrystal_V1.2.1 library of Fmalpartida
Help!!!