WO2006040798A1 - 半導体集積回路装置および電子システム - Google Patents

半導体集積回路装置および電子システム Download PDF

Info

Publication number
WO2006040798A1
WO2006040798A1 PCT/JP2004/014939 JP2004014939W WO2006040798A1 WO 2006040798 A1 WO2006040798 A1 WO 2006040798A1 JP 2004014939 W JP2004014939 W JP 2004014939W WO 2006040798 A1 WO2006040798 A1 WO 2006040798A1
Authority
WO
WIPO (PCT)
Prior art keywords
area
integrated circuit
semiconductor integrated
memory area
circuit device
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.)
Ceased
Application number
PCT/JP2004/014939
Other languages
English (en)
French (fr)
Inventor
Masashi Oshiba
Hiroshi Kishi
Yoshiaki Sato
Yoko Yamaki
Kentaro Yamakawa
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
Original Assignee
Renesas Technology Corp
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 Renesas Technology Corp filed Critical Renesas Technology Corp
Priority to US10/583,778 priority Critical patent/US20070133280A1/en
Priority to PCT/JP2004/014939 priority patent/WO2006040798A1/ja
Priority to JP2006540783A priority patent/JPWO2006040798A1/ja
Publication of WO2006040798A1 publication Critical patent/WO2006040798A1/ja
Anticipated expiration legal-status Critical
Ceased legal-status Critical Current

Links

Classifications

    • GPHYSICS
    • G11INFORMATION STORAGE
    • G11CSTATIC STORES
    • G11C16/00Erasable programmable read-only memories
    • G11C16/02Erasable programmable read-only memories electrically programmable
    • G11C16/06Auxiliary circuits, e.g. for writing into memory
    • G11C16/22Safety or protection circuits preventing unauthorised or accidental access to memory cells
    • GPHYSICS
    • G06COMPUTING OR CALCULATING; COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F12/00Accessing, addressing or allocating within memory systems or architectures
    • G06F12/14Protection against unauthorised use of memory or access to memory
    • G06F12/1416Protection against unauthorised use of memory or access to memory by checking the object accessibility, e.g. type of access defined by the memory independently of subject rights
    • G06F12/1425Protection against unauthorised use of memory or access to memory by checking the object accessibility, e.g. type of access defined by the memory independently of subject rights the protection being physical, e.g. cell, word, block
    • G06F12/1433Protection against unauthorised use of memory or access to memory by checking the object accessibility, e.g. type of access defined by the memory independently of subject rights the protection being physical, e.g. cell, word, block for a module or a part of a module

