Renesas R8C/18 Series Hardware Manual page 195

16-bit single-chip mcu
Table of Contents

Advertisement

R8C/18 Group, R8C/19 Group
Figure 17.5 shows the FMR0 Register. Figure 17.7 shows the FMR4 Register.
17.4.2.1
FMR00 Bit
This bit indicates the operating status of the flash memory. The bits value is 0 during programming,
erasure, or erase-suspend mode; otherwise, it is 1.
17.4.2.2
FMR01 Bit
The MCU is made ready to accept commands by setting the FMR01 bit to 1 (CPU rewrite mode).
17.4.2.3
FMR02 Bit
Rewriting of blocks 0 and 1 does not accept the program or block erase commands if the FMR02 bit
is set to 0 (rewrite disabled).
Rewriting of blocks 0 and 1 is controlled by bits FMR15 and FMR16 if the FMR02 bit is set to 1
(rewrite enabled).
17.4.2.4
FMSTP Bit
This bit is used to initialize the flash memory control circuits, and also to reduce the amount of current
consumed by the flash memory. Access to the flash memory is disabled by setting the FMSTP bit to
1. Therefore, the FMSTP bit must be written to by a program located outside of the flash memory.
In the following cases, set the FMSTP bit to 1:
When flash memory access resulted in an error while erasing or programming in EW0 mode
(FMR00 bit not reset to 1 (ready)).
When entering on-chip oscillator mode (main clock stops).
Figure 17.11 shows a flowchart to be followed before and after entering on-chip oscillator mode (main
clock stop). Note that when going to stop or wait mode while the CPU rewrite mode is disabled, the
FMR0 register does not need to be set because the power for the flash memory is automatically
turned off and is turned back on again after returning from stop or wait mode.
17.4.2.5
FMR06 Bit
This is a read-only bit indicating the status of an auto-program operation. The bit is set to 1 when a
program error occurs; otherwise, it is set to 0. Refer to 17.4.5 Full Status Check for details.
17.4.2.6
FMR07 Bit
This is a read-only bit indicating the status of an auto-erase operation. The bit is set to 1 when an
erase error occurs; otherwise, it is set to 0. Refer to 17.4.5 Full Status Check for details.
17.4.2.7
FMR11 Bit
Setting this bit to 1 (EW1 mode) places the MCU in EW1 mode.
17.4.2.8
FMR15 Bit
When the FMR02 bit is set to 1 (rewrite enabled) and the FMR15 bit is set to 0 (rewrite enabled),
block 0 accepts program and block erase commands.
17.4.2.9
FMR16 Bit
When the FMR02 bit is set to 1 (rewrite enabled) and the FMR16 bit is set to 0 (rewrite enabled),
block 1 accepts program and block erase commands.
Rev.1.30
Apr 14, 2006
REJ09B0222-0130
Page 180 of 233
17. Flash Memory Version

Advertisement

Table of Contents
loading

This manual is also suitable for:

R8c/1 seriesR8c seriesR8c/19 series

Table of Contents