ST7920
l Function Set
RS RW DB7 DB6 DB5 DB4 DB3 DB2 DB1 DB0
Code 0 0 0 0 1 DL X RE X X
DL: 4/8-bit interface control bit
When DL = "1", 8-bit MPU bus interface
When DL = "0", 4-bit MPU bus interface
RE: extended instruction set control bit
When RE = "1", extended instruction set
When RE = "0", basic instruction set
In same instruction cannot alter DL and RE at once. Make sure that change DL first then RE.
l Set CGRAM Address
RS RW DB7 DB6 DB5 DB4 DB3 DB2 DB1 DB0
0 0 0 1 AC5 AC4 AC3 AC2 AC1 AC0
Code
Set CGRAM address into address counter (AC)
AC range is 00H…3FH
Make sure that in extended instruction SR=0 (scroll address or RAM address select)
l Set DDRAM Address
RS RW DB7 DB6 DB5 DB4 DB3 DB2 DB1 DB0
0 0 1 AC6 AC5 AC4 AC3 AC2 AC1 AC0
Code
Set DDRAM address into address counter (AC).
First line AC range is 80H…8FH
Second line AC range is 90H…9FH
Third line AC range is A0H…AFH
Fourth line AC range is B0H…BFH
Please note that only 2 lines can be display with one ST7920.
l Read Busy Flag (BF) and Address
RS RW DB7 DB6 DB5 DB4 DB3 DB2 DB1 DB0
0
Code
1 BF AC6 AC5 AC4 AC3 AC2 AC1 AC0
Read busy flag (BF) can check whether the internal operation is finished or not. At the same time, the value of
address counter (AC) is also read. When BF = “1”, further instruction(s) will not be accepted until BF = “0”.
V4.0
21/49
2008/08/18