Hitachi H8/3048 Hardware Manual page 608

Single-chip microcomputer
Table of Contents

Advertisement

LOOPDW: DEC.W
BPL
www.DataSheet4U.com
MOV.B
CMP.B
BNE
CMP.L
BGT
BRA
RERASE: MOV.W
MOV.B
DEC.L
CMP.W
BGE
SHLL.W
KEEP:
BRA
OKEND:
MOV.W
MOV.B
MOV.W
MOV.W
MOV.B
.............................
ABEND1: MOV.W
MOV.W
MOV.B
Programming error
ABEND2: MOV.W
MOV.W
MOV.B
Erase error
#1,
R4
LOOPDW
@ER3+,
R4H
#FF,
R4H
RERASE
ER2,
ER3
EVR2
OKEND,
#4000,
R5
R5H,
@FLMCR:8 ;
#1,
ER3
#0004,
R0
KEEP
E4
ERASE
#4000,
R5
R5H,
@FLMCR:8 ;
#0000,
R5
R5,
@EBR1:16 ;
R5L,
@FLMCR:8 ;
#0000,
R5
R5,
@EBR1:16 ;
R5L,
@FLMCR:8 ;
#0000,
R5
R5,
@EBR1:16 ;
R5L,
@FLMCR:8 ;
599
;
;
Wait
Read
;
;
Read data = H'FF?
If read data ≠ H'FF, branch to RERASE
;
Last address in block?
;
;
If not last address in block, erase-verify
next address
;
Branch to OKEND
;
Clear EV bit
Erase-verify address – 1 → R3
;
;
;
Erase executed 4 times?
;
Double erase loop counter value
Erase again
;
;
Clear EV bit
;
Clear EBR1 and EBR2
Clear V
E bit
PP
One block erased
;
Clear EBR1 and EBR2
Clear V
E bit
PP
;
Clear EBR1 and EBR2
Clear V
E bit
PP

Advertisement

Table of Contents
loading

Table of Contents