Page 1 of 1

LCD HD44780 Compatible

Posted: Wed Mar 20, 2013 11:26 am
by pyrosigma
Hallo,

Please, i cannot make working my LCD and i controlled all connexions, my programm run and very simply, there's is a trouble with init, because i've got only square on the first line...

I'm using Flowcode for PIC V3.6.11.53 and for programming pickit 3 via MPLAB, all the programm that i made work fine except for LCD (EA W162B-NLW, 2x16, HD44780 kompatible).
I respect the LCD connexions like this: PORTB (B0: D1, B1: D2, B2: D3, B3:D4, B4=RS, B5: E), i've got retro and contrast ok.

In my programm, i puted a led on RC5 who's blinking fine in practice...is there a thing to modify,which one?

Can you help me, i don't know what to do, please?!
test.fcf
(8.5 KiB) Downloaded 398 times

Re: LCD HD44780 Compatible

Posted: Wed Mar 20, 2013 12:13 pm
by Benj
Hello,

First of all are your connections to the LCD correct. The data pins should go to the upper nibble eg so on the LCD pins D0 - D3 are unconnected and pins D4 - D7 are connected to the microcontroller data pins.

Also your config settings look like they have issues.

What speed crystal are you using? If your using a 20MHz then change the oscillator setting to HS not HS-PLL. If your using a 5MHz crystal then your oscillator setting is correct.

You will also need to disable the watchdog timer, the low voltage program and the extended CPU to allow the program to run correctly.

Re: LCD HD44780 Compatible

Posted: Wed Mar 20, 2013 1:40 pm
by pyrosigma
Thank you for your reply!

Effectly, all bit configuration was not like you told me, now, it's working fine!

THANK YOU THANK YOU THANK YOU!

Re: LCD HD44780 Compatible

Posted: Thu Mar 21, 2013 11:22 pm
by pyrosigma
Hallo Ben!

I'm so sorry, but i've tried to make run my lcd under flowcode V4 with pickit 3 and again doesn't work (like the first time)...Pic18f2420 at 20MHz, (my programm run because i've got always my blinking led...)..

Can you please juste give a look on configuration bit if it's ok for you? I'm tried to display a voltage value and it's work fine on simulator...

All is disabled, except:
- brown out detect (enable in hardware, SBOREN disabled)
-Brown out voltage 2.0V
-Low Power Timer 1 Osc enable
-Master Clear Enable: MCLR Disabled, RE3 Enabled

Oscillator HS

....I didn't change my connexions on my board...

Thanks to you

Re: LCD HD44780 Compatible

Posted: Thu Mar 21, 2013 11:53 pm
by Enamul
Hi

Your configuration wasn't OK. I have corrected those..

Re: LCD HD44780 Compatible

Posted: Fri Mar 22, 2013 12:49 pm
by pyrosigma
Hallo!

I cannot open the file (limited edition and no pic18f2420...?!), i tried many things to change in configuration bit with datasheet (23.1 section) but doesn't work, is it possible to send me a print screen of the bit config box by mail? (manu.fluck@gmail.com)

Thanks for your patience!