Pages: [1]   Go Down
Author Topic: LCD Libray problem with arduino (probable bug)  (Read 3498 times)
0 Members and 1 Guest are viewing this topic.
0
Offline Offline
Newbie
*
Karma: 0
Posts: 4
Arduino rocks
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

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
Logged

Cape Town, South Africa
Offline Offline
Full Member
***
Karma: 0
Posts: 177
Arduino rocks
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

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.
« Last Edit: May 28, 2010, 06:44:15 am by leppie » Logged

0
Offline Offline
Newbie
*
Karma: 0
Posts: 4
Arduino rocks
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

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
Logged

Wigan, UK
Offline Offline
God Member
*****
Karma: 19
Posts: 814
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

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.
Logged

Western New York, USA
Offline Offline
Faraday Member
**
Karma: 35
Posts: 4299
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

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
Logged

0
Offline Offline
Newbie
*
Karma: 0
Posts: 4
Arduino rocks
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

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

Thanks
Logged

Western New York, USA
Offline Offline
Faraday Member
**
Karma: 35
Posts: 4299
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

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
Logged

Central MN, USA
Offline Offline
Tesla Member
***
Karma: 73
Posts: 7188
Phi_prompt, phi_interfaces, phi-2 shields, phi-panels
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

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
Logged


0
Offline Offline
Newbie
*
Karma: 0
Posts: 43
Arduino rocks
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

 but my pin 12 does not work well.
Logged

Western New York, USA
Offline Offline
Faraday Member
**
Karma: 35
Posts: 4299
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

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

Don
Logged

0
Offline Offline
Newbie
*
Karma: 0
Posts: 2
Arduino rocks
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

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
Logged

Western New York, USA
Offline Offline
Faraday Member
**
Karma: 35
Posts: 4299
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

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
Logged

Pages: [1]   Go Up
Jump to: