EM73866
4-BIT MICRO-CONTROLLER FOR LCD PRODUCT
The bank is selected by P9.3. When P9.3 is cleared to "0", the bank 0 is selected. When P9.3 is set to "1", the bank
1 is selected.
There are 3 addressing mode to access the data memory, namely -
(1) Indirect addressing mode:
The address in the certain bank is specified by the HL registers.
P9.3
HR LR
RAM address
PROGRAM EXAMPLE: Load the data of RAM address "143h" to RAM address "032h".
SEP
LDL
P9,3
#3h
#4h
; P9.3← 1
; LR← 3
; HR← 4
; Acc← RAM[143h]
; P9.3← 0
; LR← 2
; HR← 3
; RAM[032h]← Acc
LDH
LDAM
CLP
P9,3
#2h
#3h
LDL
LDH
STAM
(2) Direct addressing mode:
The address in the bank is directly specified by 8 bits code of the second byte in the instruction field.
instruction field
xxxxxxxx
P9.3
xxxxxxxx
RAM address
PROGRAM EXAMPLE: Load the data of RAM address "143h" to RAM address "023h".
SEP
LDA
CLP
STA
P9,3
43h
; P9.3← 1
; Acc← RAM[143h]
; P9.3← 0
P9,3
23h
; RAM[023h]← Acc
(3) Zero-page addressing mode:
The address is the lower 4 bits code of the second byte in the instruction field.This kind of instructions are
only available for the zero page. Area in bank0, even the P9.3 is set.
instruction field
yyyy
yyyy
0000
0
RAM address
PROGRAM EXAMPLE: Write immediate "0Fh" to RAM address "005h".
; RAM[05h]← 0Fh
STD
#0Fh, 05h
* This specification are subject to be changed without notice.
12.29.1999
7