Definitions

  • the present invention relates to a data protection technique in a nonvolatile semiconductor memory, and more particularly to a technique that is effective when applied to prevention of program copy and rewrite in a semiconductor integrated circuit device incorporating a nonvolatile semiconductor memory. is there.
  • Some of these microcomputers with a built-in flash memory have a protect function that prohibits rewriting of application programs stored in the flash memory to maintain confidentiality.
  • EPROM Erasable Programmable Read Only Memory
  • a program is stored in a protection block set by a programmer.
  • Patent Document 1 Japanese Patent Laid-Open No. 2000-76133
  • the flash memory can easily rewrite an application program or the like while mounted on a printed wiring board such as an electronic system by activating a boot mode. May be read or rewritten.
  • RAM Random Access Memory
  • An object of the present invention is to provide a technique capable of reliably preventing unauthorized copying or falsification of a program by a third party by prohibiting reading in a specific memory area of a nonvolatile semiconductor memory. There is.
  • the present invention provides a memory array unit having a plurality of nonvolatile memory cells, a write operation for storing information in the nonvolatile memory cells, a read operation for reading information stored in the nonvolatile memory cells, and the nonvolatile memory cell And a volatile memory used as a work area for a program stored in the nonvolatile memory unit, and a control unit for controlling each operation of the erase operation for erasing information stored in the nonvolatile memory cell
  • a central processing unit capable of executing a predetermined process and instructing the nonvolatile storage unit to perform an operation instruction, and a protection operation control unit for controlling a read operation of the nonvolatile storage unit and the volatile storage unit
  • the memory array unit is prohibited from reading and writing information stored under the control of the protect operation control unit.
  • Protect memory area, and the volatile memory section is a second protect memory area where reading and writing are prohibited except for the first protected memory area of the memory array section under the control of the protect operation control section.
  • a semiconductor integrated circuit device of the present invention includes a memory array unit having a plurality of nonvolatile memory cells, a write operation for storing information in the nonvolatile memory cells, and information stored in the nonvolatile memory cells.
  • a non-volatile storage unit including a read-out read operation and a control unit that controls each operation of an erase operation for erasing information stored in the non-volatile memory cell; a volatile storage unit;
  • a semiconductor integrated circuit device having a central processing unit capable of giving an operation instruction to a nonvolatile storage unit, and a protection operation control unit for controlling a read operation of the nonvolatile storage unit and the volatile storage unit.
  • the memory array section has a first protect memory area in which reading and writing of information stored under the control of the protect operation control section is prohibited, and a volatile memory area. Parts are those out reading the first protected memory area other than the force of the memory array and writing had a second protected memory area is prohibited by the control of the protection operation control unit.
  • the present invention relates to a memory array section having a plurality of nonvolatile memory cells, a write operation for storing information in the nonvolatile memory cells, a read operation for reading information stored in the nonvolatile memory cells, and the nonvolatile memory cell
  • a nonvolatile semiconductor memory device comprising a control unit for controlling each operation of an erase operation for erasing information stored in a nonvolatile memory cell, and a volatile memory used as a work area for a program stored in the nonvolatile semiconductor memory device Controls read operations of a central processing unit, a nonvolatile semiconductor storage device, and a volatile semiconductor storage device that are capable of executing predetermined processing and instructing operation to the nonvolatile semiconductor storage device with a semiconductor storage device
  • An electronic system having a semiconductor integrated circuit device including an off-prote operation control unit, wherein the memory array unit has a protect operation control
  • the volatile semiconductor memory device has a first protected memory area where reading of stored information is prohibited by the control of the volatile semiconductor memory device.
  • FIG. 1 is a block diagram of a semiconductor integrated circuit device according to a first embodiment of the present invention.
  • FIG. 2 is an explanatory diagram showing an example of a memory map in a flash memory provided in the semiconductor integrated circuit device of FIG.
  • FIG. 3 is an explanatory view showing an example of a memory map in a RAM provided in the semiconductor integrated circuit device of FIG. 1.
  • FIG. 4 is an explanatory diagram showing a partial configuration example of a bus state controller provided in the semiconductor integrated circuit device of FIG. 1.
  • FIG. 5 is a block diagram of an erase prohibition control circuit and a rewrite prohibition control circuit in the flash memory provided in the semiconductor integrated circuit device of FIG. 1.
  • FIG. 6 is a timing chart showing an example of a read control operation in a user access area of a flash memory provided in the semiconductor integrated circuit device of FIG.
  • FIG. 7 is a timing chart showing an example of a control operation when reading the user access area power protection area of the flash memory provided in the semiconductor integrated circuit device of FIG.
  • FIG. 8 is a timing chart showing an example of a control operation when reading out the protect area from the protect area of the flash memory provided in the semiconductor integrated circuit device of FIG.
  • FIG. 9 is a timing chart showing an example of a control operation when reading data in the protected area of the RAM from the protected area of the flash memory provided in the semiconductor integrated circuit device of FIG.
  • FIG. 10 is an explanatory view showing a processing example of a RAM provided in the semiconductor integrated circuit device of FIG. 1.
  • FIG. 11 is a flowchart showing a key code setting example by the first user in the semiconductor integrated circuit device of FIG. 1.
  • FIG. 12 is a flowchart showing a key code setting example by an end user in the semiconductor integrated circuit device of FIG.
  • FIG. 13 is a block diagram of a semiconductor integrated circuit device according to a second embodiment of the present invention.
  • FIG. 14 is an explanatory diagram showing a reset sequence in the semiconductor integrated circuit device of FIG.
  • FIG. 15 is a flowchart showing a setting process of a protection process control unit in the reset sequence of FIG.
  • FIG. 16 is a flowchart showing a protection area arbitrary setting process in the flash memory provided in the semiconductor integrated circuit device of FIG. 13;
  • FIG. 17 is a supplementary explanatory diagram of a memory map of the flash memory in FIG.
  • FIG. 1 is a block diagram of the semiconductor integrated circuit device according to the first embodiment of the present invention.
  • FIG. 2 is an explanatory diagram showing an example of a memory map in a flash memory provided in the semiconductor integrated circuit device of FIG.
  • FIG. 4 is an explanatory diagram showing an example of a memory map in a RAM provided in the semiconductor integrated circuit device of FIG. 1, and
  • FIG. 4 shows a partial configuration example of a bus state controller provided in the semiconductor integrated circuit device of FIG.
  • FIG. 5 shows an erase prohibition control circuit and rewrite prohibition in the flash memory provided in the semiconductor integrated circuit device of FIG.
  • FIG. 6 is a timing chart showing an example of a read control operation in a user access area of a flash memory provided in the semiconductor integrated circuit device of FIG. 1, and FIG.
  • FIG. 7 is a semiconductor integrated circuit of FIG.
  • FIG. 8 is a timing chart showing an example of the control operation when reading the protected area of the flash memory provided in the device.
  • FIG. 8 shows the protected area from the protected area of the flash memory provided in the semiconductor integrated circuit device of FIG.
  • FIG. 9 is a timing chart showing an example of the control operation when reading data
  • FIG. 9 is a timing chart showing an example of the control operation when reading the data in the protected area of the RAM in the protect area of the flash memory provided in the semiconductor integrated circuit device of FIG. 10 is provided in the semiconductor integrated circuit device of FIG.
  • FIG. 11 is a flowchart showing an example of key code setting by the first user in the semiconductor integrated circuit device of FIG. 1, and
  • FIG. 12 is an end user in the semiconductor integrated circuit device of FIG. It is a flowchart which shows the example of a setting of the key code by.
  • the semiconductor integrated circuit device 1 includes a CPU (central processing unit) 2, a bus state controller (protection operation control unit) 3, a RAM (volatile storage unit). 4) Peripheral circuit 6 including SCI (Serial Communication Interface) 5 and the like, and non-volatile semiconductor memory exemplified by flash memory 7 are also configured.
  • CPU central processing unit
  • bus state controller protection operation control unit
  • RAM volatile storage unit
  • the CPU 2 reads instructions stored in the flash memory (nonvolatile storage unit) 7 and performs predetermined processing.
  • the bus state controller 3 controls the transfer of signals in the internal bus B including the address bus and the data bus, and also controls the state of the internal bus B.
  • RAM (volatile memory) 4 is a memory that can be read and written at any time, and is used as a work area for CPU2.
  • the SCI 5 is an interface that performs serial communication with an externally connected device.
  • Peripheral circuit 6 is also configured with other powers such as timer, WDT (Watch Dog Timer), TPU (Timer Pulse Unit), AZD (AnalogZDigital) change ⁇ , and DZA (DigitalZAn alog) change!
  • WDT Watch Dog Timer
  • TPU Timer Pulse Unit
  • AZD AnalogZDigital
  • DZA DigitalZAn alog
  • the timer is, for example, a timer based on an 8-bit counter.
  • the WDT monitors the runaway of the semiconductor integrated circuit device 1.
  • the TPU is a timer that can output a PWM (Pulse Width Modulation) waveform.
  • AZD converter converts analog signal Convert to digital signal and output.
  • the DZA converter converts a digital signal into an analog signal and outputs it.
  • the flash memory 7 is a nonvolatile semiconductor memory capable of electrically rewriting data and erasing data, and stores a control program including a program command executed by the CPU 2.
  • the flash memory 7 performs data writing, Z reading, and erasing in accordance with instructions from the CPU 2.
  • the CPU 2, the bus state controller 3, the peripheral circuit 6 including the RAM 4, the SCI 5, and the like, and the flash memory 7 are connected to each other by an internal bus B.
  • the CPU 2 is connected so that the value of the program counter indicating the address of the next instruction to be read, the write signal permitting writing, and the read signal permitting reading are input to the bus state controller 3. And
  • the RAM 4 is connected such that the RAM select signal Sl, the write signal, and the read signal output from the bus state controller 3 are input thereto.
  • the RAM select signal S1 is a signal for selecting the RAM4.
  • the write signal is a signal that allows the RAM 4 to be written, and the read signal is a signal that permits the RAM 4 to be read.
  • the SCI 5 is connected so that a serial select signal, a write signal, and a read signal are input thereto.
  • the serial select signal is a signal for selecting SCI5.
  • the write signal is a signal that permits SCI5 write
  • the read signal is a signal that permits SCI5 read.
  • the flash memory 7 is connected so that a flash memory select signal, a write signal, and a read signal are input thereto.
  • the flash memory select signal is a signal for selecting the flash memory 7.
  • the write signal is a signal that permits writing of the flash memory 7
  • the read signal is a signal that permits reading of the flash memory 7.
  • the flash memory 7 includes a memory mat (memory array unit) 7a and a control circuit (control unit) 7b.
  • the memory mat 7a regularly arranges memory cells, which are the minimum unit of storage, in an array, and includes peripheral circuits such as an address buffer, a row decoder, a column decoder, and a sense amplifier.
  • the control circuit 7b temporarily receives various control signals input from CPU2. And control the operation logic.
  • FIG. 2 is an explanatory diagram showing an example of a memory map in the memory mat 7 a of the flash memory 7.
  • a memory mat 7a As shown in the figure, a memory mat 7a, a user access area UA, a protect area (first protected memory area) PA, and a force are also configured.
  • User Access Area UA consists of multiple areas (blocks) that users can access.
  • the protected area PA is an area (block) in which programs and data are stored, and reading of these programs and data is restricted.
  • the protected area PA is not limited to one continuous address area, and may be arranged in a plurality of areas, for example.
  • FIG. 3 is an explanatory diagram showing an example of a memory map in the RAM 4.
  • a user access area UA1 and a protect area (second protect memory area) PA1 are also configured.
  • the user access area UA1 is an area for developing data such as the flash memory 7, and the protect area PA1 is used as a work area for programs stored in the protect area PA (first protect memory area) of the flash memory 7. It is an area that is
  • the program and data stored in the protection area PA of the memory mat 7a can be read by the program in the protection area PA.
  • the data stored in the protected area PA1 of the RAM4 can be read from the protected area PA of the memory mat 7a.
  • Other areas (the user access area UA of the memory mat 7a and the RAM4 User access area UA, protect area PA1) Powerful reading is disabled.
  • the flash memory 7 stores programs and data in the protected area PA of the flash memory 7 until the predetermined key code is set in the key code area KA (Fig. 5) described later. It is possible to rewrite Z erase from UA1. Until a predetermined key code is set, the flash memory 7 can be accessed from any of the protected area PA, user access area UA, and user access area UA1. This area can be accessed.
  • the data stored in the protected area PA1 of the RAM 4 can be rewritten / erased from the protected area PA of the flash memory 7, but other areas (user access to the flash memory 7) Area UA, RAM4 user access area U Al, protect area PA1) Powerful rewriting Z erasure is not possible.
  • the protected area PA1 of the RAM is prohibited from being rewritten or erased by other than the protected area PA of the flash memory 7 under the control of the protect operation control unit.
  • H'FF is set in accordance with the initial value data written in the flash memory 7, but the data read out in this case is only required to be in a state other than the high impedance state (Hi-Z).
  • Hi-Z high impedance state
  • it may be meaningless data such as H'00 or previous value hold, or any value set by the user.
  • the force set to H'00 in accordance with the NOP instruction of RAM4 is sufficient if the data to be read is in a state other than the high impedance state (Hi-Z). It can be meaningful data or any value set by the user.
  • FIG. 4 is an explanatory diagram showing an example of a partial configuration of the bus state controller 3.
  • the bus state controller 3 includes selectors 8-11 and a NOR circuit 12.
  • One input section of the selector 8-11 is connected so that an address signal from which the CPU2 (Fig. 1) force is also output is input, and the other input section of the selector 8-11 is connected to the other input section. , Each is connected so that the program counter value (PC value) output from CPU2 can be input.
  • PC value program counter value
  • Selector 8 is an address H, 00—0000—H, 00_FFFF, or an address H, 02—0000—H, 0 3_FFFF, or flash indicating the user access area UA of the flash memory 7 (FIG. 2).
  • Flash memory select signal when address H, 01—0000—H 'Ol—FFFF indicating the protected area PA of memory 7 ( Figure 2) and the program counter value becomes H, 01—0000—01—FFFF '0' (Lo level signal) that becomes active is output, and in other cases, '1' (Hi level signal) that outputs the flash memory select signal power S inactive is output.
  • the address value output by CPU 2 indicates the user access area UA of the flash memory 7, access is possible regardless of the program counter value.
  • the address value indicates the protected area PA of the flash memory 7 and the value of the program counter also indicates the protected area PA of the flash memory 7, the flash memory 7 is accessible, that is, the select signal is active.
  • the selector 9 has an address signal indicating the address H'FF—D800—H′FF—EFFF indicating the user access area UA1 (FIG. 3) of RAM4, or the address indicating the protection area PA1 (FIG. 3) of RAM4.
  • the RAM select signal becomes active when H'FF-D000-H'FF-D7FF and the program counter value is H, 01-0000- 01_FFFF (address indicating the protected area PA of flash memory 7).
  • '0' (Lo level signal) is output, and in other cases, the RAM select signal becomes inactive '(Hi level signal).
  • the address value output by CPU2 indicates the user access area UA1 of RAM4
  • access is possible regardless of the program counter value.
  • the program counter value indicates the protected area PA of the flash memory 7 and the address value indicates the protected area PA1 of the RAM 4
  • the RAM 4 is accessible.
  • the selector 10 has an address signal other than addresses H, 01—0000—H, 01—FFFF indicating the protected area PA of the flash memory 7 and a program counter value other than H, 01—0000—01—FFFF.
  • the signal becomes 0, the signal of 0 is output, the address H, 01—0000—H, 01 FFFF, and the program counter value is H, 01 0000—01 FFFF Outputs a '1' signal.
  • the selector 11 has an address signal other than the address H, FF-DOOO-H'FF-D7FF indicating the protected area PA1 of RAM4, and the program counter value is other than H, 01- OOOO-01-FFFF If the address value is H'FF—D000—H, FF—D7FF, and the program counter value is H, 01—0000—01—FFFF, then “1” is output. The signal is output.
  • the selection condition of the flash memory 7 when reading and writing the protected area PA of the flash memory 7 includes the program counter value, the address signal value, and the force difference between the protected area of the flash memory 7.
  • the flash memory select signal is valid only when it matches PA.
  • the flash memory select signal is invalid except for the above case.
  • the RAM 4 selection condition when the protected area PA 1 of the RAM 4 is read and Z-written is as follows.
  • the program counter value is the protected area PA of the flash memory 7 and the address value is the protected area of the RAM 4.
  • the RAM select signal is valid only when PA1 is selected. In all other cases, the RAM select signal is invalid.
  • the negative logical sum circuit 12 takes a negative logical sum of the signal output from the selector 10 and the read signal and outputs it to the control unit of the driver 14.
  • the NOR circuit 12 has an address signal other than the address H, 01—0000—H, 01—FFF F indicating the protected area PA of the flash memory 7 and the program counter value other than H ′ 01—0000—01—FFFF
  • the driver 14 When the active read signal (, 0,) is input, the driver 14 outputs a control signal so that H'FFFF, which is the initial value of the flash memory 7, is output.
  • H'FFFF is output as the data signal for internal bus B.
  • the value of the output signal is not limited to H ′ FF FF, and the output value can be arbitrarily set. In other words, any value can be output as long as it is not read data from the flash memory 7 according to the address signal output by the CPU 2.
  • the negative OR circuit 13 takes a negative OR of the signal output from the selector 11 and the read signal and outputs the result to the control unit of the driver 15.
  • the address signal is R Active read signal (, 0,) with address H, FF—DOOO—H, FF—D7FF indicating the AM4 protected area PA1, and the program counter value is other than H, 01—0000—H, 01—FFFF
  • a control signal is output so that H 'OOOO, which is a value that matches the NOP instruction of RAM4, is output from the driver 15.
  • H '0000 is output as the data signal for internal bus B.
  • the value of the output signal is not limited to H ′ O 000, and the output value can be arbitrarily set. In other words, any value can be output as long as it is not read data from RAM4 according to the address signal output by CPU2.
  • the flash memory 7 or '0' when the flash memory 7 or '0' is output from the CPU 2 and the flash memory select signal RAM select signal is invalid, the flash memory 7 and the RAM 4 are not accessed. Since it is prohibited, the data signal is, for example, in the state of holding the previous value.
  • FIG. 5 shows an erase prohibition control circuit (erase prohibition control unit) 16 provided in the control circuit 7b that controls the operation of the flash memory 7 in the flash memory 7, and a rewrite prohibition control circuit (rewrite prohibition control).
  • Part 17 is a block diagram.
  • the erasure prohibition control circuit 16 is a circuit that controls the erasure prohibition of the flash memory 7.
  • the key code (first set value) written in the key code area KA of the memory mat 7a in advance is preset. If the key code (second set value) matches, the deletion of the protected area PA is prohibited when the data in the protected area PA of the memory mat 7a is deleted.
  • the erasure prohibition control circuit 16 includes a key code generation unit (key code generation circuit) 18, an exclusive negative OR circuit (erase control circuit) 19, and an AND circuit (erase control circuit) 20. Yes.
  • the key code generator 18 also has a circuit power for outputting a preset key code (second set value, for example, H ′ 1234) by the node software.
  • a key code ('1234) generated by the key code generation unit 18 is connected to one input unit of the exclusive negative OR circuit 19 so that the exclusive negative OR Circuit 19 The other input section is connected so that the key code (first set value) stored in the key code area ⁇ is input.
  • One input part of the AND circuit 20 is connected so that the erase block signal EB9 output from the erase block selector EBS is input.
  • the erase block selector EBS is provided in the control circuit 7b and is one of the registers for selecting which block is to be erased. This erase block selector EBS outputs a zero erase block signal EB9 when erasing the protected area PA (Block 9) in the memory mat 7a of the flash memory 7.
  • the other input part of the AND circuit 20 is connected so that the signal output from the exclusive NOR circuit 19 is input.
  • the output of the AND circuit 20 is connected to the input of the read Z write control circuit 30 that controls the read Z write of the flash memory 7.
  • the erase block control signal EBC9 is output from the output of the AND circuit 20. Is output.
  • the erasure prohibition control circuit 16 controls the erase block control signal to be invalid, and the read Z write control circuit 30 disables the erase operation.
  • the read Z write control circuit 30 performs erasure control on the protected area PA (Block9).
  • the erasure prohibition control circuit 16 may be prepared for each protection area. As a result, erasure control can be performed for multiple protected areas.
  • the rewrite prohibition control circuit 17 includes a key code generation unit (key code generation circuit) 21, an address determination unit (address determination circuit) 22, an exclusive NOR circuit (key code determination unit) 23, an inverter ( Rewrite control circuit) 24-26, NAND circuit (rewrite control circuit) 27, holding circuit (rewrite control circuit) 28, and logical product circuit (rewrite control circuit) 29.
  • the key code generation unit 21 also has a circuit power for outputting a preset key code (third set value, for example, H '12 34) by using software.
  • the key code ( ⁇ '1234) generated by the key code generation unit 18 is input to one input unit of the exclusive NOR circuit 23.
  • the other input part of the exclusive NOR circuit 23 is connected so that the key code (first set value) stored in the key code area KA is input. It has been.
  • An address signal is input to the address determination unit 22, and when the address signal is an address H, 01-0000-H, 01-FFFF, 0 is set. Output otherwise, output '1'.
  • the input parts of the inverters 24 to 26 are connected so that the memory select signal (Fig. 1), the write signal (Fig. 1), and the determination signal output from the address determination unit 22 are input, respectively. ing.
  • the output part of the exclusive NAND circuit 23 and the output parts of the inverters 24 to 26 are connected to the input part of the NAND circuit 27, respectively. Is connected to the input of the holding circuit 28.
  • the holding circuit 28 is a circuit that holds the signal state until writing to the flash memory 7 occurs.
  • One input section of the AND circuit 29 is connected so that the program mode signal P output from the programming bit PB is input.
  • the programming bit PB is a bit that cancels the program mode that starts rewriting and makes a Z transition. When it is “0”, the program mode is canceled, and when it is “1”, it shifts to the program mode.
  • the input part of the read Z write control circuit 30 is connected to the output part of the AND circuit 29, and the program mode signal P is also output from the output part of the AND circuit 29.
  • the read Z write control circuit 30 performs rewrite control on the protect area PA (Block 9).
  • the key code is H, 1234.
  • the key code is stored in the flash memory 7 and can be any data other than the initial value ( ⁇ 'FFFF)! /, .
  • the instructions executed by CPU 2 shown in FIGS. 6 to 9 are one specific example, Various instructions are executed without being limited thereto.
  • the value of the instruction or data stored in the memory corresponding to the address (for example, “H, 6828” is stored at addresses H '00 to 4008 in Fig. 6) varies depending on the program.
  • access to various memories and other peripheral circuits is controlled by comparing the address value and program counter value by the nos state controller 3.
  • FIG. 6 shows an explanatory diagram of the read control by the flash memory 7, and the lower part thereof shows a timing chart of each part signal.
  • the CPU2 program counter indicates the addresses ⁇ , 00-4000, outputs the addresses ,, 00-4000 to the internal bus, and sequentially executes the instructions at addresses ⁇ , 00-4000 from the CPU 2 memory. read out. Subsequently, CPU2 stores H and 0000 in the general-purpose register (E2).
  • CPU2 reads the instruction at addresses H, 00 to 4004, and then reads addresses H and 00 to 4006, and stores H'OCOO in the general-purpose register (R2).
  • CPU 2 reads the instruction at addresses H, 00 to 4008, analyzes the instruction (reads the data stored in the memory indicated by the address value indicated by general-purpose register ER2, and then reads the instruction). Execute the instruction to read the data at address H'00_0C00 and store H and 1234 in the general-purpose register (R0L).
  • FIG. 7 an explanatory diagram of read control by the flash memory 7 is shown above, and a timing chart of each part signal is shown below.
  • the timing chart shows the clock signal ⁇ , the value of the program counter output from the CPU 2, the address signal output from the CPU 2, the flash memory select signal output from the bus state controller 3, the data, and the program counter from top to bottom.
  • Indicates a status signal (PC H '01 —xxxx?) Indicating whether or not the protected area PA of the flash memory 7 is used.
  • the program counter power address H'OO-400A of CPU2 is indicated, address H'00-400A is output to the internal bus, the instructions at addresses H, 00-400A are read out sequentially, and the general-purpose register Store H'0001 in (E2).
  • CPU2 sequentially reads address H, 00-400E and address H'OO-4010, and stores H, 0000 in general-purpose register (R2).
  • CPU2 reads and analyzes the instruction at address H'OO-4012 (reads the data stored in the memory indicated by the address value indicated by general-purpose register ER2). Based on this, CPU2 reads the address Read H, 01—0000 data.
  • the address H'01-0000 is in the protected area PA of the flash memory 7, and the value of the program counter output from the CPU2 is outside the protected area PA (here, H'OO-4014) Therefore, the flash memory select signal output from the bus state controller 3 becomes inactive (, 1,). Under the control of the bus state controller 3, the address signal of the internal bus B contains H'FFFF data. Will be output.
  • CPU2 reads the instruction at address H, 01-0008, performs analysis (reads the data stored in the memory indicated by the address indicated by general-purpose register ER2, and based on it).
  • CPU2 executes the instruction, reads the data stored at addresses H and 01-0100, and stores H and 1234 in the general-purpose register (R0L).
  • protect area PA power protect area PA is read, so the value of the program counter is also in protect area PA, the flash memory select signal remains active ('0'), and the flash memory Normal data read from 7 is output to the internal bus B data signal (Data).
  • FIG. 9 an explanatory diagram of read control by the flash memory 7 and the RAM 4 is shown above, and a timing chart of each part signal is shown below.
  • CPU2 reads the instruction at addresses H, 01–5008, and analyzes the instruction (reads the data stored in the memory indicated by the address indicated by general register ER2)! ⁇
  • CPU 2 reads the data at address H ′ FF — D000 in RAM 4 and stores H ′ 1234 read into the general-purpose register (R0L).
  • FIG. 10 The left side of FIG. 10 is an explanatory diagram of the RAM 4 and the flash memory 7, and the right side is a flowchart of the processing procedure.
  • step S 101 character data is expanded on the RAM 4 (step S 101), and a subroutine jump is made to the protected area PA 1 of the RAM 4 (step S 102). Thereafter, in the compression processing based on the program stored in the protection area PA, intermediate data of the compression processing and the compression processing result are stored in the protection area PA1 (step S103).
  • the intermediate data and encryption result of the encryption process are stored in the protected area PA1 (step S104), and the encryption result data is stored. Is stored in the user access area UA1 (step S 105)
  • step S106 stores the encryption result data in, for example, an external memory externally connected to the semiconductor integrated circuit device 1 (step S107).
  • the erase prohibition control circuit 16 and the rewrite prohibition control circuit 17 provided in the control circuit 7b shown in FIG. 5 will be described.
  • the erase block selector EBS outputs an erase block signal EB9 of.
  • the erasure prohibition control circuit 16 reads the key code (first set value) stored in the key code area KA, and the key code and the key code read by the exclusive NOR circuit 19.
  • Exclusive exclusive OR with the key code (second set value) generated by the key code generator 18 is taken, and when the read key code and the key code generated by the key code generator 18 match, From the subsequent AND circuit 20, the erase block control signal EBC 9 of 0 ′ is output to the read Z write control circuit 30.
  • the erase operation in the flash memory 7 is prohibited by the erase block control signal EBC9.
  • the program mode signal P of 1 is output from the programming bit PB, and the address specifying the rewrite destination is input.
  • the address determination unit 22 determines whether or not the input address signal is in the protected area PA.
  • the exclusive NAND circuit 19 compares the key code (third set value) generated by the key code generation unit 21 with the key code (first set value) stored in the key code area KA. If they match, a '0' signal is output.
  • an active (, 0,) flash memory select signal and a write signal are output from the bus state controller 3, respectively.
  • the address determination unit 22 If the input address is outside the protected area PA, the address determination unit 22 outputs a '1' signal, so the program mode signal output from the AND circuit 29 is output. P becomes, 1, and the flash memory 7 is rewritten.
  • the semiconductor integrated circuit device 1 is shipped to the end user and the key code is set by the first user. This will be described with reference to the flowchart of FIG.
  • step S201 debugging of a key program (first program) created by the first user is started (step S201).
  • Programming and erasing of the key program (step S202) are performed until the debugging is completed (step S203).
  • step S203 the key code (first setting value) is written to the key code area KA (step S204), and the debugging program (third program) stored in the user access area UA is erased.
  • step S205 To the end user (step S205).
  • step S301 debugging of the main program (second program) created by the end user is started on the end user side.
  • the main program generated by debugging is erased until the debugging is completed (steps S302 and S303).
  • step S401 Debugging of the (first program) and the main program (second program) stored in the user area is started (step S401). Then, the program (first program) and main program (second program), which are keys generated by debugging, are written and erased (step S402).
  • step S403 the key code (first set value) is written in the key code area, and the key program written in the protect area PA is protected (step S404).
  • FIG. 13 is a block diagram of the semiconductor integrated circuit device according to the second embodiment of the present invention
  • FIG. 14 is an explanatory diagram showing a reset sequence in the semiconductor integrated circuit device of FIG. 13, and
  • FIG. 15 is in the reset sequence of FIG.
  • FIG. 16 is a flowchart showing setting processing of the protection processing control unit
  • FIG. 16 is a flowchart showing arbitrary setting processing of the protection area in the flash memory 7 provided in the semiconductor integrated circuit device of FIG. 13, and
  • FIG. 6 is a supplementary explanatory diagram of a memory map of the flash memory 7.
  • the semiconductor integrated circuit device 1 includes a CPU 2, a bus state controller 3, a RAM 4, a peripheral circuit 6 including an SCI (Serial Communication Interface) 5, and a flash memory.
  • the configuration is the same as that of the first embodiment such as the nonvolatile semiconductor memory illustrated in FIG.
  • the protection area PA of the flash memory 7 is fixed to one block from the address H, 01—0000—H ′ 01—FFFF.
  • the flash memory 7 includes a memory mat 7a and a control circuit 7b.
  • the memory mat 7a has memory cells, which are the smallest storage units, regularly arranged in an array, and includes an address buffer, Peripheral circuits such as address decoder 7al, input / output buffer 7a2, and sense amplifier are included.
  • Control circuit 7b temporarily stores the control signal input from CPU2, and controls the operation logic.
  • a protection processing control unit 31 is provided in the control circuit 7b.
  • the protection processing control unit 31 performs control to arbitrarily change the protection area PA in the flash memory 7.
  • the protect area PA also includes a start address storage area SDA that stores the start address of the protect area PA, an end address storage area MDA that stores the end address of the protect area PA, and a key code area that stores the key code area.
  • SDA start address storage area
  • MDA end address storage area
  • KA key code area
  • the protection processing control unit 31 includes a protection processing control circuit 32, an address generation circuit 33, A signal signal generation circuit 34, an address Z key code storage register 35, and selectors 36 and 37.
  • the protection processing control circuit 32, the address generation circuit 33, the read signal generation circuit 34, and the address / key code storage register 35 receive the reset signal output from the reset circuit 38 that generates the reset signal. So that each is connected.
  • the protection processing control circuit 32 is connected to the address generation circuit 33, the read signal generation circuit 34, and the address Z key code storage register 35, and the signal output from the protection processing control circuit 32. Thus, these circuits start to operate.
  • the address generation circuit 33 generates the storage address of the key code stored in the memory mat 7a of the flash memory 7.
  • the read signal generation circuit 34 generates a read signal for the memory mat 7a.
  • the address Z key code storage register 35 stores the key code read from the memory mat 7a and the address indicating the area of the protected area PA.
  • the protection processing control circuit 32 is connected so that a control signal for controlling the selectors 36 and 37 is inputted thereto.
  • the selector 36 switches between the address generated by the address generation circuit 33 and the address output from the state controller 3 based on the control signal output from the protection processing control circuit 32.
  • the selector 37 switches between the read signal generated by the read signal generation circuit 34 and the read signal output from the bus state controller 3 based on the control signal output from the protection processing control circuit 32. Output.
  • FIG. 14 is an explanatory diagram showing a reset sequence in the semiconductor integrated circuit device 1
  • FIG. 15 is a flowchart showing a setting process of the protection process control unit 31 in the reset sequence of FIG.
  • FIG. 14 from top to bottom, the system clock, the reset signal input to the reset terminal of the semiconductor integrated circuit device 1, the operating state of the protection processing control unit 31, the internal path set of the semiconductor integrated circuit device 1 The signal and the operating state of CPU2 (semiconductor integrated circuit device 1) are shown.
  • step S501 when a reset signal is input from a reset terminal, which is one of the external ports of the semiconductor integrated circuit device, and the reset signal is released (step S501), the protection processing control circuit is reset. Road 32 is activated (step S502).
  • the protection processing control circuit 32 includes an address generation circuit 33 and a read signal generation circuit.
  • the protection processing control circuit 32 reads the data stored in the key code area KA of the memory mat 7a (step S504) and stores the data in the address Z key code storage register 35 (step S504). S505).
  • the protection processing control circuit 32 determines whether or not the key code (first set value) is stored in the address Z key code storage register 35 (step S506), and the key code is stored. If so, the protection processing control circuit 32 reads the start address and the end address of the protection area PA from the memory mat 7a, and stores them in the address Z key code storage register 35 (steps S507 and S508).
  • step S508 After the completion of the processing in step S508, or if there is no key code in the processing in step S506, a release signal for canceling the internal reset of the semiconductor integrated circuit device is output to the reset circuit 38 (step S 509 ), The protection processing control circuit 32 is stopped (step S510), and the semiconductor integrated circuit device 1 starts operating.
  • Reading of the key code, setting of the key code for the control circuit 7b, and confirmation of the presence / absence of protection of the protect area are executed according to the above flow after reset release. After the semiconductor integrated circuit device 1 starts a normal operation, control based on the memory access address according to FIG. 4 is executed.
  • steps S507 and S508 are not executed.
  • FIG. 16 is a flowchart showing an arbitrary setting process of the protected area PA in the flash memory 7.
  • FIG. 17 is a supplementary explanatory diagram of the memory map of the flash memory 7 in FIG.
  • step S601 program debugging is started (step S601), and program writing and erasure (step S602) are performed until debugging is completed (step S603).
  • step S602 the start address storage area SDA and the end address provided in the memory mat 7a are stored.
  • Address storage area Write any start address and any end address of protect area PA to MDA, set any area of protect area PA, and write key code to key code area KA (step S604) .
  • the area of the protected area PA can be arbitrarily changed. Therefore, reading or rewriting is prohibited, and the area can be changed flexibly according to the data capacity of the program. This makes it possible to prevent a third party from reading, copying, or changing the program.
  • the semiconductor integrated circuit device of the present invention is suitable for a technique for preventing reading and rewriting of a predetermined block in a nonvolatile semiconductor memory.

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Security & Cryptography (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Storage Device Security (AREA)

Abstract

  フラッシュメモリには、特定のブロックの読み出しが禁止されるプロテクトエリアPAが設けられ、プログラムのワークエリアとして用いられるRAMには、同じく特定のブロックの読み出しが禁止されるプロテクトエリアPA1が設けられている。バスステートコントローラ3は、プログラムカウンタの値とアドレス信号の値とを比較して、フラッシュメモリではプロテクトエリアPA以外の読み出しを禁止し、RAMでは、プロテクトエリアPA1のデータをフラッシュメモリのプロテクトエリアPAからの読み出し以外を禁止するように制御する。たとえば、ユーザがアクセス可能なユーザアクセスエリアからプロテクトエリアPAのデータを読み出す場合には、バスステートコントローラ3から、H’FFFFなどの無意味なデータがデータバスを介して出力される。

Description

明 細 書
半導体集積回路装置および電子システム
技術分野
[0001] 本発明は、不揮発性半導体メモリにおけるデータ保護技術に関し、特に、不揮発 性半導体メモリを内蔵した半導体集積回路装置におけるプログラムのコピー、書き換 えの防止に適用して有効な技術に関するものである。
背景技術
[0002] 近年、電子機器の開発 '改善の期間短縮を図るため、制御用のプログラムやデータ の書き換えが容易な不揮発性半導体メモリを内蔵した半導体集積回路装置、 V、わゆ るフラッシュメモリ内蔵マイクロコンピュータに対するニーズが高まっている。
[0003] このフラッシュメモリ内蔵マイクロコンピュータには、機密保持のためフラッシュメモリ に格納されたアプリケーションプログラムなどの書き換えなどを禁止するプロテクト機 能を有するものがある。
[0004] この種の不揮発性半導体メモリに格納されたデータやプログラムなどの保護機能と しては、たとえば、 EPROM (Erasable Programmable Read Only Memory) において、プログラマが設定した保護ブロックにプログラムを格納した後、該 EPRO M内の保護レジスタの指定ビットを設定することによって保護エリア外力 の読み出し Z書き込みを不可とする技術がある(たとえば、特許文献 1参照)。
特許文献 1:特開 2000-76133号公報
発明の開示
発明が解決しょうとする課題
[0005] ところが、上記のようなフラッシュメモリ内蔵のマイクロコンピュータにおけるプロテク ト技術では、次のような問題点があることが本発明者により見い出された。
[0006] フラッシュメモリのプロテクト機能を有効にした場合には、第三者がアプリケーション プログラムなどを読み出すことはできな 、が、該フラッシュメモリのすべてメモリ領域( ブロック)にプロテクトがかかってしまうことになるので、ユーザデータなどの書き換えも できなくなってしまうことになる。 [0007] また、フラッシュメモリは、ブートモードを起動させることによって、電子システムなど のプリント配線基板に実装した状態でアプリケーションプログラムなどの書き換えを容 易に行うことができ、第三者によって該アプリケーションプログラムの読み出しや書き 換えなどが行われてしまう恐れがある。
[0008] さらに、フラッシュメモリにプロテクトをかけた状態であっても、マイクロコンピュータに 設けられた CPUのワークエリアとして用いられる RAM (Random Access Memor y)の内容を読み出し、どのような命令を実行しているかなどを解析することによってァ プリケーシヨンプログラムの内容が推測されてしまう恐れがある。
[0009] 本発明の目的は、不揮発性半導体メモリの特定のメモリ領域における読み出しを禁 止することにより、第三者によるプログラムの不正コピーや改ざんなどを確実に防止 することのできる技術を提供することにある。
[0010] 本発明の前記ならびにその他の目的と新規な特徴は、本明細書の記述および添 付図面から明らかになるであろう。
課題を解決するための手段
[0011] 本願において開示される発明のうち、代表的なものの概要を簡単に説明すれば、 次のとおりである。
[0012] 本発明は、複数の不揮発性メモリセルを有するメモリアレイ部と、該不揮発性メモリ セルに情報を格納する書き込み動作、該不揮発性メモリセルに格納した情報を読み 出す読み出し動作、該不揮発性メモリセルに格納した情報を消去する消去動作の各 動作を制御する制御部とを備えた不揮発性記憶部と、該不揮発性記憶部に格納さ れたプログラムのワークエリアとして用いられる揮発性記憶部と、所定の処理を実行し 、該不揮発性記憶部に動作指示を行うことが可能である中央処理装置と、不揮発性 記憶部、および揮発性記憶部の読み出し動作を制御するプロテクト動作制御部とを 有した半導体集積回路装置であって、メモリアレイ部は、プロテクト動作制御部の制 御により格納された情報の読み出しおよび書き込みが禁止される第 1のプロテクトメモ リ領域を有し、揮発性記憶部は、プロテクト動作制御部の制御によりメモリアレイ部の 第 1のプロテクトメモリ領域以外力 の読み出しおよび書き込みが禁止される第 2のプ ロテクトメモリ領域を有し、不揮発性記憶部の第 1のプロテクトメモリ領域に格納された プログラムのワークエリアとして揮発性記憶部の第 2のプロテクトメモリ領域を用いるこ とを特徴とする半導体集積回路装置。
[0013] また、本発明の半導体集積回路装置は、複数の不揮発性メモリセルを有するメモリ アレイ部と、該不揮発性メモリセルに情報を格納する書き込み動作、該不揮発性メモ リセルに格納した情報を読み出す読み出し動作、該不揮発性メモリセルに格納した 情報を消去する消去動作の各動作を制御する制御部とを備えた不揮発性記憶部と 、揮発性記憶部と、所定の処理を実行し、該不揮発性記憶部に動作指示を行うこと が可能である中央処理装置と、不揮発性記憶部、および揮発性記憶部の読み出し 動作を制御するプロテクト動作制御部とを有した半導体集積回路装置であって、メモ リアレイ部は、プロテクト動作制御部の制御により格納された情報の読み出しおよび 書き込みが禁止される第 1のプロテクトメモリ領域を有し、揮発性記憶部は、プロテクト 動作制御部の制御によりメモリアレイ部の第 1のプロテクトメモリ領域以外力 の読み 出しおよび書き込みが禁止される第 2のプロテクトメモリ領域を有したものである。
[0014] また、本願のその他の発明の概要を簡単に示す。
[0015] 本発明は、複数の不揮発性メモリセルを有するメモリアレイ部と、該不揮発性メモリ セルに情報を格納する書き込み動作、該不揮発性メモリセルに格納した情報を読み 出す読み出し動作、該不揮発性メモリセルに格納した情報を消去する消去動作の各 動作を制御する制御部とを備えた不揮発性半導体記憶装置と、該不揮発性半導体 記憶装置に格納されたプログラムのワークエリアとして用いられる揮発性半導体記憶 装置と、所定の処理を実行し、不揮発性半導体記憶装置に動作指示を行うことが可 能である中央処理装置と不揮発性半導体記憶装置、および揮発性半導体記憶装置 の読み出し動作を制御するプロテ外動作制御部とを備えた半導体集積回路装置と を有した電子システムであって、メモリアレイ部は、プロテクト動作制御部の制御により 格納された情報の読み出しが禁止される第 1のプロテクトメモリ領域を有し、揮発性半 導体記憶装置は、プロテクト動作制御部の制御によりメモリアレイ部の第 1のプロテク トメモリ領域以外からの読み出しが禁止される第 2のプロテクトメモリ領域を有し、不揮 発性半導体記憶装置に格納されたプログラムのワークエリアとして第 2のプロテクトメ モリ領域を用いるものである。 発明の効果
[0016] 本願において開示される発明のうち、代表的なものによって得られる効果を簡単に 説明すれば以下のとおりである。
[0017] (1)第 1のプロテクトメモリ領域の読み出しや書き換えなどを制限することができるの で、プログラムの不正なコピーや改ざんなどを防止することができ、セキュリティを向 上させることができる。
[0018] (2)また、第 2のプロテクトメモリ領域の読み出しを制限することにより、プログラムの 推測などを困難にすることが可能となり、プログラムの不正なコピーや改ざんなどをよ り効果的に防止することができる。
[0019] (3)上記(1)、 (2)により、半導体集積回路装置やそれを用いた電子システムなど の信頼性を大幅に向上させることができる。
図面の簡単な説明
[0020] [図 1]本発明の実施の形態 1による半導体集積回路装置のブロック図である。
[図 2]図 1の半導体集積回路装置に設けられたフラッシュメモリにおけるメモリマップの 一例を示した説明図である。
[図 3]図 1の半導体集積回路装置に設けられた RAMにおけるメモリマップの一例を 示した説明図である。
[図 4]図 1の半導体集積回路装置に設けられたバスステートコントローラの一部構成 例を示した説明図である。
[図 5]図 1の半導体集積回路装置に設けられたフラッシュメモリにおける消去禁止制 御回路、および書き換え禁止制御回路のブロック図である。
[図 6]図 1の半導体集積回路装置に設けられたフラッシュメモリのユーザアクセスエリ ァにおける読み出し制御動作例を示すタイミングチャートである。
[図 7]図 1の半導体集積回路装置に設けられたフラッシュメモリのユーザアクセスエリ ァ力 プロテクトエリアを読み出す場合の制御動作例を示すタイミングチャートである
[図 8]図 1の半導体集積回路装置に設けられたフラッシュメモリのプロテクトエリアから プロテクトエリアを読み出す場合の制御動作例を示すタイミングチャートである。 [図 9]図 1の半導体集積回路装置に設けられたフラッシュメモリのプロテクトエリアから RAMのプロテクトエリアのデータを読み出す場合の制御動作例を示すタイミングチヤ ートである。
[図 10]図 1の半導体集積回路装置に設けられた RAMの処理例を示した説明図であ る。
[図 11]図 1の半導体集積回路装置における第一ユーザによるキーコードの設定例を 示すフローチャートである。
[図 12]図 1の半導体集積回路装置におけるエンドユーザによるキーコードの設定例 を示すフローチャートである。
[図 13]本発明の実施の形態 2による半導体集積回路装置のブロック図である。
[図 14]図 13の半導体集積回路装置におけるリセットシーケンスを示した説明図であ る。
[図 15]図 14のリセットシーケンスにおけるプロテクト処理制御部の設定処理を示すフ ローチャートである。
[図 16]図 13の半導体集積回路装置に設けられたフラッシュメモリにおけるプロテクト エリアの任意設定処理を示すフローチャートである。
[図 17]図 16におけるフラッシュメモリのメモリマップの補足説明図である。
発明を実施するための最良の形態
[0021] 以下、本発明の実施の形態を図面に基づいて詳細に説明する。なお、実施の形態 を説明するための全図において、同一の部材には原則として同一の符号を付し、そ の繰り返しの説明は省略する。
[0022] (実施の形態 1)
図 1は、本発明の実施の形態 1による半導体集積回路装置のブロック図、図 2は、 図 1の半導体集積回路装置に設けられたフラッシュメモリにおけるメモリマップの一例 を示した説明図、図 3は、図 1の半導体集積回路装置に設けられた RAMにおけるメ モリマップの一例を示した説明図、図 4は、図 1の半導体集積回路装置に設けられた バスステートコントローラの一部構成例を示した説明図、図 5は、図 1の半導体集積回 路装置に設けられたフラッシュメモリにおける消去禁止制御回路、および書き換え禁 止制御回路のブロック図、図 6は、図 1の半導体集積回路装置に設けられたフラッシ ュメモリのユーザアクセスエリアにおける読み出し制御動作例を示すタイミングチヤ一 ト、図 7は、図 1の半導体集積回路装置に設けられたフラッシュメモリのユーザァクセ スエリア力 プロテクトエリアを読み出す場合の制御動作例を示すタイミングチャート、 図 8は、図 1の半導体集積回路装置に設けられたフラッシュメモリのプロテクトエリアか らプロテクトエリアを読み出す場合の制御動作例を示すタイミングチャート、図 9は、 図 1の半導体集積回路装置に設けられたフラッシュメモリのプロテクトエリア力も RAM のプロテクトエリアのデータを読み出す場合の制御動作例を示すタイミングチャート、 図 10は、図 1の半導体集積回路装置に設けられた RAMの処理例を示した説明図、 図 11は、図 1の半導体集積回路装置における第一ユーザによるキーコードの設定例 を示すフローチャート、図 12は、図 1の半導体集積回路装置におけるエンドユーザに よるキーコードの設定例を示すフローチャートである。
[0023] 本実施の形態 1において、半導体集積回路装置 1は、図 1に示すように、 CPU (中 央処理装置) 2、バスステートコントローラ (プロテクト動作制御部) 3、 RAM (揮発性 記憶部) 4、 SCI (Serial Communication Interface) 5などを含む周辺回路 6、 およびフラッシュメモリ 7に例示される不揮発性半導体メモリなど力も構成されている。
[0024] CPU2は、フラッシュメモリ(不揮発性記憶部) 7に格納された命令を読み出し、所 定の処理を行う。バスステートコントローラ 3は、アドレスバスやデータバスなどを含む 内部バス Bにおける信号の転送を制御するとともに、該内部バス Bの状態を制御する
。 RAM (揮発性メモリ) 4は、随時読み出し Z書き込みが可能なメモリであり、 CPU2 のワークエリアとして用いられる。
[0025] SCI5は、外部接続されるデバイスとシリアル通信を行うインタフェースである。周辺 回路 6は、そのほかに、たとえば、タイマ、 WDT(Watch Dog Timer)、 TPU (Tim er Pulse Unit)、 AZD (AnalogZDigital)変^^、および DZA(DigitalZAn alog)変翻など力 構成されて!、る。
[0026] タイマは、たとえば、 8ビットのカウンタをベースとしたタイマである。 WDTは、半導 体集積回路装置 1の暴走などの監視を行う。 TPUは、 PWM (Pulse Width Mod ulation)波形を出力することのできるタイマである。 AZD変換器は、アナログ信号を デジタル信号に変換して出力する。 DZA変換器は、デジタル信号をアナログ信号 に変換して出力する。
[0027] フラッシュメモリ 7は、電気的にデータの書き換え Z消去が可能な不揮発性半導体 メモリであり、 CPU2によって実行されるプログラム命令を含む制御プログラムなどを 格納する。フラッシュメモリ 7は、 CPU2からの指示に応じてデータの書き込み Z読み 出しや消去などを行う。
[0028] これら CPU2、バスステートコントローラ 3、 RAM4、 SCI5などを含む周辺回路 6、 およびフラッシュメモリ 7は、内部バス Bにより相互に接続されている。
[0029] また、 CPU2からは、次に読み出される命令のアドレスを示すプログラムカウンタの 値、書き込みを許可するライト信号、ならびに読み出しを許可するリード信号がバスス テートコントローラ 3に入力されるように接続されて 、る。
[0030] RAM4には、バスステートコントローラ 3から出力された RAMセレクト信号 Sl、ライ ト信号、およびリード信号がそれぞれ入力されるように接続されている。 RAMセレクト 信号 S1は、 RAM4を選択する信号である。ライト信号は、 RAM4のライトを許可する 信号であり、リード信号は RAM4のリードを許可する信号である。
[0031] SCI5には、シリアルセレクト信号、ライト信号、ならびにリード信号がそれぞれ入力 されるように接続されている。シリアルセレクト信号は、 SCI5を選択する信号である。 ライト信号は、 SCI5のライトを許可する信号であり、リード信号は SCI5のリードを許可 する信号である。
[0032] フラッシュメモリ 7には、フラッシュメモリセレクト信号、ライト信号、およびリード信号 がそれぞれ入力されるように接続されている。フラッシュメモリセレクト信号は、フラッシ ュメモリ 7を選択する信号である。ライト信号は、フラッシュメモリ 7のライトを許可する信 号であり、リード信号は該フラッシュメモリ 7のリードを許可する信号である。
[0033] フラッシュメモリ 7は、メモリマット (メモリアレイ部) 7a、および制御回路 (制御部) 7b から構成されている。
[0034] メモリマット 7aは、記憶の最小単位であるメモリセルが規則正しくアレイ状に並べら れており、アドレスバッファ、行デコーダ、列デコーダ、およびセンスアンプなどの周辺 回路を含んでいる。制御回路 7bは、 CPU2から入力される各種制御用信号を一時 的に格納し、動作ロジックの制御を行う。
[0035] 図 2は、フラッシュメモリ 7のメモリマット 7aにおけるメモリマップの一例を示した説明 図である。
[0036] 図示するように、メモリマット 7a、ユーザアクセスエリア UAとプロテクトエリア(第 1の プロテクトメモリ領域) PAと力も構成されている。ユーザアクセスエリア UAは、ユーザ がアクセスできる複数の領域 (ブロック)力 構成されている。また、プロテクトエリア P Aは、プログラムやデータなどが格納された領域 (ブロック)であり、これらプログラムや データなどの読み出しが制限される。プロテクトエリア PAは一つの連続したアドレス 領域のみに限られず、例えば、複数の領域に配置されていてもよい。
[0037] 図 3は、 RAM4におけるメモリマップの一例を示した説明図である。
[0038] RAM4においても同様に、ユーザアクセスエリア UA1とプロテクトエリア(第 2のプロ テクトメモリ領域) PA1と力も構成されている。ユーザアクセスエリア UA1は、フラッシ ュメモリ 7などのデータを展開する領域であり、プロテクトエリア PA1は、フラッシュメモ リ 7のプロテクトエリア PA (第 1のプロテクトメモリ領域)に格納されたプログラムのヮー クエリアとして用いられる領域である。
[0039] メモリマット 7aのプロテクトエリア PAに格納されているプログラムやデータは、該プロ テクトエリア PA内のプログラムによって読み出すことは可能となっている力 該メモリ マット 7aのユーザアクセスエリア UAや RAM4のユーザアクセスエリア UA1やプロテ タトエリア PA1に格納されたプログラムからの読み出しは不可となっている。
[0040] また、 RAM4のプロテクトエリア PA1に格納されているデータなどは、メモリマット 7a のプロテクトエリア PA力 読み出すことは可能である力 そのほかのエリア (メモリマツ ト 7aのユーザアクセスエリア UA、および RAM4のユーザアクセスエリア UA、プロテ タトエリア PA1)力もの読み出しは不可となって 、る。
[0041] さらに、フラッシュメモリ 7は、後述するキーコードエリア KA (図 5)に所定のキーコー ドを設定するまでは、フラッシュメモリ 7のプロテクトエリア PAにプログラムやデータな どを RAM4のユーザアクセスエリア UA1から書き換え Z消去することが可能となって いる。所定のキーコードを設定するまでは、フラッシュメモリ 7のプロテクトエリア PAや ユーザアクセスエリア UAやユーザアクセスエリア UA1、何れの領域からもそれぞれ の領域に対してアクセスが可能となる。
[0042] キーコードが設定された場合には、フラッシュメモリ 7のプロテクトエリア PAを書き換 え Z消去することが不可となる。
[0043] RAM4のプロテクトエリア PA1に格納されているデータなどは、フラッシュメモリ 7の プロテクトエリア PAから書き換え/消去することが可能となって 、るが、そのほかのェ リア(フラッシュメモリ 7のユーザアクセスエリア UA、 RAM4のユーザアクセスエリア U Al、プロテクトエリア PA1)力もの書き換え Z消去は不可となっている。更に、キーコ ードの設定有無に関わらず RAMのプロテクトエリア PA1は、プロテクト動作制御部の 制御によってフラッシュメモリ 7のプロテクトエリア PA以外力もの書き換え Z消去が禁 止される。
[0044] また、フラッシュメモリ 7において、読み出しが禁止されているプロテクトエリア PAの プログラムやデータなどをユーザアクセスエリア UAから読み出した場合には、たとえ ば、常に H' FFのデータが読み出される。
[0045] ここでは、フラッシュメモリ 7に書き込まれている初期値のデータにあわせて H' FFと したが、この場合に読み出されるデータは、ハイインピーダンス状態 (Hi— Z)以外で あればよぐたとえば、 H' 00や前値保持などの無意味なデータ、ユーザが設定した 任意の値などであってもよ 、。
[0046] 同様に、 RAM4にお!/、て、読み出しが禁止されて!、るプロテクトエリア PA1のプロ グラムやデータなどをユーザアクセスエリア UA1から読み出した場合には、たとえば
、常に H' 00のデータが読み出される。
[0047] ここでも、 RAM4の NOP命令にあわせて H ' 00とした力 読み出されるデータは、 ハイインピーダンス状態 (Hi— Z)以外であればよぐたとえば、 H' FFや前値保持など の無意味なデータ、ユーザが設定した任意の値などであってもよ 、。
[0048] 図 4は、バスステートコントローラ 3の一部構成例を示した説明図である。
[0049] バスステートコントローラ 3は、図示するように、セレクタ 8— 11、否定論理和回路 12
, 13、およびドライバ 14, 15など力も構成されている。
[0050] セレクタ 8— 11の一方の入力部には、 CPU2 (図 1)力も出力されるアドレス信号が 入力されるようにそれぞれ接続されており、該セレクタ 8— 11の他方の入力部には、 CPU2から出力されるプログラムカウンタ値 (PC値)が入力されるようにそれぞれ接続 されている。
[0051] セレクタ 8は、アドレス信号力 フラッシュメモリ 7のユーザアクセスエリア UA (図 2)を 示すアドレス H, 00— 0000— H, 00_FFFF、またはアドレス H, 02— 0000— H, 0 3_FFFF、あるいはフラッシュメモリ 7のプロテクトエリア PA (図 2)を示すアドレス H, 01— 0000— H' Ol— FFFF、かつプログラムカウンタの値が、 H, 01— 0000— 01 —FFFFとなった場合にフラッシュメモリセレクト信号がアクティブとなる' 0' (Loレべ ル信号)を出力し、そのほかの場合には、該フラッシュメモリセレクト信号力 Sインァクテ イブとなる' 1 ' (Hiレベル信号)を出力する。つまり、 CPU2が出力するアドレス値がフ ラッシュメモリ 7のユーザアクセスエリア UAを示す場合はプログラムカウンタ値によら ずアクセスが可能である。更に、アドレス値がフラッシュメモリ 7のプロテクトエリア PA を示し、かつプログラムカウンタの値もフラッシュメモリ 7のプロテクトエリア PAを示す 場合、フラッシュメモリ 7はアクセス可能な状態、つまりセレクト信号がアクティブ状態と なる。
[0052] セレクタ 9は、アドレス信号が、 RAM4のユーザアクセスエリア UA1 (図 3)を示すァ ドレス H' FF— D800— H' FF— EFFF、または RAM4のプロテクトエリア PA1 (図 3) を示すアドレス H' FF— D000— H' FF— D7FF、かつプログラムカウンタの値が、 H ,01— 0000— 01_FFFF (フラッシュメモリ 7のプロテクトエリア PAを示すアドレス)と なった場合に RAMセレクト信号がアクティブとなる' 0' (Loレベル信号)を出力し、そ のほかの場合には、該 RAMセレクト信号がインアクティブとなる ' (Hiレベル信号) を出力する。つまり、 CPU2が出力するアドレス値が RAM4のユーザアクセスエリア UA1を示す場合はプログラムカウンタ値によらずアクセスが可能である。更に、プロ グラムカウンタ値がフラッシュメモリ 7のプロテクトエリア PAを示し、アドレス値が RAM 4のプロテクトエリア PA1を示す場合は、 RAM4はアクセス可能な状態となる。
[0053] セレクタ 10は、アドレス信号が、フラッシュメモリ 7のプロテクトエリア PAを示すアドレ ス H, 01— 0000— H, 01— FFFF、かつプログラムカウンタの値が H, 01— 0000— 01— FFFF以外となった場合に、,0,の信号を出力し、アドレス H,01— 0000— H, 01 FFFF、かつプログラムカウンタの値が H, 01 0000— 01 FFFFの場合に は、 ' 1 'の信号を出力する。
[0054] セレクタ 11は、アドレス信号が、 RAM4のプロテクトエリア PA1を示すアドレス H,F F— DOOO— H' FF— D7FF、かつプログラムカウンタの値が H, 01— OOOO— 01— FFFF以外となった場合に、,0,の信号を出力し、アドレス値が H' FF— D000— H, FF— D7FF、かつプログラムカウンタの値が H, 01— 0000— 01— FFFFの場合に は、 ' 1 'の信号を出力する。
[0055] このように、フラッシュメモリ 7のプロテクトエリア PAをリード Zライトする際のフラッシ ュメモリ 7のセレクト条件としては、プログラムカウンタの値とアドレス信号の値と力 い ずれもフラッシュメモリ 7のプロテクトエリア PAに一致する場合にのみ、フラッシュメモ リセレクト信号が有効になる。上記一致する場合以外はフラッシュメモリセレクト信号 は無効となる。
[0056] RAM4においても、該 RAM4のプロテクトエリア PA1をリード Zライトする場合の R AM4のセレクト条件としては、プログラムカウンタの値がフラッシュメモリ 7のプロテクト エリア PAで、かつアドレス値が RAM4のプロテクトエリア PA1である場合に限って R AMセレクト信号が有効となる。上記の場合以外には RAMセレクト信号は無効となる
[0057] 否定論理和回路 12は、セレクタ 10から出力される信号とリード信号との否定論理 和をとり、ドライバ 14の制御部に出力する。否定論理和回路 12は、アドレス信号が、 フラッシュメモリ 7のプロテクトエリア PAを示すアドレス H, 01—0000— H, 01— FFF F、かつプログラムカウンタの値が H' 01— 0000— 01— FFFF以外となり、かつァク ティブなリード信号(, 0,)が入力された際にドライバ 14からフラッシュメモリ 7の初期値 である H' FFFFが出力されるように制御信号を出力する。上記制御に従い、内部バ ス Bのデータ信号には H 'FFFFが出力される。ここで、出力される信号の値は H' FF FFに限られず、出力値を任意に設定することも可能である。つまり CPU2が出力する アドレス信号に従ったフラッシュメモリ 7からの読み出しデータでない限り、どのような 値が出力可能な構成であってもよい。
[0058] 否定論理和回路 13は、セレクタ 11から出力される信号とリード信号との否定論理 和をとりドライバ 15の制御部に出力する。否定論理和回路 13は、アドレス信号が、 R AM4のプロテクトエリア PA1を示すアドレス H, FF— DOOO— H, FF— D7FF、かつ プログラムカウンタの値が H, 01—0000— H, 01— FFFF以外となり、かつアクティブ なリード信号(,0,)が入力された際にドライバ 15から RAM4の NOP命令にあわせた 値である H' OOOOが出力されるように制御信号を出力する。上記制御に従い、内部 バス Bのデータ信号には H '0000が出力される。ここで、出力される信号の値は H' O 000に限られず、出力値を任意に設定することも可能である。つまり CPU2が出力す るアドレス信号に従った RAM4からの読み出しデータでない限り、どのような値が出 力可能な構成であってもよ ヽ。
[0059] ここで、 CPU2からフラッシュメモリ 7、または' 0' )が出力された場合で、上記フラッ シュメモリセレクト信号 RAMセレクト信号が無効である場合にはフラッシュメモリ 7およ び RAM4へのアクセスが禁止されるため、データ信号は、たとえば前値保持の状態 となる。
[0060] 図 5は、フラッシュメモリ 7における該フラッシュメモリ 7の動作制御を司る制御回路 7 bに設けられた消去禁止制御回路 (消去禁止制御部) 16、ならびに書き換え禁止制 御回路(書き換え禁止制御部) 17のブロック図である。
[0061] 消去禁止制御回路 16は、フラッシュメモリ 7の消去禁止を制御する回路であり、予 めメモリマット 7aのキーコードエリア KAに書き込まれたキーコード (第 1の設定値)が 予め設定されて 、るキーコード (第 2の設定値)と一致した場合、メモリマット 7aのプロ テクトエリア PAに対するデータへの消去が発生した際に該プロテクトエリア PAの消 去を禁止する。
[0062] 消去禁止制御回路 16は、キーコード発生部(キーコード発生回路) 18、排他的否 定論理和回路 (消去制御回路) 19、および論理積回路 (消去制御回路) 20から構成 されている。キーコード発生部 18は、予め設定するキーコード (第 2の設定値、たとえ ば、 H' 1234)をノヽードウエアによって出力する回路力もなる。
[0063] 排他的否定論理和回路 19の一方の入力部には、キーコード発生部 18が生成した キーコード (Η' 1234)が入力されるように接続されており、該排他的否定論理和回 路 19他方の入力部には、キーコードエリア ΚΑに格納されているキーコード (第 1の 設定値)が入力されるように接続されて ヽる。 [0064] 論理積回路 20の一方の入力部には、ィレースブロックセレクタ EBS力 出力される ィレースブロック信号 EB9が入力されるように接続されて!、る。ィレースブロックセレク タ EBSは制御回路 7bに設けられており、どのブロックを消去するかを選択するレジス タのうちの 1つである。このィレースブロックセレクタ EBSは、フラッシュメモリ 7のメモリ マット 7aにおけるプロテクトエリア PA(Block9)を消去する際に, 0,のィレースブロッ ク信号 EB9を出力する。
[0065] 論理積回路 20の他方の入力部には、排他的否定論理和回路 19から出力される信 号が入力されるように接続されている。論理積回路 20の出力部には、フラッシュメモリ 7の読み出し Z書き込みを制御する読み出し Z書き込み制御回路 30の入力部が接 続されており、論理積回路 20の出力部からィレースブロック制御信号 EBC9が出力 される。
[0066] 上記キーコード発生部 18が生成したキーコード (第 2の設定値)がキーコードエリア に格納されているキーコード (第 1の設定値)に一致する場合、上記消去禁止制御回 路 16はィレースブロック制御信号が無効となるように制御し、上記読み出し Z書き込 み制御回路 30は消去動作を禁止する。
[0067] 上記ィレースブロック制御信号 EBC9が有効な状態の時、上記読み出し Z書き込 み制御回路 30はプロテクトエリア PA (Block9)に対する消去制御を行う。
[0068] ここで、フラッシュメモリ 7のメモリセル部に複数のプロテクトエリアを設置する場合に は、プロテクトエリア毎に上記消去禁止制御回路 16を用意すればよい。これにより複 数のプロテクトエリアに対する消去制御が可能となる。
[0069] また、書き換え禁止制御回路 17は、キーコード発生部(キーコード発生回路) 21、 アドレス判定部 (アドレス判定回路) 22、排他的否定論理和回路 (キーコード判定部) 23、インバータ (書き換え制御回路) 24— 26、否定論理積回路 (書き換え制御回路) 27、保持回路 (書き換え制御回路) 28、および論理積回路 (書き換え制御回路) 29 から構成されている。
[0070] キーコード発生部 21は、予め設定するキーコード (第 3の設定値、たとえば、 H' 12 34)をノ、一ドウエアによって出力する回路力もなる。排他的否定論理和回路 23の一 方の入力部には、キーコード発生部 18が生成したキーコード (Η' 1234)が入力され るように接続されており、該排他的否定論理和回路 23の他方の入力部には、キーコ 一ドエリア KAに格納されて 、るキーコード (第 1の設定値)が入力されるように接続さ れている。
[0071] アドレス判定部 22には、アドレス信号が入力されており、該アドレス判定部 22は、ァ ドレス信号がアドレス H, 01— 0000— H, 01— FFFFの場合には、,0,を出力し、そ れ以外の場合には' 1 'を出力する。
[0072] インバータ 24— 26の入力部には、メモリセレクト信号(図 1)、ライト信号(図 1)、およ びアドレス判定部 22から出力される判定信号がそれぞれ入力されるように接続され ている。
[0073] 否定論理積回路 27の入力部には、排他的否定論理和回路 23の出力部、インバー タ 24— 26の出力部がそれぞれ接続されており、該否定論理積回路 27の出力部に は、保持回路 28の入力部が接続されている。この保持回路 28は、フラッシュメモリ 7 への書き込みが発生するまで、その信号状態を保持する回路である。
[0074] 論理積回路 29の一方の入力部には、プログラミングビット PBから出力されるプログ ラムモード信号 Pが入力されるように接続されている。プログラミングビット PBは、書き 換えを開始するプログラムモードを解除 Z遷移させるビットであり、 ' 0,の際にはプロ グラムモードが解除となり、, 1 'の場合にはプログラムモードに遷移する。
[0075] 論理積回路 29の出力部には、読み出し Z書き込み制御回路 30の入力部が接続さ れており、論理積回路 29の出力部力もプログラムモード信号 Pが出力される。
[0076] 上記キーコード発生部 21が生成したキーコード (第 3の設定値)がキーコードエリア に格納されているキーコード (第 1の設定値)に一致する場合、上記読み出し Z書き 込み制御回路 30は書き換え動作を禁止する。
[0077] 上記プログラムモード信号 Pが有効な状態の時、上記読み出し Z書き込み制御回 路 30はプロテクトエリア PA (Block9)に対する書き換え制御を行う。
[0078] ここでは、キーコードを H, 1234とした力 該キーコードは、フラッシュメモリ 7に格納 されて 、る初期値 (Η' FFFF)以外であれば、どのようなデータでもよ!/、。
[0079] 次に、本実施の形態における半導体集積回路装置 1の作用について説明する。
[0080] 図 6から図 9に示される CPU2によって実行される命令は一つの具体例であって、 それだけに限られず、各種の命令が実行される。アドレスに対応したメモリに格納さ れている命令やデータの値(たとえば、図 6のアドレス H '00— 4008には「H, 6828」 が格納される)もプログラムによって様々である。本発明ではノ スステートコントローラ 3によるアドレス値およびプログラムカウンタの値の比較によって各種メモリおよびそ の他の周辺回路に対するアクセスが制御されるものである。
[0081] 始めに、フラッシュメモリ 7のユーザアクセスエリア UAにおける読み出し制御動作に ついて、図 6を用いて説明する。
[0082] 図 6の上方は、フラッシュメモリ 7による読み出し制御の説明図を示しており、その下 方には、各部信号のタイミングチャートを示している。
[0083] この図 6のタイミングチャートにおいては、上方から下方にかけて、クロック信号 φ、 CPU2から出力されるプログラムカウンタの値、 CPU2から出力されるアドレス信号、 バスステートコントローラ 3から出力されるフラッシュメモリセレクト信号、 CPU2から出 力されるデータ信号、およびプログラムカウンタの値がフラッシュメモリ 7のプロテクト エリア PAを示しているか否かを示す状態信号 (PC =Η ' 01— xxxx)をそれぞれ示し ている。
[0084] まず、 CPU2のプログラムカウンタは、アドレス Η, 00— 4000番地を示し、アドレス Η ,00— 4000を内部バスに出力し、アドレス Η, 00— 4000番地における命令を CPU 2カ モリから順次読み出す。続いて、 CPU2は、汎用レジスタ(E2)に H, 0000を格 納する。
[0085] その後、 CPU2は、アドレス H, 00— 4004番地の命令を読み出し、続いて、ァドレ ス H, 00— 4006を読み出して、汎用レジスタ (R2)に H' OCOOを格納する。
[0086] そして、 CPU2は、アドレス H, 00— 4008の命令を読み出して、該命令を解析(汎 用レジスタ ER2が示すアドレス値が示すメモリに格納されて 、るデータをリード)した 後、その命令を実行してアドレス H' 00_0C00のデータを読み出し、汎用レジスタ( R0L)に H, 1234を格納する。
[0087] この場合、フラッシュメモリ 7におけるプロテクトエリア PAの読み出しがない、つまり アドレス値がプロテクトエリア PAを示さな 、ため、制限なくプログラム/データなどを 読み出すことができる。 [0088] また、フラッシュメモリ 7のユーザアクセスエリア UA力もプロテクトエリア PAを読み出 す場合の制御動作について、図 7を用いて説明する。
[0089] この図 7においても、上方に、フラッシュメモリ 7による読み出し制御の説明図を示し ており、その下方に、各部信号のタイミングチャートを示している。タイミングチャート は、上方から下方にかけて、クロック信号 φ、 CPU2から出力されるプログラムカウン タの値、 CPU2から出力されるアドレス信号、バスステートコントローラ 3から出力され るフラッシュメモリセレクト信号、データ、およびプログラムカウンタがフラッシュメモリ 7 のプロテクトエリア PA力否かを示す状態信号 (PC=H '01— xxxx? )をそれぞれ示 している。
[0090] まず、 CPU2のプログラムカウンタ力 アドレス H' OO— 400Aを示し、内部バスにァ ドレス H '00— 400Aを出力し、アドレス H, 00— 400A番地の命令をメモリ力 順次 読み出し、汎用レジスタ(E2)に H '0001を格納する。その後、 CPU2は、アドレス H, 00— 400E、およびアドレス H 'OO— 4010番地を順次読み出して、汎用レジスタ(R 2)に H, 0000を格納する。その後、 CPU2は、アドレス H' OO— 4012の命令を読み 出して解析 (汎用レジスタ ER2が示すアドレス値が示すメモリに格納されているデー タをリード)を行い、それに基づいて、 CPU2は、アドレス H, 01— 0000のデータを読 み出す。
[0091] このとき、アドレス H' 01— 0000は、フラッシュメモリ 7のプロテクトエリア PA内であり 、かつ CPU2から出力されるプログラムカウンタの値がプロテクトエリア PA外(ここで は H 'OO— 4014)となっているので、バスステートコントローラ 3から出力されるフラッ シュメモリセレクト信号がインアクティブ(, 1,)となり、バスステートコントローラ 3の制御 により、内部バス Bのアドレス信号には、 H' FFFFのデータが出力されることになる。
[0092] 上記構成により、ユーザエリア UAからプロテクトエリア PAに対するデータ読み出し アクセスを禁止することが可能となる。
[0093] さらに、フラッシュメモリ 7のプロテクトエリア PAからプロテクトエリア PAを読み出す 場合の制御動作について、図 8を用いて説明する。
[0094] 図 8も、上方に、フラッシュメモリ 7による読み出し制御の説明図を示しており、その 下方に、各部信号のタイミングチャートを示している。タイミングチャートは、上方から 下方に力けて、クロック信号 φ、 CPU2から出力されるプログラムカウンタの値、 CPU 2から出力されるアドレス信号、バスステートコントローラ 3から出力されるフラッシュメ モリセレクト信号、データ、およびプログラムカウンタがフラッシュメモリ 7のプロテクトェ リア PAか否かを示す状態信号 (PC=H '01— xxxx? )をそれぞれ示して ヽる。
[0095] まず、 CPU2力 アドレス H, 01—0000、およびアドレス H,01—0002番地に格納 される命令を順次読み出し、汎用レジスタ (E2)に H' 0001を格納する。その後、 CP U2は、アドレス H, 01—0004、アドレス H, 01— 0006の命令をそれぞれ読み出して 汎用レジスタ (R2)に H' 0100を格納する。
[0096] 続いて、 CPU2は、アドレス H, 01— 0008の命令を読み出して解析(汎用レジスタ ER2が示すアドレスが示すメモリに格納されて 、るデータをリード)を行 、、それに基 づいて、 CPU2は、命令を実行してアドレス H, 01—0100に格納されるデータを読 み出し、汎用レジスタ(R0L)に H, 1234を格納する。
[0097] この場合、プロテクトエリア PA力 プロテクトエリア PAを読み出すので、プログラム カウンタの値もプロテクトエリア PA内となっており、フラッシュメモリセレクト信号がァク ティブ( ' 0 ' )のままとなり、フラッシュメモリ 7から読み出された正常なデータが内部バ ス Bのデータ信号 (Data)へ出力されることになる。
[0098] 次に、フラッシュメモリ 7のプロテクトエリア PAから RAM4のプロテクトエリア PA1の データを読み出す場合の制御動作について、図 9を用いて説明する。
[0099] この図 9においては、上方に、フラッシュメモリ 7、および RAM4による読み出し制御 の説明図を示しており、その下方に、各部信号のタイミングチャートを示している。タ イミングチャートは、上方から下方にかけて、クロック信号 φ、 CPU2から出力される プログラムカウンタの値、 CPU2から出力されるアドレス信号、同様にバスステートコン トローラ 3から出力される RAMメモリセレクト信号、データ、およびプログラムカウンタ の値がフラッシュメモリ 7のプロテクトエリア PAか否かを示す状態信号 (PC = H ' 01— xxxx? )をそれぞれ示して!/、る。
[0100] まず、 CPU2力 アドレス H, 01—5000、およびアドレス H, 01— 5002の命令を順 次読み出し、汎用レジスタ(E2)に H' FFFFを格納する。その後、 CPU2は、アドレス H' 01 5004、ならびにアドレス H, 01 5006の命令を順次読み出し、汎用レジス タ (R2)に H, D000を格納する。
[0101] その後、 CPU2は、アドレス H, 01— 5008の命令を読み出し、その命令の解析(汎 用レジスタ ER2が示すアドレスが示すメモリに格納されて 、るデータをリード)を行!ヽ
、それに基づいて、 CPU2は、 RAM4におけるアドレス H' FF— D000のデータを読 み出して汎用レジスタ (R0L)に読み出した H' 1234を格納する。
[0102] この場合、プログラムカウンタの値(H '01— 50xx)は、プロテクトエリア PA1にある ので、バスステートコントローラ 3から出力される RAMセレクト信号がアクティブ(,0,) となり、正常なデータが RAM4から読み出されることになる。
[0103] ここで、ワークエリアとして用いられる RAM4の処理例について、図 10を用いて説 明する。
[0104] この図 10では、たとえば、文字データを圧縮する場合の手順について説明する。
図 10の左側は、 RAM4とフラッシュメモリ 7との説明図であり、右側は、処理手順のフ ローチャートである。
[0105] まず、文字データを RAM4上に展開し (ステップ S 101)、 RAM4のプロテクトエリア PA1へサブルーチンジャンプする(ステップ S 102)。その後、プロテクトエリア PAに 格納されたプログラムに基づく圧縮処理において、圧縮処理の中間データ、圧縮処 理結果をプロテクトエリア PA1に格納する(ステップ S 103)。
[0106] 続いて、プロテクトエリア PAに格納されたプログラムに基づく暗号化処理において 、暗号化処理の中間データ、暗号ィ匕結果をプロテクトエリア PA1に格納し (ステップ S 104)、暗号ィ匕結果データをユーザアクセスエリア UA1に格納する(ステップ S 105)
[0107] その後、リターンサブルーチンにより(ステップ S106)、暗号化結果データを、たとえ ば半導体集積回路装置 1に外部接続された外部メモリに格納する (ステップ S107)。
[0108] このように、圧縮、暗号化のプログラム処理を RAM4の Pプロテクトエリア PA1で処 理することによって、該プログラムがどのような処理を行っているかを推測しに《する ことができる。
[0109] 次に、図 5に示す制御回路 7bに設けられた消去禁止制御回路 16、および書き換え 禁止制御回路 17の動作について説明する。 [0110] まず、フラッシュメモリ 7の消去動作において、プロテクトエリア PAのブロック(Block 9)が指定されると、ィレースブロックセレクタ EBSから、,0,のィレースブロック信号 E B9が出力される。
[0111] このとき、消去禁止制御回路 16は、キーコードエリア KAに格納されているキーコー ド (第 1の設定値)を読み出し、排他的否定論理和回路 19によって、読み出した該キ 一コードとキーコード発生部 18が生成したキーコード (第 2の設定値)との排他的否 定論理和をとり、読み出したキーコードとキーコード発生部 18が生成したキーコード とが一致した際に、後段の論理積回路 20から、,0'のィレースブロック制御信号 EBC 9が読み出し Z書き込み制御回路 30に出力される。このィレースブロック制御信号 E BC9によって、フラッシュメモリ 7における消去動作が禁止されることになる。
[0112] また、フラッシュメモリ 7の書き換え動作では、まず、プログラミングビット PBから、, 1, のプログラムモード信号 Pが出力され、書き換え先を指定するアドレスが入力される。
[0113] アドレス判定部 22は、入力されたアドレス信号がプロテクトエリア PA内力否かを判 定する。また、排他的否定論理和回路 19では、キーコード発生部 21が生成したキー コード (第 3の設定値)とキーコードエリア KAに格納されているキーコード (第 1の設 定値)とを比較し、一致している際には' 0'の信号を出力する。
[0114] さらに、フラッシュメモリ 7の書き換えであるので、それぞれアクティブ(,0,)のフラッ シュメモリセレクト信号、およびライト信号がバスステートコントローラ 3から出力されて いる。
[0115] このとき、入力されたアドレスがプロテクトエリア PA内の場合には、アドレス判定部 2 2から、,0'の信号が出力され、保持回路 28を介して、,0'の信号が論理積回路 29 の他方の入力部に入力される。
[0116] よって、プログラミングビット PBからは、, 1 'のプログラムモード信号 Pが出力されて いるので、論理積回路 29からは、,0'のプログラムモード信号 Pが読み出し Z書き込 み制御回路 30に出力される。これにより、フラッシュメモリ 7における書き換え動作が 禁止されること〖こなる。
[0117] また、入力されたアドレスがプロテクトエリア PA外の場合には、アドレス判定部 22か ら、 ' 1 'の信号が出力されるので論理積回路 29から出力されるプログラムモード信号 Pは、,1,となり、フラッシュメモリ 7の書き換えが行われる。
[0118] 次に、第一ユーザ (たとえば、ソフト IPベンダ)がプログラムを書き込んだ後にエンド ユーザに半導体集積回路装置 1を出荷し、第一ユーザにおいてキーコードを設定す る際の処理にっ 、て、図 11のフローチャートを用いて説明する。
[0119] まず、第 1ユーザが作成したキーとなるプログラム (第 1プログラム)のデバッグを開 始し (ステップ S 201)。キーとなるプログラムの書き込みと消去 (ステップ S202)をデ ノ ッグが完了するまで行う (ステップ S203)。そして、デバッグが完了すると、キーコ 一ドエリア KAにキーコード (第 1の設定値)を書き込み (ステップ S 204)、ユーザァク セスエリア UAに格納されて 、るデバッグ用プログラム(第 3プログラム)などを消去し てエンドユーザに出荷する (ステップ S205)。
[0120] その後、エンドユーザ側にお 、て、エンドユーザが作成したメインプログラム (第 2プ ログラム)のデバッグを開始する (ステップ S301)。デバッグにより発生するメインプロ グラムの書き込み Z消去をデバッグが終了するまで行う(ステップ S302, S303)。
[0121] これらステップ S302, S303の処理では、キーコードが第一ユーザにより設定され て!、るので、エンドユーザによるプロテクトエリア PAに格納されて!、る第一ユーザが 書き込んだプログラム (第 1プログラム)の書き込み Z消去は不可となっている。
[0122] また、エンドユーザによりキーコードを設定する際の処理について、図 12を用いて 説明する。
[0123] まず、エンドユーザにおいて、プロテクトエリア PAに格納されるキーとなるプログラム
(第 1プログラム)およびユーザエリアに格納されるメインプログラム (第 2プログラム)の デバッグを開始する (ステップ S401)。そして、デバッグにより発生するキーとなるプロ グラム (第 1プログラム)およびメインプログラム (第 2プログラム)の書き込み Z消去を 行う(ステップ S402)。
[0124] 続いて、デバッグが終了すると (ステップ S403)、キーコードエリアにキーコード(第 1の設定値)を書き込み、プロテクトエリア PAに書き込まれたキーとなるプログラムを 保護する (ステップ S404)。
[0125] それにより、本実施の形態 1によれば、キーとなるプログラムに対しプロテクトを行う ことが可能であるため、第三者によるキーとなるプログラムの読み出しやコピー、ある いは変更などを防止することができる。
[0126] (実施の形態 2)
図 13は、本発明の実施の形態 2による半導体集積回路装置のブロック図、図 14は 、図 13の半導体集積回路装置におけるリセットシーケンスを示した説明図、図 15は、 図 14のリセットシーケンスにおけるプロテクト処理制御部の設定処理を示すフローチ ヤート、図 16は、図 13の半導体集積回路装置に設けられたフラッシュメモリ 7におけ るプロテクトエリアの任意設定処理を示すフローチャート、図 17は、図 16におけるフ ラッシュメモリ 7のメモリマップの補足説明図である。
[0127] 本実施の形態 2において、半導体集積回路装置 1は、図 13に示すように、 CPU2、 バスステートコントローラ 3、 RAM4、 SCI (Serial Communication Interface) 5 などを含む周辺回路 6、およびフラッシュメモリ 7に例示される不揮発性半導体メモリ などの前記実施の形態 1と同様の構成となっている。
[0128] 前記実施の形態 1では、フラッシュメモリ 7のプロテクトエリア PAを、アドレス H, 01— 0000— H' 01— FFFFまでの 1つのブロックに固定されていた力 本実施の形態 2の フラッシュメモリ 7では、プロテクトエリア PAの領域を任意に変更することが可能となつ ている。
[0129] フラッシュメモリ 7は、メモリマット 7a、および制御回路 7bから構成されており、該メモ リマット 7aは、記憶の最小単位であるメモリセルが規則正しくアレイ状に並べられてお り、アドレスバッファ、アドレスデコーダ 7al、入出力バッファ 7a2、およびセンスアンプ などの周辺回路を含んでいる。
[0130] 制御回路 7b、 CPU2から入力される制御用信号を一時的に格納し、動作ロジック の制御を行う。制御回路 7bには、プロテクト処理制御部 31が設けられている。
[0131] プロテクト処理制御部 31は、フラッシュメモリ 7におけるプロテクトエリア PAの領域を 任意に変更する制御を行う。また、プロテクトエリア PAには、プロテクトエリア PAの先 頭アドレスを格納する先頭アドレス格納エリア SDA、プロテクトエリア PAの末尾アドレ スを格納する末尾アドレス格納エリア MDA、およびキーコードエリアを格納するキー コードエリア KAが設けられて 、る。
[0132] プロテクト処理制御部 31は、プロテクト処理制御回路 32、アドレス生成回路 33、リ ード信号生成回路 34、アドレス Zキーコード格納レジスタ 35、およびセレクタ 36, 37 から構成されている。
[0133] プロテクト処理制御回路 32、アドレス生成回路 33、リード信号生成回路 34、および アドレス/キーコード格納レジスタ 35には、リセット信号を発生するリセット回路 38か ら出力されたリセット信号が入力されるようにそれぞれ接続されている。
[0134] プロテクト処理制御回路 32には、アドレス生成回路 33、リード信号生成回路 34、な らびにアドレス Zキーコード格納レジスタ 35がそれぞれ接続されており、該プロテクト 処理制御回路 32から出力された信号により、これらの回路が動作を開始する。
[0135] アドレス生成回路 33は、フラッシュメモリ 7のメモリマット 7aに格納されているキーコ ードの格納アドレスを生成する。リード信号生成回路 34は、メモリマット 7aのリード信 号を生成する。アドレス Zキーコード格納レジスタ 35は、メモリマット 7aから読み出し たキーコード、およびプロテクトエリア PAの領域を示すアドレスをそれぞれ格納する。
[0136] またプロテクト処理制御回路 32には、セレクタ 36, 37を制御する制御信号が入力 されるようにそれぞれ接続されている。セレクタ 36は、プロテクト処理制御回路 32から 出力される制御信号に基づいて、アドレス生成回路 33が生成したアドレスと、ノ スス テートコントローラ 3から出力されるアドレスとを切り替えて出力する。
[0137] セレクタ 37は、プロテクト処理制御回路 32から出力される制御信号に基づいて、リ ード信号生成回路 34が生成したリード信号と、バスステートコントローラ 3から出力さ れるリード信号とを切り替えて出力する。
[0138] 図 14は、半導体集積回路装置 1におけるリセットシーケンスを示した説明図であり、 図 15は、図 14のリセットシーケンスにおけるプロテクト処理制御部 31の設定処理を 示すフローチャートである。
[0139] 図 14においては、上方から下方にかけて、システムクロック、半導体集積回路装置 1のリセット端子に入力されるリセット信号、プロテクト処理制御部 31の動作状態、半 導体集積回路装置 1の内部路セット信号、および CPU2 (半導体集積回路装置 1)の 動作状態をそれぞれ示して ヽる。
[0140] まず、半導体集積回路装置の外部ポートの 1つであるリセット端子からリセット信号 が入力され、そのリセット信号が解除となると (ステップ S501)、プロテクト処理制御回 路 32が起動する(ステップ S502)。
[0141] プロテクト処理制御回路 32は、アドレス生成回路 33、ならびにリード信号生成回路
34に対して信号を出力し、これらアドレス生成回路 33、およびリード信号生成回路 3
4を動作させる(ステップ S503)。
[0142] 続いて、プロテクト処理制御回路 32は、メモリマット 7aのキーコードエリア KAに格 納されているデータを読み出し (ステップ S504)、そのデータをアドレス Zキーコード 格納レジスタ 35に格納する(ステップ S505)。
[0143] そして、プロテクト処理制御回路 32は、アドレス Zキーコード格納レジスタ 35にキー コード (第 1の設定値)が格納されている力否かを判断し (ステップ S506)、キーコード が格納されている場合、プロテクト処理制御回路 32は、メモリマット 7aからプロテクト エリア PAの先頭アドレスと末尾アドレスとを読み出して、アドレス Zキーコード格納レ ジスタ 35にそれぞれ格納する(ステップ S507, S508)。
[0144] ステップ S508の処理の終了後、またはステップ S506の処理においてキーコードが ない場合には、半導体集積回路装置の内部リセットを解除する解除信号をリセット回 路 38に出力した後 (ステップ S 509)、プロテクト処理制御回路 32が停止して (ステツ プ S510)半導体集積回路装置 1が動作を開始することになる。
[0145] キーコードの読み出しおよび制御回路 7bに対するキーコードの設定、プロテクトェ リアに対するプロテクトの有無の確認は、リセット解除後に上記フローに従って実行さ れる。半導体集積回路装置 1が通常の動作を開始した後は、図 4に従ったメモリァク セスアドレスに基づ 、た制御を実行する。
[0146] また、プロテクトエリア PAおよびプロテクトエリア PA1がそれぞれ固定的な一つの領 域とする場合はステップ S507, S508は実行されない。
[0147] また、図 16は、フラッシュメモリ 7におけるプロテクトエリア PAの任意設定処理を示 すフローチャートであり、図 17は、図 16におけるフラッシュメモリ 7のメモリマップの補 足説明図である。
[0148] まず、プログラムのデバッグを開始し (ステップ S601)、プログラム書き込みと消去( ステップ S602)をデバッグが完了するまで行う(ステップ S603)。そして、デバッグが 完了すると、メモリマット 7aに設けられた先頭アドレス格納エリア SDA、および末尾ァ ドレス格納エリア MDAにプロテクトエリア PAの任意の先頭アドレスと任意の末尾アド レスとをそれぞれ書き込み、プロテクエリア PAの任意の領域を設定するとともに、キ 一コードエリア KAにキーコードを書き込む(ステップ S604)。
[0149] この場合、先頭アドレス格納エリア SDA、末尾アドレス格納エリア MDAに、ならび にキーコードエリア KAがプロテクトエリア PAの領域内となるように、先頭アドレスと末 尾アドレスとをそれぞれ設定することにより、第三者による該プロテクトエリアの領域変 更読み出し、あるいはキーコードの読み出しや変更などを防止することができる。
[0150] それにより、本実施の形態 2によれば、プロテクトエリア PAの領域を任意変更するこ とができるので、読み出しや書き換えなどを禁止した 、プログラムのデータ容量など に応じてフレキシブルに変更することが可能となるとともに、第三者によるプログラム の読み出しやコピー、あるいは変更などを防止することができる。
[0151] 以上、本発明者によってなされた発明を実施の形態に基づき具体的に説明したが 、本発明は前記実施の形態に限定されるものではなぐその要旨を逸脱しない範囲 で種々変更可能であることは 、うまでもな!/、。
産業上の利用可能性
[0152] 本発明の半導体集積回路装置は、不揮発性半導体メモリにおける所定のブロック の読み出し、および書き換えを防止する技術に適して 、る。

Claims

請求の範囲
[1] 複数の不揮発性メモリセルを有するメモリアレイ部と、前記不揮発性メモリセルに情 報を格納する書き込み動作、前記不揮発性メモリセルに格納した情報を読み出す読 み出し動作、前記不揮発性メモリセルに格納した情報を消去する消去動作の各動作 を制御する制御部とを備えた不揮発性記憶部と、前記不揮発性記憶部に格納され たプログラムのワークエリアとして用いられる揮発性記憶部と、所定の処理を実行し、 前記不揮発性記憶部に動作指示を行うことが可能である中央処理装置と、前記不揮 発性記憶部、および前記揮発性記憶部の読み出し動作を制御するプロテクト動作制 御部とを有した半導体集積回路装置であって、
前記メモリアレイ部は、前記プロテクト動作制御部の制御により格納された情報の読 み出し、および書き込みが禁止される第 1のプロテクトメモリ領域を有し、
前記揮発性記憶部は、前記プロテクト動作制御部の制御により前記メモリアレイ部 の第 1のプロテクトメモリ領域以外からの読み出しが禁止される第 2のプロテクトメモリ 領域を有し、
前記不揮発性記憶部の第 1のプロテクトメモリ領域に格納されたプログラムのワーク エリアとして揮発性記憶部の第 2のプロテクトメモリ領域を用いることを特徴とする半導 体集積回路装置。
[2] 複数の不揮発性メモリセルを有するメモリアレイ部と、前記不揮発性メモリセルに情 報を格納する書き込み動作、前記不揮発性メモリセルに格納した情報を読み出す読 み出し動作、前記不揮発性メモリセルに格納した情報を消去する消去動作の各動作 を制御する制御部とを備えた不揮発性記憶部と、揮発性記憶部と、所定の処理を実 行し、前記不揮発性記憶部に動作指示を行うことが可能である中央処理装置と、前 記不揮発性記憶部、および前記揮発性記憶部の読み出し動作を制御するプロテクト 動作制御部とを有した半導体集積回路装置であって、
前記メモリアレイ部は、前記プロテクト動作制御部の制御により格納された情報の読 み出し、および書き込みが禁止される第 1のプロテクトメモリ領域を有し、
前記揮発性記憶部は、前記プロテクト動作制御部の制御により前記メモリアレイ部 の第 1のプロテクトメモリ領域以外からの読み出し、および書き込みが禁止される第 2 のプロテクトメモリ領域を有したことを特徴とする半導体集積回路装置。
[3] 請求項 1または 2記載の半導体集積回路装置において、
前記プロテクト動作制御部は、
前記中央処理装置から出力されるアドレス信号とプログラムカウンタとの値を比較し て前記第 1のプロテクトメモリ領域である力否かを判別することを特徴とする半導体集 積回路装置。
[4] 請求項 3記載の半導体集積回路装置において、
前記プロテクト動作制御部は、
前記中央処理装置から出力されるアドレス信号とプログラムカウンタとの値を比較し 、それらアドレス信号、およびプログラムカウンタの値がいずれも前記第 1のプロテクト メモリ領域内のアドレス値である場合のみ、前記第 1のプロテクトメモリ領域の読み出 しを許可することを特徴とする半導体集積回路装置。
[5] 請求項 1一 4のいずれか 1項に記載の半導体集積回路装置において、
前記プロテクト動作制御部は、
前記中央処理装置から出力されるアドレス信号とプログラムカウンタとの値を比較し て前記第 2のプロテクトメモリ領域である力否かを判別することを特徴とする半導体集 積回路装置。
[6] 請求項 5記載の半導体集積回路装置において、
前記プロテクト動作制御部は、
前記中央処理装置から出力されるアドレス信号とプログラムカウンタとの値を比較し 、プログラムカウンタの値が前記第 1のプロテクトメモリ領域内にあり、かつアドレス信 号が前記第 2のプロテクトメモリ領域内のアドレス値である場合のみ、前記第 2のプロ テクトメモリ領域の読み出しを許可することを特徴とする半導体集積回路装置。
[7] 請求項 1一 6のいずれか 1項に記載の半導体集積回路装置において、
前記第 1のプロテクトメモリ領域における消去を禁止する消去禁止制御部を備えた ことを特徴とする半導体集積回路装置。
[8] 請求項 7記載の半導体集積回路装置において、
前記消去禁止制御部は、 予め設定されたキーコード信号を出力するキーコード発生回路と、 前記メモリアレイ部の消去動作が発生した際に、前記キーコード発生回路が生成し たキーコード信号と、前記第 1のプロテクトメモリ領域に格納されたキーコードとを比較 し、それらキーコードが一致した際に前記第 1のプロテクトメモリ領域における消去を 禁止する消去制御回路とを備えたことを特徴とする半導体集積回路装置。
[9] 請求項 1一 8のいずれか 1項に記載の半導体集積回路装置において、
前記第 1のプロテクトメモリ領域における書き換えを禁止する書き換え禁止制御部 を備えたことを特徴とする半導体集積回路装置。
[10] 請求項 9記載の半導体集積回路装置において、
前記書き換え禁止制御部は、
予め設定されたキーコード信号を出力するキーコード発生回路と、
書き換え先アドレス信号が前記第 1のプロテクトメモリ領域内か否かを判定するアド レス判定部と、
前記キーコード発生回路が生成したキーコード信号と前記第 1のプロテクトメモリ領 域に格納されたキーコードとを比較し、それらキーコードが一致した際に一致信号を 出力するキーコード判定部と、
前記メモリアレイ部の書き換え動作が発生した際に、書き換え先アドレス信号が前 記第 1のプロテクトメモリ領域内であり、かつキーコードが一致した場合に前記第 1の プロテクトメモリ領域の書き換えを禁止する書き換え禁止信号を出力する書き換え制 御回路とを備えたことを特徴とする半導体集積回路装置。
[11] 複数の不揮発性メモリセルを有するメモリアレイ部と、前記不揮発性メモリセルに情 報を格納する書き込み動作、前記不揮発性メモリセルに格納した情報を読み出す読 み出し動作、前記不揮発性メモリセルに格納した情報を消去する消去動作の各動作 を制御する制御部とを備えた不揮発性半導体記憶装置と、
前記不揮発性半導体記憶装置に格納されたプログラムのワークエリアとして用いら れる揮発性半導体記憶装置と、
所定の処理を実行し、前記不揮発性半導体記憶装置に動作指示を行うことが可能 である中央処理装置と前記不揮発性半導体記憶装置、および前記揮発性半導体記 憶装置の読み出し動作を制御するプロテ外動作制御部とを備えた半導体集積回路 装置とを有した電子システムであって、
前記メモリアレイ部は、前記プロテクト動作制御部の制御により格納された情報の読 み出しが禁止される第 1のプロテクトメモリ領域を有し、
前記揮発性半導体記憶装置は、前記プロテクト動作制御部の制御により前記メモリ アレイ部の第 1のプロテクトメモリ領域以外からの読み出しが禁止される第 2のプロテ タトメモリ領域を有し、
前記不揮発性半導体記憶装置に格納されたプログラムのワークエリアとして前記第 2のプロテクトメモリ領域を用いることを特徴とする電子システム。
[12] 請求項 11記載の電子システムにおいて、
前記プロテクト動作制御部は、
前記中央処理装置から出力されるアドレス信号とプログラムカウンタとの値を比較し て前記第 1、および第 2のプロテクトメモリ領域である力否かを判別することを特徴とす る電子システム。
[13] 請求項 12記載の電子システムにおいて、
前記プロテクト動作制御部は、
前記中央処理装置から出力されるアドレス信号とプログラムカウンタとの値を比較し 、それらアドレス信号、およびプログラムカウンタの値がいずれも前記第 1のプロテクト メモリ領域内のアドレス値である場合に前記第 1のプロテクトメモリ領域の読み出しを 許可し、プログラムカウンタの値が前記第 1のプロテクトメモリ領域内にあり、かつアド レス信号が前記第 2のプロテクトメモリ領域内のアドレス値である場合に前記第 2のプ ロテクトメモリ領域の読み出しを許可することを特徴とする電子システム。
[14] 請求項 10— 13のいずれ力 1項に記載の電子システムにおいて、
前記第 1のプロテクトメモリ領域における消去を禁止する消去禁止制御部を備えた ことを特徴とする電子システム。
[15] 請求項 10— 14のいずれ力 1項に記載の電子システムにおいて、
前記第 1のプロテクトメモリ領域における書き換えを禁止する書き換え禁止制御部 を備えたことを特徴とする電子システム。
PCT/JP2004/014939 2004-10-08 2004-10-08 半導体集積回路装置および電子システム Ceased WO2006040798A1 (ja)

Priority Applications (3)

Application Number Priority Date Filing Date Title
US10/583,778 US20070133280A1 (en) 2004-10-08 2004-10-08 Semiconductor integrated circuit apparatus and electronic system
PCT/JP2004/014939 WO2006040798A1 (ja) 2004-10-08 2004-10-08 半導体集積回路装置および電子システム
JP2006540783A JPWO2006040798A1 (ja) 2004-10-08 2004-10-08 半導体集積回路装置および電子システム

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
PCT/JP2004/014939 WO2006040798A1 (ja) 2004-10-08 2004-10-08 半導体集積回路装置および電子システム

Publications (1)

Publication Number Publication Date
WO2006040798A1 true WO2006040798A1 (ja) 2006-04-20

Family

ID=36148100

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/JP2004/014939 Ceased WO2006040798A1 (ja) 2004-10-08 2004-10-08 半導体集積回路装置および電子システム

Country Status (3)

Country Link
US (1) US20070133280A1 (ja)
JP (1) JPWO2006040798A1 (ja)
WO (1) WO2006040798A1 (ja)

Cited By (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2015525916A (ja) * 2012-06-27 2015-09-07 ノルディック セミコンダクタ アーエスアーNordic Semiconductor ASA メモリ保護装置及び保護方法
US9542574B2 (en) 2012-07-26 2017-01-10 Mitsubishi Electric Corporation Programmable logic controller
JP2017033149A (ja) * 2015-07-30 2017-02-09 株式会社東芝 情報処理装置、コントローラ、及び、情報処理装置の制御方法
JP2019145110A (ja) * 2019-02-25 2019-08-29 株式会社東芝 情報処理装置及び情報処理装置の制御方法

Families Citing this family (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US8959311B2 (en) * 2006-08-25 2015-02-17 Texas Instruments Incorporated Methods and systems involving secure RAM
US7573292B1 (en) * 2008-02-15 2009-08-11 Xilinx, Inc. Pre-programmed integrated circuit including programmable logic
KR20110124992A (ko) * 2010-05-12 2011-11-18 삼성전자주식회사 반도체 메모리 장치 및 반도체 메모리 시스템
JP5730034B2 (ja) * 2011-01-21 2015-06-03 スパンション エルエルシー 半導体装置
JP6476098B2 (ja) * 2015-09-15 2019-02-27 ルネサスエレクトロニクス株式会社 半導体装置
CN110968254B (zh) * 2018-09-29 2024-06-28 嘉楠明芯(北京)科技有限公司 一种非易失性存储器的分区保护方法及装置
CN115083463B (zh) * 2022-08-23 2022-11-08 旋智电子科技(上海)有限公司 用于控制存储器访问权限的方法、电子系统和存储介质
CN117668779A (zh) * 2022-09-01 2024-03-08 华润微集成电路(无锡)有限公司 硬件加密模块、芯片及加密方法
TWI838137B (zh) * 2023-02-23 2024-04-01 大陸商集創北方(珠海)科技有限公司 具寫入保護功能的燒寫控制電路、電子晶片以及資訊處理裝置

Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPH10228421A (ja) * 1997-02-14 1998-08-25 Nec Ic Microcomput Syst Ltd メモリアクセス制御回路
JP2004145605A (ja) * 2002-10-24 2004-05-20 Matsushita Electric Ind Co Ltd プロセッサ

Family Cites Families (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US4590552A (en) * 1982-06-30 1986-05-20 Texas Instruments Incorporated Security bit for designating the security status of information stored in a nonvolatile memory
WO1995016238A1 (en) * 1993-12-06 1995-06-15 Telequip Corporation Secure computer memory card
FR2713803B1 (fr) * 1993-12-07 1996-01-12 Gemplus Card Int Carte à mémoire et procédé de fonctionnement.
JP3487690B2 (ja) * 1995-06-20 2004-01-19 シャープ株式会社 不揮発性半導体記憶装置
US6434584B1 (en) * 1998-06-04 2002-08-13 Texas Instruments Incorporated Flexible accumulator register file for use in high performance microprocessors
US6931552B2 (en) * 2001-05-02 2005-08-16 James B. Pritchard Apparatus and method for protecting a computer system against computer viruses and unauthorized access

Patent Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPH10228421A (ja) * 1997-02-14 1998-08-25 Nec Ic Microcomput Syst Ltd メモリアクセス制御回路
JP2004145605A (ja) * 2002-10-24 2004-05-20 Matsushita Electric Ind Co Ltd プロセッサ

Cited By (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2015525916A (ja) * 2012-06-27 2015-09-07 ノルディック セミコンダクタ アーエスアーNordic Semiconductor ASA メモリ保護装置及び保護方法
US9542574B2 (en) 2012-07-26 2017-01-10 Mitsubishi Electric Corporation Programmable logic controller
JP2017033149A (ja) * 2015-07-30 2017-02-09 株式会社東芝 情報処理装置、コントローラ、及び、情報処理装置の制御方法
JP2019145110A (ja) * 2019-02-25 2019-08-29 株式会社東芝 情報処理装置及び情報処理装置の制御方法

Also Published As

Publication number Publication date
JPWO2006040798A1 (ja) 2008-05-15
US20070133280A1 (en) 2007-06-14

Similar Documents

Publication Publication Date Title
JP3884839B2 (ja) 半導体記憶装置
JP3421526B2 (ja) デ−タ処理装置
US5881002A (en) Nonvolatile memory control circuit
JP3891539B2 (ja) 半導体装置およびその制御装置
US20010000816A1 (en) Volatile lock architecture for individual block locking on flash memory
US8607061B2 (en) Flash device security method utilizing a check register
WO2006040798A1 (ja) 半導体集積回路装置および電子システム
JP3875153B2 (ja) 不揮発性半導体記憶装置およびその書き換え禁止制御方法
KR100265266B1 (ko) 플래쉬 eeprom 을 구비하는 마이크로컴퓨터및 플래쉬 eeprom 의 소거방법
WO2020063975A1 (zh) 一种非易失性存储器的分区保护方法及装置
JP4064703B2 (ja) 半導体記憶装置
JP2008533574A (ja) セクタ単位での消去の可能な半導体メモリ手段の第1のセクタへの再書き込み方法および装置
JP2842442B2 (ja) マイクロコンピュータ、不揮発性半導体記憶装置、ならびにその書込みおよび消去方法
JP3924568B2 (ja) フラッシュメモリにおけるデータアクセス制御方法、データアクセス制御プログラム
CN100447766C (zh) 非易失性存储器的可选择块保护
JP4031693B2 (ja) 不揮発性メモリおよびこれを有したデータ記憶装置
US7310277B2 (en) Non-volatile semiconductor storage device with specific command enable/disable control signal
US6842371B2 (en) Permanent master block lock in a memory device
JPH10143434A (ja) 半導体集積回路
JP3028567B2 (ja) Eeprom内蔵マイクロコンピュータ
JP4102955B2 (ja) 半導体記憶装置及びそのテスト方法
JPH0697442B2 (ja) マイクロコンピユ−タ
JP2005085398A (ja) 不揮発性メモリ
KR100905640B1 (ko) 플래쉬 메모리의 데이터 보호 회로
JP3695931B2 (ja) マイクロコンピュータ

Legal Events

Date Code Title Description
AK Designated states

Kind code of ref document: A1

Designated state(s): AE AG AL AM AT AU AZ BA BB BG BR BW BY BZ CA CH CN CO CR CU CZ DE DK DM DZ EC EE EG ES FI GB GD GE GH GM HR HU ID IL IN IS JP KE KG KP KR KZ LC LK LR LS LT LU LV MA MD MG MK MN MW MX MZ NA NI NO NZ OM PG PH PL PT RO RU SC SD SE SG SK SL SY TJ TM TN TR TT TZ UA UG US UZ VC VN YU ZA ZM ZW

AL Designated countries for regional patents

Kind code of ref document: A1

Designated state(s): BW GH GM KE LS MW MZ NA SD SL SZ TZ UG ZM ZW AM AZ BY KG KZ MD RU TJ TM AT BE BG CH CY CZ DE DK EE ES FI FR GB GR HU IE IT LU MC NL PL PT RO SE SI SK TR BF BJ CF CG CI CM GA GN GQ GW ML MR NE SN TD TG

DPEN Request for preliminary examination filed prior to expiration of 19th month from priority date (pct application filed from 20040101)
121 Ep: the epo has been informed by wipo that ep was designated in this application
WWE Wipo information: entry into national phase

Ref document number: 2007133280

Country of ref document: US

Ref document number: 10583778

Country of ref document: US

WWE Wipo information: entry into national phase

Ref document number: 2006540783

Country of ref document: JP

NENP Non-entry into the national phase

Ref country code: DE

WWP Wipo information: published in national office

Ref document number: 10583778

Country of ref document: US

122 Ep: pct application non-entry in european phase