LG128645 Sflyh6v
LG128645 Sflyh6v
LG128645 Sflyh6v
Model: LG128645-SFLYH6V
Table of Contents
1. BASIC SPECIFICATIONS
1.1 Features
Display Format : 128 X 64 Dots
LCD Mode : STN-Yellow Green-Positive-Transflective
Driving Method : 1/32 Duty,1/6 Bias
Viewing Direction : 6:00
Backlight : LED, yellow green color
Outline Dimension : 93.0(W) X 70.0(H) X 13.5(T) mm
Viewing Area : 72.0(W) X 39.0(H) mm
Dot Size : 0.48 X 0.48 mm
Dot Pitch : 0.52 X 0.52 mm
Weight : 75 g
Controller : ST7920-0B (GB code simplified character set)
Others : 8 Chinese characters X 4 lines
8-bit, 4-bit or serial bus MPU interface
Built-in 8192 Chinese characters (16X16 dots) and 126 half
width alphanumerical characters (8X16 dots)
64 x 16-bit character display RAM (DDRAM)
64 x 256-bit graphic display RAM (GDRAM)
64 x 16-bit character generation RAM (CGRAM)
Control Signals
ST7921
RS(CS)
R/W(SID)
LCD
E(SCLK) Controller 64 SEG 64 SEG
PS LSI 32 COM
/RST
ST7920 128 x 32 dots
DB0
3. ELECTRICAL CHARACTERISTICS
Supply Current
IDD VDD=5.0V -- 3.0 5.0 V
(Logic)
E Cycle tC 1200 -- -- ns
E Rise Time tR -- -- 25 ns
E Fall Time tF -- -- 25 ns
VDD
+5V
VSS
LCM
Open VO
Open VOUT
LEDA
+5V
LEDK
VSS
+5V
VDD
LCM
VR
VO
20 k Ω
VOUT
LEDA
+5V
LEDK
Note: 5V voltage for the LED backlight should be supplied to Pin19 (LEDA) and Pin20
(LEDK) terminal of the interface, it should not be supplied to the Anode/Cathode terminal
of the LED backlight directly.
LG128645-SFLYH6V -8-
4. FUNCTION DESCRIPTION
4.1 System Interface
ST7920 supports 3 kinds of bus interface to MPU. 8-bit parallel, 4-bit parallel and clock
synchronized serial interface. Parallel interface and serial interface is selected by PSB
terminal. 8-bit/4-bit interface is selected by function set instruction DL bit. Two 8-bit
registers (Data Register DR, Instruction Register IR) are used in ST7920’s write and read
operation. Data Register (DR) can access DDRAM/CGRAM/GDRAM data through the
address pointer implemented by Address Counter (AC). Instruction Register (IR) stores
the instruction by MPU to ST7920.
4 modes of read/write operation specified by RS and RW:
RS RW Description
L L MPU write instruction to instruction register (IR)
L H MPU read busy flag (BF) and address counter (AC)
H L MPU write data to data register (DR)
H H MPU read data from data register (DR)
4.4 16x16 Character Generator ROM (CGROM) and 8x16 Half Width ROM (HCGROM)
ST7920 provides character generator ROM supporting 8192 16x16 character fonts and
126 8x16 alphanumeric characters. It is easy to support multi languages application such
as Chinese and English. Two consecutive bytes are used to specify one 16x16 character
or two 8x16 half-width characters. Character codes are written into DDRAM and the
corresponding fonts are mapped from CGROM or HCGROM to the display drivers.
Note:
1. DDRAM data (character code) bit1 and bit2 are the same as CGRAM address bit4 and
bit5.
2. CGRAM address bit0 to bit3 specify total 16 rows. Row16 is for cursor display. The
data in row 16 will be logical OR to the cursor.
3. CGRAM data for each address is 16 bits.
4. DDRAM data to select CGRAM bit4 to bit15 must be “0”. Bit0 and bit3 value are “don’t
care”.
LG128645-SFLYH6V - 12 -
GDRAM Horizontal Address (X) for Upper 32 rows of LCD (1~32 rows)
0 1 2 3 4 5 6 7
0 1
1 2
2 3
3 4
-- -- -- -- -- -- -- -- -- --
-- -- -- -- -- -- -- -- -- --
-- -- -- -- -- -- -- -- -- --
GDRAM Vertical Address (Y)
28 29
29 30
30 31
LCD Rows
31 32
0 33
1 34
2 35
3 36
-- -- -- -- -- -- -- -- -- --
-- -- -- -- -- -- -- -- -- --
-- -- -- -- -- -- -- -- -- --
28 61
29 62
30 63
31 64
LCD 1~16 17~32 33~48 49~64 65~80 81~96 97~112 113~128
Columns
8 9 10 11 12 13 14 15
GDRAM Horizontal Address (X) for Lower 32 rows of LCD (33~64 rows)
The LCD has 128 x 64 dots, it can display 8 Chinese characters x 4 lines.
The DDRAM address and character position map is as bellow:
1 2 3 4 5 6 7 8
Line1 80H 81H 82H 83H 84H 85H 86H 87H
Line2 90H 91H 92H 93H 94H 95H 96H 97H
Line3 88H 89H 8AH 8BH 8CH 8DH 8EH 8FH
Line4 98H 99H 9AH 9BH 9CH 9DH 9EH 9FH
LG128645-SFLYH6V - 14 -
5. INSTRUCTION SET
ST7920 offers basic instruction set and extended instruction set:
Clear all the display data by writing the space code “20H” to all DDRAM addresses, and
set DDRAM address to “00H” into address counter. Return cursor to the original position,
namely, bring the cursor to the upper left end of the display. The execution of clear
display instruction set entry mode to increment mode (I/D = 1).
Control the display ON/OFF status, Cursor ON/OFF and Cursor Blink function.
D: The entire display is ON when D = 1 and OFF when D = 0. The display data remains in
the DDRAM when display is OFF, it can be displayed immediately by setting D = 1.
C: The cursor displays when C = 1 and does not display when C = 0.
B: When B = 1, cursor position blink is ON, the character in cursor position will blink.
When B = 0, cursor position blink is OFF.
Shift the cursor position or display to the right or left without writing or reading display
data. This function is used to correct or search for the display.
Note that the display shift is performed simultaneously in all lines.
The contents of address counter do not change when display shift is performed.
Shift Patterns According to S/C and R/L Bits
S/C R/L Operation
0 0 Shift cursor position to the left (AC is decreased by 1)
0 1 Shift cursor position to the right (AC is increased by 1)
1 0 Shift the entire display to the left, cursor follows the display shift.
1 1 Shift the entire display to the right, cursor follows the display shift.
Set the interface data length, and select basic or extended instruction set.
DL: Set interface data length. Data is sent or received in 8-bit length (DB7 ~ DB0) when
DL = 1, and in 4-bit length (DB7 ~ DB4) when DL = 0. When the 4-bit length is
selected, data must be sent or received twice.
RE: When RE = 0, basic instruction set
When RE = 1, extended instruction set
Note: DL and RE can not be changed in a same instruction, make sure change DL first
and then RE.
LG128645-SFLYH6V - 18 -
Set CGRAM address (00H~3FH) to the address counter. Data is then written/read to/from
CGRAM.
Make sure in extended instruction SR = 0 (scroll address or RAM address select).
Set DDRAM address to the address counter, AC6 is fixed to 0. Data is then written/read
to/from DDRAM.
DDRAM address code ranges from 80H to BFH.
Refer Section 4.12 (DDRAM Address and Character position Map)
Read the busy flag (BF) and value of the address counter (AC). BF = 1 indicates that
internal operation is in progress and the next instruction will not be accepted until BF is
set to “0”. The BF status should be checked before each write operation. At the same time
the value of the address counter is read out. The address counter is used by CGRAM,
DDRAM and GDRAM, and its value is determined by the previous instruction.
the address counter will automatically increase or decrease by 1 according to the (I/D)
control bit of entry mode.
Execution of this instruction enters standby mode. Any other instruction follows this
instruction can terminate standby. The contents of DDRAM remain the same.
Select DDRAM data to reverse the display and toggle the reverse condition by repeating
LG128645-SFLYH6V - 20 -
this instruction. R1, R0 initial value is 00. When set the first time the display is reversed
and set the second time the display become normal.
R1 R0 Operation
80H~8FH RAM data (1 line and 3rd line of LCD) normal or reverse
st
0 0
0 1 90H~9FH RAM data (2nd line and 4th line of LCD) normal or reverse
1 0 A0H~AFH RAM data normal or reverse
1 1 B0H~BFH RAM data normal or reverse
Set the interface data length, and select basic or extended instruction set.
DL: Set interface data length. Data is sent or received in 8-bit length (DB7 ~ DB0) when
DL = 1, and in 4-bit length (DB7 ~ DB4) when DL = 0. When the 4-bit length is
selected, data must be sent or received twice.
RE: When RE = 0, basic instruction set
When RE = 1, extended instruction set
G: Graphic display control bit
When G = 0, graphic display OFF
When G = 1, graphic display ON (logically “EXOR” with text display)
Note: DL and RE can not be changed in a same instruction, make sure change DL first
and then RE.
Set GDRAM address to the address counter. First set vertical address and then horizontal
address (write 2 consecutive bytes to complete vertical and horizontal address set).
Vertical address range is AC5~AC0.
Horizontal address range is AC3~AC0.
The address counter of graphic RAM (GDRAM) only increases after write for horizontal
address. After horizontal address reaches 0FH it will automatically back to 00H. However,
the vertical address will not increase as the result of the same action.
8-bit interface:
4-bit interface:
LG128645-SFLYH6V - 22 -
8051 LG128645
8
P0.0~P0.7 DB0~DB7
8 A0
RS
74LS373 A1
R/W
Y0
3 +5V
P2.5~P2.7 74LS138
PSB
/RD E
/WR
RST /RST
a. Application Circuit 1
8051 LG128645
8
P1.0~P1.7 DB0~DB7
P3.0 RS
P3.1 R/W
P3.2 E
+5V
PSB
RST /RST
b. Application Circuit 2
LG128645-SFLYH6V - 24 -
7. INITIALIZATION
(1). 8-Bit Initialization:
Power on
↓
Wait for more than 40ms
/RST “L”à“H”
↓
Function Set
RS R/W DB7 DB6 DB5 DB4 DB3 DB2 DB1 DB0
0 0 0 0 1 1 X 0 X X
↓
Wait for more than 100μs
↓
Function Set
RS R/W DB7 DB6 DB5 DB4 DB3 DB2 DB1 DB0
0 0 0 0 1 1 X 0 X X
↓
Wait for more than 37μs
↓
Display ON/OFF Control
RS R/W DB7 DB6 DB5 DB4 DB3 DB2 DB1 DB0
0 0 0 0 0 0 1 D C B
↓
Wait for more than 100μs
↓
Display Clear
RS R/W DB7 DB6 DB5 DB4 DB3 DB2 DB1 DB0
0 0 0 0 0 0 0 0 0 1
↓
Wait for more than 10ms
↓
Entry Mode Set
RS R/W DB7 DB6 DB5 DB4 DB3 DB2 DB1 DB0
0 0 0 0 0 0 0 1 I/D S
↓
End of initialization
LG128645-SFLYH6V - 25 -
Power on
↓
Wait for more than 40ms
/RST “L”à“H”
↓
Function Set
RS R/W DB7 DB6 DB5 DB4 DB3 DB2 DB1 DB0
0 0 0 0 1 0 X X X X
↓
Wait for more than 100μs
↓
Function Set
RS R/W DB7 DB6 DB5 DB4 DB3 DB2 DB1 DB0
0 0 0 0 1 0 X X X X
0 0 X 0 X X X X X X
↓
Wait for more than 100μs
↓
Display ON/OFF Control
RS R/W DB7 DB6 DB5 DB4 DB3 DB2 DB1 DB0
0 0 0 0 0 0 X X X X
0 0 1 D C B X X X X
↓
Wait for more than 100μs
↓
Display Clear
RS R/W DB7 DB6 DB5 DB4 DB3 DB2 DB1 DB0
0 0 0 0 0 0 X X X X
0 0 0 0 0 1 X X X X
↓
Wait for more than 10ms
↓
Entry Mode Set
RS R/W DB7 DB6 DB5 DB4 DB3 DB2 DB1 DB0
0 0 0 0 0 0 X X X X
0 0 0 1 I/D S X X X X
↓
End of initialization
LG128645-SFLYH6V - 26 -
Z( φ =0° ) Top
φ2
Y( θ =180° , φ =-90° ) φ1
X X'
θ
Bottom
Y'( θ =0° , φ =+90° )
2.0
φ1 φ2
Viewing Angle
LG128645-SFLYH6V - 27 -
B1
Brightness
B2
Driving Voltage
90%
100%
10%
tr tf Time
LG128645-SFLYH6V - 28 -
9. DIMENSIONAL OUTLINE
LG128645-SFLYH6V - 29 -
L G 128 64 5 ― S F L Y H 6 V ― XXX
(1) (2) (3) (4) (5) (6) (7) (8) (9) (10) (11) (12) (13)
(1) Brand
(2) Module type
C - Character module
G - Graphic module
(3) Display format
Character module : Number of characters per line, two digits XX
Graphic module : Number of columns, tow or three digits XX or XXX
(4) Display format
Character module : Number of lines, one digit X
Graphic module : Number of rows, two or three digits XX or XXX
(5) Development number : One digit X ( 1~9, A~Z )
(6) LCD mode
T - TN Positive, Gray N - TN Negative, Blue
S - STN Positive, Yellow-green G - STN Positive, Gray
B - STN Negative, Blue F - FSTN Positive, White
K - FSTN Negative, Black K - FSTN Negative, Blue
1) When storing the LCD module, avoid exposure to direct sunlight or to the light of
fluorescent lamps and high temperature/high humidity. Whenever possible, the
LCD module should be stored in the same conditions in which they were shipped
from our company.
2) Exercise care to minimize corrosion of the electrodes. Corrosion of the electrodes
is accelerated by water droplets or a current flow in a high humidity environment.
11.4 Others
1) Liquid crystals solidify under low temperatures (below the storage temperature
range) leading to defective orientation or the generation of air bubbles (black or
white).
Air bubbles may also be generated if the LCD module is subjected to a strong
shock at a low temperature.
2) If the LCD modules have been operating for a long time showing the same display
patterns, the display patterns may remain on the screen as ghost images and a
slight contrast irregularity may also appear. A normal operating status can be
regained by suspending use for some time. It should be noted that this
phenomenon does not adversely affect performance reliability.
3) To minimize the performance degradation of the LCD modules resulting from
destruction caused by static electricity, etc., exercise care to avoid touching the
following sections when handling the module:
· Terminal electrode sections.
· Part of pattern wiring on TAB, etc.