Renesas RL78/G1P Hardware User Manual page 706

16-bit single-chip microcontroller
Hide thumbs Also See for RL78/G1P:
Table of Contents

Advertisement

RL78/G1P
23.7 Flash Memory Programming by Self-programming
The RL78/G1P supports a self-programming function that can be used to rewrite the flash memory via a user program.
Because this function allows a user application to rewrite the flash memory by using the RL78/G1P self-programming
library, it can be used to upgrade the program in the field.
Cautions 1. To prohibit an interrupt during self-programming, in the same way as in the normal operation
mode, execute the self-programming library in the state where the IE flag is cleared (0) by the DI
instruction. To enable an interrupt, clear (0) the interrupt mask flag to accept in the state where
the IE flag is set (1) by the EI instruction, and then execute the self-programming library.
2. When enabling RAM parity error resets (RPERDIS = 0), be sure to initialize the RAM area to use +
10 bytes before overwriting.
3. The high-speed on-chip oscillator should be kept operating during self-programming. If it is kept
stopped, it should be operated (HIOSTOP = 0). The flash self-programming library should be
executed after 30 μs have elapsed.
Remarks 1.
For details of the self-programming function and the RL78/G1P self-programming library, refer to the
RL78 Family Flash Self-Programming Library Type 01 User's Manual (R01US0050).
2. For details of the time required to execute self-programming, see the notes on use that accompany the
flash self-programming library tool.
Similar to when writing data by using the flash memory programmer, there are two flash memory programming modes
for which the voltage range in which to write, erase, or verify data differs.
Table 23-13. Programming Modes and Voltages at Which Data Can Be Written, Erased, or Verified
Mode
Wide voltage mode
Note
Full speed mode
Note This can only be specified if the CMODE1 and CMODE0 bits of the option byte 000C2H are 1.
Specify the mode that corresponds to the voltage range in which to write data. If the argument fsl_flash_voltage_u08 is
other than 00H when the FSL_Init function of the self-programming library provided by Renesas Electronics is executed,
wide-voltage mode is specified. If the argument is 00H, full-speed mode is specified.
Remarks 1. Using both the wide voltage mode and full speed mode imposes no restrictions on writing, deletion, or
verification.
2. For details of the self-programming function and the RL78/G1P self-programming library, refer to the
RL78 Family Flash Self-Programming Library Type 01 User's Manual (R01US0050).
R01UH0895EJ0100 Rev.1.00
Nov 29, 2019
Voltages at Which Data can Be Written, Erased, or Verified
2.7 V to 3.6 V
2.7 V to 3.6 V
CHAPTER 23 FLASH MEMORY
Writing Clock Frequency
32 MHz (MAX.)
32 MHz (MAX.)
687

Advertisement

Table of Contents
loading

Table of Contents