US20020144053A1 - Microcomputer, programming method and erasing method - Google Patents

Microcomputer, programming method and erasing method Download PDF

Info

Publication number
US20020144053A1
US20020144053A1 US10/080,681 US8068102A US2002144053A1 US 20020144053 A1 US20020144053 A1 US 20020144053A1 US 8068102 A US8068102 A US 8068102A US 2002144053 A1 US2002144053 A1 US 2002144053A1
Authority
US
United States
Prior art keywords
program
erase
processing unit
central processing
control program
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Abandoned
Application number
US10/080,681
Inventor
Naoki Yada
Eiichi Ishikawa
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Renesas Technology Corp
Renesas Semiconductor Package and Test Solutions Co Ltd
Original Assignee
Hitachi Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Hitachi Ltd filed Critical Hitachi Ltd
Assigned to HITACHI HOKKAI SEMICONDUCTOR, LTD., HITACHI, LTD. reassignment HITACHI HOKKAI SEMICONDUCTOR, LTD. ASSIGNMENT OF ASSIGNORS INTEREST (SEE DOCUMENT FOR DETAILS). Assignors: YADA, NAOKI, ISHIKAWA, EIICHI
Publication of US20020144053A1 publication Critical patent/US20020144053A1/en
Assigned to RENESAS TECHNOLOGY CORPORATION reassignment RENESAS TECHNOLOGY CORPORATION ASSIGNMENT OF ASSIGNORS INTEREST (SEE DOCUMENT FOR DETAILS). Assignors: HITACHI, LTD.
Priority to US11/037,261 priority Critical patent/US7194571B2/en
Priority to US11/672,468 priority patent/US7310700B2/en
Abandoned legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/30Arrangements for executing machine instructions, e.g. instruction decode
    • G06F9/32Address formation of the next instruction, e.g. by incrementing the instruction counter
    • G06F9/322Address formation of the next instruction, e.g. by incrementing the instruction counter for non-sequential address
    • G06F9/328Address formation of the next instruction, e.g. by incrementing the instruction counter for non-sequential address for runtime instruction patching
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/06Digital input from, or digital output to, record carriers, e.g. RAID, emulated record carriers or networked record carriers
    • G06F3/0601Interfaces specially adapted for storage systems
    • G06F3/0602Interfaces specially adapted for storage systems specifically adapted to achieve a particular effect
    • G06F3/0604Improving or facilitating administration, e.g. storage management
    • G06F3/0605Improving or facilitating administration, e.g. storage management by facilitating the interaction with a user or administrator
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/06Digital input from, or digital output to, record carriers, e.g. RAID, emulated record carriers or networked record carriers
    • G06F3/0601Interfaces specially adapted for storage systems
    • G06F3/0628Interfaces specially adapted for storage systems making use of a particular technique
    • G06F3/0646Horizontal data movement in storage systems, i.e. moving data in between storage devices or systems
    • G06F3/0652Erasing, e.g. deleting, data cleaning, moving of data to a wastebasket
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/06Digital input from, or digital output to, record carriers, e.g. RAID, emulated record carriers or networked record carriers
    • G06F3/0601Interfaces specially adapted for storage systems
    • G06F3/0668Interfaces specially adapted for storage systems adopting a particular infrastructure
    • G06F3/0671In-line storage system
    • G06F3/0673Single storage device
    • G06F3/0679Non-volatile semiconductor memory device, e.g. flash memory, one time programmable memory [OTP]
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F8/00Arrangements for software engineering
    • G06F8/60Software deployment
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/44Arrangements for executing specific programs
    • G06F9/448Execution paradigms, e.g. implementations of programming paradigms
    • G06F9/4482Procedural
    • G06F9/4484Executing subprograms
    • G06F9/4486Formation of subprogram jump address
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/44Arrangements for executing specific programs
    • G06F9/4401Bootstrapping

