Continue to Site

Welcome to our site!

Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

  • Welcome to our site! Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

What signals does a microcontroller need to send to a LCD?

Status
Not open for further replies.

Athosworld

Member
I want to control a simple LCD (calculator screen like) NOT THE MODULE with an ATMEGA328p uC. NOT ARDUINO, only the microcontroller. What code do I need to write in order to get something like a number displayed? What external parts do I need?
 
If it's a simple seven-segment style glass display with all the segment connections and the common plane brought out to the connector, it should be possible to control it with an MCU.

The common electrode must be toggles high and low at something between 25 - 100Hz.
Segments that should be off must be set to the level as common; segments that should be on must be set to the opposite level.

eg. If there is no difference between the individual segment and common, the segment is off. If the two voltages are different, the segment is on.

They have to alternate continuously to prevent electrolysis or breakdown of the materials in the display, so the drive is in effect AC. You probably also need a resistor divider between the common drive and half supply so you can vary the amplitude, as that will control the display contrast.

More complex LCDs with too many segments or pixels for individual wiring use a matrix system, which requires multiple levels on every connection, so it's not practical to drive them direct.
 
Just an example, some processors have onchip the capability of all the timing and step
V generation required to manage a segment LCD with commons. This is single chip solution,
very little of the overall chip resources used, see last window.

1650584940713.png


Generating the coms drive -

1650585148043.png




Regards, Dana.
 
I want to control a simple LCD (calculator screen like) NOT THE MODULE with an ATMEGA328p uC. NOT ARDUINO, only the microcontroller. What code do I need to write in order to get something like a number displayed? What external parts do I need?
If it's just bare glass, then you really need an LCD driver - and a few PIC devices have this built-in, and so can directly control a bare glass LCD display. No idea if there's any AVR's that do?, but the 328 doesn't.

Or presumably you could use an external driver chip between 328 and glass?.
 
This gives some nice clear info on direct segment drive - an old book where it's done with TTL!


This is an example of the type of display that can be driver like that - no multiplex, just overall common backplane and a pin per segment:
 
Status
Not open for further replies.

New Articles From Microcontroller Tips

Back
Top