Programming The Internal Flash Memory; Outline Of Flash Memory Programming - Mitsubishi 32172 User Manual

M32r series
Table of Contents

Advertisement

6

6.5 Programming the Internal Flash Memory

6.5.1 Outline of Flash Memory Programming

There are following two methods for writing to the internal flash memory.
(1) When no write programs exist in the internal flash memory
Set the FP pin = high, MOD0 = high, and MOD1 = low to enter boot mode. In this case, the reset
vector entry is at the beginning of the boot program area (H'8000 0000). (Normally the reset
vector entry is at the start address of the internal flash memory.)
Use the boot program to transfer the "flash write program" from the boot area into the internal
RAM. Then jump to the RAM and by using the program in the RAM, set the Flash Control
Register 1 FENTRY bit to 1 to enable the flash memory for write (flash E/W enable mode).
After that, use the "flash write program" that has been transferred into the RAM to write to the
internal flash memory.
(2) When a write program already exists in the internal flash memory
Set the FP pin = high, MOD0 = low, and MOD1 = low to enter single-chip mode. Transfer the
"flash write program" from the internal flash memory in which it was prepared beforehand into the
internal RAM. Then jump to the RAM and by using the program in the RAM, set the Flash Control
Register 1 (FCNT1) FENTRY bit to 1 to enable the flash memory for write (flash E/W enable
mode).
After that, use the "flash write program" that has been transferred into the RAM to write to the
internal flash memory.
Or you can set the FP pin = high, MOD0 = low, and MOD1 = high to enter flash E/W enable mode
in external extended mode.
During flash E/W enable mode (FP pin = 1, FENTRY = 1), the EIT vector entry for External
Interrupt (EI) moves to the start address of the internal RAM (H'0080 4000). During normal mode,
it is at the flash area address (H'0000 0080).
6.5 Programming the Internal Flash Memory
6-16
INTERNAL MEMORY
Rev.1.0

Advertisement

Table of Contents
loading

This manual is also suitable for:

32173

Table of Contents