Boot Swap Function; Outline Of Boot Swap Function - NEC MuPD78F0132H User Manual

8-bit single-chip microcontrollers, 78k0/ke1plus
Table of Contents

Advertisement

26.9 Boot Swap Function

The 78K0/KE1+ has a boot swap function.
Even if a momentary power failure occurs for some reason while the boot area is being rewritten by self-
programming and the program in the boot area is lost, the boot swap function can execute the program correctly after
re-application of power, reset, and start.

26.9.1 Outline of boot swap function

Before erasing the boot program area by self-programming, write a new boot program to the block to be swapped,
Note
and also set the boot flag
reset and started next time. Consequently, the above area to be swapped is used as a boot area, and the program is
executed correctly. Figure 26-22 shows an image of the boot swap function.
Note The boot flag is controlled by the flash memory control firmware of the 78K0/KE1+.
X X X X H
User program
User program
User program
Boot program
0 0 0 0 H
X X X X H
User program
User program
User program
Boot program
0 0 0 0 H
452
CHAPTER 26 FLASH MEMORY
. Even if a momentary power failure occurs, the address is swapped when the system is
Figure 26-22. Image of Boot Swap Function
(1) If boot swap is not supported
X X X X H
User program
Self-
programming
User program
User program
Erasure in progress
0 0 0 0 H
(2) If boot swap is supported
X X X X H
User program
Self-
programming
User program
New boot program
Erasure in progress
0 0 0 0 H
User's Manual U16899EJ2V0UD
X X X X H
User program
Momentary
power failure
User program
User program
Undefined data
0 0 0 0 H
X X X X H
User program
Momentary
power failure
User program
Undefined data
New boot program
0 0 0 0 H
Not restarted
Started correctly

Advertisement

Table of Contents
loading

Table of Contents