Go Down

Topic: LCD Libray problem with arduino (probable bug) (Read 4203 times) previous topic - next topic

CarloLuongo

Hi, I have a ploblem with LiquidCrystal Library and my arduino duemilanove board.
My LCD display have the first line full fitted, all dots are black, and the second line il full blank.
Testing all LCD library examples I have the same results.
I have analyzed the digital signal using my digital level analyzer and I have found this:
The signal RS and E (Enable) have the same values at the same time (are equal). I have read the HD44780 datasheet but this is not the correct behaviour according to the protocol.

Help me please
Thanks a lot

leppie

#1
May 28, 2010, 01:43 pm Last Edit: May 28, 2010, 01:44 pm by leppie Reason: 1
If you just get squares, it means the LCD wasnt initialized properly.

I would look at increasing the delays at initialization.

Also check that you are using the same number of bits/pins that you initialize it for.

Finally check all the connections for shorts.

The LCD library seems to be quite stable for me, I have it going through an I2C i/o expander and only needed to alter 1/2 functions.

CarloLuongo

Thanks for you answer.
I have verified all the connections.
The fact that RS and E signals are equal is good?

thanks a lot

bye

CowJam

The LCD library works for other people, so I suggest it is not at fault.

Which pins are you using for RS and E? Do you have anything else connected to the arduino?

The default pins for an LCD (11, 12) tend to be used by shields. If you have a shield plugged in try shift the pins to 7, 8.

floresta

Carlo:

Quote
The signal RS and E (Enable) have the same values at the same time (are equal).
This is not correct and the problem is not in the library if you are using the latest version of LiquidCrystal.

Your power is connected properly since you get the row of blocks on the top row.  Your contrast may need adjusting later but that is not your first priority right now.

Remove all of the the data and control wires between the LCD module and your Arduino board and then reconnect them by following one of the tutorials listed below.  If you are using a solderless breadboard then try using a different location on that board as one or more of the contacts may be bad.

Don't forget to deal with R/W (pin 5) on the LCD module.

Tutorials:
http://arduino.cc/en/Tutorial/LiquidCrystal
http://www.ladyada.net/learn/lcd/charlcd.html

If you can't get your LCD working by following these then you probably should consider a different hobby.

Don

CarloLuongo

I don't know why, but my pin 12 does not work well.
Using another digital pin all works very well.

Thanks

floresta

Quote
I don't know why, but my pin 12 does not work well.
Using another digital pin all works very well.

Are you sure you don't mean pin 13, the one with the LED attached?

Don

liudr

A bit late in reply but I recently helped someone on the troubleshooting board. The similar symptom may come from the same reason. His pins were connected the wrong way around, meaning his 1 is soldered on 16 and 2 soldered on 15. This way does get you the black blocks and the back light (both 1 and 16 are 5V and both 2 and 15 are ground), seeming to tell you the LCD should work.

http://www.arduino.cc/cgi-bin/yabb2/YaBB.pl?num=1278190981/0

laxman


floresta

Quote
but my pin 12 does not work well.
What sort of response are you expecting from the forum readers?

Don

RATAPLAN

PLEASE NOTE THAT ON THE LCD'S DB0,1,2 MUST BE CONNECTED TO GROUND AND DB3 TO VDD.
BY THIS WAY THE LCD IS PROPERLY SETTED TO 4 BIT 2 ROWS.
LET DB0,1,2,3 DISCONNETED DOES NOT ALLOW PROPER INIZIALIZATION

floresta

Quote
PLEASE NOTE THAT ON THE LCD'S DB0,1,2 MUST BE CONNECTED TO GROUND AND DB3 TO VDD.
BY THIS WAY THE LCD IS PROPERLY SETTED TO 4 BIT 2 ROWS.
LET DB0,1,2,3 DISCONNETED DOES NOT ALLOW PROPER INIZIALIZATION

Can you provide some sort of documentation that would support this claim.  I haven't run across such a requirement in the 20 or so years that I have been using these devices.

Don

Go Up