English
Language : 

HD64F3039F18 Datasheet, PDF (489/710 Pages) Renesas Technology Corp – Renesas 16-Bit Single-Chip Microcomputer H8 Family / H8/300H Series
Section 15 ROM
Start
*1
Set SWE bit in FLMCR
Wait (x) µs
*6
Store 32-byte write data in write data area
and reprogram data area
Programming operation counter n ← 1
Consecutively write 32-byte data in
reprogram data area in RAM to flash memory *2
Enable WDT
Set PSU bit in FLMCR
Wait (y) µs
*6
Set P bit in FLMCR
Wait (z) µs
Clear P bit in FLMCR
Wait (α) µs
Clear PSU bit in FLMCR
Wait (β) µs
Disable WDT
Start of programming
*6 *7
End of programming
*6
*6
Set PV bit in FLMCR
Wait (γ) µs
*6
Set verify start address
Programming end flag ← 0
H'FF dummy write to verify address
Wait (ε) µs
*6
Read verify data
*3
Programming OK?
OK
NG Programming end
flag ← 1 (unfinished)
Notes: 1. Programming should be performed in the erased state.
(Perform 32-byte programming on memory after all 32 bytes
have been erased.)
2. Data transfer is performed by byte transfer (word transfer is not
possible), with the write start address at a 32-byte boundary.
The lower 8 bits of the first address written to must be H'00,
H'20, H'40, H'60, H'80, H'A0, H'C0, or H'E0. A 32-byte data
transfer must be performed even if writing fewer than 32 bytes;
in this case, H'FF data must be written to the extra addresses.
3. Verify data is read in 16-bit (word) units. (Byte-unit reading is
also possible.)
4. Reprogram data is determined by the computation shown in the
table below (comparison of data stored in the program data
area with verify data). Programming of reprogram data 0 bits is
executed in the next programming loop. Therefore, even bits for
which programming has been completed will be programmed
again if the result of the subsequent verify operation is NG.
5. An area for storing write data (32 bytes) and an area for storing
reprogram data (32 bytes) must be provided in RAM. The
contents of the latter are rewritten in accordance with the
reprogramming data computation.
6. The values of x, y, z, α, β, γ, ε, η, and N are shown in section
18.2.5, Flash Memory Characteristics.
7. The value of z depends on the number of reprogramming loops
(n). Details are given in section 18.2.5, Flash Memory
Characteristics.
Write
Data
0
0
1
1
Verify
Data
0
1
0
1
Reprogram
Data
1
0
1
1
Comments
Programming completed
Programming incomplete; reprogram
—
Still in erased state; no action
Reprogram data computation
*4
Transfer computation result to reprogram
data area
*5
Increment verify address
No
32-byte
data verification completed?
Yes
Clear PV bit in FLMCR
Wait (η) µs
*6
Programming end flag = 0?
No
Yes
Clear SWE bit in FLMCR
End of programming
RAM
Program data storage
area (32 bytes)
Reprogram
n←n+1
n > N?
*6 No
Yes
Clear SWE bit in FLMCR
Programming failure
Reprogram data storage
area (32 bytes)
Figure 15.11 Program/Program-Verify Flowchart
Rev.3.00 Mar. 26, 2007 Page 465 of 682
REJ09B0353-0300