Electronic – arduino – Interfacing a 16×2 Character LCD to the Arduino

arduinohardwarelcd

A friend recently gave me a set of three (old) 16×2 LCD displays. (datasheet)

However, I'm having difficulty thinking through how to connect one to my Arduino. Particularly, each LCD has 14 (!) pins, of which 7 are denoted "data bus line" on the datasheet.

In the past, I've connected my Arduino to a LCD screen using serial connection, and I have an I2C LCD that I won at a competition recently (I've yet to use that one, though–I'm waiting on a specific type of jumper cable).

However, I've never used an LCD with this many pins, and certainly don't want to hog all the pins on my Arduino (Uno). So, my question is:

How do I communicate with this LCD, using my Arduino? (While keeping in mind that I want to do other things with the pins.)

Best Answer

There are a few methods to do what you want to, and you will have to dedicate 4 or 8 pins to the LCD. Looking at the datasheet you provided, the LCD is driven by a HD44780, and this has been interfaced with Arduino many times - there is a subsection of the Arduino site's LCD page devoted to it (scroll down to find it). There are a few libraries that you can use - I would recommend Liquid Crystal as it provides both 4 and 8-bit modes, and apparently comes with the Arduino software. You probably could reuse the pins though by making use of enable/chipselect pins and then attaching boards/shields on top. This question may assist with that.