Renesas M16C/6NK Laptop User Manual


 
Rev.1.10 Jul 01, 2005 page 312 of 318
REJ09B0124-0110
M16C/6N Group (M16C/6NK, M16C/6NM) 22. Usage Precaution
Under development
This document is under development and its contents are subject to change.
22.18.8 Operation Speed
Set the CM06 bit in the CM0 register and the CM17 to CM16 bits in the CM1 register to clock frequency
of 10 MHz or less before entering CPU rewrite mode (EW0 or EW1 mode). Also, set the PM17 bit in the
PM1 register to 1 (with wait state).
22.18.9 Prohibited Instructions
The following instructions cannot be used in EW0 mode because the CPU tries to read data in flash
memory: UND instruction, INTO instruction, JMPS instruction, JSRS instruction, and BRK instruction
22.18.10 Interrupt
EW0 Mode
To use interrupts having vectors in a relocatable vector table, the vectors must be relocated to the RAM
area.
_______
The NMI and watchdog timer interrupts are available since the FMR0 and FMR1 registers are forcibly
reset when either interrupt request is generated. Allocate the jump addresses for each interrupt service
_______
routines to the fixed vector table. Flash memory rewrite operation is aborted when the NMI or watchdog
timer interrupt request is generated. Execute the rewrite program again after exiting the interrupt routine.
The address match interrupt is not available since the CPU tries to read data in the flash memory.
EW1 Mode
Do not acknowledge any interrupts with vectors in the relocatable vector table or address match interrupt
during the auto program or auto erase period.
Do not use the watchdog timer interrupt.
_______
The NMI interrupt is available since the FMR0 and FMR1 registers are forcibly reset when the interrupt
request is generated. Allocate the jump address for the interrupt service routine to the fixed vector table.
_______
Flash memory rewrite operation is aborted when the NMI interrupt request is generated. Execute the
rewrite program again after exiting the interrupt service routine.
22.18.11 How to Access
To set the FMR01, FMR02 or FMR11 bit to 1, write 1 after first setting the bit to 0. Do not generate an
interrupt or a DMA transfer between the instruction to set the bit to 0 and the instruction to set the bit to
_______
1. Set the bit while an H signal is applied to the NMI pin.
22.18.12 Rewriting in User ROM Area
EW0 Mode
The supply voltage drops while rewriting the block where the rewrite control program is stored, the flash
memory cannot be rewritten because the rewrite control program is not correctly rewritten. If this error
occurs, rewrite the user ROM area while in standard serial I/O mode or parallel I/O mode or CAN I/O
mode.
EW1 Mode
Avoid rewriting any block in which the rewrite control program is stored.
22.18.13 DMA Transfer
In EW1 mode, do not perform a DMA transfer while the FMR00 bit in the FMR0 register is set to 0 (auto
programming or auto erasing).