Definitions

  • the present invention relates to a microcomputer having an electrically erasable and programmable non-volatile memory and a CPU (Central Processing Unit), and particularly to erase and program control on the non-volatile memory, e.g., a technology effective for application to a one-chip microcomputer having a flash memory.
  • a microcomputer having an electrically erasable and programmable non-volatile memory and a CPU (Central Processing Unit), and particularly to erase and program control on the non-volatile memory, e.g., a technology effective for application to a one-chip microcomputer having a flash memory.
  • An electrically erasable and programmable non-volatile memory such as a flash memory or the like stores information therein according to the difference between threshold voltages programmed to memory cells.
  • the difference between the threshold voltages is realized by the difference between the amounts of electrons or positive holes held by a floating gate.
  • a state of a threshold voltage high relatively with respect to a threshold voltage in a thermal equilibrium state is referred to as a program state, and a state of a threshold voltage low relatively therewith is called an erase state (the definition of the inverse is allowed).
  • respective operations for erasing for bringing each memory cell into the erase state and programming for bringing each memory cell into the program state need to repeatedly perform the application of a high voltage pulse and verify of a threshold voltage state based on it.
  • a microcomputer with a flash memory being on-chipped includes a writer mode and a boot mode as operations modes for enabling the on-chip flash memory to execute erase and programming.
  • the writer mode is an operation mode for making the microcomputer equivalent to a flash memory chip apparently and connecting it to a programming or writing device like an EPROM writer to thereby make it possible to carry out erasing and programming.
  • the boot mode is an operation mode for establishing communications with a packaging system via a serial interface such as step synchronism or the like in a state of the microcomputer being packaged in a system to thereby make it possible to carry out erasing and programming.
  • Unexamined Patent Publication No. Hei 5(1993)-266219 is known as an example of a reference in which the microcomputer equipped with the flash memory has been described.
  • the terms of a user employed in the present specification means one utilizing a semiconductor device such as a microcomputer or the like in a broad sense.
  • a semiconductor device such as a microcomputer or the like in a broad sense.
  • An object of the present invention is to provide a microcomputer wherein even in a system that needs to respond to events developed at intervals shorter than an erase/program process time, erase/programming can be effected on an on-chip non-volatile memory as necessary during a process thereof.
  • Another object of the present invention is to provide a programming method for allowing a central processing unit to execute a process other than a process for writing data and information into an electrically programmable non-volatile memory in the course of the process in a microcomputer having the central processing unit and the non-volatile memory.
  • a further object of the present invention is to provide an erasing method for allowing a central processing unit to execute a process other than a process for erasing data and information in an electrically erasable non-volatile memory in the course of the erasing process in a microcomputer having the central processing unit and the non-volatile memory.
  • An erase and program control program for an electrically erasable and programmable non-volatile memory is set up inclusive of loops such as the application of a high voltage pulse and data verify or the like. If a program jumped to a subroutine for an address specified by a user is programmed into the loops in advance, it is then able to jump to a user branch, i.e., the subroutine at the address specified by the user. If a return instruction from the subroutine is executed after the execution of the subroutine, then the program returns to the original process routine. It is therefore possible to continuously carry out an erase and programming process halfway.
  • the erase and program control program is stored in a boot mat, for example.
  • a branch address (jump-destined address) specified by a user is not described in the program. If the user passes the jump-destined address as an argument when the program is executed, then the program can jump to a desired branch-destined address by referring to the address according to a jump subroutine instruction. Even during programming, control can be returned to a user control program at certain predetermined intervals. Further, since this is executed on a software basis, the intervals at which it is returned to the user's control, can also be changed by software.
  • the jump destination is allowed even if taken in any areas of a built-in RAM or a non-volatile memory free of the execution of erase and programming.
  • a microcomputer includes an erasable and programmable non-volatile memory, and a CPU.
  • the CPU is capable of temporarily branching to a process indicated by information set to first register means (FUBRA) for each cycle of a unit process including the application of an erase voltage for an erase operation or a program voltage for a programming operation, and a verify operation, or every plural cycles.
  • the first register means is capable of programmably setting information thereto.
  • the first register means is one of general purpose registers of the CPU, for example.
  • the branching by the set value of the first register means may be, for example, either a method for performing branching by directly referring to the first register means according to a jump subroutine instruction, or a method for pre-executing an initialization process for embedding a jump-destined code into a jump subroutine instruction, based on the set value of the first register means and thereafter executing its program.
  • the former method may be used where a compiler for an erase and program control program thereof is able to refer to the first register means within a limited range of the number of general purpose registers available as an argument within one function. This is because if not so, then the set value of the first register means is stacked and time is taken to execute a procedure for utilizing the corresponding register. In order to avoid it, the latter method may be adopted. When a program argument is passed using an assembler, the easiness of creation of the program is lost.
  • the CPU skips the branching process when the information written into the first register means is a predetermined value. It is also easy to perform control on execution and non-execution of the branch. Further, control for changing a branching interval is also easy.
  • second register means (FKEY) readable and writable by the CPU.
  • the non-volatile memory sets the setting of a first set value to the second register means as a necessary condition for enabling erase and programming operations.
  • the CPU may set a value other than the first set value to the second register means upon the branch and set the first set value to the second register means for each return from the branch. This is done in consideration of a runaway of a program at a user branch destination. Namely, when program enable is taken due to the runaway of the CPU in a transferred state of the erase and program control program, the possibility that the information stored in the flash memory will be destroyed, still remains.
  • the value other than the first set value may be code information indicative of the progress of an erase and program process.
  • the code information corresponding to the progress thereof is added to a user branch between respective process cycles for erase and programming.
  • the code information is useful in a check for a malfunction of its operation.
  • the setting of masking an interrupt lower in interrupt priority level than a non-maskable interrupt may preferably be carried out when erase and programming are effected on an interrupt control circuit for inputting an interrupt request signal therein, and performing arbitration of interrupt requests which compete with one another, and an interrupt priority level-based interrupt mask process to thereby output an interrupt signal to the CPU.
  • the CPU may perform a process for changing the location of an interrupt process routine for a non-maskable interrupt request to an address of a RAM. For example, a vector base register is changed to an address in a RAM area or the use of a dedicated vector register is set. This is because since information stored in an area being in the course of the erase and programming is still imperfect in its writing, the execution of a subroutine cannot be assured.
  • a microcomputer includes an erasable and programmable non-volatile memory, and a CPU.
  • the non-volatile memory has an erase and program control program executed by the CPU and used for erase/program-controlling the non-volatile memory.
  • the erase and program control program allows a process of the CPU to temporarily branch to another branch for each cycle of a unit process including the application of an erase voltage for an erase operation or a program voltage for a programming operation and a verify operation, or every plural cycles.
  • the CPU specifies another process referred to above according to a value set to first register means (FUBPA).
  • a further aspect of the present invention is particularly based on the assumption that attention is paid to a program or write loop and a program time is longer than an erase time.
  • a microcomputer according to this viewpoint includes a non-volatile memory including a plurality of electrically programmable memory cells, and a central processing unit capable of executing a program control program with respect to the non-volatile memory.
  • the central processing unit is capable of temporarily branching to a process for a first control program different from the program control program during the execution of the program control program.
  • the program control program defines a process for executing a plurality of times of program process loops and writing the corresponding information into the specified memory cell.
  • the process of the central processing unit is capable of branching to the first control program for each program process loop referred to above.
  • the microcomputer further includes a first memory circuit (FUBRA) programmable by the central processing unit.
  • FUBRA first memory circuit
  • the process of the central processing unit continuously executes the program control program.
  • the process of the central processing unit is branched to the first control program for each program process loop referred to above.
  • a still further aspect of the present invention is particularly based on the assumption that attention is given to an erase loop and an erase time is longer than a program time.
  • a microcomputer according to this viewpoint includes a non-volatile memory including a plurality of electrically erasable memory cells, and a central processing unit capable of executing an erase control program with respect to the non-volatile memory.
  • the central processing unit is capable of temporarily branching to a process for a first control program different from the erase control program during the execution of the erase control program.
  • the erase control program defines a process for executing a plurality of times of erase process loops and thereby erasing the corresponding information for the specified memory cell.
  • the process of the central processing unit is capable of branching to the first control program for each erase process loop referred to above.
  • the microcomputer further includes a first memory circuit (FUBRA) programmable by the central processing unit.
  • FUBRA first memory circuit
  • the process of the central processing unit continuously executes the erase control program.
  • the process of the central processing unit is branched to the first control program for each erase process loop referred to above.
  • a programming method for causing a central processing unit included in a microcomputer having the central processing unit and an electrically programmable non-volatile memory to execute a program control program to thereby write information into the non-volatile memory includes a first step for supplying an address for a memory cell to be programmed in the non-volatile memory, a second step for supplying information to be programmed to the memory cell, and a third step for repeatedly writing the data to be programmed into the memory cell.
  • the third step includes a voltage applying step for applying a program voltage to the memory cell, a verify step for confirming whether the data to be programmed has been written into the memory cell, a step for referring to a value of a predetermined register and transitioning a process of the central processing unit to a predetermined process corresponding to a predetermined value set to the register when the predetermined value is stored in the register, and a step for returning the process of the central processing unit from the predetermined process to the third step.
  • an erasing method for causing a central processing unit included in a microcomputer having the central processing unit and an electrically erasable non-volatile memory to execute an erase program to thereby erase information stored in a predetermined memory cell of the non-volatile memory includes a first step for supplying an address for a memory cell to be erased in the non-volatile memory, and a second step for erasing the information from the memory cell.
  • the second step includes a voltage applying step for applying an erase voltage to the memory cell, a verify step for confirming whether the information has been erased from the memory cell, a step for referring to a value of a predetermined register and transitioning a process of the central processing unit to a predetermined process corresponding to a predetermined value set to the register when the predetermined value is stored in the register, and a step for returning the process of the central processing unit from the predetermined process to the second step.
  • a still further aspect of the present invention pays attentions to an on-board programming method.
  • a programming method for mounting a microcomputer having a central processing unit and an electrically programmable non-volatile memory to a substrate and thereafter causing the central processing unit to execute a program control program to thereby write information into a predetermined memory cell of the non-volatile memory includes a first step for supplying an address for a memory cell to be programmed in the non-volatile memory, a second step for supplying information to be programmed to the memory cell, and a third step for repeatedly writing the data to be programmed into the memory cell.
  • the third step includes a voltage applying step for applying a program voltage to the memory cell, a verify step for confirming whether the data to be programmed has been written into the memory cell, a step for causing the process of the central processing unit to transit to a predetermined process, and a step for returning the process of the central processing unit from the predetermined process to the third step.
  • an erasing method for mounting a microcomputer having a central processing unit and an electrically erasable non-volatile memory to a substrate and thereafter causing the central processing unit to execute an erase program to thereby erase information stored in a predetermined memory cell of the non-volatile memory includes a first step for supplying an address for a memory cell to be erased in the non-volatile memory, and a second step for erasing the information from the memory cell.
  • the second step includes a voltage applying step for applying an erase voltage to the memory cell, a verify step for confirming whether the information has been erased from the memory cell, a step for causing the process of the central processing unit to transit to a predetermined process, and a step for returning the process of the central processing unit from the predetermined process to the second step.
  • the central processing unit is allowed to execute a process other than the writing or programming process.
  • FIG. 1 is a block diagram of a microcomputer according to one embodiment of the present invention.
  • FIG. 2 is a block diagram showing a specific example of a CPU 2 ;
  • FIG. 3 is an explanatory diagram illustrating a memory mat of a flash memory by way of example
  • FIG. 4 is an explanatory diagram illustrating by an example, access forms in respective operation modes set every memory mats of the flash memory
  • FIG. 5 is an explanatory diagram typically showing locations of programs executed by a CPU and operations made by their execution
  • FIG. 6 is a logic circuit diagram illustrating by an example, a logic configuration for erase and program protection of the flash memory
  • FIG. 7 is a state transition diagram at the time that CPU's operations are switched between a user mat and a user boot mat;
  • FIG. 8 is a flowchart for describing a program mode determining process
  • FIG. 9 is a flowchart for describing a writer mode process
  • FIG. 10 is a flowchart for describing a boot mode process
  • FIG. 11 is a flowchart for describing a user boot mode process
  • FIG. 12 is a flowchart for describing a user mode process
  • FIG. 13 is a flowchart for describing program/erase processes in Step S 42 of FIG. 11 and Step S 54 of FIG. 12;
  • FIG. 14 is a schematic flowchart which focuses attention on a program process of FIG. 13;
  • FIG. 15 is a flowchart illustrating details on a transfer process (T 1 ) to a RAM by way of example;
  • FIG. 16 is a flowchart illustrating by an example, details on a programming initialization process (T 2 );
  • FIG. 17 is a flowchart illustrating by an example, details on a program execution (T 3 );
  • FIG. 18 is an explanatory diagram illustrating by way of example, data connection relations among a built-in RAM, a programming program, an initialization process, and registers (R 4 and R 5 ) at the programming initialization of FIG. 16;
  • FIG. 19 is an explanatory diagram illustrating by an example, data connection relations among a RAM, general purpose registers (R 4 and R 5 ) and a programming program at programming;
  • FIG. 20 is a process flow for describing a programming program corresponding to Step S 35 of FIG. 17;
  • FIG. 21 is a schematic flowchart which focuses attention on the erase process of FIG. 13;
  • FIG. 22 is a flowchart illustrating details on an erase initialization process (T 6 ) by way of example
  • FIG. 23 is a flowchart illustrating details on an erase execution (T 7 ) by way of example
  • FIG. 24 is an explanatory diagram illustrating by an example, data connection relations among a built-in RAM, an erase program, an initialization process and registers (R 4 and R 5 ) at the erase initialization of FIG. 22;
  • FIG. 25 is an explanatory diagram illustrating by way of example, data connection relations among a RAM, general purpose registers (R 4 and R 5 ) and an erase program at erasing;
  • FIG. 26 is a process flow for describing an erase program corresponding to Step T 74 of FIG. 23.
  • FIG. 27 is a flowchart for describing a user branch process for enabling inhibition of a state in which information stored in a flash memory is destructed due to a runaway of CPU at a user branch destination.
  • FIG. 1 A microcomputer used as a data processor according to one embodiment of the present invention is shown in FIG. 1.
  • the microcomputer 1 shown in the same drawing is formed on a single semiconductor substrate (semiconductor chip) like monocrystal silicon by a CMOS integrated circuit manufacturing technology.
  • the microcomputer 1 has a central processing unit (CPU) 2 used as an arithmetic control device, a RAM 3 used as a non-volatile memory, a bus state controller (BSC) 4 , a flash memory 13 , and other module 7 generically referred to as other built-in circuits.
  • the flash memory 13 is one example of an electrically reprogrammable non-volatile memory, which comprises a flash memory module 5 and a flash control module 6 .
  • the other module 7 includes a mask ROM 8 , an interrupt controller (INTC) 9 , a timer (TMR) 10 , an input/output port (I/O) 11 , a serial interface controller (SCI) 12 , other interface controller 16 , a DMAC (Direct Memory Access Controller) 17 and a system controller 15 or the like.
  • Those circuit modules are interfaced via buses IAB, IDB, PAB, PDB and CONT.
  • the buses IAB and IDB are respectively an internal address bus and an internal data bus relatively fast in information transmission rate.
  • the buses PAB and PDB are respectively a peripheral address bus and a peripheral data bus relatively slow in information transmission rate.
  • Control signal lines for transferring bus commands, bus access control signals and timing control signals or the like are collectively referred to as the bus CONT.
  • the BSC 4 optimally controls access operation timing or the like with respect to the difference in operating speed between each of the internal buses IDB and IAB and each of the peripheral buses PDB and PAB or with respect to the difference in access form inherent in an access object. Further, the BSC 4 also performs chip selection or module selection control or the like corresponding to an access address.
  • a mode signal 14 of plural bits and a reset signal RES or the like are externally inputted to the system controller 15 .
  • the reset signal RES is brought to a low level with power-on reset or hardware reset of the microcomputer 1 , a rest operation is carried out inside the microcomputer 1 during its low level period.
  • the corresponding operation mode for the microcomputer 1 is determined according to the state of the mode signal 14 of the plural bits.
  • the CPU 2 reads a reset vector in a program area corresponding to the operation mode, fetches an instruction for its address, decodes the fetched instruction, and starts an instruction execution.
  • the RAM 3 is used even as a work area for the CPU 2 or an area for temporarily storing data or a program.
  • the mask ROM 8 is defined as a storage area such as a data table.
  • the flash memory module 5 is defined as an area for storing a program and data for the CPU 2 .
  • the interrupt controller 9 receives therein an interrupt request supplied from the outside of the microcomputer 1 or an interrupt request generated from a built-in circuit module according to the state of the interior of the microcomputer 1 . Further, the interrupt controller 9 performs arbitration of interrupt requests which compete with one another and a priority level-based interrupt mask process according to interrupt priority levels and interrupt masks or the like. According to the results of the interrupt request arbitration and the interrupt mask process, the interrupt controller 9 supplies an interrupt signal IRQ to the CPU 2 and gives an interrupt vector address corresponding to an interrupt factor for the accepted interrupt request to the CPU 2 . The CPU 2 causes processing to branch to a program instructed by the interrupt vector address. The interrupt controller 9 is supplied with interrupt mask data (IMSK) from the CPU 2 and masks the reception of an interrupt request lower than an interrupt priority level indicated by the interrupt mask data (IMSK).
  • IMSK interrupt mask data
  • the I/O 11 is used for connection to an external address bus and an external data bus, external interface with the SCI 12 , the input of an external event signal to the TMR 10 , external interface to the interface controller 16 , etc.
  • the interface controller 16 can be applied to interfaces such as an ATAPI or an SCSI or the like.
  • the CPU 2 includes, at an execution section, computing units such as a shifter SFT and an arithmetic logic unit ALU or the like, a register group such as 32-bit general purpose registers RO through R 31 , a program counter PC, a status register SR and a temporary register TR or the like, and buffer circuits such as a read data buffer RDB, a write data buffer WDB and an address buffer AB or the like. They are connected to a predetermined internal bus of first through third internal buses IB 1 through IB 3 .
  • the CPU 2 includes an instruction register IR, an instruction decoder IDEC and an instruction sequence logic INTL as an instruction control section.
  • the read data buffer RDB supplies data inputted from, for example, a 32-bit data bus IDB to the internal bus IB 2 .
  • the status register SR has a field for interrupt mask data IMSK.
  • the interrupt mask data IMSK is supplied to the interrupt controller 9 .
  • the interrupt controller 9 masks an interrupt request lower than an interrupt priority level indicated by the interrupt mask data IMSK.
  • the program counter PC has an instruction address to be next executed.
  • an instruction read from its corresponding address of the RAM 3 or the like is fetched into the instruction register IR via the internal data bus IDB.
  • the instruction decoder IDEC decodes the instruction fetched into the instruction register IR to generate a control signal in the CPU 2 , thereby controlling arithmetic processing done by the execution section.
  • the instruction sequence logic INTL performs control for changing an instruction execution sequence in response to the interrupt signal IRQ or the like.
  • the flash memory module 5 includes a memory cell array 20 , an X decoder.driver (XDE.DV) 21 , a sense amplifier array (SAA) 22 , a Y switch array (YSW) 23 , a Y decoder (YDE) 24 , an input/output circuit (IFB) 25 , a power circuit or voltage generator (VGN) 26 , and a timing generator (TGN) 27 .
  • the memory cell array 20 has flash memory cells (not shown) disposed in matrix form.
  • each of the flash memory cell includes a source and a drain on a semiconductor substrate or a well region and has a stacked structure formed with a floating gate and a control gate above a channel with an insulating film interposed therebetween.
  • Each of the flash memory cells is configured such that the source is electrically connected to its corresponding source line, the drain is electrically connected to its corresponding bit line and the control gate is electrically connected to its corresponding word line.
  • Each of the flash memory cells has a threshold voltage made programmable and holds information according to the programmed threshold voltage.
  • a relatively high threshold voltage state is called a program state whereas a relatively low threshold voltage state is called an erase state.
  • a program operation for acquiring the program state is not restricted in particular, 10V is applied to the control gate, 5V, for example, is applied to the drain, and 0V, for example, is applied to the source and the substrate to allow a current to flow between the drain and source, whereby the injection of hot electrons occurs.
  • 5V for example
  • 0V for example
  • an erase operation for acquiring the erase state is not restricted in particular, 10V is applied to the control gate, ⁇ 10V, for example, is applied to the source and the substrate, and the drain is rendered open (floating), for example, to thereby emit electrons stored in the floating gate into the substrate, whereby the threshold voltage of the memory cell is lowered.
  • the input/output circuit 25 inputs addresses, control signals and commands among the buses IAB, IDB, PAB, PDB and CONT and performs the input/output of data. Address signals inputted to the input/output circuit 25 are inputted to the XDEC.DV 21 and YDE 24 , where they are respectively decoded.
  • the XDEC.DV 21 selects a corresponding word line according to the result of decoding thereof.
  • the YDE 24 selects a corresponding bit line through the YSW 23 according to the result of decoding thereof.
  • the corresponding flash memory cell is selected according to the word-line selection and the bit-line selection.
  • Programming.program inhibition is controlled according to the latched data with respect to each memory cell subjected to the word-line selection. Prior to program processing, erasure is effected on each flash memory cell in block units before the program processing.
  • the power circuit 26 has a clamp circuit, a charge pump circuit, etc. and supplies various voltages used for operations such as programming, erase, reading effected on the flash memory.
  • the timing generator 27 performs controls for interface with the outside of the flash memory, based on a strobe signal supplied via the control bus CONT and commands inputted via the data buses PDB and IDB.
  • the flash control module 6 includes program transfer related various registers 30 for effecting programming and erasing on the flash memory module 5 , and a control logic circuit 29 .
  • An FCCS, an FKEY, FMATS, a writer mode related register, and a program/erase related register are typically illustrated in FIG. 1 as control registers.
  • a storage area of the RAM 3 and the general purpose registers of the CPU 2 are also available for the control of the program/erase operations on the flash memory module 5 .
  • the memory cell array 20 of the flash memory module 5 includes an electrically erasable and programmable boot mat (first area) Tmat, a user boot mat (second area) Umat, a user mat (third area) Mmat, and a repair and trimming mat Rmat.
  • the boot mat Tmat, the user boot mat Umat and the user mat Mmat are respectively assigned memory spaces with a 0 address (H′ 0000000) indicative of a leading or start address in an address space of the CPU 2 as a start address.
  • the boot mat Tmat, the user boot mat Umat and the user mat Mmat are configured so that their address spaces overlap each other.
  • the address decoder YDEC and XDEC.DV select address decode logic in response to an instruction indicative of which mat should be utilized. Which mat should be used, depends on the operation modes or the like of the microcomputer, which is instructed by the mode signal 14 .
  • the repair and trimming mat Rmat stores therein defect relief addresses in the memory cell array, and setting data for a trimming circuit for carrying out an alignment fit corresponding to each circuit characteristic.
  • the microcomputer 1 has a writer mode, a boot mode (first mode), a user boot mode (second mode) and a user mode (third mode).
  • the mode signal 14 is of two bits, and the system controller 15 decodes a combination of its logical values and judges whether the specified operation mode corresponds to any of the writer mode, the boot mode, the user boot mode and the user mode.
  • the writer mode is an operation mode which enables the execution of the erase/programming for the flash memory 13 by use of a programming device like an EPROM writer.
  • the CPU 2 effects vector fetch from a leading or start address of the boot mat Tmat after reset processing and starts execution of a program (start up from the boot mat). Further, the CPU 2 transfers all of a command decision program and erase/program related programs to the RAM 3 . Thereafter, the CPU 2 proceeds to the execution of the programs transferred to the RAM 3 , and the flash memory 13 is capable of performing erase/programming by the EPROM writer.
  • the writer mode is suitable for storing an arbitrary user control program or the like into the user mat Mmat and user boot mat Umat off board (in a state in which the microcomputer is not implemented or mounted on a system board).
  • the boot mode is an operation mode which is capable of effecting erasing on all of the mats Tmat, Umat and Mmat and enables execution of programming through the use of the SCI 12 .
  • the boot mode allows the CPU 2 to process the program of the boot mat Tmat and disables the CPU 2 to effect erase and programming on the boot mat Tmat. Described specifically, when the boot mode is specified, the CPU 2 effects vector fetch from a start or leading address of the boot mat Tmat after reset processing and starts execution of a program. Further, the CPU 2 transfers the erase/program related program and the command decision program in the boot mat Tmat to the RAM 3 as a process necessary for the boot mode.
  • the CPU 2 proceeds to the execution of the programs on the RAM 3 .
  • the command decision program is started up and programming is enabled through the use of the SCI 12 .
  • the boot mode is suitable for storing an arbitrary user control program, etc. into the user mat Mmat and user boot mat Umat at an on-board equipped with a serial communication interface.
  • the user boot mode is an operation mode which allows the CPU 2 to process the corresponding program of the user boot mat Umat to thereby enable execution of erase and programming using a user-based interface, and disables erasure and programming for the boot mat Tmat and user boot mat Umat. Described specifically, the user boot mode starts from the boot mat Tmat. The CPU 2 executes the program lying within the boot mat Tmat and transfers a user boot mat change program to the RAM 3 . Afterwards, the CPU 2 is shifted to the execution of the corresponding program on the RAM 3 .
  • the mat on the flash memory 13 as seen in the address space of the CPU 2 is changed from a default user mat Mmat to a user boot mat Umat and jumped over to its area after the vector address of the user boot mat Umat has been read.
  • a jump is carried out after the erasing of the user mat Mmat has been carried out.
  • a necessary erase/programming program is downloaded from the boot mat Tmat to the RAM 3 through the use of an SCO mode to be described later. Thereafter, the erase/program control program is used to effect programming on the user mat Mmat.
  • a user-dedicated interface program is prepared for the user boot mat Umat, and program data transfer matched with a mounting board of a user can be implemented.
  • the user boot mode is suitable for writing a user control program or the like into the user mat Mmat through the use of an onboard interface included in the system board of the user.
  • the erasure of the user boot mat Umat is inhibited in this operation.
  • the user mode is an operation mode which enables execution of erasure and programming through the use of the corresponding program held in the user mat Mmat and disables erasure and programming for the boot mat Tmat and user boot mat Umat. Described in details, the CPU 2 is started up from the user mat Mmat to execute the program on the user mat Mmat. Particularly when an SCO bit to be described later is enabled when required by a user, the boot mat Tmat and the user mat Mmat are automatically switched, so that the program is started from a given address on the boot mat Tmat, whereby the erase/program control program on the boot mat Tmat is transferred to the RAM 3 .
  • the user mat Mmat and the boot mat Tmat are automatically switched to provide a return to user's processing.
  • the erase/program control program is utilized according to the user program, thereby enabling erasure and programming with respect tot the user mat Mmat.
  • the erase/program control program on the boot mat Tmat is transferred onto the RAM 3 through the use of an SCO mode to be described later, thereby enabling the utilization of such a program.
  • the user mode is suitable for reprogramming parameters on the user mat Mmat on board during the execution of the user control program.
  • FIGS. 4 (A) and 4 (B) Access forms based on the respective operation modes of the respective mats are illustrated in FIGS. 4 (A) and 4 (B).
  • the access forms shown in the same drawing are those obtained by putting in order the access forms described in the above operation modes.
  • the repair and trimming mat Rmat and the boot mat Tmat are disabled for erasure and programming in any operation modes.
  • the user boot mat Umat is enabled for erasure and programming in the user boot mode and the user mode (user program mode) that enable execution of the user control program.
  • the user boot mode is suitable for writing a user control program or the like into the user mat Mmat through the use of an onboard interface included in the system board of the user. Upon this operation, the erasure of the user boot mat Umat is inhibited.
  • the access means a read access
  • symbol ⁇ means that the read access can be carried out according to a program stored in the boot mat and does not means that the read access can be arbitrarily performed according to the user control program.
  • FIG. 5 typically shows the location of a program executed by a CPU and operation based on its execution.
  • the illustration of the CPU 2 is omitted in FIG. 5.
  • CN 1 virtually shows a control signal group of a result obtained by decoding an erase and program control program or the like transferred from the boot mat Tmat to the RAM 3 with the CPU 2 .
  • CN 2 virtually shows a control signal group of a result obtained by decoding a serial interface control program transferred from the boot mat Tmat to the RAM 3 with the CPU 2 .
  • CN 3 virtually shows a control signal group of a result obtained by decoding a user interface control program of the user boot mat Umat with the CPU 2 .
  • CN 4 virtually shows a control signal group of a result obtained by decoding a user interface control program of the user mat Mmat with the CPU 2 . While the control signals CN 3 and CN 4 are respectively illustrated so as to indicate the results of decoding of the programs fetched directly from the user boot mat Umat and user mat Mmat, they may be results of decoding of programs temporarily transferred to the RAM 3 and fetched therefrom.
  • Sig 1 through Sig 4 mean the result of decoding of a mode signal 14 after the release of reset by the system controller 15 .
  • Sig 1 means a boot mode
  • Sig 2 means a user boot mode
  • Sig 3 means a user mode
  • Sig 4 means a write mode, respectively. While those signals Sig 1 through Sig 4 are actually supplied even to the CPU 2 , the illustration of their states is omitted herein.
  • the flash control module 6 transfers an erase and program control program and a serial communication control program or the like of the boot mat Tmat to the RAM 3 in response to the signal Sig 1 (path P 1 ).
  • program data is brought from a serial interface on board a host device HST 1 to the RAM 3 (path P 2 ).
  • the flash memory 13 is subjected to erasure, and a user control program is programmed into the user boot mat Umat and the user mat Mmat by use of the program data on the RAM 3 (paths P 3 and P 4 ).
  • the flash control module 6 transfers a mat change control program or the like from the boot mat Tmat to the RAM 3 in response to the signal Sig 2 (path P 1 ), so that the boot mat is switched to the user boot mat Umat, where its leading vector is fetched and executed.
  • an erase and programming program is downloaded from the boot mat Tmat to the RAM 3 .
  • program data is brought from a user interface on board a host device HST 2 to the RAM 3 (path P 5 ).
  • the flash memory 13 is subjected to erasure, and a user control program and user data are programmed into the user mat Mmat by use of the program data on the RAM 3 (paths P 3 and P 4 ).
  • the user interface may be mentioned, for example, an ATAPI interface or the like realized by the other interface controller 16 .
  • the user interface control program stored in the user boot mat Umat may be a serial interface control program similar or different from one stored in the boot mat Tmat.
  • the user mode When the user mode is specified by the mode signal 14 , it is transferred to the flash control module 6 in response to the signal Sig 3 .
  • an erase and programming program is downloaded from the boot mat Tmat to the RAM 3 .
  • program data is captured from the user interface on board the host HST 2 to the RAM 3 (path P 5 ).
  • the flash memory 13 is subjected to erasure, and a user control program and user data are programmed into the user mat Mmat by use of the program data on the RAM 3 (paths P 3 and P 4 ).
  • the user interface control program stored in the user mat Mmat may be a serial interface control program similar or different from one stored in the boot mat Tmat.
  • a microcomputer unequipped with a user boot mat Umat and a user boot mode as an example compared with the microcomputer 1 although not illustrated in the drawing in particular. If, in this case, a user interface program stored in the user boot mat Umat is stored in a user mat Mmat, then the microcomputer is capable of programming or reprogramming programs and data into the user mat Mmat via a user interface on board a host device HST 2 in a manner similar to the microcomputer 1 . As is the case in the microcomputer 1 , however, the microcomputer has a possibility that the user interface program stored in the user mat Mmat will be erased from the relationship in which free reprogramming is allowed for the user mat Mmat. If the host device HST 2 is not provided on board with a serial interface available in a boot mode when erased, then the microcomputer according to the comparative example is no longer capable of performing the input/output of information to and from the host device HST 2 .
  • the microcomputer 1 having the operation modes referred to above, the following operations and effects can be obtained.
  • the user boot mat Umat capable of storing therein the user-dedicated communication protocol
  • the arbitrary interface provided in the microcomputer 1 can be diverted to the erasure and programming of the flash memory 13 .
  • the serial interface may not necessarily be prepared for the host device HST 2 .
  • the user boot mat Umat and the user mat Mmat are provided in parts, the user-optional program interface can be realized for the erasure and programming even if the dedicated communication protocol is not programmed into the user mat Mmat.
  • FIG. 6 A logic configuration for protection against erasure and programming of the flash memory 13 is illustrated in FIG. 6 by way of example.
  • the logic shown in the same drawing is defined as positive logic and the configuration thereof is implemented by the flash control module 6 .
  • the operation of effecting erasure and programming on the flash memory is enabled by setting control data necessary for processing to an initial value of a programming/erase related register group 30 A.
  • the setting of the control data to the programming/erase related register group 30 A is enabled when a control bit SWE is of a logical value “1”. In short, unless the control bit SWE is set to the logical value “1”, the erase and programming for the flash memory 13 is disabled.
  • a first condition for setting the control bit SWE to the logical value “1” is to set an enable bit FEW of a register FCCS to the logical value “1 through an external terminal Pfwe.
  • a second condition is to obtain a select state of an operation mode for setting the output of an NAND gate 40 to the logical value “1”, and a mat select state of the flash memory.
  • the test mode is of an operation mode used in a device test by a maker for manufacturing a microcomputer. While all the operations are enabled, such consideration that an operation mode non-open to a user, i.e., a user-based setting is disabled, has been given thereto.
  • the signal UMATSEL is defined as a decision result for a register FMATS and an AA decision circuit 41 with respect to a set value of the register FMATS.
  • the register FMATS is used to perform switching between the user mat Mmat and the user boot mat Umat. Using the register FMATS makes it possible to cause the operation of the CPU 2 to transit from the user mat Mmat to the user boot mat Umat. There are, however, items restricted to the mat change. Namely, a condition under which a user boot mat select bit for the register FMATS can be set, is that the operation of the CPU 2 is executing the program of the RAM 3 . Under this condition, the BSC 4 detects and determines that an address area for instruction fetch made by the CPU 2 is an address area for the RAM 3 .
  • An initial value of the register FMATS is other than H′AA and indicates a user mat select state.
  • the user mat select state is indicated by H′AA.
  • a third condition is that a register FKEY has been set to an erase and programming allowable value.
  • the register FKEY is provided to prevent a runaway of a program due to a voltage drop and noise or the like and the destruction of the program due to it.
  • the register FKEY is used in view of the case in which the program runs away after the erase and program control program (programming/erase program) has been transferred. Even if the CPU 2 gone haywire due to the terminal Pfwe and the control bit SWE, no programming/erase is executed basically. However, in order to further enhance reliability, the user sets the value of “5A” to the register FKEY before the execution of the programming/erase.
  • the register FKEY functions as a program transfer relation as well as functioning as the programming/erase program relation. Namely, in terms of the relationship in which an erase and program control program for a flash memory is stored in its corresponding boot mat Tmat and made available in a user boot mode and a user mode as well as in a boot mode, a control bit SCO is provided for the register FCCS and enabled to transfer the erase and program control program to the RAM 3 . In doing so, the user mat Mmat is automatically changed to the boot mat Tmat so that the erase and program control program is transferred from the boot mat Tmat to the RAM 3 , whereby a return instruction is executed after the completion of the processing to thereby make a return to the processing of the user.
  • the register FKEY is used.
  • the user stores “A5” in the register FKEY before the control bit SCO is set.
  • the control bit SCO cannot be set.
  • the operation of the program on the RAM 3 by the CPU 2 is also defined as a condition.
  • the SCO bit can be set, and the transfer of the erase and program control program from the boot mat Tmat to the RAM 3 is allowed.
  • the register FKEY exclusively controls the transfer and erase/programming of each program. Therefore, when the program runs away in its non-transferred state, it is hard to execute programming/erase.
  • An SCO mode means an operation mode used when erase and programming are effected on the flash memory in a user mode.
  • a boot mode a writer mode, a user boot mode and a user mode, their corresponding mode terminals are set and a reset release may be carried out after their setting.
  • the SCO mode is set by setting the logical value “1” to the control bit SCO during the user mode.
  • Mode information is set to its corresponding mode judge register according to the set operation mode.
  • the CPU 2 executes a program in a boot mat (OP in boot mat).
  • the CPU 2 fetches a vector from a start address in the boot mat to start program execution (S 1 ).
  • S 1 start program execution
  • a process is started from a predetermined address other than the start address in the boot mat, e.g., a user break address corresponding to exception handling highest in priority.
  • the CPU 2 reads the mode judge register (S 2 ) and judges the contents thereof. Further, the CPU 2 executes necessary pre-processes such as the transfer of an ease and program control program, etc. (S 2 through S 5 ) and proceeds to corresponding processes (S 6 through S 9 ).
  • the term of user” shown in each process column of the flowchart means that its process is a process executed based on a program defined by a user.
  • the term of “boot” shown in each process column means that its process is a process executed based on a program in a boot mat Tmat.
  • FIG. 9 A flowchart for describing a writer mode process is illustrated in FIG. 9.
  • the writer mode control program is transferred to the RAM 3 as shown in FIG. 8.
  • a command/data register (CDL) used for erase and programming, and a flag register (FLG) are first cleared, and “1” is set to a command flag (CDF)(S 11 ).
  • Erasing (S 14 and S 15 ) and programming (S 12 and S 13 ) for a user mat Mmat and a user boot mat Umat are executed until a power supply is terminated, according to a command and program data set to the command/data register (CDL) from an EPROM writer while referring to the states of the flag register (FLG) and the command flag (CDF).
  • the writer mode process is defined as operation in the RAM 3 .
  • FIG. 10 A flowchart for describing a boot mode process is illustrated in FIG. 10 by way of example. Transmission and reception between the serial interface and SCI 12 on board are first established (S 20 ). Required parameters such as an oscillated frequency, etc. for the microcomputer 1 are downloaded and set (S 21 ). Next, a command from a host device is decoded and thereby status such as a product name of a microcomputer, the number of erase blocks and etc., are returned to the host device (S 22 ). A command decision program and an erase program are transferred to the RAM 3 (SCO mode is also available), and the boot mode process changes to operation in the RAM 3 (S 23 ).
  • SCO mode is also available
  • a user mat Mmat and a user boot mat Umat are subjected to full erasure (S 24 ) and thereafter a user mat program process (S 25 ), a user boot mat program process (S 26 ), a program verify process (S 27 , S 28 ), etc. are executed in response to the command.
  • FIG. 11 A flowchart for describing a user boot mode process is illustrated in FIG. 11 by way of example. Although not restricted in particular in the user boot mode, operation is started from a start vector in s boot mat Tmat. A change program to a user boot mat Umat is transferred from the boot mat Tmat to the RAM 3 (S 30 ). A change to operation in the RAM 3 is made (S 31 ). Further, H′AA is set to its corresponding register FMATS, and the specified state (initial value) of user mat by the register FMATS is changed to its corresponding user boot mat (S 32 ). It is now judged whether an error exists in area settings of the user boot mat Umat (S 33 , S 34 ).
  • a start vector address of the user boot mat Umat is read (S 35 ), and a subroutine is jumped to the read vector address (S 36 ).
  • the CPU 2 executes a program on the user boot mat Umat to thereby firstly establish user defined communications, and transfers a user program required for programming to the RAM 3 (S 37 ).
  • the CPU 2 changes to execution of the program on the RAM 3 (S 38 ) and performs the operation of the register FMATS again. Thereafter, the CPU 2 changes a mat to be processed from the user boot mat Umat to a user mat Mmat (S 39 ).
  • the CPU 2 executes a user program on the RAM 3 to thereby set a control bit SCO to “1” (S 40 ) and proceeds to an SCO mode process, where it transfers an erase and program control program in the boot mat Tmat to the RAM 3 (S 41 ), whereby a program/erase process using the transferred erase and program control program is executed (S 42 ).
  • FIG. 12 A flowchart for describing a user mode process is illustrated in FIG. 12 by way of example.
  • a vector fetch is made from the start of a user mat Mmat (S 50 ) and a user control program is executed (S 51 ).
  • the CPU 2 performs operation in the RAM 3 to set an SCO bit to “1” (S 52 ) and proceeds to the SCO mode process, thereby transferring an erase and program control program in the boot mat to the RAM 3 (S 53 ), whereby a program/erase process using the transferred erase and program control program is performed (S 54 ).
  • Steps S 60 through S 63 correspond to a program/erase initialization process.
  • an erase and program control program has been stored in a boot mat Tmat in advance by a maker for the microcomputer 1 .
  • the program does not define a condition inherent in a user.
  • the time required to apply each of an erase voltage pulse and a program voltage pulse is determined according to the characteristic of a flash memory cell. It is however necessary to control the pulse applying time by an operation clock signal for the microcomputer 1 .
  • Data about an operation frequency necessary therefor is set to a control register FPEFEQ (S 60 ).
  • the general purpose register R 4 for the CPU 2 is assigned to the control register FPEFEQ.
  • the erase voltage pulse, the program voltage pulse, and a branch-destination processing address for a user branch process are set to a register FUBRA (S 61 ).
  • a control bit FWE is set to a logical value “1” via a terminal Pfwe to release erase/programming hardware hard protection. Consequently, the hard protection is released and a change to execution of a user program is performed (S 64 ).
  • Programming data is prepared in this operation state (S 65 ), and programming/erase that a user desires to perform, is executed (S 66 ). The processes in Steps S 65 and S 66 are repeated until the user-purposed process is completed.
  • FIG. 14 is a schematic flowchart in which attention has been given to the program process of FIG. 13.
  • the program process is roughly divided into a process (T 1 ) for transferring a source code (erase and program control program or the like) from a boot mat Tmat to the RAM 3 , execution of the initialization of programming (T 2 ) and execution of programming (T 3 ).
  • the transfer process (T 1 ) selects a program to be transferred, sets the register FKEY and enables the control bit SCO. By executing it, the transfer program is automatically started form its corresponding boot mat. The program is to be transferred to a required region alone from the start address of the RAM 3 . At this time, an initialization program is also transferred.
  • the initialization program Upon the execution of the initialization (T 2 ), the initialization program is executed, and the setting of the number of wait time loops depending on an operation frequency and a user branch address are set to the transferred program.
  • T 3 Upon the execution of programming (T 3 ), programming data is transferred onto the RAM 3 before the execution of programming although it may be any mode. At this time, it is necessary to align data in a given determined sequence. A user is able to arbitrarily set a transfer area. After a required procedure has been executed and the transfer of the program data has been performed, a subroutine is jumped to a certain determined address of the program. Programming is executed by execution of such a subroutine jump.
  • the register FKEY is first set to “A5” (T 10 ) and a source code to be transferred is selected (T 11 ).
  • the selection of the source code is effected on the programming/erase related register 30 A.
  • selectable source codes may include a program and program verify program, an erase and erase verify program, etc.
  • the control bit SCO is set to “1” and the selected source code is transferred to a predetermined area of the RAM 3 (T 12 ). When the control bit SCO is enabled, the CPU 2 needs to have operation being in execution outside the flash memory 13 .
  • T 2 Details on the programming initialization process (T 2 ) are illustrated in FIG. 16 by way of example.
  • An operation frequency of the microcomputer 1 is firstly set to the register FPEFEQ (R 4 ) (T 20 ), and a user branch address is set to the register FUBRA.
  • the general purpose register R 5 of the CPU 2 is assigned to the register FUBRA.
  • a programming initialization program is executed (T 22 ).
  • a program related initialization program refers to the set value of chip operation frequency and decides the number of wait time loops.
  • a process for embedding the decided wait time interval into the program control program transferred onto the RAM 3 is executed.
  • the programming initialization program executes a user branch by referring to the value of the register FUBRA (R 5 ).
  • the register FUBRA is a register for specifying the user branch address in the course of program/erase. This area exists in the general purpose register R 5 .
  • H′ 00000000 is set to the present register.
  • FIG. 18 Data connection relations among the built-in RAM 3 , programming program, initialization process, and registers R 4 and R 5 at the programming initialization of FIG. 16 are illustrated in FIG. 18. It is apparent from the same drawing that an initialization program refers to the registers R 4 and R 5 , reflects the result of referring on a user branch process of the programming program and reflects it on wait related parameters.
  • T 3 Details on the execution of programming (T 3 ) are illustrated in FIG. 17 by way of example.
  • a vector base register may be changed so as to be set to the address area of the RAM 3 . This is because a flash memory area being in the course of programming may preferably be avoided or kept off in terms of the prevention of a malfunction.
  • Such an NMI may be utilized to call an error processing routine defined by a user.
  • An interrupt lower in interrupt priority level than the NMI is masked (T 31 ).
  • An interrupt priority level low next to an NMI of interrupt mask data IMSK may be set to the status register SR, for example.
  • an area for setting a write address is set to the general purpose register R 5 (T 32 ). Namely, a start address in a write address area, which has been written in the built-in RAM 3 , is set to the general purpose register R 5 .
  • a setting area for an address of write data is set to the general purpose register R 4 (T 33 ). Namely, a start address in a write data address area, which has been written into the built-in RAM 3 , is set to the general purpose register R 4 .
  • a program/erase code “5A” is set to its corresponding register FKEY (T 34 ), and a subroutine is jumped to a programming program, whereby programming is executed (T 35 ). Finally, a judgement is made whether programming was completed normally (T 36 ).
  • RAM areas FMPDR 0 and FMPDR 1 can be referred to by the register R 4
  • RAM areas FMPAR 0 and FMPAR 1 can be referred to by the register R 5 .
  • FIG. 20 A process flow for describing a programming program corresponding to Step S 35 of FIG. 17 is illustrated in FIG. 20 by way of example.
  • This process flow includes a step (T 53 ) for judging whether a subroutine is jumped to a user branch address during processing cycles of programming data latch (T 50 ), the application of a programming pulse (T 51 ), and programming verify (T 52 ).
  • T 53 a step for judging whether a subroutine is jumped to a user branch address during processing cycles of programming data latch (T 50 ), the application of a programming pulse (T 51 ), and programming verify (T 52 ).
  • the programming program branches to the user branch address, where the subroutine is executed (T 54 ). After its execution, it returns to a programming operation routine again.
  • the control can be returned to the user control program at certain predetermined intervals even during programming.
  • the intervals at which the control is returned to the user control program may be changed by software. Owing to the returning of the control to the user control program at the predetermined intervals even during the programming, erase and programming can be executed even without deactivating the system using the microcomputer 1 for a long time. Thus, erase and programming can be effected on a system which needs to confirm internal and external events every predetermined intervals or a system with a learning function, or the like during the execution of a user program.
  • FIG. 21 is a schematic flowchart in which attention is given to an erase process.
  • the erase process is roughly divided into a process for transferring a source code (erase and program control program or the like) from a boot mat to the RAM 3 (T 5 ), execution of erase initialization (T 6 ) and execution of an erase (T 7 ).
  • the transfer process (T 5 ) is identical to the transfer process (T 1 ).
  • an initialization program is executed for a transferred program for purposes of the setting of the number of wait time loops and the setting of a user branch depending on an operation frequency.
  • the erase Upon the execution of the erase (T 7 ), the erase is executed by jumping a subroutine to a certain fixed address of an erase program transferred to the RAM 3 .
  • FIG. 22 Details on the erase initialization process (T 6 ) are illustrated in FIG. 22 by way of example.
  • An operation frequency of the microcomputer 1 is first set to the register FPEFEQ (R 4 ) T 60 ).
  • a user branch address is set to the register FUBRA (T 61 ).
  • the general purpose register R 5 of the CPU 2 is assigned to the register FUBRA.
  • an erase initialization program is executed (T 62 ). In an erase program at its transfer, the number of wait loops is placed in an initially-set state. From this viewpoint, this initialization program is used to thereby change all the numbers of wait loops for the erase program.
  • a user sets the register FPEFEQ (R 4 ).
  • the erase initialization program refers to the set value of the register FUBRA to thereby execute an erase program change as to whether the user branch should be executed or to which address it jumps upon its execution.
  • the user sets a value to the register FUBRA to execute such a change.
  • a judgement is made as to whether the initialization process was completed normally (T 63 ), and the present process is terminated.
  • FIG. 24 Data connection relations among the built-in RAM 3 , erase program, initialization process and registers R 4 and R 5 at the erase initialization of FIG. 22 are illustrated in FIG. 24. It is apparent from the same drawing that an initialization program refers to the registers R 4 and R 5 , reflects the result of referring on a user branch process of the programming program and reflects it on wait related parameters.
  • NMI non-maskable interrupt
  • a vector base register may be changed so as to be set to the address area of the RAM 3 . This is because a flash memory area being in the course of erasing may preferably be avoided or kept off in terms of the prevention of a malfunction.
  • Such an NMI may be utilized to call an error processing routine defined by a user.
  • An interrupt lower in interrupt priority level than the NMI is masked (T 71 ).
  • An interrupt priority level low next to an NMI of interrupt mask data IMSK may be set to the status register SR, for example. This means that a high voltage is being applied to a flash memory according to the state during the erasing. Even if an interrupt such as IRQ or the like is taken in this condition, it is not possible to assure that a vector of the flash memory can be read. Thus, interrupts except for the NMI are inhibited during the erasing.
  • an erase block number is set to the general purpose register R 4 (T 72 ).
  • a program/erase code “5A” is set to the register FKEY (T 73 ), and a subroutine is jumped to an erase program (T 74 ). It is finally judged whether the erase was completed normally (T 75 ).
  • connection relations among the RAM 3 , general purpose registers R 4 and R 5 and erase program at erasing are illustrated in FIG. 25 by way of example. Since the user does not create the erase program, such connection relations are used as an interface method for erase mat selection, i.e., the delivery of the erase block selection is executed by delivering an erase block number via the register FEBS (R 4 ).
  • a process flow for describing an erase program corresponding to Step T 74 of FIG. 23 is illustrated in FIG. 26 by way of example.
  • This process flow includes a step (T 83 ) for judging whether a subroutine is jumped to a user branch address during processing cycles of erase data latch (T 80 ), the application of an erase pulse (T 58 ), and erase verify (T 82 ).
  • T 83 When instructions for a subroutine jump is made (when the user branch address is except for H′ 00000000) according to a set value based on an initialization process, the erase program branches into the user branch address, where the subroutine is executed (T 84 ). After its execution, it returns to an erase operation routine again.
  • the erase program is capable of branching to the subroutine process indicated by the user branch address during the cycles of the application of the erase pulse and the erase verify, then the control can be returned to the user control program at certain predetermined intervals even during erasing. Owing to the returning of the control to the user control program at the predetermined intervals even during the erase, the erase can be executed even without deactivating the system using the microcomputer 1 for a long time. Thus, erase and programming can be effected on a system which needs to confirm internal and external events every predetermined intervals or a system with a learning function, or the like during the execution of a user program.
  • FIG. 27 A program/erase processing method capable of inhibiting the situation that the CPU 2 runs away at a user branch destination and thereby the information stored in the flash memory 13 is destroyed, is illustrated in FIG. 27. Namely, according to the user branch process corresponding to each of Steps T 44 and T 84 , which is executed for each process termination during the program/erase flow, an operating power supply for programming/erase is initialized to make a change to an operating power supply for a read operation ( 90 ).
  • a code set to the register FKEY is set as a code meaningful to processing, e.g., a code indicative of the progress of erase/program in the process of Step T 91 .
  • a malfunction or failure can be detected by reference to the value of the register FKEY where the routine procedure is returned from the program/erase processing routine in a program/erase non-completed state or where the value of the register FKEY is changed to a value other than an expected value due to a runaway or the like.
  • a code meaningful to processing e.g., a code indicative of the progress of erase/program in the process of Step T 91
  • FKEY may not be used as the register, which holds the work progress.
  • the utilization of the register FKEY is economical for both aspects of a hardware resource and a process load.
  • an erasable and programmable non-volatile memory is not limited to a binary flash memory. It may be a multi-valued flash memory, e.g., a multi-valued flash memory capable of allowing one flash memory to hold stored information of 2 bits or more.
  • one flash memory cell is a memory in which information stored in one flash memory cell is represented in plural bits, which memory is set to one of four types or more of threshold voltages specified by programming data of plural bits upon information storage and outputs the state of the threshold voltage as its corresponding stored information of plural bits upon information reading.
  • a flash memory capable of writing 2-bit information into one flash memory cell and reading the information is illustrated as one example herein.
  • an information stored state of one memory cell is set to one selected from, for example, an erase state (“11”), a first program state (“10”), a second program state (“00”), and a third program state (“01”).
  • the information stored states of four types in total are defined as states determined according to 2-bit data. Namely, one memory cell stores 2-bit data therein.
  • the flash memory cell is not limited to a vertical stacked structure of a floating gate and a control gate.
  • a gate electrode of a MOS transistor is formed as a floating gate electrode, and a channel region is used as a control gate via a MOS gate capacitance formed by allowing the gate electrode to extend, may be adopted.
  • the non-volatile storage element is not limited to the flash memory. It may be a non-volatile memory like an EEPROM (Electrically Erasable and Programmable Read Only Memory) in which MNOS (Metal Nitride Oxide Semiconductor) transistors are formed as storage elements, or a ferroelectric memory or the like.
  • a circuit module included in a microcomputer on an on-chip basis is not limited to the above example. It may be suitably changed.
  • the various register means may be peripheral registers each with a built-in flash memory, general purpose registers each having a CPU built therein, or memory mapped I/O registers each comprising a memory such as an SRAM or the like.
  • the user branch has been described as the case in which the initialization process for reprogramming the jump-destined code for the jump subroutine instruction in advance is carried out based on the set value of the register FUBRA (R 5 ) and thereafter its program is executed.
  • the register FUBRA (R 5 ) may be allowed to branch by being directly referred to by the jump subroutine instruction.
  • a compiler for its erase and program control program must be able to refer to the general purpose register R 5 within a limited range of the number of general purpose registers available as an argument within one function.
  • a program jumped to a subroutine corresponding to an address specified by a user is programmed in advance during a loop of the application of a high voltage pulse and data verify or the like. If a user passes a jump-destined address as an argument upon execution of a program, for example, then the address can be referred to by a jump subroutine instruction. Therefore, control can be returned to a user control program at certain predetermined intervals even during erase/programming for a non-volatile memory. Thus, erase/programming for an on-chip non-volatile memory can be carried out as necessary during its process even in the case of a system, which needs to respond to events developed at intervals each shorter than an erase/program process time.

