Nokia 3310 LCD and the AVR
What is a computer without an user interface? And which user interface is better than just LEDs? Well, LCD! Man, it can talk and show pictures.
I have been reading since long about interfacing a Nokia 3310 LCD to many different microcontrollers. There are many libraries available for these different microcontrollers that make programming these devices trivial. But where to get these devices? Luckily for us Indians, it is ridiculously easy to procure one of them. I just went to Chennai’s Ritchie street and got myself one. Not only did I get a monochrome 3310 LCD, I also got a 4K colour LCD that comes with the Nokia 6610!
The shop was in the dingiest of places. You could never suspect that civilization could exist there. But there it was, teaming with activity. Here you could get virtually any replacement for cell phone spares. What’s more, I saw cell phone repair manuals, with complete schematics! I wonder if these came from China, there was markings in a foreign tongue resembling the Chinese language. Every major Indian city must have one of these shops.
I first asked for a Nokia 3310 display. The shopkeeper promptly asked me if I wanted “O.G” or duplicate. The “O.G” meant original. Beware, these are really not the original spares themselves, just two different qualities of the counterfeit spares available in the market, as I later found out. The 6610 colour display came as a separate package, just the LCD, but the 3310 LCD came with a frame, it also had the ear piece. For some wierd reason, the shopkeeper warned me not to remove the earpiece. I ignored him since I needed space to shove in a capacitor. Things are fine. The “original” and the “duplicate” items had a difference of Rs. 25 among them. The “originals” for the 3310 and the 6610 cost me 150 and 350 respectively.
The 3310 is very simple to interface. It can talk to the SPI port of the AVR or any other microcontroller. It uses a Philips PCD 8455 controller that is simple to understand. But why reinvent the wheel for regular tasks? There is a wonderful library written by our friend, Louis Frigon. You can see that here. So I went about making myself a simple AVR programmer as described by Pramode in his wonderful article here. I was previously running off a breadboard. This time around I bought a ZIF socket for easy installation and removal of the chip being programmed. This can save a lot of time and it is also gentle on the chip.
Then came the part of soldering the 8 wires on the Nokia LCD. Well you don’t need 8, but 7, since pin number 7 is connected to a capacitor that is grounded. I normally use a 10W soldering iron that is available usually for Rs. 20, but this time I knew the old guy was not a match for the precision required for the job. So I got myself a relatively expensive one from Goot that came with a sharp tip.
With this iron, it was easy to solder the wires. I also managed to solder the 4.7 uF electrolytic capacitor on the pad itself. But I guess I pulled the wires a little bit, some pads then became loosely connected, internally, as I would later find out. If your soldering is bad, don’t even try it! Get someone who can do it for you. If you are too used to the breadboard, you may find this a tad difficult. Connecting these many flimsy wires to a breadboard can be a pain. So, I decided to use a general purpose PCB.
The LCD requires a 3.3 V power supply. I’m sure that a 3V power supply will work. Some sites also hint this. But I wanted to try out 3.3V, since I have never used components for that before. I called up my hardware wizard friend, Selva, my ex-colleague from Novatium. He suggested either LM317 or LM1086. There are fixed and adjustable versions of these useful chips. I suggest that using the 317 with 2 resistors is a simple way to avoid using the pricey LM1086 that costs Rs. 250. The LM317 costs a mere Rs. 15.

When I connected power and switched on, nothing! Well I rechecked and powered on, nothing again. I got this very familiar feeling of frustration. On closely examining the LCD soldering I saw that I had pulled the wires hard and the pads were not in their natural shape. I pressed the pads down with one finger and then powered on. And there I saw the words “God is Great”. With a line I had drawn from (1,1) to (30,30) just to check out the line routine.
main() {
LcdInit();
LcdStr(FONT_1X,"God is Great");
LcdLine(1,1,30,30,PIXEL_ON);
LcdUpdate();
}
Now is time for something more interesting.
The Colour LCD
Well, working with the monochromatic 3310 LCD was easy and just a few hours work. The colour LCD will be challenging both in terms of hardware(the pads are microscopic) and software. There is no library available.

Hi dude your work is awesome..its very much informative and inspiring for others to follow your work and your blog is very well presented and showcased. Great work!! Please keep posting such stuffs very often!!!!!!
Comment by Admirer — May 27, 2007 @ 11:23 pm
Hey, i’m a layaman in this field, but reading ur blog, i’ve become curious abt this field. Great post. Enjoyed reading each word of it.
Comment by Amit — July 9, 2007 @ 3:43 pm
i want to know the code in FONT_2X form
Comment by taslima — September 24, 2007 @ 12:15 pm
dear sir ,
i am currently working on a project in which i have to make a keyboard interface with the nokia 3310 LCD using atmega8 micro-controller.
now i am pretty familiar with that micro-controller working thing , about its ports , programmer n all., but i have no idea how to start my work..
as in , how to proceed,
this is wat exactly what i have to do.. kindly have a look .. hope to get reply soon..
http://www.flickr.com/photos/14247938@N06/?saved=1
regards
karan
Comment by Karan kukreja — September 27, 2007 @ 10:10 pm
Hi Dear shuveb
I have opened the 3310 LCD metal cover and there was not any chip inside, so what do mean of controller chip? for another question: if I use a AVR mcu that uses +5 volts for power supply not 3.3 volts, can the +5 volts port levels damage to LCD?
Please answer to my email
Sincerely Yours and thanks for your info
Comment by Ali — October 29, 2007 @ 11:36 pm
Shuveb,
You have done great work… I’m doing a project which makes involves a LCD display… I was hoping to use the 3310 or a 6610 colour LCD display… I read the datasheet of the Phillips 8544 and the microsyl website and understood the working of the LCD… I’m now going to do the real stuff… I’m also in Chennai only… Can you please tell me where you got the 3310 LCD and the 6610 LCD…
It’s quite tempting to use the colour display… But there’s no guide on the net… I already have a Phillips P89V51RD2 controller of the 8051 family… But the header file was for ATmega controller… Do you have any header files for the micro C… or can you suggest any shop in Chennai where I can get a ATmega64 at cheap rate… I have a fairly decent knowledge of the Ritchie street.. So please guide me to the light…
My mail ID is ashok.guy@gmail.com
Comment by Ashok Kumar — November 7, 2007 @ 5:56 pm
Great one. I had done same in my room and later used the LCD to display graphics (bar display for audio graphic equalizer). I am in Bangalore, and here too, we get the LCD cheaply from SP road. I kind of inspired to use the color display. Let me check the price here.
Comment by Debraj — December 18, 2007 @ 3:50 pm