Connecting Nokia 3310 LCD to USB using AVR. Part 1. Schematic
What do you do with an old phone, a microcontroller and lots of time?
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?
What features does the code have?
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.)
For this project, you need some components, this include:
You also need an USB cable, your standard soldering tools and thin wires. (As thin as possible. I used IDE cable wires, works pretty well. )
I did not have 3,6v zener diodes or 68ohm resistors available, but I had 3,2v zener diodes and 33 ohm resistors, so I used those instead. However, I highly recommend using the listed components! If you gamble like I did, the device might not be correctly recognized and might show up as "Unknown Device".
If you have trouble finding parts, may I suggest old broken electronic devices? Not only can you find most parts you need in old electronic devices, but you're also being "green" by recycling! All the parts I have used in this project comes from recycled components (Except for the ATMega8).
When you're soldering, be sure to note the D+ (Green ) and D- (White ) on the USB cable. It's very important not to mix those!
Also, if you do I like I did and solder the wires directly onto the LCD display, be very careful to not make any bridges between the connections! The connections are very small, and trust me, it's not fun when you realize the only problem with your circuit is a bridged connection on the display.
Once you've uploaded the firmware to the microcontroller, detach the programming cable. If you've done everything correctly , the display should now say "Display Initialized" and your computer should notify you that an USB device has been plugged in.
If you have trouble burning the chip:
If the display does not work:
If your computer does not find the device over USB:
In the following part of article we will consider high lights in the microcontroller and Host-device software. We will stop on the most important functions participating in realisation of the USB interface.
PCB Pricing: https://jlcpcb.com/quote