Pages: [1]   Go Down
Author Topic: 8bit, 2line x 16char LCD problems  (Read 655 times)
0 Members and 1 Guest are viewing this topic.
6500ft. Up in the Rockies!
Offline Offline
Newbie
*
Karma: 0
Posts: 35
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

I recently bought an LCD hoping to interface it to my ARD.  It is this one: http://www.sparkfun.com/commerce/product_info.php?products_id=255.

I think it might even be the same exact lcd as the one in the tutoral ( http://www.arduino.cc/en/Tutorial/LCDLibrary ) but that does not matter.  The lcd driver is the same.

I downloaded the LCD library and wired up the display as indicated by the tutorial (which, based on the pinouts on my lcd, is an odd way of wiring the pins).  When I upload the basic program, all I get on the lcd is a row of squares.  The top row is solid with every character pixel lit and the bottom row is blank.  I played with the contrast pot (50k) and it works to adjust the contrast but I cannot get anything to appear on the LCD.

Looking over the datasheet linked by the vendor I wrote some of my own code and did my best to verify it but still get the same output on the display....squares.

Can anybody point me in a direction?  I can post the code I wrote if needed, but I do not think that is the problem.
Logged

Robert Carpenter
(my hackery - http://robertcarpenter.net )

0
Offline Offline
Jr. Member
**
Karma: 0
Posts: 61
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

I have the same display, and it works for me.  I'm using the 4-bit library.  The only problem I encountered is the datasheet says pin 16 is + and 15 is gnd, and it's actually the other way.  I don't think that's your problem, though.

Are you using 4-bit or 8-bit?

D.
Logged

6500ft. Up in the Rockies!
Offline Offline
Newbie
*
Karma: 0
Posts: 35
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

The library I used and the code I wrote are 8 bit.  I wrote some 4 bit code too, but converted it to 8 bit when it didn't work.

How did you find out that your vcc and gnd pins were backwards?  On my display it says those pins are for backlight.  

Oh, and where did you find a 4 bit library?
« Last Edit: March 08, 2007, 04:04:46 pm by robacarp » Logged

Robert Carpenter
(my hackery - http://robertcarpenter.net )

0
Offline Offline
Jr. Member
**
Karma: 0
Posts: 61
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

The 4-bit library is in the playground - I used the one from neilzero.  There are two data sheets available from Spark Fun, the short one has backlight wrong, the longer one has it right.  Don't worry, if you hooked it backwards you didn't fry your LCD - I did it!

One thing I remember is the RST line must be connected to ground.

Also, the library functions expect NUL-terminated strings.  If you don't add a NUL, it will display lots of garbage.

Good luck!
Logged

6500ft. Up in the Rockies!
Offline Offline
Newbie
*
Karma: 0
Posts: 35
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

I have not tried attaching the RS pin to ground but from what understand the datasheet tells me that grounding the RS pin would disable a few of the features that the read/write bus on the hitachi chip allows.  

I think that I might have gotten a bad LCD, I am going to try and get in contact with the sparkfun people and see if I can get an exchange.


Logged

Robert Carpenter
(my hackery - http://robertcarpenter.net )

Pages: [1]   Go Up
Jump to: