Pages: [1] 2 3 ... 7   Go Down
Author Topic: LCD shield and/or LCD serial backpack  (Read 26484 times)
0 Members and 1 Guest are viewing this topic.
Brisbane, Australia
Offline Offline
God Member
*****
Karma: 1
Posts: 593
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

No one has made a LCD shield yet which I find odd. Is there any interest for one?
I could even make it use my cool 3 pin LCD interface or even I2C, SPI and serial.

Also serial backpacks are relatively pricey and not as useful as they could be.
In theory I could make a backpack which cost $10 and also provided SPI and I2C interfaces.
For comparison, SparkFun's is $17 and only provides serial.

What do you guys think?
Logged

London
Offline Offline
Faraday Member
**
Karma: 8
Posts: 6240
Have fun!
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Although I am now past that point on my current project, I would have been very interested in an I2C LCD shield for $10.

I would think that I2C and serial support for LCDs at that price would be useful to many.
Logged

Brisbane, Australia
Offline Offline
God Member
*****
Karma: 1
Posts: 593
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

Well for the backpack I've calculated approx costs.

The PCB is a tiny 1.5 inches by 0.75 inches which at BatchPCB means $5 per board.
It would be $2.50 if I can shave off a fraction off a inch.
At Futurlec for buying 100 of them its just over a dollar a board.

Components wise I can get them singly for about $3.50.
Buying in bulk would slash that amount.

Specs:
ATmega8 running at 16mhz.
Contrast control via trimpot.
Ability to turn the LCD's backlight on/off (power saving or for getting attention).
I2C, Serial and SPI all avaliable.
ICSP header for programming.

Software:
The software will be GPLed naturally. smiley
I'll probably put the Arduino bootloader on it so it can be easily updated.
The serial protocol will probably be compatible with other serial backpacks.
The SPI and I2C protocols will be a efficient protocol which I'll work out.
Sample code will be provided for interfacing it with the Arduino using all three methods.

So is there enough interest for me to make a batch of about 25 boards?
Logged

Forum Administrator
Cambridge, MA
Offline Offline
Faraday Member
*****
Karma: 9
Posts: 3538
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

Sounds cool.

If you do want to put the Arduino bootloader on it, you should probably do a lot of testing to make sure it doesn't cause any problems.  If people are sending serial commands to the chip (intended to control the LCD) while the bootloader is active, it could get confused and never launch the code that controls the LCD.  The latest ATmega168 bootloader has some code to try to prevent these sorts of problems, but it's not perfect, and it's not in the current ATmega8 bootloader.  Also, you'll need to balance out the need for the bootloader to have a reasonable delay (so people can actually time an upload properly) vs. having the LCD being responsive quickly.  One idea would be to have a jumper on a digital pin that the bootloader checks when it starts - immediately running the LCD application if it's LOW (or HIGH).  We didn't do that on the Arduino because we didn't want to dedicate a pin to it or add an extra jumper to the board, but it might make sense for this application.  There might even be commented code in the bootloader to handle it.  smiley
Logged

London
Offline Offline
Faraday Member
**
Karma: 8
Posts: 6240
Have fun!
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Quote
So is there enough interest for me to make a batch of about 25 boards?
I am in for one.

Presumably you will be using the RW line rather than delays to determine when the LCD is ready to accept data.

Logged

Brisbane, Australia
Offline Offline
God Member
*****
Karma: 1
Posts: 593
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

Quote
Presumably you will be using the RW line rather than delays to determine when the LCD is ready to accept data.
Yep. Its got a dedicated chip so there is no need to cut corners with the pins. smiley

Also I just realised that I can make the backlight brightness variable.
Logged

Toronto, ON, Canada
Offline Offline
Newbie
*
Karma: 0
Posts: 12
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

Quote
Quote
Presumably you will be using the RW line rather than delays to determine when the LCD is ready to accept data.
Yep. Its got a dedicated chip so there is no need to cut corners with the pins. smiley

Also I just realised that I can make the backlight brightness variable.

Not sure if you have taken a look at Peter Anderson's K107 backpack. Should at least provide a good reference for designing your own backpack..
Logged

Ven Pixel
-----------
Wandering Samurai
"Since light travels faster than sound, p

Brisbane, Australia
Offline Offline
God Member
*****
Karma: 1
Posts: 593
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

Quote
If you do want to put the Arduino bootloader on it, you should probably do a lot of testing to make sure it doesn't cause any problems.
Sorry I missed your post.

If they are using it with a Arduino then it wouldnt matter at all because they would have to wait anyway.
Ladyada has a hack which starts the program if anything other than 00 is sent to the bootloader so that would also work.
I might put a SMD jumper on to enable/disable it. Just solder over it to enable.

The K107 looks good but it has a awful number of limitations.
I can steal some ideas from its software though. smiley
Logged

Brisbane, Australia
Offline Offline
God Member
*****
Karma: 1
Posts: 593
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

Ok I've finished fiddling with it. Here is the design so far:



I ditched the ICSP connector to save space.
Since I'm breaking out SPI anyway, it'll be simple to make a adaptor.
The labels need to be moved around a bit as well.

It should be breadboard compatible and you'd be able to use a DIP-16 socket if you wanted.
You can also solder it directly to a LCD or even put a socket on it so its removable.

Any feedback?

Also what kind of transistor should I use?
It controls the backlight so it needs to handle about 200mA.
Logged

London
Offline Offline
Faraday Member
**
Karma: 8
Posts: 6240
Have fun!
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Looking good!

