![](http://datasheet.mmic.net.cn/30000/M30280M6-XXXHP_datasheet_2358793/M30280M6-XXXHP_353.png)
M16C/28 Group
Under development Preliminary specification
Specifications in this manual are tentative and subject to change.
19. Flash Memory Version
Rev.0.60 2004.02.01
page 335 of N
REJ09B0047-0060Z
19.5 Register Description
Figure 19.5.1 shows the flash memory control register 0 and flash memory control register 1. Figure 19.5.2
shows the flash memory control register 4.
19.5.1 Flash memory control register 0 (FMR0):
FMR 00 Bit
This bit indicates the operation status of the flash memory. The bit is “0” during programming, erasing,
or erase-suspend mode; otherwise, the bit is “1”.
FMR01 Bit
The microcomputer enables to acknowledge commands by setting the FMR01 bit to “1” (CPU rewrite
mode). To set this bit to “1”, it is necessary to set to “0” after first setting to “1”. To set this bit to “0” by
only writing “0”.
FMR02 Bit
The combined setting of the FMR02 bit and the FMR16 bit enable to program and erase in the user
ROM area. See Table 19.5.2.1 for setting details. To set this bit to “1”, it is necessary to set to “0” after
first setting to “1”. To set this bit to “0” by only writing “0”. This bit is enabled only when the FMR01 bit
is “1” (CPU rewrite mode enable).
FMSTP Bit
This bit resets the flash memory control circuits and minimizes power consumption in the flash
memory. Access to the flash memory is disabled when the FMSTP bit is set to “1”. Set the FMSTP bit
by a program in a space other than the flash memory.
Set the FMSTP bit to “1” if one of the following occurs:
A flash memory access error occurs during erasing or programming in EW0 mode (FMR00 bit does
not switch back to “1” (ready)).
Low-power consumption mode or ring oscillator low-power consumption mode is entered. Figure
19.5.1.3 shows a flow chart illustrating how to start and stop the flash memory before and after enter-
ing low power mode. Follow the procedure on this flow chart.
FMR06 Bit
This is a read-only bit indicating an auto-program operation status. This bit is set to “1” when a pro-
gram error occurs; otherwise, it is set to “0”. For details, refer to the description of the full status check.
FMR07 Bit
This is a read-only bit indicating an auto-erase operation status. The bit is set to “1” when an erase
error occurs; otherwise, it is set to “0”. For details, refer to the description of the full status check.
Figure 19.5.1.1 shows a EW0 mode set/reset flowchart, figure 19.5.1.2 shows a EW1 mode set/reset
flowchart.