Society of Robots - Robot Forum

Electronics => Electronics => Topic started by: BANE on June 29, 2008, 10:18:41 AM

Title: LCD driver needed?
Post by: BANE on June 29, 2008, 10:18:41 AM
Hello, I'm going to buy this LCD http://www.robotshop.ca/home/products/robot-parts/electronique-lcd/sfe-16x2-parallel-lcd-black-green.html (http://www.robotshop.ca/home/products/robot-parts/electronique-lcd/sfe-16x2-parallel-lcd-black-green.html) and don't know if i need a driver or not.

I'm going to be controlling it with my Basic Micro 28 pin chip.   Do you have to have a driver or can you just connect all the leads to the microcontroller's pins?

If I need a driver, can i get the right one on digikey?

Bane
Title: Re: LCD driver needed?
Post by: izua on June 29, 2008, 11:06:09 AM
you don't need a driver for that one - the basic 16x2, if it's the stn black/green type.
some special types, like red on black, might need it, although most have it integrated.
Title: Re: LCD driver needed?
Post by: BANE on June 29, 2008, 01:34:09 PM
Thats nice, (i couldn't seem to find one for it :P).  But will it take more than 4 pins from my micro controller?  The image of it shows 16 pins coming from the LCD, do I just take pick six (including ground and +5v) and not use the rest?

Bane
Title: Re: LCD driver needed?
Post by: BANE on June 29, 2008, 02:25:28 PM
Here's something, (see image) this makes alot more sense to me since there not using all my pins.  And the 74HC164 is only like $.50 too.

Bane
Title: Re: LCD driver needed?
Post by: izua on June 29, 2008, 02:29:46 PM
8 + 3 or 4 + 3. Using 4 + 3 will require more complex code.
Google for additional details on "44780" tutorial or "lcd tutorial".

No, you can't pick six. It will automatically and randomly pick six pins to be used every minute, and return the chosen pins as a polynomial. the value of that polynomial will be outputed as a frequncy through a smd speaker. you will need a mike and some code to read that frequency, then math code, to expand the polynomial, and after that you will see what pins it has chosen.
It will also randomly switch the ground and v+ pins, so you will need short circuit protection, because it will always switch them every second. If you won't supply it with the correct polarity when it switches ground with v+, it will reset, and you will need to read the frequency polynomial again.

On a more serious note: Have you ever found an IC that allows you to choose which pins are GND and V+? Rember what mr. garrison from south park said about stupid questions :P
Title: Re: LCD driver needed?
Post by: izua on June 29, 2008, 02:31:39 PM
yes, if you can afford even more cpu cycles, to transform the data for the chip, and some more soldering, sure:P add a shift register. i'm not a fan of shift register, unless i really need the output pins. you're basically trading 8 pins for 2 (you still need E, RS and RW separate). what you could do is use a 4bit communication, which would use for bits instead of eight.
this way, you'd have two more pins (4+3 instead of 2+3) but the code will be simpler.

also, using a shift register you can't read data back from the lcd.
Title: Re: LCD driver needed?
Post by: BANE on June 29, 2008, 02:47:01 PM
Quote
On a more serious note: Have you ever found an IC that allows you to choose which pins are GND and V+? Rember what mr. garrison from south park said about stupid questions
LOL :D  I didn't mean it that way, i mean choose the right ones from the data sheet.

And I'm trying to conserve on pins since i've got only 16 and I've got 4 taken for the PS2 controller, 1 SSC-32 data line, 3 (high\low) pins for the lights, 3 Sharp IR sensors, and 1 Ping sensor.  So i've only 4 pins left :P.

Heres something else (see image)

There's the PCF8574A that can reduce the number of pins used and increase the amount of soldering :D

Bane
Title: Re: LCD driver needed?
Post by: BANE on June 29, 2008, 03:00:43 PM
Here the chip available form Digikey
http://search.digikey.com/scripts/DkSearch/dksus.dll?Detail?name=296-13106-5-ND (http://search.digikey.com/scripts/DkSearch/dksus.dll?Detail?name=296-13106-5-ND)

Bane
Title: Re: LCD driver needed?
Post by: izua on June 29, 2008, 03:31:18 PM
Look for serial controlled LCDs with address.
Or, make a microcontroller receive data via serial, and that microcontroller will command the lcd.

Then, you put it on a pcb, and attach it to the lcd's pcb. You will only send serial data to the second microcontroller, which, in turn, will allow you to control the lcd. The nice thing about this is that you can control various other data, such as light, contrast, saving messages (so you can access them with a short command), boot messages, store a lot of special characters, etc.
Title: Re: LCD driver needed?
Post by: BANE on June 29, 2008, 04:11:31 PM
Like this one;http://www.jameco.com/webapp/wcs/stores/servlet/ProductDisplay?langId=-1&storeId=10001&catalogId=10001&productId=150990 (http://www.jameco.com/webapp/wcs/stores/servlet/ProductDisplay?langId=-1&storeId=10001&catalogId=10001&productId=150990)

A little more exensive, but thats what money is for....... right :P

A serial controlled LCD seems a lot easier to control and takes less pins :)

bane