20x4 LCD screen (Parallel not Ser)

Hello everyone, I have read the previous posts on the topic, but found a whole bunch of dead links.

I am trying to get a 20x4 LCD screen to work properly (it's a New Haven module, blue with white letters).

I previously used the LCD4bit library with no problem on a 16x2, but i am wandering if anyone has a tested and working system to get a 4 line 20 char LCD screen talking with Arduino.

What's your recipe? Which library is better and is there a simple way to modify the existing library to accomodate 4 lines?

I'm experiencing the usual problems, line arrangement (1,3,2,4) and missing lines and some occasional LCD freak outs.

Any suggestion would be incredibly appreciated!! Thanks.


Benedetta :-?


The libraries that work with a 16x2 display should also work with a 20x4 display. The displays may have 1, 2, or 4 lines (actually rows) of characters but the LCD controllers deal with only 1 or 2 'lines' of memory. A display with 1 row of characters may use either 1 or 2 lines of memory. All of the 2 and 4 row displays use 2 lines of memory.

I'm experiencing the usual problems, line arrangement (1,3,2,4)

For a complete explanation of this phenomena check out the information on [u]LCD Addressing[/u] at http://web.alfredstate.edu/weimandn.


Hi! Thanks for the response!

I am aware of the fact that the regular libraries should work, that's why i was asking also if there were solid library adaptations that work with 4x20 because my LCD screen actually works with KS0066U rather than the HD chip. Should be compatible, but the timing is definitely off. I have read the datasheet for my LCD and tried to compare it to the existing library and i do know that there's only 2 lines of DDRAM.

I am going to look at the link you sent me, thanks a lot for that! I actually had not come across that link in my never ending research. :) But the same memory mapping that is on that website is on my datasheet as well. I understand it but i still dont have anything working that actually fixes the alignment problem.

Should i try 8 bit mode instead of 4 bit?

thanks for all your help, i am hoping to get a really good library working and code to post it back. This problem is showing up on any possible forum with no clear answer.



I am currently working with an ATMEGA2560 trying to control a NEWHAVEN parallel 20X4 char LCD (NHD[ch8208]0420AZ[ch8208]FSW[ch8208]GBW[ch8208]3V3). You said that you were work on/looking for a library. Were you able to get something that works? It would be a huge help.



If you want to fix the line 1,3,2,4 issue look at http://www.arduino.cc/cgi-bin/yabb2/YaBB.pl?num=1264823411

You may solve some timing issues with LiquidCrystal4Bit at http://code.google.com/p/liquidcrystal440/downloads/list

BlackJester: This is a really old thread and a lot has happened in the meantime. There is no reason why the current LiquidCrystal library shouldn't work correctly with any 20x4 display. If you are having trouble then I suggest that you start with the tutorial at http://www.ladyada.net/learn/lcd/charlcd.html. Pay particular attention to getting the row (two rows in your case) of black boxes shown about halfway through the tutorial. If you don't get the boxes then it is fruitless to proceed. If that tutorial doesn't work for you then post a photo that clearly and unambiguously shows the interconnections between your processor and your LCD module along with a copy/paste of the actual code that you are using (as opposed to a link to the code that you think you are using).



Where did you learn to type so fast.