I just picked up a couple ardunino nano and lcds ..But I am finding it hard to find the right way to hook my lcds up to the nano ...
So can please explain the right way so I can build a test rig to test each lcd ??
Here's the lcd
No part number?
There's 99% or better odds (based on the silkscreened pinout) that it has a Hitachi HD44780 (or compatible) controller chip. Pins 1-14 will be the standard HD44780 ones and 15,16 are for the LED backlight.
You will want to use 4 bit mode, with three control lines to minimise the wiring. Googling
HD44780 Arduino should find you all you need to know.
Grab a copy of the HD44780 datasheet, you *will* need it:
https://www.sparkfun.com/datasheets/LCD/HD44780.pdfYou will need to find your display's actual datasheet if you don't want to have to do a lot guessing and experimenting to find the correct hookup for the backlight and contrast control.
You will want to use 4 bit mode, with three control lines to minimise the wiring.
For extra points, if the number of pins used is an issue, you could use a shift register such as a 74HC595 to reduce the number of pins required from your micro even further.
You will want to use 4 bit mode, with three control lines to minimise the wiring.
For extra points, if the number of pins used is an issue, you could use a shift register such as a 74HC595 to reduce the number of pins required from your micro even further.
You
could do that, but why? Search ebay or your favorite marketplace for "arduino lcd serial" and buy a <$1 adapter board that lets you talk to the LCD over I2C. There are pre-canned libraries to use these adapters. The pinout is likely to exactly match the pinout of the LCD module, and the wiring is reduced to just two signals plus power.
You could do that, but why? Search ebay or your favorite marketplace for "arduino lcd serial" and buy a <$1 adapter board that lets you talk to the LCD over I2C. There are pre-canned libraries to use these adapters. The pinout is likely to exactly match the pinout of the LCD module, and the wiring is reduced to just two signals plus power.
I have a whole box of HD44780 LCDs which turn out to be much cheaper to use than buying some new serial LCDs. Also, a $0.10 shift register is 10 times cheaper than a $1 breakout board....
Further to that, If you really want to learn how things work as opposed to just hacking something together, I think it's a good learning exercise to go through. Especially if you have never worked with shift registers. Using pre made libraries and break out boards will only get you so far.
You could do that, but why? Search ebay or your favorite marketplace for "arduino lcd serial" and buy a <$1 adapter board that lets you talk to the LCD over I2C. There are pre-canned libraries to use these adapters. The pinout is likely to exactly match the pinout of the LCD module, and the wiring is reduced to just two signals plus power.
I have a whole box of HD44780 LCDs which turn out to be much cheaper to use than buying some new serial LCDs. Also, a $0.10 shift register is 10 times cheaper than a $1 breakout board....
Further to that, If you really want to learn how things work as opposed to just hacking something together, I think it's a good learning exercise to go through. Especially if you have never worked with shift registers. Using pre made libraries and break out boards will only get you so far.
I agree that building an adapter yourself is a great learning exercise both in hardware and in software to make it work. However I don't agree with the cost argument. Your shift register IC will need a PCB and connectors as well as time to assemble everything, and all those things (especially time) have real costs. Having options is wonderful, and each person can decide on costs vs benefit knowing the options.
I agree that building an adapter yourself is a great learning exercise both in hardware and in software to make it work. However I don't agree with the cost argument. Your shift register IC will need a PCB and connectors as well as time to assemble everything, and all those things (especially time) have real costs. Having options is wonderful, and each person can decide on costs vs benefit knowing the options.
You only need extra components
if you decide the LCD has to live on a separate board. As you say it will come down to the application.
Attached ist the datasheet for your LCD with the instruction set as well. Included is the pinout of the module.
V0 should be connected to a pot, between Vdd and Ground. The LED connection is obvious
All the other pins are digital ones, which are connected directly to the Arduino. The instructions how to program it might help with that (from page 9 on).
Myke Predko has a post online (somewhere) using a 74LS174 and a 2-wire interface (literally Data and Clk) to drive the 'shift register' and the LCD -- nothing else than a diode, resistor, and supply rails.
I've used this a few times - (just finished a new project this morning with a 20x4 LCD)
If you use a resistor ladder for pushbuttons - the whole front panel occupies 3 pins, and almost no parts!