Troubles getting lcd display & i2c working with Digispark Attiny85

I have just started working on my first Arduino project using the Digispark Attiny 85 and I am trying to use a 16x2 LCD display paired with an I2C bus adapter. I thought it would be easier to use the I2C to manage only 4 connections vs. trying to figure out how to wire the 16 pins to the 6 I/O pins on the Digispark.

I have P0 connected to the SDA, and P2 connected to the SCL on the I2C bus.

I'm currently unable to get the display to do anything but turn on. I have the backlight lit, the top row does display all white boxes, and I can see the dark blue boxes on the bottom row.

I have been trying to get this working for 2 whole days without any success, I currently have the example DigisparkLCD>BasicUsage loaded. But after searching through several other sketches I am thinking it is missing the syntax that correctly sets up the pins to use the I2C bus. Can anyone take a look, and give me a piece of advice?

If everything appears to be correct, is there a way to test the outputs of P0 and P2 to see if the signal is coming through ?

What I have tried:

Replacing the LiquidCrystal_I2C.cpp & LiquidCrystal_I2C.h files located within my digistump folder from this link.(possible wrong location?)
link 1

Using the code from this link, as well as trying to modify the example code with this syntax. If need be, I can reload this code to show the error, but I don't believe these libraries work with the Attiny85.
Link 2

The code I am using:

/* ATtiny85 as an I2C Master   Ex2        BroHogan                           1/21/11
 * Modified for Digistump - Digispark LCD Shield by Erik Kettenburg 11/2012
 * SETUP:
 * ATtiny Pin 1 = (RESET) N/U                      ATtiny Pin 2 = (D3) N/U
 * ATtiny Pin 3 = (D4) to LED1                     ATtiny Pin 4 = GND
 * ATtiny Pin 5 = SDA on DS1621  & GPIO            ATtiny Pin 6 = (D1) to LED2
 * ATtiny Pin 7 = SCK on DS1621  & GPIO            ATtiny Pin 8 = VCC (2.7-5.5V)
 * NOTE! - It's very important to use pullups on the SDA & SCL lines!
 * PCA8574A GPIO was used wired per instructions in "info" folder in the LiquidCrystal_I2C lib.
 * This ex assumes A0-A2 are set HIGH for an addeess of 0x3F
 * LiquidCrystal_I2C lib was modified for ATtiny - on Playground with TinyWireM lib.
 * TinyWireM USAGE & CREDITS: - see TinyWireM.h
 */

//#define DEBUG
#include <TinyWireM.h>                  // I2C Master lib for ATTinys which use USI - comment this out to use with standard arduinos
#include <LiquidCrystal_I2C.h>          // for LCD w/ GPIO MODIFIED for the ATtiny85

#define GPIO_ADDR     0x27             // (PCA8574A A0-A2 @5V) typ. A0-A3 Gnd 0x20 / 0x38 for A - 0x27 is the address of the Digispark LCD modules.


LiquidCrystal_I2C lcd(GPIO_ADDR,16,2);  // set address & 16 chars / 2 lines


void setup(){
  TinyWireM.begin();                    // initialize I2C lib - comment this out to use with standard arduinos
  lcd.init();                           // initialize the lcd 
  lcd.backlight();                      // Print a message to the LCD.
  lcd.print("Digispark!");
}


void loop(){

}

Have you had any luck?

I have had success driving I2C displays with the hd44780 library on my Tiny85 projects.

For an I2C LCD display to work, the I2C address and the I2C backpack to LCD pin mapping must be correct. If the library default settings for either or both are not correct the LCD will not work. You can try to figure out the right pin mapping and use an I2C scanner to find the address, but if you install and use the hd44780 library that is done automatically by the library.

Install the hd44780 library. The hd44780 library is the best available for I2C LCDs. The library is available in the Library Manager. Go to Library Manager (in the IDE, Sketch, Include Libraries, Manage Libraries) and in the Topics dropdown choose Display and in the Filter your search box enter hd44780. Select and install the hd44780 library by Bill Perry.

The class that you want to use is the hd44780_I2Cexp class. There are examples to show how to use the library. The nice thing about the hd44780 library is that it will autodetect the I2C address and the I2C backpack to LCD pin mapping.

Here is tested example code using the hd44780 library. I used the default ATTiny core pins for I2C. Pin 0 = SDA, pin 2 = SCL (like you had). No changes, except the display parameters, needed.

#include <Wire.h>
#include <hd44780.h>                       // main hd44780 header
#include <hd44780ioClass/hd44780_I2Cexp.h> // i2c expander i/o class header

hd44780_I2Cexp lcd; // declare lcd object: auto locate & auto config expander chip


// LCD geometry
const int LCD_COLS = 20;  // replace with your display parameters
const int LCD_ROWS = 4;

void setup()
{
   lcd.begin(LCD_COLS, LCD_ROWS);
   lcd.print("Hello, World!");
}

void loop()
{
   static unsigned long timer = 0;
   unsigned long interval = 500;
   if (millis() - timer >= interval)
   {
      timer = millis();
      lcd.setCursor(0, 1);
      lcd.print("millis =        ");
      lcd.setCursor(8, 1);
      lcd.print(millis());
   }
}

first try i2c scanner code and get the address and then change the address0x27 to the address u got