8bit, 2line x 16char LCD problems

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.

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?


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?

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!

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.