Functions To Prevent Flash Memory From Rewriting; Rom Code Protect Function; Id Code Check Function - Renesas M16C FAMILY series Hardware Manual

16-bit single-chip microcomputer
Hide thumbs Also See for M16C FAMILY series:
Table of Contents

Advertisement

M
1
6
C
2 /
8
G
o r
u
p
(
M
1
6
C

18.3 Functions To Prevent Flash Memory from Rewriting

The flash memory has a built-in ROM code protect function for parallel I/O mode and a built-in ID code
check function for standard input/output mode to prevent the flash memory from reading or rewriting.

18.3.1 ROM Code Protect Function

The ROM code protect function disables reading or changing the contents of the on-chip flash memory in
parallel I/O mode. Figure 18.5 shows the ROMCP address. The ROMCP address is located in a user
ROM area. To enable ROM code protect, set the ROMCP1 bit to "00
bit 0 to "111111
".
2
To cancel ROM code protect, erase the block including the the ROMCP1 register in CPU rewrite mode or
standard serial I/O mode.

18.3.2 ID Code Check Function

Use the ID code check function in standard serial input/output mode. Unless the flash memory is blank,
the ID code sent from the programmer and the 7-byte ID code written in the flash memory are compared
for match. If the ID codes do not match, the commands sent from the programmer are not acknowledged.
The ID code consists of 8-bit data, starting with the first byte, into addresses, 0FFFDF
0FFFEB
, 0FFFEF
16
with the ID code set in these addresses.
R
e
. v
2
0 .
0
J
a
. n
3
, 1
2
0
0
7
R
E
J
0
9
B
0
0
4
7
0 -
2
0
0
2 /
, 8
M
1
6
C
2 /
8
) B
, 0FFFF3
, 0FFFF7
16
16
page 302
f o
3
8
5
, and 0FFFFB
. The flash memory must have a program
16
16
18. Flash Memory Version
", "01
", or "10
" and set the bit 5 to
2
2
2
16
, 0FFFE3
,
16

Advertisement

Table of Contents
loading

This manual is also suitable for:

Tiny seriesM16c series

Table of Contents