Abstract

The present invention provides a microcomputer wherein in a system which needs to respond to events developed at intervals each shorter than an erase/program process time, erase/programming can be effected on an on-chip non-volatile memory as necessary during its processing. An erase and program control program for an electrically erasable and programmable non-volatile memory is configured inclusive of a loop of the application of a high voltage pulse and data verify or the like, for example. If a program jumped to a subroutine for an address specified by a user is programmed in advance during this loop, then a process by a CPU can be temporarily jumped to the subroutine for the user defined address. Thus, erase and programming can be effected on a system which needs to confirm internal and external events every predetermined intervals or a system with a learning function, or the like during the execution of a user program.

Description

    BACKGROUND OF THE INVENTION
  • The present invention relates to a microcomputer having an electrically erasable and programmable non-volatile memory and a CPU (Central Processing Unit), and particularly to erase and program control on the non-volatile memory, e.g., a technology effective for application to a one-chip microcomputer having a flash memory. [0001]
  • An electrically erasable and programmable non-volatile memory such as a flash memory or the like stores information therein according to the difference between threshold voltages programmed to memory cells. In the flash memory, the difference between the threshold voltages is realized by the difference between the amounts of electrons or positive holes held by a floating gate. For example, a state of a threshold voltage high relatively with respect to a threshold voltage in a thermal equilibrium state is referred to as a program state, and a state of a threshold voltage low relatively therewith is called an erase state (the definition of the inverse is allowed). At this time, respective operations for erasing for bringing each memory cell into the erase state and programming for bringing each memory cell into the program state need to repeatedly perform the application of a high voltage pulse and verify of a threshold voltage state based on it. [0002]
  • A microcomputer with a flash memory being on-chipped includes a writer mode and a boot mode as operations modes for enabling the on-chip flash memory to execute erase and programming. The writer mode is an operation mode for making the microcomputer equivalent to a flash memory chip apparently and connecting it to a programming or writing device like an EPROM writer to thereby make it possible to carry out erasing and programming. The boot mode is an operation mode for establishing communications with a packaging system via a serial interface such as step synchronism or the like in a state of the microcomputer being packaged in a system to thereby make it possible to carry out erasing and programming. When a program and data are initially written into the on-chip flash memory before the system packaging, the writer mode is available. However, the reprogramming of information stored in an on-chip flash memory for upgrading a program and tuning data after the system packaging needs to utilize the boot mode. It is also possible to perform erasing and programming on board according to the execution of a user control program stored in a user area of a flash memory. [0003]
  • Incidentally, Unexamined Patent Publication No. Hei 5(1993)-266219 is known as an example of a reference in which the microcomputer equipped with the flash memory has been described. [0004]
  • SUMMARY OF THE INVENTION
  • In a flash memory on-chip type microcomputer which has heretofore been used, no control was returned to a user program until the completion of erasing and programming where a CPU was activated to effect erasing and programming on an on-chip flash memory. [0005]
  • However, according to discussions of the present inventors, assuming that the erase/program process for the flash memory takes at least 10 msecs, the CPU must control the erase/program process during that time. Further, it is not possible to allow the CPU to execute other processes. Therefore, the present inventors have found out that a system that needs to confirm the state of a terminal located per 1 msec, is not able to perform an erase/program process during execution of a user control program. In short, it has been found out by the present inventors that a system requiring a response to events developed at intervals shorter than an erase/program processing time also has the need for enabling erase/programming on a flash memory as necessary during its process. Incidentally, the terms of a user employed in the present specification means one utilizing a semiconductor device such as a microcomputer or the like in a broad sense. Thus, if a maker for manufacturing the semiconductor device makes use of the semiconductor device in one way or another, then the maker is even a user so far as it is concerned. [0006]
  • An object of the present invention is to provide a microcomputer wherein even in a system that needs to respond to events developed at intervals shorter than an erase/program process time, erase/programming can be effected on an on-chip non-volatile memory as necessary during a process thereof. [0007]
  • Another object of the present invention is to provide a programming method for allowing a central processing unit to execute a process other than a process for writing data and information into an electrically programmable non-volatile memory in the course of the process in a microcomputer having the central processing unit and the non-volatile memory. [0008]
  • A further object of the present invention is to provide an erasing method for allowing a central processing unit to execute a process other than a process for erasing data and information in an electrically erasable non-volatile memory in the course of the erasing process in a microcomputer having the central processing unit and the non-volatile memory. [0009]
  • The above, other objects and novel features of the present invention will become apparent from the description of the present specification and the accompanying drawings. [0010]
  • Summaries of typical ones of the inventions disclosed in the present application will be described in brief as follows: [0011]
  • [1] An erase and program control program for an electrically erasable and programmable non-volatile memory is set up inclusive of loops such as the application of a high voltage pulse and data verify or the like. If a program jumped to a subroutine for an address specified by a user is programmed into the loops in advance, it is then able to jump to a user branch, i.e., the subroutine at the address specified by the user. If a return instruction from the subroutine is executed after the execution of the subroutine, then the program returns to the original process routine. It is therefore possible to continuously carry out an erase and programming process halfway. [0012]
  • The following operations and effects are obtained from the above. (1) The erase and program control program is stored in a boot mat, for example. A branch address (jump-destined address) specified by a user is not described in the program. If the user passes the jump-destined address as an argument when the program is executed, then the program can jump to a desired branch-destined address by referring to the address according to a jump subroutine instruction. Even during programming, control can be returned to a user control program at certain predetermined intervals. Further, since this is executed on a software basis, the intervals at which it is returned to the user's control, can also be changed by software. The jump destination is allowed even if taken in any areas of a built-in RAM or a non-volatile memory free of the execution of erase and programming. (2) Owing to the returning of the control to the user control program at the predetermined intervals even during the erase and programming, the erase and programming can be executed even without long-time deactivation of a system using the microcomputer. Accordingly, the erase and programming can be executed on a system that needs to confirm internal and external events or a system or the like with a learning function every predetermined intervals during execution of a user program. [0013]
  • [2] A microcomputer according to a more detailed aspect of the present invention includes an erasable and programmable non-volatile memory, and a CPU. The CPU is capable of temporarily branching to a process indicated by information set to first register means (FUBRA) for each cycle of a unit process including the application of an erase voltage for an erase operation or a program voltage for a programming operation, and a verify operation, or every plural cycles. The first register means is capable of programmably setting information thereto. The first register means is one of general purpose registers of the CPU, for example. The branching by the set value of the first register means may be, for example, either a method for performing branching by directly referring to the first register means according to a jump subroutine instruction, or a method for pre-executing an initialization process for embedding a jump-destined code into a jump subroutine instruction, based on the set value of the first register means and thereafter executing its program. The former method may be used where a compiler for an erase and program control program thereof is able to refer to the first register means within a limited range of the number of general purpose registers available as an argument within one function. This is because if not so, then the set value of the first register means is stacked and time is taken to execute a procedure for utilizing the corresponding register. In order to avoid it, the latter method may be adopted. When a program argument is passed using an assembler, the easiness of creation of the program is lost. [0014]
  • Even in the case of the microcomputer according to this aspect, the operations and effects described in the paragraphs (1) and (2) can be obtained. [0015]
  • The CPU skips the branching process when the information written into the first register means is a predetermined value. It is also easy to perform control on execution and non-execution of the branch. Further, control for changing a branching interval is also easy. [0016]
  • There is provided second register means (FKEY) readable and writable by the CPU. The non-volatile memory sets the setting of a first set value to the second register means as a necessary condition for enabling erase and programming operations. At this time, the CPU may set a value other than the first set value to the second register means upon the branch and set the first set value to the second register means for each return from the branch. This is done in consideration of a runaway of a program at a user branch destination. Namely, when program enable is taken due to the runaway of the CPU in a transferred state of the erase and program control program, the possibility that the information stored in the flash memory will be destroyed, still remains. In order to reduce the possibility of such undesired destruction even in small quantities, attempt should be taken so as not to meet a necessary condition for taking into consideration the runaway at the user branch destination, and changing the value of the second register means before a user branch executed during an erase and program flow, thereby enabling the erase and programming operations. Even in the event that the CPU runs away owing to the execution of the above, no erase and programming operations are started unless reprogramming of the second register means is done. [0017]
  • The value other than the first set value may be code information indicative of the progress of an erase and program process. In short, the code information corresponding to the progress thereof is added to a user branch between respective process cycles for erase and programming. Thus, when the routine processing is returned from a subroutine by mistake due to the runaway of the CPU or the like, the code information is useful in a check for a malfunction of its operation. [0018]
  • Assuming that no interrupts and exception handling are accepted during the erase and program process, it is not possible to cope with events that need an emergent process. Further, there is a possibility that an unrecoverable abnormal condition will occur in a system. When all the interrupts are accepted in reverse, the efficiency of the erase and program process is considerably degraded. In order to cope with it, the setting of masking an interrupt lower in interrupt priority level than a non-maskable interrupt may preferably be carried out when erase and programming are effected on an interrupt control circuit for inputting an interrupt request signal therein, and performing arbitration of interrupt requests which compete with one another, and an interrupt priority level-based interrupt mask process to thereby output an interrupt signal to the CPU. [0019]
  • When the erase and programming are executed, the CPU may perform a process for changing the location of an interrupt process routine for a non-maskable interrupt request to an address of a RAM. For example, a vector base register is changed to an address in a RAM area or the use of a dedicated vector register is set. This is because since information stored in an area being in the course of the erase and programming is still imperfect in its writing, the execution of a subroutine cannot be assured. [0020]
  • [3] A microcomputer according to another aspect of the present invention includes an erasable and programmable non-volatile memory, and a CPU. The non-volatile memory has an erase and program control program executed by the CPU and used for erase/program-controlling the non-volatile memory. The erase and program control program allows a process of the CPU to temporarily branch to another branch for each cycle of a unit process including the application of an erase voltage for an erase operation or a program voltage for a programming operation and a verify operation, or every plural cycles. The CPU specifies another process referred to above according to a value set to first register means (FUBPA). [0021]
  • Let's consider an aspect intended to realize a user branch by embedding a branch-destined address into a jump subroutine instruction for the erase and program control program in the above. Attention is given to a change in program code (embedding of branch-destined address). In this case, a RAM is placed in an address space of the CPU, and the non-volatile memory is caused to hold a transfer control program for transferring the erase and program control program to the RAM. Further, the CPU may embed a parameter (branch-destined address) to the branchable other process into the erase and program control program transferred to the RAM to thereby execute the erase and program control program. [0022]
  • [4] A further aspect of the present invention is particularly based on the assumption that attention is paid to a program or write loop and a program time is longer than an erase time. A microcomputer according to this viewpoint includes a non-volatile memory including a plurality of electrically programmable memory cells, and a central processing unit capable of executing a program control program with respect to the non-volatile memory. The central processing unit is capable of temporarily branching to a process for a first control program different from the program control program during the execution of the program control program. [0023]
  • For example, when information is written into the specified memory cell of the electrically programmable plural memory cells, the program control program defines a process for executing a plurality of times of program process loops and writing the corresponding information into the specified memory cell. The process of the central processing unit is capable of branching to the first control program for each program process loop referred to above. [0024]
  • Described more specifically, the microcomputer further includes a first memory circuit (FUBRA) programmable by the central processing unit. When the first memory circuit is set to a first set value by the central processing unit, the process of the central processing unit continuously executes the program control program. When the first memory circuit is set to a second set value different from the first set value by the central processing unit, the process of the central processing unit is branched to the first control program for each program process loop referred to above. [0025]
  • [5] A still further aspect of the present invention is particularly based on the assumption that attention is given to an erase loop and an erase time is longer than a program time. A microcomputer according to this viewpoint includes a non-volatile memory including a plurality of electrically erasable memory cells, and a central processing unit capable of executing an erase control program with respect to the non-volatile memory. The central processing unit is capable of temporarily branching to a process for a first control program different from the erase control program during the execution of the erase control program. [0026]
  • For example, when information is erased from the specified memory cell of the electrically erasable plural memory cells, the erase control program defines a process for executing a plurality of times of erase process loops and thereby erasing the corresponding information for the specified memory cell. The process of the central processing unit is capable of branching to the first control program for each erase process loop referred to above. [0027]
  • Described more specifically, the microcomputer further includes a first memory circuit (FUBRA) programmable by the central processing unit. When the first memory circuit is set to a first set value by the central processing unit, the process of the central processing unit continuously executes the erase control program. When the first memory circuit is set to a second set value different from the first set value by the central processing unit, the process of the central processing unit is branched to the first control program for each erase process loop referred to above. [0028]
  • [6] A still further aspect of the present invention pays attention to a programming method. Namely, a programming method for causing a central processing unit included in a microcomputer having the central processing unit and an electrically programmable non-volatile memory to execute a program control program to thereby write information into the non-volatile memory includes a first step for supplying an address for a memory cell to be programmed in the non-volatile memory, a second step for supplying information to be programmed to the memory cell, and a third step for repeatedly writing the data to be programmed into the memory cell. The third step includes a voltage applying step for applying a program voltage to the memory cell, a verify step for confirming whether the data to be programmed has been written into the memory cell, a step for referring to a value of a predetermined register and transitioning a process of the central processing unit to a predetermined process corresponding to a predetermined value set to the register when the predetermined value is stored in the register, and a step for returning the process of the central processing unit from the predetermined process to the third step. [0029]
  • A still further aspect of the present invention pays attention to an erasing method. Namely, an erasing method for causing a central processing unit included in a microcomputer having the central processing unit and an electrically erasable non-volatile memory to execute an erase program to thereby erase information stored in a predetermined memory cell of the non-volatile memory includes a first step for supplying an address for a memory cell to be erased in the non-volatile memory, and a second step for erasing the information from the memory cell. The second step includes a voltage applying step for applying an erase voltage to the memory cell, a verify step for confirming whether the information has been erased from the memory cell, a step for referring to a value of a predetermined register and transitioning a process of the central processing unit to a predetermined process corresponding to a predetermined value set to the register when the predetermined value is stored in the register, and a step for returning the process of the central processing unit from the predetermined process to the second step. [0030]
  • A still further aspect of the present invention pays attentions to an on-board programming method. Namely, a programming method for mounting a microcomputer having a central processing unit and an electrically programmable non-volatile memory to a substrate and thereafter causing the central processing unit to execute a program control program to thereby write information into a predetermined memory cell of the non-volatile memory includes a first step for supplying an address for a memory cell to be programmed in the non-volatile memory, a second step for supplying information to be programmed to the memory cell, and a third step for repeatedly writing the data to be programmed into the memory cell. The third step includes a voltage applying step for applying a program voltage to the memory cell, a verify step for confirming whether the data to be programmed has been written into the memory cell, a step for causing the process of the central processing unit to transit to a predetermined process, and a step for returning the process of the central processing unit from the predetermined process to the third step. [0031]
  • A still further aspect of the present invention pays attention to an on-board erasing method. Namely, an erasing method for mounting a microcomputer having a central processing unit and an electrically erasable non-volatile memory to a substrate and thereafter causing the central processing unit to execute an erase program to thereby erase information stored in a predetermined memory cell of the non-volatile memory includes a first step for supplying an address for a memory cell to be erased in the non-volatile memory, and a second step for erasing the information from the memory cell. The second step includes a voltage applying step for applying an erase voltage to the memory cell, a verify step for confirming whether the information has been erased from the memory cell, a step for causing the process of the central processing unit to transit to a predetermined process, and a step for returning the process of the central processing unit from the predetermined process to the second step. [0032]
  • According to these methods, on the way to a process for writing or erasing data and information into or from an electrically programmable non-volatile memory in a microcomputer having a central processing unit and the electrically programmable non-volatile memory, the central processing unit is allowed to execute a process other than the writing or programming process.[0033]
  • BRIEF DESCRIPTION OF THE DRAWINGS
  • While the specification concludes with claims particularly pointing out and distinctly claiming the subject matter which is regarded as the invention, it is believed that the invention, the objects and features of the invention and further objects, features and advantages thereof will be better understood from the following description taken in connection with the accompanying drawings in which: [0034]
  • FIG. 1 is a block diagram of a microcomputer according to one embodiment of the present invention; [0035]
  • FIG. 2 is a block diagram showing a specific example of a CPU[0036] 2;
  • FIG. 3 is an explanatory diagram illustrating a memory mat of a flash memory by way of example; [0037]
  • FIG. 4 is an explanatory diagram illustrating by an example, access forms in respective operation modes set every memory mats of the flash memory; [0038]
  • FIG. 5 is an explanatory diagram typically showing locations of programs executed by a CPU and operations made by their execution; [0039]
  • FIG. 6 is a logic circuit diagram illustrating by an example, a logic configuration for erase and program protection of the flash memory; [0040]
  • FIG. 7 is a state transition diagram at the time that CPU's operations are switched between a user mat and a user boot mat; [0041]
  • FIG. 8 is a flowchart for describing a program mode determining process; [0042]
  • FIG. 9 is a flowchart for describing a writer mode process; [0043]
  • FIG. 10 is a flowchart for describing a boot mode process; [0044]
  • FIG. 11 is a flowchart for describing a user boot mode process; [0045]
  • FIG. 12 is a flowchart for describing a user mode process; [0046]
  • FIG. 13 is a flowchart for describing program/erase processes in Step S[0047] 42 of FIG. 11 and Step S54 of FIG. 12;
  • FIG. 14 is a schematic flowchart which focuses attention on a program process of FIG. 13; [0048]
  • FIG. 15 is a flowchart illustrating details on a transfer process (T[0049] 1) to a RAM by way of example;
  • FIG. 16 is a flowchart illustrating by an example, details on a programming initialization process (T[0050] 2);
  • FIG. 17 is a flowchart illustrating by an example, details on a program execution (T[0051] 3);
  • FIG. 18 is an explanatory diagram illustrating by way of example, data connection relations among a built-in RAM, a programming program, an initialization process, and registers (R[0052] 4 and R5) at the programming initialization of FIG. 16;
  • FIG. 19 is an explanatory diagram illustrating by an example, data connection relations among a RAM, general purpose registers (R[0053] 4 and R5) and a programming program at programming;
  • FIG. 20 is a process flow for describing a programming program corresponding to Step S[0054] 35 of FIG. 17;
  • FIG. 21 is a schematic flowchart which focuses attention on the erase process of FIG. 13; [0055]
  • FIG. 22 is a flowchart illustrating details on an erase initialization process (T[0056] 6) by way of example;
  • FIG. 23 is a flowchart illustrating details on an erase execution (T[0057] 7) by way of example;
  • FIG. 24 is an explanatory diagram illustrating by an example, data connection relations among a built-in RAM, an erase program, an initialization process and registers (R[0058] 4 and R5) at the erase initialization of FIG. 22;
  • FIG. 25 is an explanatory diagram illustrating by way of example, data connection relations among a RAM, general purpose registers (R[0059] 4 and R5) and an erase program at erasing;
  • FIG. 26 is a process flow for describing an erase program corresponding to Step T[0060] 74 of FIG. 23; and
  • FIG. 27 is a flowchart for describing a user branch process for enabling inhibition of a state in which information stored in a flash memory is destructed due to a runaway of CPU at a user branch destination.[0061]
  • DETAILED DESCRIPTION OF THE INVENTION
  • <<Microcomputer>>[0062]
  • A microcomputer used as a data processor according to one embodiment of the present invention is shown in FIG. 1. Although not restricted in particular, the [0063] microcomputer 1 shown in the same drawing is formed on a single semiconductor substrate (semiconductor chip) like monocrystal silicon by a CMOS integrated circuit manufacturing technology.
  • The [0064] microcomputer 1 has a central processing unit (CPU) 2 used as an arithmetic control device, a RAM 3 used as a non-volatile memory, a bus state controller (BSC) 4, a flash memory 13, and other module 7 generically referred to as other built-in circuits. The flash memory 13 is one example of an electrically reprogrammable non-volatile memory, which comprises a flash memory module 5 and a flash control module 6. The other module 7 includes a mask ROM 8, an interrupt controller (INTC) 9, a timer (TMR) 10, an input/output port (I/O) 11, a serial interface controller (SCI) 12, other interface controller 16, a DMAC (Direct Memory Access Controller) 17 and a system controller 15 or the like. Those circuit modules are interfaced via buses IAB, IDB, PAB, PDB and CONT.
  • The buses IAB and IDB are respectively an internal address bus and an internal data bus relatively fast in information transmission rate. The buses PAB and PDB are respectively a peripheral address bus and a peripheral data bus relatively slow in information transmission rate. Control signal lines for transferring bus commands, bus access control signals and timing control signals or the like are collectively referred to as the bus CONT. The [0065] BSC 4 optimally controls access operation timing or the like with respect to the difference in operating speed between each of the internal buses IDB and IAB and each of the peripheral buses PDB and PAB or with respect to the difference in access form inherent in an access object. Further, the BSC 4 also performs chip selection or module selection control or the like corresponding to an access address.
  • A [0066] mode signal 14 of plural bits and a reset signal RES or the like are externally inputted to the system controller 15. When the reset signal RES is brought to a low level with power-on reset or hardware reset of the microcomputer 1, a rest operation is carried out inside the microcomputer 1 during its low level period. After the release of the reset according to the reset signal RES, the corresponding operation mode for the microcomputer 1 is determined according to the state of the mode signal 14 of the plural bits. The CPU 2 reads a reset vector in a program area corresponding to the operation mode, fetches an instruction for its address, decodes the fetched instruction, and starts an instruction execution.
  • The [0067] RAM 3 is used even as a work area for the CPU 2 or an area for temporarily storing data or a program. The mask ROM 8 is defined as a storage area such as a data table. The flash memory module 5 is defined as an area for storing a program and data for the CPU 2.
  • The interrupt [0068] controller 9 receives therein an interrupt request supplied from the outside of the microcomputer 1 or an interrupt request generated from a built-in circuit module according to the state of the interior of the microcomputer 1. Further, the interrupt controller 9 performs arbitration of interrupt requests which compete with one another and a priority level-based interrupt mask process according to interrupt priority levels and interrupt masks or the like. According to the results of the interrupt request arbitration and the interrupt mask process, the interrupt controller 9 supplies an interrupt signal IRQ to the CPU 2 and gives an interrupt vector address corresponding to an interrupt factor for the accepted interrupt request to the CPU 2. The CPU 2 causes processing to branch to a program instructed by the interrupt vector address. The interrupt controller 9 is supplied with interrupt mask data (IMSK) from the CPU 2 and masks the reception of an interrupt request lower than an interrupt priority level indicated by the interrupt mask data (IMSK).
  • The I/[0069] O 11 is used for connection to an external address bus and an external data bus, external interface with the SCI 12, the input of an external event signal to the TMR 10, external interface to the interface controller 16, etc. The interface controller 16 can be applied to interfaces such as an ATAPI or an SCSI or the like.
  • A specific example of the [0070] CPU 2 is shown in FIG. 2. Although not restricted in particular, the CPU 2 includes, at an execution section, computing units such as a shifter SFT and an arithmetic logic unit ALU or the like, a register group such as 32-bit general purpose registers RO through R31, a program counter PC, a status register SR and a temporary register TR or the like, and buffer circuits such as a read data buffer RDB, a write data buffer WDB and an address buffer AB or the like. They are connected to a predetermined internal bus of first through third internal buses IB1 through IB3. The CPU 2 includes an instruction register IR, an instruction decoder IDEC and an instruction sequence logic INTL as an instruction control section.
  • The read data buffer RDB supplies data inputted from, for example, a 32-bit data bus IDB to the internal bus IB[0071] 2. The status register SR has a field for interrupt mask data IMSK. The interrupt mask data IMSK is supplied to the interrupt controller 9. The interrupt controller 9 masks an interrupt request lower than an interrupt priority level indicated by the interrupt mask data IMSK.
  • The program counter PC has an instruction address to be next executed. When the instruction address is outputted from the address buffer AB to the internal address bus IAB, an instruction read from its corresponding address of the [0072] RAM 3 or the like is fetched into the instruction register IR via the internal data bus IDB. The instruction decoder IDEC decodes the instruction fetched into the instruction register IR to generate a control signal in the CPU 2, thereby controlling arithmetic processing done by the execution section. The instruction sequence logic INTL performs control for changing an instruction execution sequence in response to the interrupt signal IRQ or the like.
  • In FIG. 1, the [0073] flash memory module 5 includes a memory cell array 20, an X decoder.driver (XDE.DV) 21, a sense amplifier array (SAA) 22, a Y switch array (YSW) 23, a Y decoder (YDE) 24, an input/output circuit (IFB) 25, a power circuit or voltage generator (VGN) 26, and a timing generator (TGN) 27. The memory cell array 20 has flash memory cells (not shown) disposed in matrix form. Although not restricted in particular, each of the flash memory cell includes a source and a drain on a semiconductor substrate or a well region and has a stacked structure formed with a floating gate and a control gate above a channel with an insulating film interposed therebetween. Each of the flash memory cells is configured such that the source is electrically connected to its corresponding source line, the drain is electrically connected to its corresponding bit line and the control gate is electrically connected to its corresponding word line.
  • Each of the flash memory cells has a threshold voltage made programmable and holds information according to the programmed threshold voltage. When one flash memory cell retains one-bit information, for example, a relatively high threshold voltage state is called a program state whereas a relatively low threshold voltage state is called an erase state. Although a program operation for acquiring the program state is not restricted in particular, 10V is applied to the control gate, 5V, for example, is applied to the drain, and 0V, for example, is applied to the source and the substrate to allow a current to flow between the drain and source, whereby the injection of hot electrons occurs. Thus, electrons are stored in the floating gate and hence the threshold voltage of the memory cell increases. Although an erase operation for acquiring the erase state is not restricted in particular, 10V is applied to the control gate, −10V, for example, is applied to the source and the substrate, and the drain is rendered open (floating), for example, to thereby emit electrons stored in the floating gate into the substrate, whereby the threshold voltage of the memory cell is lowered. [0074]
  • The input/[0075] output circuit 25 inputs addresses, control signals and commands among the buses IAB, IDB, PAB, PDB and CONT and performs the input/output of data. Address signals inputted to the input/output circuit 25 are inputted to the XDEC.DV 21 and YDE 24, where they are respectively decoded. The XDEC.DV 21 selects a corresponding word line according to the result of decoding thereof. The YDE 24 selects a corresponding bit line through the YSW 23 according to the result of decoding thereof. The corresponding flash memory cell is selected according to the word-line selection and the bit-line selection. Upon a read operation, data read from the selected flash memory cell is detected by the SAA 22, which in turn is outputted to the bus PDB or IDB via the input/output circuit 25. Upon the program operation, program data supplied to the input/output circuit 25 from the bus PDB or IDB is latched in a program latch circuit lying within the input/output circuit 25.
  • Programming.program inhibition is controlled according to the latched data with respect to each memory cell subjected to the word-line selection. Prior to program processing, erasure is effected on each flash memory cell in block units before the program processing. [0076]
  • The [0077] power circuit 26 has a clamp circuit, a charge pump circuit, etc. and supplies various voltages used for operations such as programming, erase, reading effected on the flash memory. The timing generator 27 performs controls for interface with the outside of the flash memory, based on a strobe signal supplied via the control bus CONT and commands inputted via the data buses PDB and IDB.
  • In FIG. 1, the [0078] flash control module 6 includes program transfer related various registers 30 for effecting programming and erasing on the flash memory module 5, and a control logic circuit 29. An FCCS, an FKEY, FMATS, a writer mode related register, and a program/erase related register are typically illustrated in FIG. 1 as control registers. A storage area of the RAM 3 and the general purpose registers of the CPU 2 are also available for the control of the program/erase operations on the flash memory module 5.
  • <<Memory Mats of Flash Memory>>[0079]
  • Memory mats of a flash memory are illustrated in FIG. 3 by way of example. The [0080] memory cell array 20 of the flash memory module 5 includes an electrically erasable and programmable boot mat (first area) Tmat, a user boot mat (second area) Umat, a user mat (third area) Mmat, and a repair and trimming mat Rmat. The boot mat Tmat, the user boot mat Umat and the user mat Mmat are respectively assigned memory spaces with a 0 address (H′ 0000000) indicative of a leading or start address in an address space of the CPU 2 as a start address. In short, the boot mat Tmat, the user boot mat Umat and the user mat Mmat are configured so that their address spaces overlap each other. The address decoder YDEC and XDEC.DV select address decode logic in response to an instruction indicative of which mat should be utilized. Which mat should be used, depends on the operation modes or the like of the microcomputer, which is instructed by the mode signal 14. The repair and trimming mat Rmat stores therein defect relief addresses in the memory cell array, and setting data for a trimming circuit for carrying out an alignment fit corresponding to each circuit characteristic.
  • <<Operation Modes>>[0081]
  • In a flash memory, program-related and erase-related programs are becoming complex with advances in process generation. Assuming that a user must create erase/program control programs under such circumstances, the user becomes a large burden. The [0082] microcomputer 1 has been taken into consideration in such a manner that the erase/programming program creating burden on the user can be reduced and the erase/program can be executed in any modes with simple procedures. Particularly when each of parameters such as a high voltage pulse applying time required to effect erase/programming on the flash memory 13 is tuned up or a processing flow is changed, operation modes are prepared which are capable of being implemented using software without depending on hardware and enable the implementation of erase/programming with simple procedures without imposing a burden on a user. The contents thereof will be described in brief. Reference can be made to the erase/program control program held in the boot mat Tmat in any operation modes. Further, since a portion about security is also described in the program of the boot mat Tmat, the user is able to use the program in an inconvenience-free range.
  • The operations modes of the [0083] microcomputer 1 will be described in detail. When attention is given to erase/programming for the flash memory 13, the microcomputer 1 has a writer mode, a boot mode (first mode), a user boot mode (second mode) and a user mode (third mode). Although not restricted in particular, the mode signal 14 is of two bits, and the system controller 15 decodes a combination of its logical values and judges whether the specified operation mode corresponds to any of the writer mode, the boot mode, the user boot mode and the user mode.
  • The writer mode is an operation mode which enables the execution of the erase/programming for the [0084] flash memory 13 by use of a programming device like an EPROM writer. When the writer mode is specified, the CPU 2 effects vector fetch from a leading or start address of the boot mat Tmat after reset processing and starts execution of a program (start up from the boot mat). Further, the CPU 2 transfers all of a command decision program and erase/program related programs to the RAM 3. Thereafter, the CPU 2 proceeds to the execution of the programs transferred to the RAM 3, and the flash memory 13 is capable of performing erase/programming by the EPROM writer. The writer mode is suitable for storing an arbitrary user control program or the like into the user mat Mmat and user boot mat Umat off board (in a state in which the microcomputer is not implemented or mounted on a system board).
  • The boot mode is an operation mode which is capable of effecting erasing on all of the mats Tmat, Umat and Mmat and enables execution of programming through the use of the [0085] SCI 12. The boot mode allows the CPU 2 to process the program of the boot mat Tmat and disables the CPU 2 to effect erase and programming on the boot mat Tmat. Described specifically, when the boot mode is specified, the CPU 2 effects vector fetch from a start or leading address of the boot mat Tmat after reset processing and starts execution of a program. Further, the CPU 2 transfers the erase/program related program and the command decision program in the boot mat Tmat to the RAM 3 as a process necessary for the boot mode. After the completion of the transfer thereof and the termination of other processes, the CPU 2 proceeds to the execution of the programs on the RAM 3. After the erasing is effected on all of the mats Umat and Mmat by the execution of the programs on the RAM 3, the command decision program is started up and programming is enabled through the use of the SCI 12. The boot mode is suitable for storing an arbitrary user control program, etc. into the user mat Mmat and user boot mat Umat at an on-board equipped with a serial communication interface.
  • The user boot mode is an operation mode which allows the [0086] CPU 2 to process the corresponding program of the user boot mat Umat to thereby enable execution of erase and programming using a user-based interface, and disables erasure and programming for the boot mat Tmat and user boot mat Umat. Described specifically, the user boot mode starts from the boot mat Tmat. The CPU 2 executes the program lying within the boot mat Tmat and transfers a user boot mat change program to the RAM 3. Afterwards, the CPU 2 is shifted to the execution of the corresponding program on the RAM 3. With the execution of the program on the RAM 3 by the CPU 2, the mat on the flash memory 13 as seen in the address space of the CPU 2 is changed from a default user mat Mmat to a user boot mat Umat and jumped over to its area after the vector address of the user boot mat Umat has been read. When security is provided, a jump is carried out after the erasing of the user mat Mmat has been carried out. Upon execution of programming, a necessary erase/programming program is downloaded from the boot mat Tmat to the RAM 3 through the use of an SCO mode to be described later. Thereafter, the erase/program control program is used to effect programming on the user mat Mmat. In short, a user-dedicated interface program is prepared for the user boot mat Umat, and program data transfer matched with a mounting board of a user can be implemented. The user boot mode is suitable for writing a user control program or the like into the user mat Mmat through the use of an onboard interface included in the system board of the user. The erasure of the user boot mat Umat is inhibited in this operation. Thus, even if the system board of the user is not provided with a serial interface and the boot mode is unavailable on board, programming made via an onboard interface included in the system board of the user as an alternative to it can be secured.
  • The user mode is an operation mode which enables execution of erasure and programming through the use of the corresponding program held in the user mat Mmat and disables erasure and programming for the boot mat Tmat and user boot mat Umat. Described in details, the [0087] CPU 2 is started up from the user mat Mmat to execute the program on the user mat Mmat. Particularly when an SCO bit to be described later is enabled when required by a user, the boot mat Tmat and the user mat Mmat are automatically switched, so that the program is started from a given address on the boot mat Tmat, whereby the erase/program control program on the boot mat Tmat is transferred to the RAM 3. After the transfer of the program has been completed, the user mat Mmat and the boot mat Tmat are automatically switched to provide a return to user's processing. Thus, the erase/program control program is utilized according to the user program, thereby enabling erasure and programming with respect tot the user mat Mmat. In short, in the user program mode, the erase/program control program on the boot mat Tmat is transferred onto the RAM 3 through the use of an SCO mode to be described later, thereby enabling the utilization of such a program. The user mode is suitable for reprogramming parameters on the user mat Mmat on board during the execution of the user control program.
  • Access forms based on the respective operation modes of the respective mats are illustrated in FIGS. [0088] 4(A) and 4(B). The access forms shown in the same drawing are those obtained by putting in order the access forms described in the above operation modes. As is apparent from the same drawing, the repair and trimming mat Rmat and the boot mat Tmat are disabled for erasure and programming in any operation modes. The user boot mat Umat is enabled for erasure and programming in the user boot mode and the user mode (user program mode) that enable execution of the user control program. The user boot mode is suitable for writing a user control program or the like into the user mat Mmat through the use of an onboard interface included in the system board of the user. Upon this operation, the erasure of the user boot mat Umat is inhibited. Thus, even if the user's system board is not provided with a serial interface and the boot mode is not available on board, programming made via the onboard interface included in the user's system board can be assured as an alternative to it. Incidentally, in FIG. 4, the access means a read access, symbol Δ means that the read access can be carried out according to a program stored in the boot mat and does not means that the read access can be arbitrarily performed according to the user control program.
  • FIG. 5 typically shows the location of a program executed by a CPU and operation based on its execution. The illustration of the CPU[0089] 2 is omitted in FIG. 5. CN1 virtually shows a control signal group of a result obtained by decoding an erase and program control program or the like transferred from the boot mat Tmat to the RAM 3 with the CPU 2. CN2 virtually shows a control signal group of a result obtained by decoding a serial interface control program transferred from the boot mat Tmat to the RAM 3 with the CPU 2. CN3 virtually shows a control signal group of a result obtained by decoding a user interface control program of the user boot mat Umat with the CPU 2. CN4 virtually shows a control signal group of a result obtained by decoding a user interface control program of the user mat Mmat with the CPU 2. While the control signals CN3 and CN4 are respectively illustrated so as to indicate the results of decoding of the programs fetched directly from the user boot mat Umat and user mat Mmat, they may be results of decoding of programs temporarily transferred to the RAM 3 and fetched therefrom. Sig1 through Sig4 mean the result of decoding of a mode signal 14 after the release of reset by the system controller 15. Sig1 means a boot mode, Sig2 means a user boot mode, Sig3 means a user mode, and Sig4 means a write mode, respectively. While those signals Sig1 through Sig4 are actually supplied even to the CPU 2, the illustration of their states is omitted herein.
  • When the boot mode is specified by the [0090] mode signal 14, the flash control module 6 transfers an erase and program control program and a serial communication control program or the like of the boot mat Tmat to the RAM 3 in response to the signal Sig1 (path P1). According to the result of decoding of the serial communication control program by the CPU 2 (CN2), program data is brought from a serial interface on board a host device HST1 to the RAM 3 (path P2). According to the result of decoding of the erase and program control program by the CPU 2 (CN1), the flash memory 13 is subjected to erasure, and a user control program is programmed into the user boot mat Umat and the user mat Mmat by use of the program data on the RAM 3 (paths P3 and P4).
  • When the user boot mode is specified by the [0091] mode signal 14, the flash control module 6 transfers a mat change control program or the like from the boot mat Tmat to the RAM 3 in response to the signal Sig2 (path P1), so that the boot mat is switched to the user boot mat Umat, where its leading vector is fetched and executed. Upon execution of programming, an erase and programming program is downloaded from the boot mat Tmat to the RAM 3. According to the result of decoding of the user interface control program held in the user boot mat Umat (CN3), program data is brought from a user interface on board a host device HST2 to the RAM 3 (path P5). According to the result of decoding of the erase and program control program by the CPU 2 (CN1), the flash memory 13 is subjected to erasure, and a user control program and user data are programmed into the user mat Mmat by use of the program data on the RAM 3 (paths P3 and P4). As the user interface, may be mentioned, for example, an ATAPI interface or the like realized by the other interface controller 16. Incidentally, the user interface control program stored in the user boot mat Umat may be a serial interface control program similar or different from one stored in the boot mat Tmat.
  • When the user mode is specified by the [0092] mode signal 14, it is transferred to the flash control module 6 in response to the signal Sig3. Upon execution of programming, an erase and programming program is downloaded from the boot mat Tmat to the RAM 3. According to the result of decoding of the user interface control program held in the user mat Mmat (CN4), program data is captured from the user interface on board the host HST2 to the RAM 3 (path P5). According to the result of decoding of the erase and program control program by the CPU 2, the flash memory 13 is subjected to erasure, and a user control program and user data are programmed into the user mat Mmat by use of the program data on the RAM 3 (paths P3 and P4). Incidentally, the user interface control program stored in the user mat Mmat may be a serial interface control program similar or different from one stored in the boot mat Tmat.
  • Now consider a microcomputer unequipped with a user boot mat Umat and a user boot mode as an example compared with the [0093] microcomputer 1 although not illustrated in the drawing in particular. If, in this case, a user interface program stored in the user boot mat Umat is stored in a user mat Mmat, then the microcomputer is capable of programming or reprogramming programs and data into the user mat Mmat via a user interface on board a host device HST2 in a manner similar to the microcomputer 1. As is the case in the microcomputer 1, however, the microcomputer has a possibility that the user interface program stored in the user mat Mmat will be erased from the relationship in which free reprogramming is allowed for the user mat Mmat. If the host device HST2 is not provided on board with a serial interface available in a boot mode when erased, then the microcomputer according to the comparative example is no longer capable of performing the input/output of information to and from the host device HST2.
  • According to the [0094] microcomputer 1 having the operation modes referred to above, the following operations and effects can be obtained. (1) Since the user boot mat Umat capable of storing therein the user-dedicated communication protocol is prepared, the arbitrary interface provided in the microcomputer 1 can be diverted to the erasure and programming of the flash memory 13. (2) Since it is possible to adopt the user-optional interface for the erasure and programming of the flash memory 13, the serial interface may not necessarily be prepared for the host device HST2. (3) Since the user boot mat Umat and the user mat Mmat are provided in parts, the user-optional program interface can be realized for the erasure and programming even if the dedicated communication protocol is not programmed into the user mat Mmat. Therefore, it becomes easy to create the control program used with being stored in the user mat Mmat. In short, no special consideration may be given to the prevention of erasure of the communication control program used in the user program mode. (4) Since the erasure and programming for the user boot mat Umat are disabled on a hardware basis in the user boot mode started up from the user boot mat Umat, the information stored in the user boot mat Umat is prevented from destruction due to a runaway or the like. Further, even if the CPU 2 has gone haywire upon debug, this does not lead to the destruction of the program for controlling the external interface. Therefore, the reprogramming of the user mat Mmat can be freely carried out on board even without detachment of the packaged microcomputer chip.
  • <<Erase and Program Protect>>[0095]
  • A logic configuration for protection against erasure and programming of the [0096] flash memory 13 is illustrated in FIG. 6 by way of example. The logic shown in the same drawing is defined as positive logic and the configuration thereof is implemented by the flash control module 6.
  • The operation of effecting erasure and programming on the flash memory is enabled by setting control data necessary for processing to an initial value of a programming/erase [0097] related register group 30A. The setting of the control data to the programming/erase related register group 30A is enabled when a control bit SWE is of a logical value “1”. In short, unless the control bit SWE is set to the logical value “1”, the erase and programming for the flash memory 13 is disabled.
  • A first condition for setting the control bit SWE to the logical value “1” is to set an enable bit FEW of a register FCCS to the logical value “1 through an external terminal Pfwe. [0098]
  • A second condition is to obtain a select state of an operation mode for setting the output of an [0099] NAND gate 40 to the logical value “1”, and a mat select state of the flash memory. Namely, the operation mode is a test mode (TESTTM=1), a writer mode (WRTM=1) or a boot mode (BOOT=1). Alternatively, no user boot mat Umat is selected in a user mode or a user boot mode (UMATSEL=0). Incidentally, the test mode is of an operation mode used in a device test by a maker for manufacturing a microcomputer. While all the operations are enabled, such consideration that an operation mode non-open to a user, i.e., a user-based setting is disabled, has been given thereto.
  • The signal UMATSEL is defined as a decision result for a register FMATS and an [0100] AA decision circuit 41 with respect to a set value of the register FMATS. The register FMATS is used to perform switching between the user mat Mmat and the user boot mat Umat. Using the register FMATS makes it possible to cause the operation of the CPU 2 to transit from the user mat Mmat to the user boot mat Umat. There are, however, items restricted to the mat change. Namely, a condition under which a user boot mat select bit for the register FMATS can be set, is that the operation of the CPU 2 is executing the program of the RAM 3. Under this condition, the BSC 4 detects and determines that an address area for instruction fetch made by the CPU 2 is an address area for the RAM 3. An initial value of the register FMATS is other than H′AA and indicates a user mat select state. The user mat select state is indicated by H′AA. A transition state at the time that the operation (OP) of the CPU 2 is switched between the user mat Mmat and the user boot mat Umat, is shown in FIG. 7.
  • Owing to the second condition, access to the user boot mat Umat is enabled in any modes. However, programming/erase is allowed only in the writer mode and boot mode (and test mode). [0101]
  • A third condition is that a register FKEY has been set to an erase and programming allowable value. The register FKEY is provided to prevent a runaway of a program due to a voltage drop and noise or the like and the destruction of the program due to it. The register FKEY is used in view of the case in which the program runs away after the erase and program control program (programming/erase program) has been transferred. Even if the [0102] CPU 2 gone haywire due to the terminal Pfwe and the control bit SWE, no programming/erase is executed basically. However, in order to further enhance reliability, the user sets the value of “5A” to the register FKEY before the execution of the programming/erase. When this “5A” is not stored therein, the control bit SWE cannot be set even if FWE is brought to enable (“1”). A state in which “5A” is being stored in the register FKEY, is detected by an A5, 5A decision circuit 42, where it is brought to a signal fwemkp=1, whereby SWE can be set to the logical value “1”.
  • The register FKEY functions as a program transfer relation as well as functioning as the programming/erase program relation. Namely, in terms of the relationship in which an erase and program control program for a flash memory is stored in its corresponding boot mat Tmat and made available in a user boot mode and a user mode as well as in a boot mode, a control bit SCO is provided for the register FCCS and enabled to transfer the erase and program control program to the [0103] RAM 3. In doing so, the user mat Mmat is automatically changed to the boot mat Tmat so that the erase and program control program is transferred from the boot mat Tmat to the RAM 3, whereby a return instruction is executed after the completion of the processing to thereby make a return to the processing of the user. When, at this time, the program runs away at a location where the user does not desire to execute programming/erase, and the programming/erase program is transferred, there is a high possibility that a user program will be destroyed. In order to avoid it, the register FKEY is used. The user stores “A5” in the register FKEY before the control bit SCO is set. When no “A5” is stored therein, the control bit SCO cannot be set. Further, the operation of the program on the RAM 3 by the CPU 2 is also defined as a condition. When “A5” is stored therein and the operation of the CPU 2 is effected on the RAM 3, the SCO bit can be set, and the transfer of the erase and program control program from the boot mat Tmat to the RAM 3 is allowed.
  • As to the erase and programming effected on the [0104] flash memory 13 as described above, the register FKEY exclusively controls the transfer and erase/programming of each program. Therefore, when the program runs away in its non-transferred state, it is hard to execute programming/erase.
  • <<Program Mode Judge Process>>[0105]
  • Processes in the respective operation modes will now be described in detail. A [0106] flowchart 13 for describing a program mode decision or judge process is illustrated in FIG. 8 by way of example. An SCO mode means an operation mode used when erase and programming are effected on the flash memory in a user mode. As to a boot mode, a writer mode, a user boot mode and a user mode, their corresponding mode terminals are set and a reset release may be carried out after their setting. The SCO mode is set by setting the logical value “1” to the control bit SCO during the user mode. Mode information is set to its corresponding mode judge register according to the set operation mode.
  • When the operation mode is set, the [0107] CPU 2 executes a program in a boot mat (OP in boot mat). In the boot mode, writer mode and user boot mode, the CPU 2 fetches a vector from a start address in the boot mat to start program execution (S1). In the case of the SCO mode, however, a process is started from a predetermined address other than the start address in the boot mat, e.g., a user break address corresponding to exception handling highest in priority.
  • When the process start is made, the [0108] CPU 2 reads the mode judge register (S2) and judges the contents thereof. Further, the CPU 2 executes necessary pre-processes such as the transfer of an ease and program control program, etc. (S2 through S5) and proceeds to corresponding processes (S6 through S9). Incidentally, the term of user” shown in each process column of the flowchart means that its process is a process executed based on a program defined by a user. The term of “boot” shown in each process column means that its process is a process executed based on a program in a boot mat Tmat.
  • <<Writer Mode Process>>[0109]
  • A flowchart for describing a writer mode process is illustrated in FIG. 9. When the writer mode is set, the writer mode control program is transferred to the [0110] RAM 3 as shown in FIG. 8. In the writer mode, a command/data register (CDL) used for erase and programming, and a flag register (FLG) are first cleared, and “1” is set to a command flag (CDF)(S11). Erasing (S14 and S15) and programming (S12 and S13) for a user mat Mmat and a user boot mat Umat are executed until a power supply is terminated, according to a command and program data set to the command/data register (CDL) from an EPROM writer while referring to the states of the flag register (FLG) and the command flag (CDF). The writer mode process is defined as operation in the RAM 3.
  • <<Boot Mode Process>>[0111]
  • A flowchart for describing a boot mode process is illustrated in FIG. 10 by way of example. Transmission and reception between the serial interface and [0112] SCI 12 on board are first established (S20). Required parameters such as an oscillated frequency, etc. for the microcomputer 1 are downloaded and set (S21). Next, a command from a host device is decoded and thereby status such as a product name of a microcomputer, the number of erase blocks and etc., are returned to the host device (S22). A command decision program and an erase program are transferred to the RAM 3 (SCO mode is also available), and the boot mode process changes to operation in the RAM 3 (S23). A user mat Mmat and a user boot mat Umat are subjected to full erasure (S24) and thereafter a user mat program process (S25), a user boot mat program process (S26), a program verify process (S27, S28), etc. are executed in response to the command.
  • <<User Boot Mode Process>>[0113]
  • A flowchart for describing a user boot mode process is illustrated in FIG. 11 by way of example. Although not restricted in particular in the user boot mode, operation is started from a start vector in s boot mat Tmat. A change program to a user boot mat Umat is transferred from the boot mat Tmat to the RAM [0114] 3 (S30). A change to operation in the RAM 3 is made (S31). Further, H′AA is set to its corresponding register FMATS, and the specified state (initial value) of user mat by the register FMATS is changed to its corresponding user boot mat (S32). It is now judged whether an error exists in area settings of the user boot mat Umat (S33, S34). If it is judged that there is no error, then a start vector address of the user boot mat Umat is read (S35), and a subroutine is jumped to the read vector address (S36). The CPU 2 executes a program on the user boot mat Umat to thereby firstly establish user defined communications, and transfers a user program required for programming to the RAM 3 (S37). The CPU 2 changes to execution of the program on the RAM 3 (S38) and performs the operation of the register FMATS again. Thereafter, the CPU 2 changes a mat to be processed from the user boot mat Umat to a user mat Mmat (S39). Further, the CPU 2 executes a user program on the RAM 3 to thereby set a control bit SCO to “1” (S40) and proceeds to an SCO mode process, where it transfers an erase and program control program in the boot mat Tmat to the RAM 3 (S41), whereby a program/erase process using the transferred erase and program control program is executed (S42).
  • <<User Mode Process>>[0115]
  • A flowchart for describing a user mode process is illustrated in FIG. 12 by way of example. When a user mode is specified, a vector fetch is made from the start of a user mat Mmat (S[0116] 50) and a user control program is executed (S51). When programming to the user mat Mmat is required during execution of a user program, the CPU 2 performs operation in the RAM 3 to set an SCO bit to “1” (S52) and proceeds to the SCO mode process, thereby transferring an erase and program control program in the boot mat to the RAM 3 (S53), whereby a program/erase process using the transferred erase and program control program is performed (S54).
  • <<Program/Erase Process>>[0117]
  • A flowchart for describing a program/erase process shown in each of Steps S[0118] 42 and S54 referred to above is illustrated in FIG. 13 by way of example. Steps S60 through S63 correspond to a program/erase initialization process. Here, an erase and program control program has been stored in a boot mat Tmat in advance by a maker for the microcomputer 1. In short, the program does not define a condition inherent in a user. For example, the time required to apply each of an erase voltage pulse and a program voltage pulse, for example, is determined according to the characteristic of a flash memory cell. It is however necessary to control the pulse applying time by an operation clock signal for the microcomputer 1. Data about an operation frequency necessary therefor is set to a control register FPEFEQ (S60). Although not restricted in particular, the general purpose register R4 for the CPU 2 is assigned to the control register FPEFEQ.
  • The erase voltage pulse, the program voltage pulse, and a branch-destination processing address for a user branch process (whose details will be described later) for resolving inconvenience in which a user process is completely disabled during a cycle of a verify operation, are set to a register FUBRA (S[0119] 61).
  • Thereafter, a subroutine is jumped to an initialization program region (S[0120] 62) and an initialization program is executed (S64). According to the contents of the initial setting of the frequency or user branch address, parameters for erase and programming are automatically set onto the erase and program control program.
  • Next, a control bit FWE is set to a logical value “1” via a terminal Pfwe to release erase/programming hardware hard protection. Consequently, the hard protection is released and a change to execution of a user program is performed (S[0121] 64). Programming data is prepared in this operation state (S65), and programming/erase that a user desires to perform, is executed (S66). The processes in Steps S65 and S66 are repeated until the user-purposed process is completed.
  • <<User Branch>>[0122]
  • The user branch process will be explained while the program/erase process of FIG. 13 is being described in further detail. [0123]
  • FIG. 14 is a schematic flowchart in which attention has been given to the program process of FIG. 13. The program process is roughly divided into a process (T[0124] 1) for transferring a source code (erase and program control program or the like) from a boot mat Tmat to the RAM 3, execution of the initialization of programming (T2) and execution of programming (T3).
  • The transfer process (T[0125] 1) selects a program to be transferred, sets the register FKEY and enables the control bit SCO. By executing it, the transfer program is automatically started form its corresponding boot mat. The program is to be transferred to a required region alone from the start address of the RAM 3. At this time, an initialization program is also transferred.
  • Upon the execution of the initialization (T[0126] 2), the initialization program is executed, and the setting of the number of wait time loops depending on an operation frequency and a user branch address are set to the transferred program.
  • Upon the execution of programming (T[0127] 3), programming data is transferred onto the RAM 3 before the execution of programming although it may be any mode. At this time, it is necessary to align data in a given determined sequence. A user is able to arbitrarily set a transfer area. After a required procedure has been executed and the transfer of the program data has been performed, a subroutine is jumped to a certain determined address of the program. Programming is executed by execution of such a subroutine jump.
  • Details on the transfer process (T[0128] 1) to the RAM 3 are illustrated in FIG. 15 by way of example. The register FKEY is first set to “A5” (T10) and a source code to be transferred is selected (T11). The selection of the source code is effected on the programming/erase related register 30A. Although not restricted in particular, selectable source codes may include a program and program verify program, an erase and erase verify program, etc. Further, the control bit SCO is set to “1” and the selected source code is transferred to a predetermined area of the RAM 3 (T12). When the control bit SCO is enabled, the CPU 2 needs to have operation being in execution outside the flash memory 13. This is because since a mat capable of operation changes from the user mat Mmat to the boot mat Tmat, the program runs away. When the control bit SCO has been enabled, the program is automatically started from the boot mat Tmat. This boot program saves the value of each general purpose register into a stack according to a software process. Upon a return to a user process, the user process is returned according to a return instruction. Before the execution of such a return, a transfer program in the boot mat Tmat serves so as to restore the saved value of the general purpose register. It is finally judged whether transmission was completed normally (T13).
  • Details on the programming initialization process (T[0129] 2) are illustrated in FIG. 16 by way of example. An operation frequency of the microcomputer 1 is firstly set to the register FPEFEQ (R4) (T20), and a user branch address is set to the register FUBRA. The general purpose register R5 of the CPU 2 is assigned to the register FUBRA. Afterwards, a programming initialization program is executed (T22). A program related initialization program refers to the set value of chip operation frequency and decides the number of wait time loops. A process for embedding the decided wait time interval into the program control program transferred onto the RAM 3 is executed. Further, the programming initialization program executes a user branch by referring to the value of the register FUBRA (R5). Alternatively, when the user branch is executed, a programming program change indicative of to which address it jumps, is executed. In short, the value of the register FUBRA (R5) is embedded into a subroutine jump instruction for executing the user branch, as a branch destination address. It is finally judged whether the initialization process was completed normally (T23), and the present process is terminated.
  • Now, the register FUBRA is a register for specifying the user branch address in the course of program/erase. This area exists in the general purpose register R[0130] 5. When it is not desired to execute the user branch, H′ 00000000 is set to the present register. In order to avoid the occurrence of a malfunction due to the user branch, it is desirable to prohibit an area in the course of the program/erase in the flash memory from the execution of the user branch, inhibit the user branch effected on an area of a built-in RAM, to which the program/erase program has been transferred, inhibit reprogramming of program data, and inhibit execution of an SCO mode and calling of a program/erase routine and a program/erase initialization routine.
  • Data connection relations among the built-in [0131] RAM 3, programming program, initialization process, and registers R4 and R5 at the programming initialization of FIG. 16 are illustrated in FIG. 18. It is apparent from the same drawing that an initialization program refers to the registers R4 and R5, reflects the result of referring on a user branch process of the programming program and reflects it on wait related parameters.
  • Details on the execution of programming (T[0132] 3) are illustrated in FIG. 17 by way of example. A branch destination at the time that a non-maskable interrupt (NMI) is accepted, is changed to an address area of the RMA 3 (T30). For example, a vector base register may be changed so as to be set to the address area of the RAM 3. This is because a flash memory area being in the course of programming may preferably be avoided or kept off in terms of the prevention of a malfunction. Such an NMI may be utilized to call an error processing routine defined by a user. An interrupt lower in interrupt priority level than the NMI is masked (T31). An interrupt priority level low next to an NMI of interrupt mask data IMSK may be set to the status register SR, for example. This means that a high voltage is being applied to a flash memory according to the state during program/erase. Even if an interrupt such as IRQ or the like is made in this condition, it is not possible to assure that a vector of the flash memory can be read. Thus, interrupts except for the NMI are inhibited during program/erase.
  • Further, an area for setting a write address is set to the general purpose register R[0133] 5 (T32). Namely, a start address in a write address area, which has been written in the built-in RAM 3, is set to the general purpose register R5. A setting area for an address of write data is set to the general purpose register R4 (T33). Namely, a start address in a write data address area, which has been written into the built-in RAM 3, is set to the general purpose register R4. Afterwards, a program/erase code “5A” is set to its corresponding register FKEY (T34), and a subroutine is jumped to a programming program, whereby programming is executed (T35). Finally, a judgement is made whether programming was completed normally (T36).
  • Data connection relations among the [0134] RAM 3, general purpose registers R4 and R5, and programming program at programming are illustrated in FIG. 19 by way of example. Since dual bank programming is under assumption herein, reference must be made to a start address in a write address area and a start address in a write data address area every their banks. Therefore, RAM areas FMPDR0 and FMPDR1 can be referred to by the register R4, and RAM areas FMPAR0 and FMPAR1 can be referred to by the register R5.
  • A process flow for describing a programming program corresponding to Step S[0135] 35 of FIG. 17 is illustrated in FIG. 20 by way of example. This process flow includes a step (T53) for judging whether a subroutine is jumped to a user branch address during processing cycles of programming data latch (T50), the application of a programming pulse (T51), and programming verify (T52). When instructions for a subroutine jump is made (when the user branch address is except for H′ 00000000) according to a set value based on an initialization process, the programming program branches to the user branch address, where the subroutine is executed (T54). After its execution, it returns to a programming operation routine again. When no predetermined threshold state is obtained upon programming verify, the number of times N that pulses are applied, is incremented and the same loop is repeated again (T55). If a programming normal state is obtained before the number of times that it is repeated, reaches the maximum number of times (WMAX), then this routine procedure returns to the flow of FIG. 17 (T56) at this time. When the programming cannot be completed normally even if the maximum number of times is reached, a programming error process is executed (T57), and the routine procedure returns to the flow of FIG. 17.
  • Thus, if the programming program is capable of branching to the subroutine process indicated by the user branch address during the cycles of the application of the programming pulse and the programming verify, then the control can be returned to the user control program at certain predetermined intervals even during programming. Further, since the program is executed on a software basis, the intervals at which the control is returned to the user control program, may be changed by software. Owing to the returning of the control to the user control program at the predetermined intervals even during the programming, erase and programming can be executed even without deactivating the system using the [0136] microcomputer 1 for a long time. Thus, erase and programming can be effected on a system which needs to confirm internal and external events every predetermined intervals or a system with a learning function, or the like during the execution of a user program.
  • FIG. 21 is a schematic flowchart in which attention is given to an erase process. The erase process is roughly divided into a process for transferring a source code (erase and program control program or the like) from a boot mat to the RAM [0137] 3 (T5), execution of erase initialization (T6) and execution of an erase (T7).
  • The transfer process (T[0138] 5) is identical to the transfer process (T1). Upon the execution of the initialization (T6), an initialization program is executed for a transferred program for purposes of the setting of the number of wait time loops and the setting of a user branch depending on an operation frequency.
  • Upon the execution of the erase (T[0139] 7), the erase is executed by jumping a subroutine to a certain fixed address of an erase program transferred to the RAM 3.
  • Details on the erase initialization process (T[0140] 6) are illustrated in FIG. 22 by way of example. An operation frequency of the microcomputer 1 is first set to the register FPEFEQ (R4) T60). A user branch address is set to the register FUBRA (T61). The general purpose register R5 of the CPU 2 is assigned to the register FUBRA. Afterwards, an erase initialization program is executed (T62). In an erase program at its transfer, the number of wait loops is placed in an initially-set state. From this viewpoint, this initialization program is used to thereby change all the numbers of wait loops for the erase program. In order to execute this calculation, a user sets the register FPEFEQ (R4). Upon the setting of the register FUBRA (R5), the setting of a user branch for the erase program is executed. The erase initialization program refers to the set value of the register FUBRA to thereby execute an erase program change as to whether the user branch should be executed or to which address it jumps upon its execution. The user sets a value to the register FUBRA to execute such a change. A judgement is made as to whether the initialization process was completed normally (T63), and the present process is terminated.
  • Now, the meaning of the register FUBRA is identical to the programming. When it is not desired to execute the user branch, H′ 00000000 is set to this register. [0141]
  • Data connection relations among the built-in [0142] RAM 3, erase program, initialization process and registers R4 and R5 at the erase initialization of FIG. 22 are illustrated in FIG. 24. It is apparent from the same drawing that an initialization program refers to the registers R4 and R5, reflects the result of referring on a user branch process of the programming program and reflects it on wait related parameters.
  • Details on the erase execution (T[0143] 7) are illustrated in FIG. 23 by way of example. A branch destination at the time that a non-maskable interrupt (NMI) is accepted, is changed to an address area of the RMA 3 (T70). For example, a vector base register may be changed so as to be set to the address area of the RAM 3. This is because a flash memory area being in the course of erasing may preferably be avoided or kept off in terms of the prevention of a malfunction. Such an NMI may be utilized to call an error processing routine defined by a user. An interrupt lower in interrupt priority level than the NMI is masked (T71). An interrupt priority level low next to an NMI of interrupt mask data IMSK may be set to the status register SR, for example. This means that a high voltage is being applied to a flash memory according to the state during the erasing. Even if an interrupt such as IRQ or the like is taken in this condition, it is not possible to assure that a vector of the flash memory can be read. Thus, interrupts except for the NMI are inhibited during the erasing.
  • Further, an erase block number is set to the general purpose register R[0144] 4 (T72). Afterwards, a program/erase code “5A” is set to the register FKEY (T73), and a subroutine is jumped to an erase program (T74). It is finally judged whether the erase was completed normally (T75).
  • Data connection relations among the [0145] RAM 3, general purpose registers R4 and R5 and erase program at erasing are illustrated in FIG. 25 by way of example. Since the user does not create the erase program, such connection relations are used as an interface method for erase mat selection, i.e., the delivery of the erase block selection is executed by delivering an erase block number via the register FEBS (R4).
  • A process flow for describing an erase program corresponding to Step T[0146] 74 of FIG. 23 is illustrated in FIG. 26 by way of example. This process flow includes a step (T83) for judging whether a subroutine is jumped to a user branch address during processing cycles of erase data latch (T80), the application of an erase pulse (T58), and erase verify (T82). When instructions for a subroutine jump is made (when the user branch address is except for H′ 00000000) according to a set value based on an initialization process, the erase program branches into the user branch address, where the subroutine is executed (T84). After its execution, it returns to an erase operation routine again. When no predetermined threshold state is obtained upon erase verify, the number of times N that pulses are applied, is incremented and the same loop is repeated again (T85). If an erase normal state is obtained before the number of times that it is repeated, reaches the maximum number of times (EMAX), then this routine procedure returns to the flow of FIG. 23 at this time (T56). When the erasing cannot be completed normally even if the maximum number of times is reached, an erase error process is executed (T87), and the routine procedure returns to the flow of FIG. 23.
  • Thus, if the erase program is capable of branching to the subroutine process indicated by the user branch address during the cycles of the application of the erase pulse and the erase verify, then the control can be returned to the user control program at certain predetermined intervals even during erasing. Owing to the returning of the control to the user control program at the predetermined intervals even during the erase, the erase can be executed even without deactivating the system using the [0147] microcomputer 1 for a long time. Thus, erase and programming can be effected on a system which needs to confirm internal and external events every predetermined intervals or a system with a learning function, or the like during the execution of a user program.
  • <<Runaway of Program at User Branch Destination>>[0148]
  • When the programming/erase program is in a transferred state and the terminal Pfwe is in an enable state (“1”), it is difficult to completely assure that the stored information held in the [0149] flash memory 13 is held normally in any case. A program/erase processing method capable of inhibiting the situation that the CPU 2 runs away at a user branch destination and thereby the information stored in the flash memory 13 is destroyed, is illustrated in FIG. 27. Namely, according to the user branch process corresponding to each of Steps T44 and T84, which is executed for each process termination during the program/erase flow, an operating power supply for programming/erase is initialized to make a change to an operating power supply for a read operation (90). Afterwards, the value of the register FKEY is changed to an arbitrary value other than a programmable/erasable value “5A” (T91). It is used as 7X (X=0˜F), for example. Since the setting of the control bit SWE is disabled owing to the execution thereof, the program/erase cannot be executed briefly even if the CPU runs away at the user branch destination.
  • If a code set to the register FKEY is set as a code meaningful to processing, e.g., a code indicative of the progress of erase/program in the process of Step T[0150] 91, then a malfunction or failure can be detected by reference to the value of the register FKEY where the routine procedure is returned from the program/erase processing routine in a program/erase non-completed state or where the value of the register FKEY is changed to a value other than an expected value due to a runaway or the like. In the example illustrated in FIG. 27, “71” is set between the application of a pulse End verify, “72” is set between the verify and re-computation of programming data, and “73” is set between the re-computation and dummy write prior to the application of a program pulse. When the present procedure escapes from the user branch process, a judgement is made as to whether the value of the register FKEY indicates “7X(X=1˜7) (T92). If it is found to be other than it, it is then judged that some abend or failure has occurred, and thereby a fail process is effected on the program/erase (T93). If FKEY is equal to “7X”, then the process is regarded as have been terminated normally, and FKEY is returned to “5A” (T93).
  • Incidentally, FKEY may not be used as the register, which holds the work progress. However, if consideration is given to the situation that it is advisable to reprogram the value of FKEY into the value other than “5A” in the case of a user branch, then the utilization of the register FKEY is economical for both aspects of a hardware resource and a process load. [0151]
  • While the invention made above by the present inventors has been described specifically by the illustrated embodiments, the present invention is not limited to the embodiments. It is needless to say that various changes can be made thereto within the scope not departing from the substance thereof. [0152]
  • For example, an erasable and programmable non-volatile memory is not limited to a binary flash memory. It may be a multi-valued flash memory, e.g., a multi-valued flash memory capable of allowing one flash memory to hold stored information of 2 bits or more. Namely, one flash memory cell is a memory in which information stored in one flash memory cell is represented in plural bits, which memory is set to one of four types or more of threshold voltages specified by programming data of plural bits upon information storage and outputs the state of the threshold voltage as its corresponding stored information of plural bits upon information reading. A flash memory capable of writing 2-bit information into one flash memory cell and reading the information is illustrated as one example herein. In a multi-valued information storage technology intended to realize such a flash memory, an information stored state of one memory cell is set to one selected from, for example, an erase state (“11”), a first program state (“10”), a second program state (“00”), and a third program state (“01”). The information stored states of four types in total are defined as states determined according to 2-bit data. Namely, one memory cell stores 2-bit data therein. [0153]
  • The flash memory cell is not limited to a vertical stacked structure of a floating gate and a control gate. Such a device structure or the like that a gate electrode of a MOS transistor is formed as a floating gate electrode, and a channel region is used as a control gate via a MOS gate capacitance formed by allowing the gate electrode to extend, may be adopted. Further, the non-volatile storage element is not limited to the flash memory. It may be a non-volatile memory like an EEPROM (Electrically Erasable and Programmable Read Only Memory) in which MNOS (Metal Nitride Oxide Semiconductor) transistors are formed as storage elements, or a ferroelectric memory or the like. [0154]
  • A circuit module included in a microcomputer on an on-chip basis is not limited to the above example. It may be suitably changed. [0155]
  • No limitation is imposed to such a configuration that the erase and program control program is initially held in a boot mat. Such a configuration that it is downloaded from a system board, may be adopted. Further, the various register means may be peripheral registers each with a built-in flash memory, general purpose registers each having a CPU built therein, or memory mapped I/O registers each comprising a memory such as an SRAM or the like. [0156]
  • The user branch has been described as the case in which the initialization process for reprogramming the jump-destined code for the jump subroutine instruction in advance is carried out based on the set value of the register FUBRA (R[0157] 5) and thereafter its program is executed. As an alternative to it, the register FUBRA (R5) may be allowed to branch by being directly referred to by the jump subroutine instruction. In this case, a compiler for its erase and program control program must be able to refer to the general purpose register R5 within a limited range of the number of general purpose registers available as an argument within one function.
  • An advantageous effect obtained by a typical one of the inventions disclosed in the present application will be described in brief as follows: [0158]
  • A program jumped to a subroutine corresponding to an address specified by a user is programmed in advance during a loop of the application of a high voltage pulse and data verify or the like. If a user passes a jump-destined address as an argument upon execution of a program, for example, then the address can be referred to by a jump subroutine instruction. Therefore, control can be returned to a user control program at certain predetermined intervals even during erase/programming for a non-volatile memory. Thus, erase/programming for an on-chip non-volatile memory can be carried out as necessary during its process even in the case of a system, which needs to respond to events developed at intervals each shorter than an erase/program process time. [0159]

