Quote Originally Posted by iw2fvo View Post
Steve,
this code still works well:
Thanks ,Ambrogio

Code:
DEFINE OSC 40 ' 10 MHz XTAL AND X 4 INTERNAL PLL 
DEFINE I2C_SLOW 1
C VAR portd.3 ' S_CLOCK 
D VAR portd.2 ' S_DATA
ADDR VAR BYTE 
ADDR = %01001110 ' dec 78 , hex 4E
CMD VAR BYTE
LCD_CMD VAR BYTE 
E VAR LCD_CMD.BIT2 
RS VAR LCD_CMD.BIT0
E=0:RS=0
LCD_CMD = 0
PAUSE 1000 

MAIN:

I2CWRITE D, C, ADDR, [%00000000] ' bck_lt= off
PAUSE 200
I2CWRITE D, C, ADDR, [%00001000] ' bck_lt=on
PAUSE 200

GOTO MAIN
This works because you can see the backlight turn on and off. This tells me the LCD is working and the address is correct. Unfortunately that has eliminated the obvious. I will dig deeper into Darrel's code as I can not see anything that would stop it working.