PDA

View Full Version : 2 LCD Displays, one Pic



Art
- 8th April 2010, 10:38
Hi Guys,
So I would like to connect 2 seperate identical LCD modules to the same pic.
Do I just connect everything in parallel except the contrast and enable pins,
then just toggle the enable pins to select which display I'm talking to?

Dave
- 8th April 2010, 12:02
Art, I have done just that in the past for a few projects, except I have 1 enable line that is dedicated to the enable port pin declaired with 2 resistors of 1 K ohm value connected to the enable line from the processor. Then each of the other resistor legs get connected to the respective display enable lines. Then I just used 2 remaining processor pins connected to the the display enable lines respectivly, these pins would be held low and set as outputs. Now to communicate to a display you just set the respective (enable) pin to an input state then send the lcd commands to that display. The other display will keep its former displayed material as it's (enable) line would be held low.

Dave Purola,
N8NTA

Ioannis
- 8th April 2010, 12:38
Darrel had done this but cannot find the link in the forum.

If he gets back on-line I am sure he will post it.

Ioannis

Darrel Taylor
- 8th April 2010, 18:48
Sure I will ...

Two LCDs on one PIC
http://www.picbasic.co.uk/forum/showthread.php?p=2388#post2388

Maximun Cable Length for PIC to LCD
http://www.picbasic.co.uk/forum/showthread.php?t=7596

<img src="http://www.picbasic.co.uk/forum/picture.php?albumid=1&pictureid=4" />

malc-c
- 8th April 2010, 20:19
Nice neat breadboarding there DT ;)

Art
- 8th April 2010, 20:24
Cheers, that's about how I expected it would work except for the trick with the resistors.

Dave
- 9th April 2010, 12:05
Art, What Darrel shows is what I was talking about....

Dave Purola,
N8NTA

Art
- 10th April 2010, 08:18
No wI'm wondering why you'd use 3 pins to control 2 Enable signals?
Why not just use one pin per LCD Enable pin, and manually set each one high
to talk to each LCD display?

Darrel Taylor
- 10th April 2010, 08:33
Because LCD's are sent data "Synchronously".
Which means that the data is Clocked in with a pulse, and that pulse is on the Enable line.

For a 4-bit interface, it takes two clocks per byte.

So the Enable lines must be controllable by LCDOUT, and LCDOUT can only control one.

The other two Disable outputs simply keep the "Clock" from getting to that display.

hth,

Ioannis
- 10th April 2010, 12:20
Art, think of the two extra lines as a CS (Chip Select) line of the LCD to be active.

Ioannis

Art
- 10th April 2010, 13:56
Ah, never mind, I thought the Enable pin was simply held high to talk to the LCD.
I guess I thought wrong.