Claims (39)

What is claimed is:
1. A microcomputer comprising:
an erasable and programmable non-volatile memory; and
a CPU,
wherein said CPU is capable of temporarily branching to a process indicated by information set to first register means for each cycle of a unit process including the application of an erase voltage for an erase operation or a program voltage for a programming operation, and a verify operation, or every plural cycles, and said first register means is capable of programmably setting information thereto.
2. The microcomputer according to claim 1, wherein said CPU skips said branch process when the information set to the first register means is a first set value, and branches to a process specified based on the first set value when the information is except for the first set value.
3. The microcomputer according to claim 1 or 2, further including second register means (FKEY) readable and writable by said CPU, and
wherein said non-volatile memory sets the setting of a second set value to said second register means as a necessary condition for enabling erase and programming operations, and
said CPU sets a value other than the second set value to said second register means upon said branch and sets the second set value to said second register means for each return from the branch.
4. The microcomputer according to claim 3, wherein the value other than the second set value is code information indicative of the progress of an erase and program process.
5. The microcomputer according to claim 1 or 2, further including an interrupt control circuit for inputting an interrupt request signal therein, and performing arbitration of interrupt requests which compete with one another, and an interrupt priority level-based interrupt mask process to thereby output an interrupt signal to said CPU, and
wherein said CPU causes said interrupt control circuit to carry out a setting for masking an interrupt lower in interrupt priority level than a non-maskable interrupt.
6. The microcomputer according to claim 5, wherein said CPU executes a process for changing the location of an interrupt process routine for a non-maskable interrupt request to an address of a RAM upon execution of the erase and programming.
7. A microcomputer comprising:
an erasable and programmable non-volatile memory; and
a CPU,
wherein said non-volatile memory has an erase and program control program executed by said CPU and used for erase/program-controlling said non-volatile memory,
wherein the erase and program control program allows a process of said CPU to temporarily branch to another branch for each cycle of a unit process including the application of an erase voltage for an erase operation or a program voltage for a programming operation and a verify operation, or every plural cycles, and
wherein said CPU specifies said another process according to a value set to first register means.
8. The microcomputer according to claim 7, wherein said first register means is a register selected from general purpose registers of said CPU.
9. The microcomputer according to claim 7 or 8, further including a RAM disposed in an address space of said CPU, and
wherein said non-volatile memory has a transfer control program for transferring the erase and program control program to said RAM, and said CPU sets parameters for said another process to the erase and program control program transferred to said RAM, based on the set value of the first register means and thereby executes the erase and program control program.
10. A microcomputer comprising:
a non-volatile memory including a plurality of electrically programmable memory cells; and
a central processing unit capable of executing a program control program with respect to said non-volatile memory,
wherein said central processing unit is capable of temporarily branching to a process for a first control program different from the program control program during the execution of the program control program.
11. The microcomputer according to claim 10,
wherein when information is written into the specified memory cell of said electrically programmable plural memory cells, the program control program defines a process for executing a plurality of times of program process loops and writing the corresponding information into the specified memory cell, and
wherein the process of said central processing unit is capable of branching to the first control program for said each program process loop.
12. The microcomputer according to claim 11, further including a first memory circuit programmable by said central processing unit,
wherein when said first memory circuit is set to a first set value by said central processing unit, the process of said central processing unit continuously executes the program control program, and
wherein when said first memory circuit is set to a second set value different from the first set value by said central processing unit, the process of said central processing unit is branched to the first control program for said each program process loop.
13. The microcomputer according to claim 10, wherein each of said plurality of memory cells is an electrically programmable and erasable non-volatile memory cell having a floating gate.
14. The microcomputer according to claim 10, wherein said non-volatile memory is an electrically programmable and erasable flash memory.
15. The microcomputer according to claim 10, wherein said non-volatile memory stores the program control program therein.
16. The microcomputer according to claim 15, further including a memory to which the program control program is transferred from said non-volatile memory.
17. A microcomputer comprising:
a non-volatile memory including a plurality of electrically erasable memory cells; and
a central processing unit capable of executing an erase control program with respect to said non-volatile memory,
wherein said central processing unit is capable of temporarily branching to a process for a first control program different from the erase control program during the execution of the erase control program.
18. The microcomputer according to claim 17,
wherein when information is erased from the specified memory cell of said electrically erasable plural memory cells, the erase control program defines a process for executing a plurality of times of erase process loops and thereby erasing the corresponding information for the specified memory cell, and
wherein the process of said central processing unit is capable of branching to the first control program for said each erase process loop.
19. The microcomputer according to claim 18, further including a first memory circuit programmable by said central processing unit,
wherein when said first memory circuit is set to a first set value by said central processing unit, the process of said central processing unit continuously executes the erase control program, and
wherein when said first memory circuit is set to a second set value different from the first set value by said central processing unit, the process of said central processing unit is branched to the first control program for said each erase process loop.
20. The microcomputer according to claim 17, wherein each of said plurality of memory cells is an electrically programmable and erasable non-volatile memory cell having a floating gate.
21. The microcomputer according to claim 17, wherein said non-volatile memory is an electrically programmable and erasable flash memory.
22. The microcomputer according to claim 17, wherein said non-volatile memory stores the erase control program therein.
23. The microcomputer according to claim 22, further including a memory to which the erase control program is transferred from said non-volatile memory.
24. A microcomputer comprising:
a non-volatile memory including a plurality of electrically erasable and programmable memory cells; and
a central processing unit capable of executing an erase control program and a program control program with respect to said non-volatile memory,
wherein said central processing unit is capable of temporarily branching to a process for a first control program different from the program control program during the execution of the program control program.
25. The microcomputer according to claim 24,
wherein when information is written into the specified memory cell of said electrically programmable plural memory cells, the program control program defines a process for executing a plurality of times of program process loops and thereby writing the corresponding information into the specified memory cell, and
wherein the process of said central processing unit is capable of branching to the first control program for said each program process loop.
26. The microcomputer according to claim 25, further including a first memory circuit programmable by said central processing unit,
wherein when said first memory circuit is set to a first set value by said central processing unit, the process of said central processing unit continuously executes the program control program, and
wherein when said first memory circuit is set to a second set value different from the first set value by said central processing unit, the process of said central processing unit is branched to the first control program for said each program process loop.
27. The microcomputer according to claim 24, wherein each of said plurality of memory cells is a non-volatile memory cell having a floating gate.
28. The microcomputer according to claim 24, wherein said non-volatile memory is a flash memory.
29. The microcomputer according to claim 24, wherein said non-volatile memory stores the program control program therein.
30. The microcomputer according to claim 29, further including a memory to which the program control program is transferred from said non-volatile memory.
31. The microcomputer according to claim 26, wherein said central processing unit is capable of temporarily branching to a process for a first control program different from the erase control program during the execution of the erase control program.
32. The microcomputer according to claim 31,
wherein when information is erased from the specified memory cell of said electrically erasable plural memory cells, the erase control program defines a process for executing a plurality of times of erase process loops and thereby erasing the corresponding information for the specified memory cell, and
wherein the process of said central processing unit is capable of branching to the first control program for said each erase process loop.
33. The microcomputer according to claim 32,
wherein when said first memory circuit is set to the first set value by said central processing unit, the process of said central processing unit continuously executes the erase control program, and
wherein when said first memory circuit is set to the second set value by said central processing unit, the process of said central processing unit is branched to the first control program for said each erase process loop.
34. A programming method for causing a central processing unit included in a microcomputer having the central processing unit and an electrically programmable non-volatile memory to execute a program control program to thereby write information into said non-volatile memory, comprising:
a first step for supplying an address for a memory cell to be programmed in the non-volatile memory;
a second step for supplying information to be programmed to the memory cell; and
a third step for repeatedly writing the data to be programmed into the memory cell,
said third step including:
a voltage applying step for applying a program voltage to the memory cell;
a verify step for confirming whether the data to be programmed has been written into the memory cell;
a step for referring to a value of a predetermined register and transitioning a process of the central processing unit to a predetermined process corresponding to a predetermined value set to the register when the predetermined value is stored in the register; and
a step for returning the process of the central processing unit from the predetermined process to said third step.
35. An erasing method for causing a central processing unit included in a microcomputer having the central processing unit and an electrically erasable non-volatile memory to execute an erase program to thereby erase information stored in a predetermined memory cell of said non-volatile memory, comprising:
a first step for supplying an address for a memory cell to be erased in the non-volatile memory; and
a second step for erasing the information from the memory cell,
said second step including:
a voltage applying step for applying an erase voltage to the memory cell;
a verify step for confirming whether the information has been erased from the memory cell;
a step for referring to a value of a predetermined register and transitioning a process of the central processing unit to a predetermined process corresponding to a predetermined value set to the register when the predetermined value is stored in the register; and
a step for returning the process of the central processing unit from the predetermined process to said second step.
36. A programming method for mounting a microcomputer having a central processing unit and an electrically programmable non-volatile memory to a substrate and thereafter causing the central processing unit to execute a program control program to thereby write information into a predetermined memory cell of said non-volatile memory, comprising:
a first step for supplying an address for a memory cell to be programmed in the non-volatile memory;
a second step for supplying information to be programmed to the memory cell; and
a third step for repeatedly writing the data to be programmed into the memory cell,
said third step including:
a voltage applying step for applying a program voltage to the memory cell;
a verify step for confirming whether the data to be programmed has been written into the memory cell;
a step for causing the process of the central processing unit to transit to a predetermined process; and
a step for returning the process of the central processing unit from the predetermined process to said third step.
37. The programming method according to claim 36, wherein said step for causing the process of the central processing unit to transit to the predetermined process includes a step for referring to a value of a predetermined register and allowing the process thereof to transit to the predetermined process corresponding to the value set to the register where the predetermined value is stored in the register.
38. An erasing method for mounting a microcomputer having a central processing unit and an electrically erasable non-volatile memory to a substrate and thereafter causing the central processing unit to execute an erase program to thereby erase information stored in a predetermined memory cell of said non-volatile memory, comprising:
a first step for supplying an address for a memory cell to be erased in the non-volatile memory; and
a second step for erasing the information from the memory cell,
said second step including:
a voltage applying step for applying an erase voltage to the memory cell;
a verify step for confirming whether the information has been erased from the memory cell;
a step for causing the process of the central processing unit to transit to a predetermined process; and
a step for returning the process of the central processing unit from the predetermined process to said second step.
39. The erasing method according to claim 38, wherein said step for causing the process of the central processing unit to transit to the predetermined process includes a step for referring to a value of a predetermined register and allowing the process thereof to transit to the predetermined process corresponding to the value set to the register where the predetermined value is stored in the register.
US10/080,681 2001-03-30 2002-02-25 Microcomputer, programming method and erasing method Abandoned US20020144053A1 (en)

