LCD's.....

cactusface

Senior Member
Hi,
I hope to start on a new project soon, to read temps, daylight etc. Perhaps the start of a weather station. I want to use a 2 line LCD, its seems that connecting it by the serial firmware chip, makes sending the data much easier! But cost more, also I note this only uses the 4 high bits, so are there some commands or data that can't be sent to the LCD?? (now where did that old ASCII table go!). If I use a bigger Picaxe I could use a whole port for the data output.

So perhaps those of you that have done it, what do you think? Any advice would be welcome.
Regards
Cactusface
 

westaust55

Moderator
Options depending upon which PICAXE you are using:

- one or two 74HC595 (two in cascade) needs 3 dedicated PICAXE outputs

- one MCP23017 - if you have an X/X1/X2 part. Use the common i2c lines and you can even read data back form the LCD module if needed.

- use a PICAXE as a dedicated LCD controller chip. 14M could potentially achieve with a single serial line required to transfer serial but "LCD controller" might lose data if doing something elese while data transmitted.

= = = = = =

with one 595, you have 8 outputs so 4 for data and others for control functions.

with two 595's, use one for 8-bit data transfer and the second for control.
In PICAXE, then there is no need to break out the nybbles for each byte so tentatively faster.

I am about to look at using the two 74HC595 method to drive one of the 2x16 char displays with Backlight that I have picked up on Saturday.
 

hippy

Ex-Staff (retired)
Whether an LCD operates in 4-bit mode or 8-bit modes it should perform exactly the same, albeit at slower speed because two nibbles have to be clocked out instead of one byte.

When used with a serial-to-LCD controller there should be no perceptable difference in speed of operation as the time to send two nibbles is not much more than sending one byte; the limiting factor is how quickly you can get data over serial.
 

moxhamj

New Member
There are a myriad of compromises with speed vs pins. I've gone for the 6 pin solution (as per the picaxe manual) as I think it has the best compromise. Plus the code is already written!
 

russbow

Senior Member
I have been building a "weather station" for some time. Almost completed !!

In fact you passed comment about the display in my breadboard post.

http://www.picaxeforum.co.uk/attachment.php?attachmentid=4200&d=1254765499

For a couple of quid, I would recommend the firmware chip. Takes out all the hassles and doesn't seem to have any limitations. Interfacing with the picaxe is a doddle - serout.

Mine's pretty basic, but working through it I've learnt about ADC, readtemp, serout, serin ( including radio interfacing ), LCD commands, pulse counting and even some basic maths to convert to MPH. Next step is relative humidity and barometric pressure.

I think an LCD module is a must for any development and if you use the FRM, you only need +5v, 0v, and serin to interface with any of your projects. Just 3 wires !

russ
 

hippy

Ex-Staff (retired)
The 4-bit mode ( 6 signals ) is handy because that fits on single port where 8-bit mode ( 10 signals ) doesn't. 8-bit can be appropriate for PICAXE X1 and X2 where an entire port can be used for data and two other output lines as control.

Except where I had a specific reason I'd likely use an FRM010 or AXE033 these days. Most of my efforts seemed to be spent in making a PICAXE work as an FRM010 which most cannot perform as well as nor is it really any cheaper once time is taken into account.

I'd build the FRM010 board separate to the main PICAXE circuit ( similar to AXE033 ), then it can also be temporarily used with other projects under development.

The big advantage of communicating serially to an LCD is that a Terminal program can easily verify what is being sent if there are problems with the display. With bit-banged, and particularly shift-register, control it's a much harder job figuring out why something isn't working.
 

cactusface

Senior Member
LCDs..more!

Hi Folks,
Thanks for all your replies. I should have known that the LCD would take the data in 2 nibbles of 4 bits, and still come up with the right 8 bit code! I think I will be going with the serial option, and as the 28X2 cost the same as the 40X2, I'll go with the 40X2. It's all going on a fair sized board, so I might as well get as much I/O as I can. Lots of pin headers, and as suggested the LCD on a separate board so it can be used elsewhere. Perhaps this will become a general testbed for picaxes with a 40 pin socket (good quality turned pin socket strips) and home-made adapters for the smaller sizes. :)

Thanks again
Mel
 
Last edited:

lanternfish

Senior Member
... Perhaps this will become a general testbed for picaxes with a 40 pin socket (good quality turned pin socket strips) and home-made adapters for the smaller sizes. :) ...
Part 1 of the manual gives all the pinouts for the various models.

The 8, 14 & 20 pin models all have similar pinouts so only one 20 pin adapter needed for these.

The 28X? have similar pinouts to the 40X? parts so an adaptor for this should be easy to make.

Interesting idea. You could add a 3V3 regulator and a header so that you can jumper between 5V and 3V3 for using 20X2 and others at lower voltage. (Refer to this post on the topic.)

Cheers
 
Top