S3F80JB

EMBEDDED FLASH MEMORY INTERFACE

 

 

The Sector Erase Procedure in User Program Mode

1.Set Flash Memory User Programming Enable Register (FMUSR) to “10100101B”.

2.Set Flash Memory Sector Address Register (FMSECH and FMSECL).

3.Set Flash Memory Control Register (FMCON) to “10100001B”.

4.Set Flash Memory User Programming Enable Register (FMUSR) to “00000000B”.

 

Start

 

SB1

FMUSR

#0A5H

FMSECH

High Address of Sector

FMSECL

Low Address of Sector

FMCON

#10100001B

FMUSR

#00H

;Select Bank1

;User Programimg Mode Enable

;Set Sector Base Address

;Mode Select & Start Erase

;User Prgramming Mode Disable

SB0

; Select Bank0

Finish One Sector Erase

Figure 15-8. Sector Erase Flowchart in User Program Mode

NOTES

1.If user erases a sector selected by Flash Memory Sector Address Register FMSECH and FMSECL, FMUSR should be enabled just before starting sector erase operation. And to erase a sector, Flash Operation Start Bit of FMCON register is written from operation stop ‘0’ to operation start ‘1’. That bit will be cleared automatically just after the corresponding operation completed. In other words, when S3F80JB is in the condition that flash memory user programming enable bits is enabled and executes start operation of sector erase, it will get the result of erasing selected sector as user’s a purpose and Flash Operation Start Bit of FMCON register is also clear automatically.

2.If user executes sector erase operation with FMUSR disabled, FMCON.0 bit, Flash Operation Start Bit, remains 'high', which means start operation, and is not cleared even though next instruction is executed. So user should be careful to set FMUSR when executing sector erase, for no effect on other flash sectors.

15-9

Page 288
Image 288
Samsung S3F80JB manual Sector Erase Procedure in User Program Mode, Sector Erase Flowchart in User Program Mode