Priority Applications (2)

Application Number Priority Date Filing Date Title
US11/037,261 US7194571B2 (en) 2001-03-30 2005-01-19 Microcomputer, programming method and erasing method
US11/672,468 US7310700B2 (en) 2001-03-30 2007-02-07 Microcomputer, programming method and erasing method

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
JP2001097808A JP4230122B2 (en) 2001-03-30 2001-03-30 Microcomputer, writing method and erasing method
JP2001-097808 2001-03-30

Related Child Applications (1)

Application Number Title Priority Date Filing Date
US11/037,261 Continuation US7194571B2 (en) 2001-03-30 2005-01-19 Microcomputer, programming method and erasing method

Publications (1)

Publication Number Publication Date
US20020144053A1 true US20020144053A1 (en) 2002-10-03

Family

ID=18951544

Family Applications (3)

Application Number Title Priority Date Filing Date
US10/080,681 Abandoned US20020144053A1 (en) 2001-03-30 2002-02-25 Microcomputer, programming method and erasing method
US11/037,261 Expired - Fee Related US7194571B2 (en) 2001-03-30 2005-01-19 Microcomputer, programming method and erasing method
US11/672,468 Expired - Fee Related US7310700B2 (en) 2001-03-30 2007-02-07 Microcomputer, programming method and erasing method

