English
Language : 

SH7052 Datasheet, PDF (734/919 Pages) Renesas Technology Corp – SuperHTM RISC engine
20.6.2 User Program Mode
After setting FWE, the user should branch to, and execute, the previously prepared
programming/erase control program.
Use the following procedure (figure 20.12) to execute the programming control program that
writes to flash memory (when transferred to RAM).
Write FWE assessment program
1
and transfer program
FWE = 1
2
(user program mode)
3
Transfer programming/erase
control program to RAM
Execute programming/
4 erase control program in RAM
(flash memory rewriting)
Execute user application
5
program
Figure 20.12 User Program Mode Execution Procedure
Note: When programming and erasing, start the watchdog timer so that measures can be taken to
prevent program runaway, etc. Memory cells may not operate normally if
overprogrammed or overerased due to program runaway.
20.7 Programming/Erasing Flash Memory
A software method, using the CPU, is employed to program and erase flash memory in the on-
board programming modes. There are four flash memory operating modes: program mode, erase
mode, program-verify mode, and erase-verify mode. Transitions to these modes are made by
setting the PSU1, ESU1, P1, E1, PV1, and EV1 bits in FLMCR1.
The flash memory cannot be read while it is being written or erased. Install the program to control
flash memory programming and erasing (programming control program) in the on-chip RAM, in
708