
610
CHAPTER 23 512K / 1024K BIT FLASH MEMORY
23.8
Programming Example of 512K Bit Flash Memory
This section presents a programming example for the use of 512K bit flash memory.
■
Programming Example Using 512K Bit Flash Memory
NAME
FLASHWE
TITLE FLASHWE
;---------------------------------------------------------------------------
;512-KB FLASH Sample pro
g
ram for 512-KB FLASH
;
;1: Transfer the pro
g
ram from the flash memory (address: FFBC00
H
sector: SA2) to RAM (address: 000700
H
).
;2: R
u
n the transferred pro
g
ram in RAM.
;3: Write the val
u
e of
P
DR1 to the flash memory (address: FF0000
H
sector: SA0).
;4: Read the written val
u
e (address: FF0000
H
sector: SA0), and o
u
tp
u
t the val
u
e to
P
DR2.
;5: Erase the sector (SA0) to which the val
u
e was written.
;6: O
u
tp
u
t a confirmation that the data was erased.
; Req
u
irements:
;
- N
u
mber of bytes transferred to RAM: 100 H (256 B)
;
- Determination that writin
g
or erasin
g
has ended
;
Determined via DQ5 (timin
g
limit exceeded fla
g
)
;
Determined via DQ6 (to
gg
le bit fla
g
)
;
Determined via RDY (FMCS)
;
- Error handlin
g
;
O
u
tp
u
t Hi to
P
00 to
P
07.
;
Iss
u
e a reset command.
;---------------------------------------------------------------------------
;
RESOUS
IOSEG
ABS=00
;
"
RESOUS
"
I/O se
g
ment definition
ORG
0000H
P
DR0
RB
1
P
DR1
RB
1
P
DR2
RB
1
P
DR3
RB
1
ORG
0010H
DDR0
RB
1
DDR1
RB
1
DDR2
RB
1
DDR3
RB
1
ORG
00A1H
CKSCR
RB
1
ORG
00AEH
FMCS
RB
1
ORG
006FH
ROMM
RB
1
RESOUS
ENDS
;
SSTA
SSEG
RW
0127H
STA_T
RW
1
SSTA
ENDS
;
DATA
DSEG
ABS=0FFH
;Flash command address
ORG
5554H
COMADR2 RW
1
ORG
0AAAAH
COMADR1 RW
1
Summary of Contents for MB90460 Series
Page 1: ...The following document contains information on Cypress products ...
Page 3: ......
Page 5: ......
Page 9: ...iv ...
Page 41: ...22 CHAPTER 1 OVERVIEW ...
Page 45: ...26 CHAPTER 2 NOTES ON HANDLING DEVICES ...
Page 83: ...64 CHAPTER 3 CPU ...
Page 95: ...76 CHAPTER 4 RESET ...
Page 107: ...88 CHAPTER 5 CLOCK ...
Page 131: ...112 CHAPTER 6 LOW POWER CONSUMPTION MODE ...
Page 175: ...156 CHAPTER 7 INTERRUPT ...
Page 181: ...162 CHAPTER 8 MODE SETTING ...
Page 223: ...204 CHAPTER 9 I O PORT ...
Page 237: ...218 CHAPTER 10 TIME BASE TIMER ...
Page 247: ...228 CHAPTER 11 WATCHDOG TIMER ...
Page 275: ...256 CHAPTER 12 16 BIT RELOAD TIMER ...
Page 373: ...354 CHAPTER 14 MULTI FUNCTIONAL TIMER ...
Page 485: ...466 CHAPTER 16 PWC Timer ...
Page 531: ...512 CHAPTER 17 UART ...
Page 559: ...540 CHAPTER 19 DELAYED INTERRUPT GENERATOR MODULE ...
Page 589: ...570 CHAPTER 20 8 10 BIT A D CONVERTER ...
Page 601: ...582 CHAPTER 21 ROM CORRECTION FUNCTION ...
Page 633: ...614 CHAPTER 23 512K 1024K BIT FLASH MEMORY ...
Page 645: ...626 CHAPTER 24 EXAMPLE OF F2 MC 16LX MB90F462 F462A F463A CONNECTION FOR SERIAL WRITING ...
Page 715: ...696 APPENDIX ...
Page 716: ...697 INDEX INDEX The index follows on the next page This is listed in alphabetic order ...
Page 739: ......