Family Applications After (2)

Application Number Title Priority Date Filing Date
US11/037,261 Expired - Fee Related US7194571B2 (en) 2001-03-30 2005-01-19 Microcomputer, programming method and erasing method
US11/672,468 Expired - Fee Related US7310700B2 (en) 2001-03-30 2007-02-07 Microcomputer, programming method and erasing method

Country Status (3)

Country Link
US (3) US20020144053A1 (en)
JP (1) JP4230122B2 (en)
KR (1) KR20020077050A (en)

Cited By (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20030225962A1 (en) * 2002-05-31 2003-12-04 Hitachi, Ltd. Memory card and memory card system
US20040153906A1 (en) * 2002-12-26 2004-08-05 Fujitsu Limited Microcomputer
US20060252502A1 (en) * 1997-06-23 2006-11-09 Walker Jay S Gaming device for a flat rate play session and a method of operating same
US20130290587A1 (en) * 2012-04-27 2013-10-31 Denso Corporation Microcomputer
US10983584B2 (en) * 2018-11-12 2021-04-20 Samsung Electronics Co., Ltd. Electronic device and operation method thereof
US20210281423A1 (en) * 2020-03-09 2021-09-09 Kabushiki Kaisha Toshiba Information processing device
US20220156004A1 (en) * 2020-11-17 2022-05-19 SK Hynix Inc. Storage device and method of operating the same

Families Citing this family (12)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP4848126B2 (en) * 2004-11-04 2011-12-28 オンセミコンダクター・トレーディング・リミテッド Microcomputer, data protection method for nonvolatile memory in microcomputer
KR101395778B1 (en) * 2007-03-14 2014-05-19 삼성전자주식회사 Memory card and memory system including the same and operating method thereof
US7864589B2 (en) * 2008-08-14 2011-01-04 Micron Technology, Inc. Mitigation of runaway programming of a memory device
US10838646B2 (en) 2011-07-28 2020-11-17 Netlist, Inc. Method and apparatus for presearching stored data
US10380022B2 (en) 2011-07-28 2019-08-13 Netlist, Inc. Hybrid memory module and system and method of operating the same
US10198350B2 (en) 2011-07-28 2019-02-05 Netlist, Inc. Memory module having volatile and non-volatile memory subsystems and method of operation
KR20150050879A (en) * 2013-11-01 2015-05-11 에스케이하이닉스 주식회사 Semiconductor memory apparatus, memory system and method for operating thereof
US10248328B2 (en) 2013-11-07 2019-04-02 Netlist, Inc. Direct data move between DRAM and storage on a memory module
WO2015070110A2 (en) 2013-11-07 2015-05-14 Netlist, Inc. Hybrid memory module and system and method of operating the same
US11182284B2 (en) 2013-11-07 2021-11-23 Netlist, Inc. Memory module having volatile and non-volatile memory subsystems and method of operation
EP3286654B1 (en) * 2015-04-20 2021-10-27 Netlist, Inc. Memory module and system and method of operation
CN109343893B (en) * 2018-09-11 2021-05-18 中国科学院长春光学精密机械与物理研究所 Parameter binding system and binding method for aerial remote sensing equipment

Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US5444664A (en) * 1993-07-13 1995-08-22 Hitachi, Ltd. Flash memory and a microcomputer
US5581503A (en) * 1992-03-17 1996-12-03 Hitachi, Ltd. Data line disturbance free memory block divided flash memory and microcomputer having flash memory therein

Family Cites Families (10)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US5355464A (en) * 1991-02-11 1994-10-11 Intel Corporation Circuitry and method for suspending the automated erasure of a non-volatile semiconductor memory
JPH05266219A (en) 1992-03-17 1993-10-15 Hitachi Ltd Microcomputer
FR2711831B1 (en) * 1993-10-26 1997-09-26 Intel Corp Method and circuit for storing and prioritizing erasure orders in a memory device.
US6738894B1 (en) * 1995-02-07 2004-05-18 Hitachi, Ltd. Data processor
JP3292864B2 (en) * 1995-02-07 2002-06-17 株式会社日立製作所 Data processing device
US5805501A (en) * 1996-05-22 1998-09-08 Macronix International Co., Ltd. Flash memory device with multiple checkpoint erase suspend logic
JP3173407B2 (en) * 1997-02-05 2001-06-04 日本電気株式会社 Microcomputer with built-in flash EEPROM
KR100313939B1 (en) * 1998-12-05 2001-12-20 김영환 Interrupt Controller
JP3727485B2 (en) * 1999-04-02 2005-12-14 シャープ株式会社 Microcomputer with built-in nonvolatile memory
JP4535565B2 (en) * 2000-06-09 2010-09-01 ルネサスエレクトロニクス株式会社 Nonvolatile semiconductor memory device

Patent Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US5581503A (en) * 1992-03-17 1996-12-03 Hitachi, Ltd. Data line disturbance free memory block divided flash memory and microcomputer having flash memory therein
US5444664A (en) * 1993-07-13 1995-08-22 Hitachi, Ltd. Flash memory and a microcomputer

Cited By (10)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20060252502A1 (en) * 1997-06-23 2006-11-09 Walker Jay S Gaming device for a flat rate play session and a method of operating same
US20030225962A1 (en) * 2002-05-31 2003-12-04 Hitachi, Ltd. Memory card and memory card system
US20040153906A1 (en) * 2002-12-26 2004-08-05 Fujitsu Limited Microcomputer
US20130290587A1 (en) * 2012-04-27 2013-10-31 Denso Corporation Microcomputer
US9501434B2 (en) * 2012-04-27 2016-11-22 Denso Corporation Microcomputer
US10983584B2 (en) * 2018-11-12 2021-04-20 Samsung Electronics Co., Ltd. Electronic device and operation method thereof
US20210281423A1 (en) * 2020-03-09 2021-09-09 Kabushiki Kaisha Toshiba Information processing device
US11888990B2 (en) * 2020-03-09 2024-01-30 Kabushiki Kaisha Toshiba Information processing device controlling analysis of a program being executed based on a result of verification of an analysis program
US20220156004A1 (en) * 2020-11-17 2022-05-19 SK Hynix Inc. Storage device and method of operating the same
US11789650B2 (en) * 2020-11-17 2023-10-17 SK Hynix Inc. Storage device and method of operating the same

Also Published As

Publication number Publication date
JP2002297562A (en) 2002-10-11
US20070130416A1 (en) 2007-06-07
JP4230122B2 (en) 2009-02-25
KR20020077050A (en) 2002-10-11
US7310700B2 (en) 2007-12-18
US20050122777A1 (en) 2005-06-09
US7194571B2 (en) 2007-03-20

Similar Documents

Publication Publication Date Title
US7194571B2 (en) Microcomputer, programming method and erasing method
US7805562B2 (en) Microcomputer with configurable communication interfacing
US5901330A (en) In-circuit programming architecture with ROM and flash memory
EP0554917B1 (en) Digital signal processing system having two instruction memories accessed by a processor under control of host
US20040003167A1 (en) Microcomputer
US20020129195A1 (en) Microcomputer with built-in programmable nonvolatile memory
JP3563768B2 (en) ROM program change device
JP3173407B2 (en) Microcomputer with built-in flash EEPROM
US7096351B2 (en) Single-chip microcomputer and boot region switching method thereof
JPH06275084A (en) Nonvolatile semiconductor storage and data processor using the same
US7093042B2 (en) Microcomputer and data processing device
US20020083283A1 (en) Control of the access to a memory integrated with a microprocessor
JP2003044457A (en) Data processor
KR100465610B1 (en) Microcomputer with embedded flash memory having on-chip programming capability and method of programming data into the embedded flash memory
JP3866269B2 (en) Microcomputer
JP2010170579A (en) Data processor
JP2008186476A (en) Microcomputer
JP3633812B2 (en) Flash memory control system with flash farm download
JP2002287994A (en) Microcontroller
JPH11272642A (en) 1-chip microcomputer and start address setting method
JPH11167484A (en) Nonvolatile memory mixed-loaded microcomputer, its program changing history managing method and recording medium recording program changing history managing program of its microcomputer
JP2000207217A (en) Data processor, and program downloading method
JP2007095093A (en) Microcomputer
JP2008004258A (en) Manufacturing method of semiconductor system
JP2008276938A (en) Microcomputer

Legal Events

Date Code Title Description
AS Assignment

Owner name: HITACHI HOKKAI SEMICONDUCTOR, LTD., JAPAN

Free format text: ASSIGNMENT OF ASSIGNORS INTEREST;ASSIGNORS:YADA, NAOKI;ISHIKAWA, EIICHI;REEL/FRAME:012634/0817;SIGNING DATES FROM 20020215 TO 20020218

Owner name: HITACHI, LTD., JAPAN

Free format text: ASSIGNMENT OF ASSIGNORS INTEREST;ASSIGNORS:YADA, NAOKI;ISHIKAWA, EIICHI;REEL/FRAME:012634/0817;SIGNING DATES FROM 20020215 TO 20020218

AS Assignment

Owner name: RENESAS TECHNOLOGY CORPORATION, JAPAN

Free format text: ASSIGNMENT OF ASSIGNORS INTEREST;ASSIGNOR:HITACHI, LTD.;REEL/FRAME:014190/0106

Effective date: 20030912

STCB Information on status: application discontinuation

Free format text: ABANDONED -- FAILURE TO RESPOND TO AN OFFICE ACTION