More a passing thought then a suggestion, but I was wondering if you would gain real estate and lower cost replacing the contrast pot with a  transistor and capacitor  driven from a spare onboard pwm pin.  Providing the arduino with software commands to increase and decrease contrast may be more convenient then getting at the pot.
Logged

Toronto, ON, Canada
Offline Offline
Newbie
*
Karma: 0
Posts: 12
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

Quote
Looking good!

More a passing thought then a suggestion, but I was wondering if you would gain real estate and lower cost replacing the contrast pot with a  transistor and capacitor  driven from a spare onboard pwm pin.  Providing the arduino with software commands to increase and decrease contrast may be more convenient then getting at the pot.

Other people may have had different experiences but I have always found that I only adjust the contrast once.
Logged

Ven Pixel
-----------
Wandering Samurai
"Since light travels faster than sound, p

Brisbane, Australia
Offline Offline
God Member
*****
Karma: 1
Posts: 593
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

Its certainly possible.
Even if it is set only once its probably cheaper.
The value can be stored in EEPROM once the optimal contrast is found or it can be changed dynamically.
Logged

berlin
Offline Offline
Sr. Member
****
Karma: 0
Posts: 293
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

hej cheater, great idea! just 2 questions: do you target a special LCD or is your board supposed to be a general garphics card? i'm asking this, because i use these monochrome nokia displays (monochrome, 84px x 48px). i have the code working and really would like to work on a library if someone would be willing to assist. the problem with this display is, that it works on 3.3v and comes with a pretty annoying connector which like cries for a custom board.

sparkfun is selling the display including a board (no backlight) for $35. http://www.sparkfun.com/commerce/product_info.php?products_id=8428
the display only is available for about $5 / 4$. the color displays (OLED) i'v been looking need 3.3v (some 3.6v) as well. you could keep that in mind when configuring the atmegas brown out detection and stuff. plus maybe you find one of these mobile phones display connectors to be worth supportable. i guess there are a million different, still it might be something to investigate.

my second question is a general question on your first design. do you (or anyone) have experience on running an atmega on the internal oscillator at 8Mhz? just maybe you don't need the crystal and can save that space. if the communication uses a clock line i wouldn't see a problem with timing or speed. what do think?

i'm using ladyada's bootloader hack as well, and have no problems uploading sketches to the 8Mhz/3.3v at 19.200 bps using just RX/TX. "run program on power up" is a great feature (and something i would suggest for the official arduino bootloader! to upload a sketch you reset the board with the reset button).

i'm for the software controlled contrast and backlight by the way. they can be used for cool effects.

as for a backlight  transistor: i think bc-337 and 2n2222 would be suited. at least these i've found to meet very often, and if i remember correctly support a max of 400mA (or was it 800?).

if we could find a reasonable priced way to get them here to berlin, i'd be interested in at least 2 of these :-)

//kuk


Logged

London
Offline Offline
Faraday Member
**
Karma: 8
Posts: 6240
Have fun!
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Quote
... i use these monochrome nokia displays (monochrome, 84px x 48px). i have the code working and really would like to work on a library if someone would be willing to assist.
I don't want to hijack this thread but I have a few of these and would be interested in helping with a library. It would be great if cheater could support these displays in his shield, but if not then it may be worth starting another thread to discuss this.
« Last Edit: January 17, 2008, 07:04:40 am by mem » Logged

Brisbane, Australia
Offline Offline
God Member
*****
Karma: 1
Posts: 593
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

Quote
hej cheater, great idea! just 2 questions: do you target a special LCD or is your board supposed to be a general garphics card?
This is designed for a standard HD44780 character LCD, not a graphical one.
The idea however can be adapted to nearly anything.

Quote
i'm asking this, because i use these monochrome nokia displays (monochrome, 84px x 48px). i have the code working and really would like to work on a library if someone would be willing to assist. the problem with this display is, that it works on 3.3v and comes with a pretty annoying connector which like cries for a custom board.
I'd assist if I had one. smiley-wink

Quote
my second question is a general question on your first design. do you (or anyone) have experience on running an atmega on the internal oscillator at 8Mhz? just maybe you don't need the crystal and can save that space. if the communication uses a clock line i wouldn't see a problem with timing or speed. what do think?
I dont have experience with it but I have ordered a bunch of ATtiny chips to play with along with two ATmega32's.
So in a week or two I will have experience running them without a crystal. smiley

Space isnt a issue with my design.
The width is constant because I want it to fit in a DIP socket and the length is also constant because it needs to match a LCD's pin out.

The crystal is dirt cheap and is faster and more reliable. Why not have it? smiley
For smaller designs I probably wouldnt have one though.

Quote
as for a backlight  transistor: i think bc-337 and 2n2222 would be suited. at least these i've found to meet very often, and if i remember correctly support a max of 400mA (or was it 800?).
I found a SMD one which says its max current is 800mA so that should be fine.

The backlight shouldnt cause much of a problem anyway.
I've got a neat setup where I control 4 20x4 LCDs from three pins with individual backlight control.
A 595 can power the backlights just fine even with massive capacitors which make a cool fading effect.

Quote
if we could find a reasonable priced way to get them here to berlin, i'd be interested in at least 2 of these :-)
Australia to Berlin should be fine. smiley

I'm getting a 128x64 graphical LCD (a larger one, not a tiny one. KS0108B controller) so I can definitely help with graphical routines for any LCD and a library for similar LCDs.
Just need to dust off my trigonometry. smiley

I could also make a backpack or shield for other LCDs which does all the hard work and provides Serial/I2C/SPI interfaces.
Making one for a PSP LCD (with touch screen even) would be bloody cool. smiley-grin
Logged

Pages: [1] 2 3 ... 7   Go Up
Jump to: