Datasheet

A
PPLICATION NOT
E
REU05B0042-0100Z June 2003
Page 1 of 8
M16C/26
Programming Flash Memory via Flash-Over-USB™
1.0 Abstract
The following article describes using a synchronous serial port and the FoUSB (Flash-over-USB™) Programmer
application to program the user flash memory of the M16C/26 series of microcontrollers. This is referred to in the
M16C/26 datasheet as the “Standard Serial I/O Mode 1” method of flash programming.
2.0 Introduction
The Renesas M16C/26 is a 16-bit MCU based on the M16C/60 series CPU core. The peripheral set includes
10-bit A/D, UARTs, Timers, DMA, and GPIO. The MCU features include up to 64K bytes of Flash ROM, 2K bytes
of RAM, and 4K bytes of virtual EEPROM. The flash memory is divided into several blocks as shown in Figure 1,
and so, allows memory to be erased one block at a time.
Block B: 2KB
RESERVED
Block 3: 32KB
0F000H
0F800H
FFFFFH
Block A: 2KB
Block 2: 16KB
Block 1: 8KB
Block 1: 8KB
FE000H
FC000H
F8000H
F0000H
Part No.
M30262F3-GP
M30262F4-GP
M30262F6-GP
M30262F8-GP
Block 3 Size
0 KB
0 KB
16KB
32KB
Start Address
N/A
N/A
F4000H
F0000H
Block 2 Size
8KB
16KB
16KB
16KB
Part No.
M30262F3-GP
M30262F4-GP
M30262F6-GP
M30262F8-GP
Start Address
FA000H
F8000H
F8000H
F8000H
8KB
User ROM Area Boot ROM Area
Figure 1 M16C/26 Flash Memory Map
The M16C/26 flash memory can be programmed with a single voltage. Three flash memory modes are available
in which to read, program and erase: (1) parallel I/O and (2) serial I/O modes in which the flash memory can be
manipulated using a programmer and (3) CPU rewrite mode in which the flash memory can be manipulated by
the Central Processing Unit (CPU). The Standard Serial I/O Mode can be further divided into a synchronous
mode (Standard Serial I/O Mode 1) and an asynchronous mode (Standard Serial I/O Mode 2). The standard
serial I/O mode inputs and outputs the software commands, addresses and data needed to operate (read,
program, erase, etc.) the internal flash memory using the serial I/O port UART1.
The flash memory is divided into two major blocks, a user program area and a boot ROM area. The user program
area is used for user application program and data. The boot ROM area has a control program stored in it when
shipped from the factory and can only be accessed when a special hardware reset sequence is initiated. This

Summary of content (9 pages)