Hi Guys,
I am trying to make my first LCD project with I2C LCD (NHD-C0216CiZ-FSW-FBW-3V3 from Digikey) but not sure how to approach. Does anyone have a sample? I use PIC18f46J50 like this:
ANCON0=%11111111
ANCON1=%11111111
TRISA = 0
TRISB = %0110000
TRISC = 0
start:
I2CWRITE PORTA.0,PORTA.2,0,$7C,[$7C]
PAUSE 20
I2CWRITE PORTA.0,PORTA.2,0,$7C,[0]
PAUSE 20
I2CWRITE PORTA.0,PORTA.2,0,$7C,[$00]
PAUSE 20
I2CWRITE PORTA.0,PORTA.2,0,$7C,[$31]
PAUSE 20
I2CWRITE PORTA.0,PORTA.2,0,$7C,[$14]
PAUSE 20
I2CWRITE PORTA.0,PORTA.2,0,$7C,[$25]
PAUSE 20
I2CWRITE PORTA.0,PORTA.2,0,$7C,[$56]
PAUSE 20
I2CWRITE PORTA.0,PORTA.2,0,$7C,[$6D]
PAUSE 20
I2CWRITE PORTA.0,PORTA.2,0,$7C,[$0C]
PAUSE 20
I2CWRITE PORTA.0,PORTA.2,0,$7C,[$06]
PAUSE 20
I2CWRITE PORTA.0,PORTA.2,0,$7C,[$01]
PAUSE 20
I2CWRITE PORTA.0,PORTA.2,0,$7C,["TEXT"]
IF PORTB.1 =0 THEN
PORTB.1 = 1
ELSE
PORTB.1=0
ENDIF
PAUSE 1000
GOTO START
--------------
LED blinking but i do not see any output on LCD
Thank you,
Alexey
Bookmarks