Using LCD (ST7066U Controller) with PCF8574T Backpack

I can’t seem to make this 16x4 LCD (https://tinyurl.com/yax5sb49) work with the PCF8574T backpack (I2C module). Just a blank screen but the backlight works.

Based on this tutorial: https://tinyurl.com/kukgb5k, I assumed it will work. The pinouts of my LCD and the tutorial is the same. But I am not so sure with the code… Am I doing something wrong?

The pinout of the trouble LCD:

Here’s the I2C backpack:

/* Demonstration sketch for PCF8574T I2C LCD Backpack 
Uses library from https://bitbucket.org/fmalpartida/new-liquidcrystal/downloads GNU General Public License, version 3 (GPL-3.0) */
#include <Wire.h>
#include <LCD.h>
#include <LiquidCrystal_I2C.h>

LiquidCrystal_I2C lcd(0x27,2,1,0,4,5,6,7); // 0x27 is the I2C bus address for an unmodified backpack

void setup()
{
  // activate LCD module
  lcd.begin (16,2); // for 16 x 2 LCD module
  lcd.setBacklightPin(3,POSITIVE);
  lcd.setBacklight(HIGH);
}

void loop()
{
  lcd.home (); // set cursor to 0,0
  lcd.print(" tronixlabs.com"); 
  lcd.setCursor (0,1);        // go to start of 2nd line
  lcd.print(millis());
  delay(1000);
  lcd.setBacklight(LOW);      // Backlight off
  delay(250);
  lcd.setBacklight(HIGH);     // Backlight on
  delay(1000);
}

Using a backpack with a ST7066 will be exactly the same as a HD44780 LCD. The backpack should be properly soldered.

Install hd44780 library via the Library Manager. Read the instructions. Run the diagnostic sketches. Run the examples.

David.

Thanks, David. I’ll try your suggestion.

So to clarify, apart from these three libraries:
#include <Wire.h>
#include <LCD.h>
#include <LiquidCrystal_I2C.h>

I should install and include the HD44780 library?

Wire.h comes with the Arduino.
You must install hd44780.h with the Library Manager.

There are so many “bad” LiquidCrystal_I2C versions that it is better to avoid them.
In fact your particular fmalpartida version should work ok when you diagnose the correct constructor (with the hd44780.h sketch).

David.