Picture of Connecting Nokia 3310 LCD to USB using AVR
What do you do with an old phone, a microcontroller and lots of time?
You hook the old phone's LCD screen to the computer USB of course!

In this project we're going to communicate with a Nokia 3310 LCD display over USB! How are we going to do that? We're going to connect the LCD display to an Atmel ATmega8 micocontroller and talk to it using the SPI, then connect the ATmega to a PC using V-USB.

The Nokia 3310 LCD display is easy to find, and has a very well documented interface, so it's perfect for hobby use! Not only that, but we're going to use V-USB (Formerly AVR-USB) as our USB driver on the AVR chip. This makes the project very easy to pull off the ground.

V-USB is very slow, so you cannot do any fancy animations this way, but is perfect for updating the display with text! Also, when using USB, you can use this on pretty much any computer. It does require libusb though, but libusb is cross platfrom, so that shouldn't be a problem. Or, if you're really hardcore, you can write your own driver for this project (This is way out of the scope of this instructable)!

What uses does thing have?
As I mentioned, V-USB is pretty slow, so it's best for sending text. Even through this is a little drawback, there is still a lot of stuff you can do with it!
Display RSS feed, Twitter updates, weather, temperature, free disk space, unread e-mails.
You are not limited to just display text though. If you're feeling really fancy, you can make a 1-bit picture slideshow!
Only your imagination (And the slow speed of V-USB) limits you :)

What features does the code have?
With the code you get from this Instructable, you get:
* Built-in font and support for writing ASCII characters
* Character wrapping (Prevents characters from being printed over 2 lines if end of display is reached)
* USB connected
and powered
* Easy to expand

The code is open source (Both firmware and host software), so you're free to do whatever you want with it. (This only includes the software I have written. See the license for V-USB for further use of that, same goes for libusb. Both licenses are included in the source files.)

This project is loosely based on Raphnet's Multiuse PCB, V-USB's PowerSwitch and DharmaniTech's Nokia 3310 LCD routines library.

If you have problems downloading the attached files, I have mirrored them here: Atmega8_LCD.rar and LCD_Screen.rar
khasan3 years ago
At last, after 3 months try, i have successfully completed your project. Now it displays time.. Thanks.....

What software i will use to compile host software?
Can u give me a vb6.0 example?
khasan khasan3 years ago
i m using codeblocks and vb6.0 but failed
We followed your schematic but why is it always "USB Device Not Recognized"?
wkter (author)  alexiscalingasan3 years ago
You may have swapped the D+ and D- wires. I spent a few hours debugging only to find I had swapped them. Also, if the voltage on the data lines are not according to the specs you'll also get a "Device Not Recognized". Get your multimeter and confirm the data lines are running at around 3,3v.
Sir we already have the "Display Initialized" output at the LCD but why is it still "usb device not recognized" in my pc? Am I doing it right?
wkter (author)  alexiscalingasan3 years ago
The display will initialize regardless of the success of the USB connection. Did you double check the data lines on the USB connector?
I think the problem is the zener diodes... Can I use 5V to data lines.
wkter (author)  alexiscalingasan3 years ago
No, using 5v on the data lines will almost certainty make your device not recognized, and may damage your USB port. You have to follow the USB specifications and use 3.3v to ensure proper operation.
jalfan3 years ago
hey how r u,,,,, dude ur anabsolute genious..could u tell me what's the way to display content on any lcd screen plz???
putyn4 years ago
hey :)
nice instructable but i have to ask something isnt the nokia lcd running @3.3V ?
wkter (author)  putyn4 years ago
Only the data input lines has a recommended voltage of 3.3v, they can however work with up to 7v if you look at the maximum ratings in the datasheet. It's also actually recommended to run the VCC at 6v to 9v, but should work at lower voltages. For simplicity sake I just ran everything off the 5v of the USB, which works pretty good and shouldn't be at risk of permanently damaging the LCD. Hope this cleared things up!
putyn wkter4 years ago
ive done some tests myself and got the lcd working powered @ 3.3V from arduino and the data lines were @5V

anyway thanks for the quick reply
hrshovon5 years ago
thanks a lot for this instructable...i have been looking for a better reference on v-usb for months and at last ... i found yours!great work!
wkter (author)  hrshovon5 years ago
Thank you very much for your comment! I decided to give some attention to the use of V-USB in this instructable (Especially considering this was for the USB contest). I'm glad you found it useful!
hrshovon wkter4 years ago
Your work made me understand v-usb....and i have applied it to develop a loader software for usbasp.But i can only send data to the device...cant get them....i m using vb6 as my language and libusbvb0.dll as my link library to communicate with libusb...if u can give me some suggestions...that will be really great!!!
(My software is actually a GUI for avrdude..with some extra usbasp control features)
joe570055 years ago
do you think the LCD from a nokia 6340i would work? it looks very similar to the one in your picture, same dimensions, pin count, but it has three smd components instead of two. i haven't been able to find much helpful info from google, just a bunch of sites trying to sell replacement parts. i guess i'll just have to wire it up and see what happens.
wkter (author)  joe570055 years ago
I can tell you right off the bat that it will most likely not use the same interface as the 3310 display and in worst case might damage the display (The 3310 display says in the datasheet the operation without resetting the screen first might damage the device). If you give me a few moments, I can try to look for a datasheet and see if we cannot modify the code to work with your 6340i display! ;)
joe57005 wkter5 years ago
Thanks for your info! i'll let you know if i get it working!
CrLz5 years ago
Thanks for posting this Instructable! Hard work = sweet project
wkter (author)  CrLz5 years ago
Thanks a lot! I did pull my hair a couple of times during this project, hehe.
blackwellj5 years ago
could you point me in the direction of doing this on a mac
wkter (author)  blackwellj5 years ago
Unfortunately, I have no experience in compiling programs on Mac, but the Mac port of libusb can be found here: http://libusb.darwinports.com/ . The firmware on the AVR is the same regardless of OS, so you only have to worry about the host software. Hopefully, the Mac port of libusb uses the same header file as the Win-32 port, so your only concern should be to actually get the program to compile. I do have Macs myself, so if you're really stuck I probably can look into the Mac developing tools and help you.
rammstein25 years ago
could the lcd be used as a multimeter panel(for e.g i want to include an lcd screen on a bench power supply)??
wkter (author)  rammstein25 years ago
Yes! As long as you have the information, you can display it on this LCD display. For getting the information, you can use the ADC on the AVR chip (If you do, you don't even need the USB connection!).