
1-191
Under
development
Specifications in this manual are tentative and subject to change
Rev. H
CPU Rewrite Mode (Flash Memory Version)
MITSUBISHI MICROCOMPUTERS
M30222 Group
SINGLE-CHIP 16-BIT CMOS MICROCOMPUTER
Software Commands
Table 1.75 lists the software commands available with the M30222 (flash memory version).
After setting the CPU rewrite mode select bit to 1, write a software command to specify an erase or
program operation. Note that when entering a software command, the upper byte (D8 to D15) is ig-
nored. The content of each software command is explained below.
Read Array Command (FF16)
The read array mode is entered by writing the command code "FF16" in the first bus cycle. When an even address
to be read is input in one of the bus cycles that follow, the content of the specified address is read out at the data
bus (D0 –D15), 16 bits at a time. The read array mode is retained intact until another command is written.
Read Status Register Command (7016)
When the command code "7016" is written in the first bus cycle, the content of the status register is read out at the
data bus (D0–D7) by a read in the second bus cycle.
The status register is explained in the next section.
Clear Status Register Command (5016)
This command is used to clear the error bits of the status register after they have been set. These bits indicate that
operation has ended in an error. To use this command, write the command code "5016" in the first bus cycle.
Table 1.75. List of software commands (CPU rewrite mode)
Note 1: When a software command is input, the high-order byte of data (D15:D8) is ignored.
Note 2: SRD = Status Register Data
Note 3: WA = Write Address, WD = Write Data (16 bits)
Note 4: BA = Block Address (Enter the maximum address of each block that is an even address)
Note 5: X denotes a given even address in the user ROM.
Note 6: Lock bit output on Data bit 6
Commands (Note 1)
Cycle
No.
1st Bus Cycle
2nd Bus Cycle
Mode
Address
Data
(D7:D0)
Mode
Address
Data
(D7:D0)
Read
1
Write
X (Note 5)
FFh
ID Codes
2
Write
X
90h
Read
IA
ID
Status Regiser Read
2
Write
X
70h
Read
X
SRD (Note 2)
Status Register Clear
1
Write
X
50h
Word Program
2
Write
X
40h
Write
WA (Note 3)
WD (Note 3)
Auto Block Erase
2
Write
X
20h
Write
BA (Note 4)
D0h
Erase
2
Write
X
20h
Write
X
20h
(Erase all unlocked blocks)
2
Write
X
A7h
Write
X
D0h
Lock Bit Status Read
2
Write
X
71h
Read
BA (Note 4)
(D6)(Note 6)
Lock Bit Program
2
Write
X
77h
Write
BA (Note 4)
D0h