PDA

View Full Version : Interfacing 16x2 LCD to PIC18F2520



spotlite
- 21st January 2012, 08:09
Hi,

I have issues to run LCD (HITACHI based) with 18F2520.
The LCD data are connected to PORT.A0...A3
Enable & RS -> PORTA.4 & PORTA.5

When trying to write, nothing happens.

No impulses are read via oscilloscope on data pins, I see pulses only on E and RS pins.

How to initialize the PORTA to work correct as digital in/out?

I have ADCON1=7 included.
What else to initialize?
Also tried with CMCON=7, but nothing changes!

Also have 10k pull-up resistors on PORTA.4 & PORTA.5


Please advice?

THX

spotlite
- 21st January 2012, 08:29
FIXED!

Just corrected like this:

ADCON1 = %00001111

Now it works!