NEC 78K0S/KB1+ User Manual page 292

8-bit single-chip microcontrollers
Hide thumbs Also See for 78K0S/KB1+:
Table of Contents

Advertisement

<R>
Caution Be sure to perform the series of operations described above using the user program at an
address where data is not erased nor written.
Remark
<1> to <7> in Figure 19-20 correspond to <1> to <7> in 19.8.4 (previous page).
292
CHAPTER 19 FLASH MEMORY
Figure 19-20. Example of Shifting to Self Programming Mode
Shift to self programming mode
<1> Disable interrupts (by setting
MK0 to FFH and executing DI
instruction)
<2> Clear FLCMD
(FLCMD = 00H)
<3> Clear PFS
If the CPU clock is lower than 1 MHz,
set it to be 1 MHz or higher.
PFCMD = A5H
FLPMC = 01H (set value)
<4>
FLPMC = 0FEH (inverted set value)
FLPMC = 01H (set value)
NOP instruction
<5>
HALT instruction
<6> Check execution result
(FPRERR flag)
Normal
<7> Termination
User's Manual U17446EJ3V1UD
; When interrupt function is used
; Set value is invalid
; Set value is valid
Abnormal

Advertisement

Table of Contents
loading

Table of Contents