Arduino UNO r3/MEGA 2560 and LCD by I2c 16x2 and 20x4 on PCF8574T

Hello,
I have arduino uno r3 and Mega2560 and displays 16x2 and 20x4 with i2c adapter . When connected in all possible configurations displayers. I have a problem after flashing/uploading a simple sample program ( with liquidcrystal_i2c ) "hello world". LCD Backlight is blue , they were tested on different items of unfortunately for me after uploading the same thing again . I checked on windows 8.1 windows 7 x64 and windows xp 32 bit seems to me that it is not the fault of the system (on the others PC). The software version on which I tested is 1.0.5 and 1.5.5 beta . Items are 100% correct - was checked by seller. Another LCD connect by 4 bits connection (E RS R/W D4 D5 D6 D7) works fine. I checked another usb cable, set contrast and connect to external DC source 9V/1.5A.

When I connect a standard install / update the drivers from the drivers folder of the software. Please send me suggestions on where may be at issue . Thanks in advance for your help and best regards.

Edit : I intercede movie who illustrates the problem after upload the program on arduino:

We can not advice to you when we do not know how you wired backpack and when you not post your sketch.

Here is my working solution.

Note: I2C wires SDA and SCL are connected to the corresponding SDA and SCL pins on both ends

I have adapter with the LCDs (PCF8574T). The adapter have only 4 pins (GND, VCC, SDA, SCL) all is integred in this module.
Each looks like this http://farm9.staticflickr.com/8046/8115486011_a99d721319_b.jpg I know that lcds and arduino's works fine.

Could you give me any idea to resolve this problem?

1 Like

xlodder:
Could you give me any idea to resolve this problem?

Without inspecting your sketch and wiring diagram: no.

Ok,
LCD 20x4 with I2c adapter -> Arduino Mega 2560
GND -> GND no.2 / POWER SECTION
VCC -> 5V / POWER SECTION

SDA -> SDA 20 / COMMUNICATION SECTION
SCL -> SCL 21 / COMMUNICATION SECTION

Connect in UNO in additional sketch

I2cScanner give me 0x27 adress for LCD

The first steps I followed for information from http://test.mauroalfieri.it/en/elettronica/display-lcd-1602-i2c-pcf8574t.html

I tested it on 3 configuration:
Notebook DELL 7520 I5-3210M 2.5 GHz 12 GB DDRIII 500 GB HDD GRAPH - HD7730 1 GB + Win 8.1 N Professional x64
PC Intel Core2Duo E8500 3.16 Ghz 4 GB DDRII 500 GB HDD GRAPH - QUADRO 512 MB + Windows 7 Professional x64
PC Acer Veriton S661 Intel Core2Duo E 6500 2.6 GHz 3 GB DDRII 160 GB HDD GRAPH - Int + Windows XP SP3 Professional x32

Arduino 1.0.5 + LiquidCrystal_I2c

And I have the same problem from 1st post.

The wiring is correct and sketch should also work. The last thing left to check is the wiring PCF8574T - I got it as follows:

#define I2C_ADDR      0x27 // I2C address of PCF8574A
#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

I did not change anything in a working example (NewLiquidCrystal library) obtained from:
https://bitbucket.org/fmalpartida/new-liquidcrystal
You use PCF8574T while I have PCF8574A, but perhaps these chips are identical.

Ok it's WORK FINE!
I resolve this problem after using library from -> http://arduino-info.wikispaces.com/file/view/LiquidCrystal_I2C2004V1.zip/341635418/LiquidCrystal_I2C2004V1.zip

I have funduino I2c adapter on PCF8574T

Thanks K5CZ !
Greetings from Poland.

You use PCF8574T while I have PCF8574A, but perhaps these chips are identical.

For your future reference the devices operate identically but they have different address ranges.

The devices with an 'A' in the suffix have a base address of 0x38 and a range from 0x38 to 0x3F.

The devices without an 'A' in the suffix have a base address of 0x20 and a range from 0x20 to 0x27.

Don

Thanks Don for the explanation! Hence I update "our" I2C Scanner (see attachment). There is also on my site.

I2C_scanner_v008.ino (8.78 KB)

Thanks, xlodder, for posting the link to the library:

I resolve this problem after using library from -> http://arduino-info.wikispaces.com/file/view/LiquidCrystal_I2C2004V1.zip/341635418/LiquidCrystal_I2C2004V1.zip

The above library worked for me, too. I am using a Sainsmart I2C LCD2004 20x4 display which has the PCF8574T backpack to convert the inputs to I2C.

A couple other libraries, including the LiquidCrystal_I2C, didn't work for me (compilation errrors).

I changed the address of the LCD to 0x3F, and all the example sketches worked.

Using Mega 2560 with mega.SDA (pin 20) and mega.SCL (pin 21) connected to the corresponding LCD I2C pins.