You are on page 1of 17

Liquid Crystal Display

Embedding Ideas

LCD is a dot matrix Liquid Crystal Display that displays


Numeric, Alpha Numeric, some special characters and

graphics.

TICO INSTITUTE OF EMBEDDED TECHNOLOGY

Application of LCD

Embedding Ideas

Calculators Cell phones Camera Watches Computer screen TV screen Telephone Instrument Weighting machines Electronic Instruments

TICO INSTITUTE OF EMBEDDED TECHNOLOGY

Why named Liquid Crystal Display

Embedding Ideas

Liquid crystal is a material which behaves as liquid at one time and solid at the other in different environmental conditions. A particular sort of NEMATIC liquid crystal is used in LCDs because they react predictably to electrical current in such a way as to control light passage.

TICO INSTITUTE OF EMBEDDED TECHNOLOGY

Why LCD is better than LED & 7Segment Display


Embedding Ideas

Low power consumption. Thinner, light weighted & having small size. Declining prices of LCD. Ability to display characters & graphics but 7-segment can display only numbers & a few characters. LCD continuously refreshed by its own controller but 7segment have to refresh by CPU. Better Visualization D. Easy programming for characters and graphics.

TICO INSTITUTE OF EMBEDDED TECHNOLOGY

Limitation of LCD

Embedding Ideas

Very slow devices. Sensitive to temperature

TICO INSTITUTE OF EMBEDDED TECHNOLOGY

Types of LCD

Embedding Ideas

Numeric Alphanumeric Graphics

TICO INSTITUTE OF EMBEDDED TECHNOLOGY

Different Patterns of LCD

Embedding Ideas

Numeric & Alphanumeric 81, 82 (XY =X characters in Y lines.) 161, 162 201, 202, 204 401, 402, 404 Font of Single Character: 57, 510 (XY=Z pixels in a single character in XY matrix form)

Graphics LCD 64128 128128 (XY=Z pixels in the LCD in XY matrix form.) 128256

TICO INSTITUTE OF EMBEDDED TECHNOLOGY

Features of LCD

Embedding Ideas

Easy interfacing with 4-bit and 8-bit C. Display data RAM for 80 characters. Character generation RAM having capacity to store 8 kind of 57 dot or 4 kind of 510 dot character patterns. Character generation ROM that can generate 160 character with font 57 dots or 32 characters with font 510 dot character patterns. Internal automatic reset circuit at power ON. Built in oscillator circuit (No external clock required). Wide range of instruction function: Clear display, Cursor at home, Display ON, Cursor shift, Display shift etc.

TICO INSTITUTE OF EMBEDDED TECHNOLOGY

Physical Structure of LCD

Embedding Ideas

LCD SCREEN
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16

TICO INSTITUTE OF EMBEDDED TECHNOLOGY

LCD pin description


PIN
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16

Embedding Ideas
Description
Ground VCC Power Supply to control Contrast Register Select Read/Write Enable 8 bit data bus 8 bit data bus 8 bit data bus 8 bit data bus 8 bit data bus 8 bit data bus 8 bit data bus 8 bit data bus VCC Ground

Symbol
VSS VDD VEE RS R/W EN DB0 DB1 DB2 DB3 DB4 DB5 DB6 DB7 VDD VSS

TICO INSTITUTE OF EMBEDDED TECHNOLOGY

10

LCD Control Lines


RS (Register Select): To select command & data register. 0 COMMAND 1 DATA R/W (Read/Write): 0 WRITE 1 READ

Embedding Ideas

EN (Enable): To latch data present at data pins. It needs high to low transition. t=450 ns

TICO INSTITUTE OF EMBEDDED TECHNOLOGY

11

LCD Connection to C
Embedding Ideas

LCD
(LSB) P1.0 D0 D1 D2 D3 D4 D5 Vss D6 1,16 D7 4 5 6 Vcc 2 15 Vee 3 +5V

10K

C
(MSB) P1.7
P.0 P.1 P.2

RS R/W E

TICO INSTITUTE OF EMBEDDED TECHNOLOGY

12

LCD Command codes


Code
1 2 4 6 5 7 0C 0E 0F 10 14 18 80 C0 38

Embedding Ideas

Description
Clear the display Return to home Decrement cursor ( left shift) Increment cursor (right shift) Shift display right Shift display left Display ON, Cursor OFF Display ON, Cursor ON Display ON ,Cursor ON Shift Cursor Position to left Shift Cursor Position to right Shift entire display to left Force Cursor to beginning of 1st line Force Cursor to display on 2nd line 2 line & 57 matrix in 8 bit mode

TICO INSTITUTE OF EMBEDDED TECHNOLOGY

13

LCD TIMING DIAGRAM


Data

Embedding Ideas

EN

tDS
W

t
H

R/W

tA
S

tPW
H

tA
H

RS tPWH = Enable pulse width = 450 ns(minimum) tDSW = Data set up time = 195 ns(minimum) tH = Data hold time = 10 ns(minimum) tAS = Set up time prior to E (going high) for both RS and R/W = 140 ns(minimum) tAH = Hold time after E has come down for both RS and R/W = 10 ns(minimum)

TICO INSTITUTE OF EMBEDDED TECHNOLOGY

14

FLOW CHART
START

Embedding Ideas

INITIALIZE THE LCD BY USING CODE (38)

SEND COMMAND (OE) FOR DISPLAY ON & CURSOR ON

SEND COMMAND (01) FOR CLEARING DISPLAY

SEND DATA

END

TICO INSTITUTE OF EMBEDDED TECHNOLOGY

15

Algorithm for sending command Embedding Ideas 1. 2. 3. 4. Send command code to lcd dataport Make RS = 0 Make R/W = 0 for write Send H-to-L pulse to E.

Algorithm for sending data 1. 2. 3. 4. Send data(ASCII code or character in inverted commas) to lcd dataport Make RS = 1 Make R/W = 0 for write Send H-to-L pulse to E.

TICO INSTITUTE OF EMBEDDED TECHNOLOGY

16

TIPS & TRAPS


Embedding Ideas

Data lines should be connected synchronously to the C Give High to Low pulse at EN pin. While sending COMMAND make RS=0 & While sending DATA make RS=1. Send initializing command three times at particular delay of 20 M sec. If the DATA lines or CONTROL lines are connected to PORT 0 then pull up register should be connected to PORT 0

TICO INSTITUTE OF EMBEDDED TECHNOLOGY

17

You might also like