English
Language : 

SH7018 Datasheet, PDF (340/431 Pages) Renesas Technology Corp – SuperH™ RISC engine
16.5 Register Descriptions
16.5.1 Flash Memory Control Register 1 (FLMCR1)
FLMCR1 is an 8-bit register used for flash memory operating mode control. Program-verify mode
or erase-verify mode is entered by setting SWE to 1 when FWE = 1. Program mode is entered by
setting SWE to 1 when FWE = 1, then setting the PSU bit, and finally setting the P bit. Erase
mode is entered by setting SWE to 1 when FWE = 1, then setting the ESU bit, and finally setting
the E bit. FLMCR1 is initialized by a power-on reset, and in standby mode. Its initial value is H'80
when a low level is input to the FWP pin, and H'00 when a high level is input. When on-chip flash
memory is disabled, a read will return H'00, and writes are invalid.
Writes to bits SWE, ESU, PSU, EV, and PV are enabled only when FWE = 1 and SWE = 1; writes
to the E bit only when FWE = 1, SWE = 1, and ESU = 1; and writes to the P bit only when FWE =
1, SWE = 1, and PSU = 1.
Bit: 7
6
5
4
3
2
1
0
FWE SWE ESU PSU
EV
PV
E
P
Initial value: 1/0
0
0
0
0
0
0
0
R/W: R
R/W R/W R/W R/W R/W R/W R/W
• Bit 7—Flash Write Enable Bit (FWE): Sets hardware protection against flash memory
programming/erasing.
Bit 7:
FWE
0
1
Description
When a high level is input to the FWP pin (hardware-protected state)
When a low level is input to the FWP pin
(Initial value)
• Bit 6—Software Write Enable Bit (SWE): Enables or disables the flash memory. This bit
should be set before setting bits 5 to 0, EBR1 bits 7 to 0, and EBR2 bits 2 to 0. The flash
memory cannot be read when SWE is set to 1, except in the program verify/erase verify mode.
Bit 6:
SWE
0
1
Description
Writes disabled
Writes enabled
[Setting condition]
When FWE = 1
(Initial value)
324