587
CHAPTER 28 3M-BIT FLASH MEMORY
28.10
Example of Programming 3M-bit Flash Memory
This section presents a programming example of 3M-bit flash memory.
■
Programming Example of 3M-bit Flash Memory
Flash Memory Sample Program
NAME FLASHWE
TITLE FLASHWE
;-------------------------------------------------------------------------------
;3M-bit-Flash test program
;
;1: Transmits the program (address: FF8000H, sector: SA6) from Flash to RAM
; (address: 001500H).
;2: Executes the program on RAM.
;3: Writes the PDR1 value to Flash (address: F90000H, sector: SA1).
;4: Reads the written value (address: F90000H, sector: SA1) and outputs it to PDR2.
;5: Erases the written sector (SA1).
;6: Checks and outputs erase data.
;Conditions
; - Number of bytes transmitted to RAM: 100H (256B)
; - Write/erase termination judgment
; Judgment according to DQ5 (timing limit excess flag)
; Judgment according to DQ6 (toggle bit flag)
; Judgment according to RDY (FMCS)
; - Error handling
; “H” output to P00 to P07
; Reset command issuance
;-------------------------------------------------------------------
;
RESOUS IOSEG ABS=00 ;"RESOUS" I/O segment definition
ORG 0000H
PDR0 RB 1
PDR1 RB 1
PDR2 RB 1
PDR3 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
DATA ENDS
Содержание MB90390 Series
Страница 2: ......
Страница 4: ......
Страница 17: ...xiii APPENDIX D List of Interrupt Vectors 690 INDEX 695 ...
Страница 18: ...xiv ...
Страница 132: ...104 CHAPTER 5 CLOCKS ...
Страница 152: ...124 CHAPTER 6 CLOCK MODULATOR ...
Страница 210: ...182 CHAPTER 11 TIME BASE TIMER ...
Страница 218: ...190 CHAPTER 12 WATCHDOG TIMER ...
Страница 264: ...236 CHAPTER 14 16 BIT RELOAD TIMER WITH EVENT COUNT FUNCTION ...
Страница 274: ...246 CHAPTER 15 WATCH TIMER ...
Страница 306: ...278 CHAPTER 17 DTP EXTERNAL INTERRUPTS ...
Страница 338: ...310 CHAPTER 18 8 10 BIT A D CONVERTER ...
Страница 364: ...336 CHAPTER 19 UART0 UART1 ...
Страница 398: ...370 CHAPTER 20 UART2 UART3 Figure 20 5 2 ORE Set Timing Receive data RDRF ORE ...
Страница 432: ...404 CHAPTER 20 UART2 UART3 ...
Страница 482: ...454 CHAPTER 22 SERIAL I O ...
Страница 560: ...532 CHAPTER 24 STEPPING MOTOR CONTROLLER ...
Страница 582: ...554 CHAPTER 27 ROM MIRRORING MODULE ...
Страница 632: ...604 CHAPTER 29 EXAMPLES OF SERIAL PROGRAMMING CONNECTION ...
Страница 722: ...694 APPENDIX ...
Страница 723: ...695 INDEX The index follows on the next page This is listed in alphabetic order ...
Страница 740: ......