JPS62251841A - Single chip microcomputer - Google Patents

Single chip microcomputer

Info

Publication number
JPS62251841A
JPS62251841A JP61095561A JP9556186A JPS62251841A JP S62251841 A JPS62251841 A JP S62251841A JP 61095561 A JP61095561 A JP 61095561A JP 9556186 A JP9556186 A JP 9556186A JP S62251841 A JPS62251841 A JP S62251841A
Authority
JP
Japan
Prior art keywords
test mode
data
rom
built
permission
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.)
Granted
Application number
JP61095561A
Other languages
Japanese (ja)
Other versions
JPH081606B2 (en
Inventor
Yoshihide Fujimura
藤村 善英
Wataru Okamoto
渉 岡本
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.)
NEC Corp
Original Assignee
NEC 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 NEC Corp filed Critical NEC Corp
Priority to JP61095561A priority Critical patent/JPH081606B2/en
Publication of JPS62251841A publication Critical patent/JPS62251841A/en
Publication of JPH081606B2 publication Critical patent/JPH081606B2/en
Anticipated expiration legal-status Critical
Expired - Lifetime legal-status Critical Current

Links

Landscapes

  • Test And Diagnosis Of Digital Computers (AREA)
  • Microcomputers (AREA)

Abstract

PURPOSE:To improve the security of the titled microcomputer system by providing the system with an execution permission specifying means with a test mode function, executing the prescribed data processing of software stored in a memory at the time of permission, and after the end of its test, turning the execution permission specifying means to an inhibition state. CONSTITUTION:A mask ROM 103-2 storing a user program or data is arranged in a mask ROM block 103 and a flag 105-5 for discriminating the permission/ inhibition of a test mode is arranged in a CPU control part 5. Receiving a test mode request signal from a request line 105-6, the control part 105 inputs an instruction code in a ROM 103-2 through a register 4 and sets up the leading address of a test mode processing routine in a ROM 105-3. When the flag 105-5 is not set up, data are fetched from the ROM 103-2 to a bus 2 and outputted to an execution part 101, and after executing the prescribed processing of the data, the flag 105-5 is set up.

Description

【発明の詳細な説明】 〔産業上の利用分野〕 本発明は、単一半導体基盤上にテストモード機能及びコ
ンピュータ機能を集積したシングルチップマイクロコン
ピュータに関する。
DETAILED DESCRIPTION OF THE INVENTION [Field of Industrial Application] The present invention relates to a single-chip microcomputer that integrates test mode functionality and computer functionality on a single semiconductor substrate.

〔従来の技術〕[Conventional technology]

近年、LSI製造技術の進歩により、シングルチップマ
イクロコンピュータの分野においても高集積化が進み、
単一半導体基盤上に集積される機能もより高度化してい
る。例えば、内蔵メモリの容量の増加、データ処理能力
の向上などである。
In recent years, advances in LSI manufacturing technology have led to higher integration in the field of single-chip microcomputers.
The functions integrated on a single semiconductor substrate are also becoming more sophisticated. Examples include an increase in the capacity of built-in memory and an improvement in data processing capacity.

これに伴ってシングルチップマイクロコンピュータの制
御を司るソフトウェアもしだいに高度化し、各社のノウ
ハウを結集したソフトウェアがチップ内に内蔵されるに
至っているが、最近ではこれらのソフトウェアが盗用さ
れる問題が起こっている。
Along with this, the software that controls single-chip microcomputers has gradually become more sophisticated, and software that combines the know-how of various companies is now built into the chip.However, recently, problems have arisen in which this software is stolen. ing.

例えば、TVゲームマシンのプログラムコピーや紙幣両
替機の制御ソフトウェアを悪用した擬似紙幣の作成など
大きな社会問題となったものもある。
For example, there are some cases that have become a major social problem, such as copying the programs of TV game machines and creating fake banknotes by exploiting the control software of banknote exchange machines.

従って、この様なソフトウェアの盗用に対して、最近で
はソフトウェアのセキュリティに対する関心と要求が高
まってきている。
Therefore, recently there has been a growing interest and demand for software security against such software theft.

一般にシングルチップマイクロコンピュタの内Mプログ
ラムのコピーは、内蔵メモリに格納されたユーザプログ
ラム及びデータを出力ボートから読み出す機能(以下、
この機能をテストモード機能という)を利用して簡単に
行なうことができる。
In general, the M program copy function of a single-chip microcomputer is a function (hereinafter referred to as
This function can be easily performed using the test mode function.

上記機能は本来内蔵メモリに格納されたプログラム及び
データの確認用に付加されたもので、はとんどすべての
シングルチップマイクロコンピュータにおいて内蔵され
ている。
The above function was originally added for checking programs and data stored in built-in memory, and is built into almost all single-chip microcomputers.

第3図に従来のテストモード機能を内蔵したシングルチ
ップマイクロコンピュータのブロック図を示し、以下同
図に基づき動作を説明する。第3図において、アドレス
バス1はアドレスデータを転送するバスである。データ
バス2は中央処理装ft(以下、CPUという)の処理
データを転送するバスである。内蔵ROMブロック3は
プログラムカウンタ及びユーザプログラムやデータを格
納するメモリブロックである。一般にROMにはマスク
固定されたROM(以下、マスクROMという)とデー
タの書き込みが可能な読み出し専用メモリ(以下、FR
OMという)があシ、またFROMとしては紫外線でメ
モリ内のデータを消去するUVEFROM、及び電気的
にデータの書込み消去が行なえるE2FROMが存在す
る。命令レジスタ4は内蔵ROMブロック3から読み出
した命令コードを格納するレジスタである。CPU制御
部5は命令レジスタ4に格納された命令コードで指定さ
れたプログラム動作を制御するブロックである。
FIG. 3 shows a block diagram of a conventional single-chip microcomputer with a built-in test mode function, and the operation will be explained below based on the diagram. In FIG. 3, address bus 1 is a bus for transferring address data. The data bus 2 is a bus for transferring processing data of the central processing unit ft (hereinafter referred to as CPU). The built-in ROM block 3 is a memory block that stores a program counter, user programs, and data. Generally, ROM includes ROM with a fixed mask (hereinafter referred to as mask ROM) and read-only memory (hereinafter referred to as FR) in which data can be written.
There are two types of FROM: UVEFROM, which erases data in the memory using ultraviolet rays, and E2FROM, which allows data to be written and erased electrically. The instruction register 4 is a register that stores an instruction code read from the built-in ROM block 3. The CPU control unit 5 is a block that controls program operations specified by instruction codes stored in the instruction register 4.

アキュムレータ6はデータ処理の中心となるレジスタで
ある。テンポラリレジスタ7は算術論理演算ユニット8
への入力データを一時保持するだめのレジスタである。
The accumulator 6 is a register that plays a central role in data processing. Temporary register 7 is arithmetic logic unit 8
This is a register that temporarily holds input data to the .

算術論理演算ユニット8は、アキュムレータ6、テンポ
シリレジスタ7に格納されたデータべ対し指定された算
術論理演算を行ない、結果をデータバス2へ出力する。
The arithmetic and logic operation unit 8 performs designated arithmetic and logic operations on the database stored in the accumulator 6 and the tempo register 7, and outputs the result to the data bus 2.

RAM 9は汎用レジスタ及び様々な処理データ格納用
として用いられる続出し及び賽込みが可能なメモリで、
アドレスバス1でアドレス指定される格納データをデー
タバス2へ出力するか、データバス2上のデータをアド
レスバス1でt賃走される内部RAM9のアドレス位置
に格納する。ボート10はデータバス2上のデータを外
部へ出力する機能を有する出力ボートである。
RAM 9 is a memory that can be accessed and reloaded, and is used as a general-purpose register and for storing various processing data.
The stored data addressed by the address bus 1 is output to the data bus 2, or the data on the data bus 2 is stored at the address location of the internal RAM 9 which is accessed by the address bus 1. The boat 10 is an output boat that has a function of outputting data on the data bus 2 to the outside.

次に動作説明を行なう。従来のテストモード機能内蔵シ
ングルチップマイクロコンピータにおいては、内蔵RO
Mブロック3内のプログラムカウンタで指定されるアド
レスの命令コードを内蔵ROMブロック3から読み出し
、データバス2を介して命令レジスタ4に格納する。命
令レジスタ4に格納された命令コードはCPU制御部5
へ入力され、PLA(プログラマブルロジックアレイ)
などのハードウェアによってデコードされて、命令機能
が実行される。例えばアキュムレータ6と汎用レジスタ
間の二項演算の場合、汎用レジスタの内容を8人M9か
ら読み出し、テンポラリレジスタ7に格納する。次に算
術論理演算ユニット8を動作させ、演算結果をデータバ
ス2を介して、デスティネー7!lンがアキエムレータ
8の場合はそこに書き込み、汎用レジスタの場合はRA
MQ内の汎用レジスタに書き込む。上記動作は全てCP
U制御部5内のPLAなどのハードウェアによシ、デコ
ードされた制御信号により行□なわれる。
Next, the operation will be explained. In conventional single-chip microcomputers with a built-in test mode function, the built-in RO
The instruction code at the address specified by the program counter in the M block 3 is read from the built-in ROM block 3 and stored in the instruction register 4 via the data bus 2. The instruction code stored in the instruction register 4 is sent to the CPU control unit 5.
input to PLA (programmable logic array)
It is decoded by hardware such as , and the instruction function is executed. For example, in the case of a binary operation between the accumulator 6 and a general-purpose register, the contents of the general-purpose register are read from the eight M9s and stored in the temporary register 7. Next, the arithmetic and logic operation unit 8 is operated, and the operation result is sent to the destination 7! via the data bus 2. If the input is Achiemulator 8, write there, and if it is a general-purpose register, write to RA.
Write to general-purpose register in MQ. All the above operations are CP
This is performed using a control signal decoded by hardware such as a PLA in the U control unit 5.

次に第4図を用いて、従来のテストモード機能に関して
その動作説明を行なう。第4図は第3図における内蔵R
OMブロック3の詳細構成を示したものである。第4図
においてプログラムカウンタ31は、内蔵ROM(FR
OMまたはマスクROM)32に格納された命令コード
の格納アドレスを指すアドレスポインタである。内蔵R
OM32はユーザプログラム及びデータの格納に用いる
読出し専用メモリであり、メモリ内の命令コード及びデ
ータはデータバス2に出力される。なおデータを読み出
す場合は、プログラムカウンタ31は経由せずにバス3
7上のアドレス値によって、直接アドレス指定して読み
出す。テストモード制御部33はテストモード要求線3
6に信号が出力されると動作するブロックで、テストモ
ード機能の動作制御を司る。プログ、ラムカウンタリセ
ット&134はテストモード機能実行時にプログラムカ
ウンタ31をリセットするだめの信号線で、テストモー
ド制御部33より信号がプログラムカウンタ31に対し
出力される。プログラムカウンタインクリメント綜35
はテストモード機能実行時にプログラムカウンタ31を
インクリメントするための市1]御線で、テストモード
制御部33よυ信号がプログラムカウンタ31に対し出
力される。
Next, the operation of the conventional test mode function will be explained using FIG. Figure 4 shows the built-in R in Figure 3.
This figure shows the detailed configuration of the OM block 3. In FIG. 4, the program counter 31 is a built-in ROM (FR
This is an address pointer that points to the storage address of the instruction code stored in the OM (or mask ROM) 32. Built-in R
OM32 is a read-only memory used to store user programs and data, and the instruction code and data in the memory are output to the data bus 2. Note that when reading data, the program counter 31 is not used, but the bus 3 is read.
Directly address and read using the address value above 7. The test mode control unit 33 uses the test mode request line 3
This block operates when a signal is output to 6, and controls the operation of the test mode function. PROGRAM COUNTER RESET &134 is a signal line used to reset the program counter 31 when the test mode function is executed, and a signal is output from the test mode control section 33 to the program counter 31. Program counter increment 35
is an input line for incrementing the program counter 31 when the test mode function is executed, and the test mode control unit 33 outputs the υ signal to the program counter 31.

従来のシングルチップマイクロコンピュータの特定外部
端子に高電圧を印加すると、テストモード要求線36に
信号が出力され、テストモード制i卸部33に入力され
る。テストモード制御部33は、ia号大力後、直ちに
プログラム力ウンタリセッHJI34に信号を出力し、
プログラムカウンタ31の内部をQにクリアする。そし
てプログラムカラ/り31によって指定されたアドレス
の命令コードまたはデータを内蔵ROM32よシ読み出
し、データバス2上に出力し、さらにデータバス2上の
データをボート10を経由して外部に出力する。
When a high voltage is applied to a specific external terminal of a conventional single-chip microcomputer, a signal is output to the test mode request line 36 and input to the test mode control section 33. The test mode control unit 33 immediately outputs a signal to the program power unreset HJI 34 after the IA power is applied,
The inside of the program counter 31 is cleared to Q. Then, the instruction code or data at the address specified by the program controller 31 is read out from the built-in ROM 32 and output onto the data bus 2, and further the data on the data bus 2 is output via the boat 10 to the outside.

その後、テストモード制御部33はプログラムカウンタ
インクリメント綜35に信号を出力し、プログラムカウ
ンタ31をインクリメントして、プログラムカウンタ3
1で指定される内蔵ROM32内の命令コードまたはデ
ータをボート10により外部へ出力する。そして以下は
同様にプログラムカウンタインクリメント綜35に信号
を出力し、プログラムカウンタ31を順次インクリメン
トしていき、内蔵メモリ32内のデータを順次データバ
ス2及びボート10を経由して外部へ出力する。
Thereafter, the test mode control unit 33 outputs a signal to the program counter increment head 35, increments the program counter 31, and increments the program counter 31.
The instruction code or data in the built-in ROM 32 specified by 1 is outputted to the outside by the boat 10. Then, similarly, a signal is output to the program counter increment head 35, the program counter 31 is sequentially incremented, and the data in the built-in memory 32 is sequentially output to the outside via the data bus 2 and the boat 10.

このようKして、テストモード制御部33は、ユーザプ
ログラムおよびデータの格納された内蔵ROM32の内
容を順次データバス2に送り出し、ボート10を経由し
て外部に出力する。
In this manner, the test mode control unit 33 sequentially sends the contents of the built-in ROM 32 in which the user program and data are stored to the data bus 2, and outputs them to the outside via the boat 10.

上記手段を用いてユーザはチップの特定外部端子に高電
圧を印加し、前記テストモード機能を実行することによ
り、内蔵ROM32内のプログラムおよびデータをボー
ト10を経由して外部に読み出してチェックすることが
できる。
Using the above means, the user applies a high voltage to a specific external terminal of the chip and executes the test mode function, thereby reading out the program and data in the built-in ROM 32 to the outside via the boat 10 and checking it. Can be done.

〔発明が解決しようとする問題点〕[Problem that the invention seeks to solve]

上述したテストモード機能を内蔵したシングルチップマ
イクロコンピュータにおいては、テストモード機能を用
いることにより、内蔵されたユーザプログラム及びデー
タを容易に外部に読み出すことができるので、機密性の
高いプログラム及びデータが内蔵されている場合でも悪
意の第3者が外部から簡単に読み出すことができ、内蔵
ソフトウェアに対する保僅か全くなされていないという
欠点があった。
In a single-chip microcomputer with a built-in test mode function as described above, by using the test mode function, the built-in user program and data can be easily read externally, so that highly confidential programs and data can be easily read out. Even if the software is installed, a malicious third party can easily read it from the outside, and there is little or no protection for the built-in software.

〔問題点を解決するだめの手段〕[Failure to solve the problem]

本発明の/ングルチップマイクロコンピュータは、単一
半導体基盤上にコンピュータ機能及びテストモード機能
を集積したシングルチップマイクロコンピュータであっ
て、ユーザノットウェア格納用の読み出し専用メモリと
、各種命令機能を呆行およびテストモード+j!に北の
許iif判定、実行を制御するマイクロプログラムが格
(N’JれたマイクロROM、マイクロl< OMに格
納された処理ルーチンの開始アドレスを設定するマイク
ロアドレス設定回路、テストモード機能の実行許可を指
定する手段とを有し、テストモード機能実行要求°時は
テストモード制御用のマイクロプログラムの処理ルーチ
ンに基づき、テストモード機能実行の許可判定を行ない
、テストモード機能実行の場合は前記処理ルーチンによ
り前記ROMに格納されたソフトウェアに対し所定のデ
ータ処理を行ない、テスト終了後に前記実行許可を指定
する手段を禁止状態に設定することにより、以後のテス
トモード機能実行を禁止することによって、ソフトウェ
アに対し、正確性、安全性を向上させたことを特徴とす
る。
The single-chip microcomputer of the present invention is a single-chip microcomputer that integrates computer functions and test mode functions on a single semiconductor substrate, and has a read-only memory for storing user notware and various instruction functions. and test mode +j! The microprogram that controls the IIF judgment and execution is stored in the microROM (N'J), the microaddress setting circuit that sets the start address of the processing routine stored in the OM, and the execution of the test mode function. When a test mode function execution request is made, permission for test mode function execution is determined based on a processing routine of a microprogram for test mode control, and in the case of test mode function execution, the above-mentioned processing is performed. A routine performs predetermined data processing on the software stored in the ROM, and after the test is completed, the means for specifying execution permission is set to a prohibited state, thereby prohibiting future execution of the test mode function. It is characterized by improved accuracy and safety.

〔実施例〕〔Example〕

次に本発明に係わるシングルチップマイクロコンピュー
タの一実施例を第1図、第2図を用いて説明する。
Next, an embodiment of a single-chip microcomputer according to the present invention will be described with reference to FIGS. 1 and 2.

第1図は本発明に係わるシングルチップマイクロコンピ
ュータの第1の実施例の構成を示したものである。まず
、構成要素の説明を行なう。第1しくにおいて、マスク
ROMブロック103とCPU制御部105は従来例の
第3図における内戚ROMブロック3及びCPU制御部
5に各々対応している。また第3図におけるアキュムレ
ータ6.テンポラリレジスタ7、算術論理演算ユニット
8をまとめて第1図では実行部101として示しである
FIG. 1 shows the structure of a first embodiment of a single-chip microcomputer according to the present invention. First, the constituent elements will be explained. In the first example, the mask ROM block 103 and the CPU control section 105 respectively correspond to the internal ROM block 3 and the CPU control section 5 in FIG. 3 of the conventional example. Also, accumulator 6 in FIG. The temporary register 7 and the arithmetic and logic operation unit 8 are collectively shown as an execution unit 101 in FIG.

本発明に係わるシングルチップマイクロコンビエータに
おいてマスクROMブロック103とCPU制御部10
5以外の構成要素は第3図に示す従来例と相異がないの
で、以下マスクROMブロック103とCPU制御部1
05の構成のみ説明する。
Mask ROM block 103 and CPU control unit 10 in the single-chip micro combinator according to the present invention
Components other than 5 are the same as the conventional example shown in FIG.
Only the configuration of 05 will be explained.

マスクROMブロック103はプログラムカウンタ10
3−1とマスクROM1o3−2から構成され、プログ
ラムカウンタ103−1はマスクROM103−2内の
命令コード格納アドレスを指すアドレスポインタである
。マスクROM103−2はユーザプログラムもしくは
データ格納に用いる続出し7専用メモリであり、メモリ
内の命令コードはデータバス2を経由して、命令レジス
タ4に格納され、各命令に対応[7た処理がCPU制御
部105により実行される。またデータを読み出す場合
はバス103−3上のアドレス値により、直接アドレス
指定して、マスクROM103−2内のデータをデータ
バス2に出力する。CPU制御部105は命令実行の制
御及びテストモード機能動作の制御を行なうブロックで
、マイクロアドレス設定回路105−1.  マイクロ
プログラムカウンタ105−2゜マイクロプログラムR
OM105−3.  デコーダ105−4.  テスト
モード許可フラグ105−5.テストモード要求線10
5−6から構成されている。
Mask ROM block 103 is program counter 10
The program counter 103-1 is an address pointer pointing to an instruction code storage address in the mask ROM 103-2. The mask ROM 103-2 is a 7-dedicated memory used for storing user programs or data, and the instruction code in the memory is stored in the instruction register 4 via the data bus 2, and the processing corresponding to each instruction is It is executed by the CPU control unit 105. When reading data, the data in the mask ROM 103-2 is output to the data bus 2 by directly specifying the address using the address value on the bus 103-3. The CPU control unit 105 is a block that controls instruction execution and test mode function operation, and includes microaddress setting circuits 105-1. Micro program counter 105-2゜Micro program R
OM105-3. Decoder 105-4. Test mode permission flag 105-5. Test mode request line 10
It consists of 5-6.

マイクロアドレス設定回路105−1はテストモード要
求信号をテストモード要求線105−6を介して受は取
ると、テストモード処理ルーチン開始アドレスをマイク
ロプログラムカウンタ105−2に設定する。マイクロ
プログラムカウンタ105−2は、命令レジスタ4に取
り込まれた命令コードにより、その命令に対応した処理
の格納されたマイクロプログラムROM105−3内の
マイクロ命令のアドレスを指し示すもので、インクリメ
ント機能を有している。マイクロプログラムROM10
5−3は各命令に対応した制御情報を格納した読み出し
専用メモリで、デコーダ105−4を介して各部に制御
信号を出力する。またこのマイクロプログラムROM1
05−3内にはテストモード機能の動作及びテストモー
ド機能実行の許可判定を司るテストモード処理ルーチン
も含んでいる。テストモード許可フラグ105−5はテ
ストモードの許可。
When the micro address setting circuit 105-1 receives the test mode request signal via the test mode request line 105-6, it sets the test mode processing routine start address in the micro program counter 105-2. The microprogram counter 105-2 points to the address of the microinstruction in the microprogram ROM 105-3 in which the process corresponding to the instruction is stored, based on the instruction code taken into the instruction register 4, and has an incrementing function. ing. Micro program ROM10
A read-only memory 5-3 stores control information corresponding to each command, and outputs control signals to each section via a decoder 105-4. Also, this micro program ROM1
05-3 also includes a test mode processing routine that controls the operation of the test mode function and determines permission to execute the test mode function. Test mode permission flag 105-5 allows test mode.

禁止を判別するだめのフラグで、このフラグへのデータ
の書込み及び読出しはCPUの専用命令で行なう。また
このフラグは初期状態においてクリアされており、一度
セットされると、消去ができない半固定フラグである。
This flag is used to determine prohibition, and writing and reading data to this flag is performed by a dedicated CPU instruction. Further, this flag is cleared in the initial state, and once set, it is a semi-fixed flag that cannot be erased.

次に前記構成要素を用い−C動作説明を行なう。Next, -C operation will be explained using the above-mentioned components.

木用1の実施例におけるシングルチップマイクロコンピ
ュータにおいては、マスクROMブロック103内のプ
ログラムカウンタ103−1で指定されるアドレスのデ
ータをマスクROM103−2から読み出し、データバ
ス2を介して命令レジスタ4に格納する。命令レジスタ
4に格納された命令コードはCPU制御部105へ出力
され、テストモード要求線105−6に信号が出力され
ない時、マイクロアドレス設定回路105−IKよりそ
のままマイクロプログラムカウンタ105−2に格納さ
れ、各命令に対応した”処理を行なうマイクロプログラ
ムROM105−3内のエントリアドレスを与える。そ
してマイクロプログラムカウンタ105−2は自動的に
インクリメントされ、各命令実行シーケンスが格納され
た、マイクロプログラムROM内のアドレスを順次指し
示す。次にマイクロプログラムROM105−3により
出力された信号はデコーダ105−4によシブコードさ
れ、各部へ制御信号を送シ、命令機能が実行される。
In the single-chip microcomputer in the wooden 1 embodiment, the data at the address specified by the program counter 103-1 in the mask ROM block 103 is read from the mask ROM 103-2 and sent to the instruction register 4 via the data bus 2. Store. The instruction code stored in the instruction register 4 is output to the CPU control unit 105, and when no signal is output to the test mode request line 105-6, the instruction code is stored directly in the micro program counter 105-2 from the micro address setting circuit 105-IK. , gives an entry address in the microprogram ROM 105-3 that performs the process corresponding to each instruction.Then, the microprogram counter 105-2 is automatically incremented, and the entry address in the microprogram ROM 105-3 in which each instruction execution sequence is stored is given. The addresses are sequentially pointed to.Then, the signals outputted by the microprogram ROM 105-3 are encoded by the decoder 105-4, and control signals are sent to each section to execute command functions.

以上が第1の実施例のシングルチップマイクロコンピュ
ータの命令実行形態であるが、次に第1の実施例におけ
るテストモード機能の実行について説明する。本チップ
の特定の外部端子に高電圧を印加すると、テストモード
要求線105−6に信号が出力され、マイクロアドレス
設定回路105−1に入力される。マイクロアドレス設
定回路105−1はマイクロプログラムカウンタ105
−2にマイクロプログラムROM1os−3内のテスト
モード処理ルーチンの先頭アドレスを設定する。
The above is the instruction execution form of the single-chip microcomputer of the first embodiment. Next, the execution of the test mode function in the first embodiment will be explained. When a high voltage is applied to a specific external terminal of this chip, a signal is output to the test mode request line 105-6 and input to the micro address setting circuit 105-1. The micro address setting circuit 105-1 is a micro program counter 105.
The start address of the test mode processing routine in the microprogram ROM 1os-3 is set to -2.

その後テストモード機能の許可判定及び実行がマイクロ
プログラムによって行なわれる。
Thereafter, permission determination and execution of the test mode function are performed by the microprogram.

さてマイクロプログラムROM105−3内のテストモ
ード処理ルーチンにおいては次に示すシーケンスで処理
を行なう。
Now, in the test mode processing routine in the microprogram ROM 105-3, processing is performed in the following sequence.

■:テストモード許許可ラグ105−5の値を読み出す
■: Read the value of the test mode permission lag 105-5.

■:■においてテストモード許可フラグ105−5がセ
ットされていた場合は、テストモード機能実行が禁止さ
れたと判断し、このテストモード処理ルーチンはそのま
ま無限ループに入り、テストモード機能を実行しない。
■: If the test mode permission flag 105-5 is set in ■, it is determined that the test mode function execution is prohibited, and this test mode processing routine enters an infinite loop without executing the test mode function.

■:■においてテストモード許可フラグ105−5がセ
ットされていない場合は、テストモード機能実行が許可
されたと判断し、マスクROMブロック103内のプロ
グラムカウンタ103−1をリセットする。
■: If the test mode permission flag 105-5 is not set in ■, it is determined that the test mode function execution is permitted, and the program counter 103-1 in the mask ROM block 103 is reset.

■ニブログラムカウンタ103−1によって指定された
アドレスに対応し、たデータをマスクROM2O3−2
内から取り出し、データバス2に出力する。
■Data corresponding to the address specified by the nib program counter 103-1 is stored in the mask ROM2O3-2.
It is taken out from inside and output to data bus 2.

■:データバス2上のデータを実行部101に出力し、
実行部101において、パリティビット付加、暗号化な
ど所定のデータ処理を施し、処理されたデータを再びデ
ータバス2上に出力する。
■: Output the data on the data bus 2 to the execution unit 101,
The execution unit 101 performs predetermined data processing such as adding parity bits and encryption, and outputs the processed data onto the data bus 2 again.

■:データバス2上のデータをポート10を経由して、
外部へ出力する。
■: Data on data bus 2 is passed through port 10,
Output to outside.

■ニブログラムカウンタ103−1の値どマスクROM
103−2の最終アドレス値とを比較し、一致した場合
はこのテストモード処理ルーチンは無限ループに入る。
■Mask ROM including value of Niprogram counter 103-1
The final address value of 103-2 is compared, and if they match, this test mode processing routine enters an infinite loop.

一致しない場合は次のステップへ移行する。If they do not match, move to the next step.

■ニブログラムカウンタ103−1をインクリメントす
る。
(2) Increment the nib program counter 103-1.

■:処処理ステップへ移行する。■: Move to the processing step.

以上が、マイクロプログラムを用いたテストモード機能
の許可判定及びテストモード機能実行形態である。
The above is the test mode function permission determination and test mode function execution form using the microprogram.

なお、上記実施例においてはマイクロプログラムカウン
タ105−2によってマイクロプログラムROM105
−3のアドレス指定を行なっているが、マイクロ命令内
特定フィールドによりアドレス指定する方法でもよい。
In the above embodiment, the microprogram counter 105-2 controls the microprogram ROM 105.
-3 is specified, however, a method of specifying the address using a specific field within the microinstruction may also be used.

従来テストモード機能はシングルチップマイコンの製造
時の動作検査時に用いる目的で製造メーカにより内蔵さ
れたものであり、上記機能を利用すると簡単に内蔵のプ
ログラム及びデータを読み出すことができ、ソフトウェ
アの保護対策が全くなされていなかった。し7かるに本
発明の第1の実施例においては、テストモード許可フラ
グ105−5を内蔵し、マイクロプログラムを用いるこ
とにより、容易に高度な内蔵ソフトウェア保護を実現し
ている。
The conventional test mode function was built in by the manufacturer for the purpose of testing the operation during the manufacture of single-chip microcontrollers.Using the above function allows you to easily read the built-in programs and data, and is a software protection measure. was not done at all. However, in the first embodiment of the present invention, a test mode permission flag 105-5 is built in, and by using a microprogram, a high degree of built-in software protection is easily realized.

テストモード許可フラグ105−5は前記の通シ、CP
Uの専用命令によってのみ絖出し、:4!込みが可能で
あるが、−&セントすると消去が不可能な半固定フラグ
である。よってメーカはマスクROM103−2内のソ
フトウェアの開発及びデバッグ中は上記フラグをセット
せずテストモード機能によって内蔵ソフトウェアを読み
出せるようにしておく。そして内蔵ソフトウェアのデバ
ッグが完了後製品を市場に出荷する時に、テストモード
許可フラグ105−5をセットして以後のテストモード
機能実行を禁止することによって、内蔵プログラム及び
データを読み出せないようにする。上記手段により、テ
ストモード機能を内蔵したまま内蔵ソフトウェアに対す
る保護が実現できる。
The test mode permission flag 105-5 is set to
Investing only by special order of U: 4! This is a semi-fixed flag that can be set, but cannot be erased if -&cent is entered. Therefore, during the development and debugging of the software in the mask ROM 103-2, the manufacturer does not set the above flag and allows the built-in software to be read by the test mode function. Then, when the product is shipped to the market after debugging of the built-in software is completed, the test mode permission flag 105-5 is set to prohibit further execution of the test mode function, thereby making it impossible to read out the built-in programs and data. . With the above means, protection for built-in software can be realized while the test mode function is built-in.

さらに木用1の実施例においては、上記テストモード許
可フラグの判定及びテストモード機能の実行をマイクロ
プログラムで実現しているので、内蔵プログラムに対し
、パリティピットの追加。
Furthermore, in the wooden version 1 embodiment, since the determination of the test mode permission flag and the execution of the test mode function are realized by a microprogram, a parity pit is added to the built-in program.

暗号化等のデータ処理を行なって、データの確実性、安
全性の向上を容易に実現でき、さらに上記処理シーケン
スの解読は非常に困難であり、マクロプログラムによる
実行に比べ、内蔵ソフトウェアに対しより高度な保護が
可能である。
By performing data processing such as encryption, it is easy to improve the reliability and security of data. Furthermore, it is extremely difficult to decipher the above processing sequence, and compared to execution using a macro program, it is more difficult for built-in software to perform data processing. A high degree of protection is possible.

また、テストモード許可フラグ105−5のセットをC
PUの専用命令で実行しているので、外部操作によるフ
ラグ値の変更が絶対に不可能であシ、上記手段は非常に
安全性の高いものとなる。
Also, the test mode permission flag 105-5 is set to C.
Since it is executed using a dedicated instruction of the PU, it is absolutely impossible to change the flag value by external operation, and the above means is extremely safe.

次に本発明1/C係わるシングルチップマイクロコンピ
ュータの第2の実施例を第2図を用いて説明する。まず
構成要素の説明を行なう。第2図におけるFROM7’
ロック203は、本発明に係わるシングルチップマイク
ロコンピュータのwhlの実施例の構成を示す第1図の
マスクROMブロック103 Vc対応し、さらKPR
OM203−2は第1図のマスクROM103−2に対
応している。また第1図におけるCPυ制御部105内
のテストモード許可フラグ105−5に対応して、第2
図ではテストモード許可パラメータ203−3がF R
OM2O3−2内の特定なアドレスに割や付けられてお
り、8g2の実施例においては、テストモード許可フラ
グ105−5は存在しない。上記以外の構成要素はMX
1図と全く同様である。故に以下はFROMブロック2
03の構成についてのみ説明する。
Next, a second embodiment of a single-chip microcomputer according to the present invention 1/C will be described with reference to FIG. First, the constituent elements will be explained. FROM7' in Figure 2
The lock 203 corresponds to the mask ROM block 103 Vc in FIG.
OM203-2 corresponds to mask ROM103-2 in FIG. Also, in response to the test mode permission flag 105-5 in the CPυ control unit 105 in FIG.
In the figure, the test mode permission parameter 203-3 is FR
It is assigned to a specific address within OM2O3-2, and the test mode permission flag 105-5 does not exist in the 8g2 embodiment. Components other than the above are MX
It is exactly the same as Figure 1. Therefore, the following is FROM block 2
Only the configuration of 03 will be explained.

PROMフ′ロック203はプログラムカウンタ203
−1とFROM203−2から構成され、プログラムカ
ウンタ203−1はFROM203−2の命令コード格
納アドレスを指すアドレスボイ/りである。FROM2
03−2はユーザプログラムもしくはデータ格納に用い
るプログラマブルな読み出し専用メモリであり、メモリ
内の命令コードはデータバス2を経由して、命令レジス
タ4に格納され、各命令に対応した処理がCPU?t+
1ll1部105により実行される。またデータを読み
出す場合はパス203−4上のアドレス値により直接ア
ドレス指定して、FROM203−2内のデータをデー
タバス2に出力する。テストモード許可パラメータ20
3−3はテストモードの許可、禁止を判別するために用
いるパラメータで、FROM203−2内の特定なアド
レスの内容に割り付ける。上記パラメータへのデータの
書込み及び耽出しはCPUの専用命令で行なう。
PROM block 203 is the program counter 203
-1 and FROM 203-2, and program counter 203-1 is an address counter pointing to the instruction code storage address of FROM 203-2. FROM2
03-2 is a programmable read-only memory used for storing user programs or data, and the instruction codes in the memory are stored in the instruction register 4 via the data bus 2, and the processing corresponding to each instruction is executed by the CPU? t+
This is executed by the 1ll1 unit 105. When reading data, the data in FROM 203-2 is output to data bus 2 by directly specifying the address using the address value on path 203-4. Test mode permission parameter 20
3-3 is a parameter used to determine whether the test mode is permitted or prohibited, and is assigned to the contents of a specific address in FROM 203-2. Writing and reading of data to the above parameters is performed by dedicated instructions from the CPU.

次に@2図を用いて動作説明を行なう。Next, the operation will be explained using Figure @2.

第2の実施側圧おけるシングルチップマイクロコンビエ
ータの動作は第1の実施例と同様で、マイクロプログラ
ムにより、命令機能が実行される。
The operation of the single-chip microcombinator in the second implementation mode is similar to that in the first embodiment, and the command functions are executed by the microprogram.

また上記構成4!素におけるテストモード機能実行形態
は、第1の実施例における実行形層とほぼ同一である。
Also, the above configuration 4! The basic test mode function execution form is almost the same as the execution form layer in the first embodiment.

すなわち、本チップの特定外部端子に高電圧が印加され
ると、テストモード要求線105−6に信号が出力され
、マイクロアドレス設定回路105−1に入力される。
That is, when a high voltage is applied to a specific external terminal of this chip, a signal is output to the test mode request line 105-6 and input to the micro address setting circuit 105-1.

そしてマイクロアドレス設定回路105−1はマイクロ
プログラムカウンタ105−2にマイクロプログラムR
OM105−3内のテストモード処理ルーチンの先頭ア
ドレスを設定する。その後テストモード機能の許可判定
及び実行がマイクロプログラムによって行なわれる。
The micro address setting circuit 105-1 then sends the micro program R to the micro program counter 105-2.
Set the start address of the test mode processing routine in OM105-3. Thereafter, permission determination and execution of the test mode function are performed by the microprogram.

マイクロプログラムにより、テストモード許可パラメー
タ203−3の内容をチェックし、sQsであればテス
トモード機能を実行する。ただし、テストモード許可パ
ラメータ203−3は初期状態において% Q I/の
値をとる。テストモード機能肩上の場合は第1の′!A
適例における場合と同様にCPUの専用命令により、テ
ストモード許可パラメータ203−3に% Q I/以
外のデータを書き込み、以後FROM203−2内のプ
ログラム及びデータの読み出しを禁止する。
The microprogram checks the content of the test mode permission parameter 203-3, and if it is sQs, executes the test mode function. However, the test mode permission parameter 203-3 takes a value of % Q I/ in the initial state. If the test mode function is above the 1st'! A
As in the case of the preferred example, data other than % Q I/ is written in the test mode permission parameter 203-3 by a dedicated instruction of the CPU, and reading of the program and data in the FROM 203-2 is prohibited thereafter.

また第2の実施例においては、テストモード許可パラメ
ータ203−3の値の消去および書き換えが可能である
が、FROM203−2がUVBPROMの場合は、テ
ストモード許可パラメータ203−3内のデータを紫外
線で消去することにより、他のプログラム及びデータも
消去されてしまうので問題はない。またF”FROMの
場合は内蔵プログラムによって、テストモード許可パラ
メータ203−3へのデータ書き込み及びを禁止するこ
とにより、対処可能である。よって木簡2の実施例にお
いても、FROM203−2内のプログラム及びデータ
に対する保護が実現されており、内蔵ソフトウェア九対
するセキエリティ性が高度化している。またCPUの命
令によってのみテキストモード許可バ2メータ203−
3の値の操作が可能であるため、外部からの変更は不可
能であり、よって上記処理シーケンスは安全性の高いも
のである。
In the second embodiment, it is possible to erase and rewrite the value of the test mode permission parameter 203-3, but if FROM 203-2 is a UVBPROM, the data in the test mode permission parameter 203-3 can be erased with ultraviolet light. There is no problem because other programs and data will also be erased by erasing. In addition, in the case of F'' FROM 203-2, this can be handled by prohibiting the writing of data to the test mode permission parameter 203-3 using the built-in program. Data protection has been realized, and the security of the built-in software has been improved.Additionally, the text mode permission bar 2 meter 203-2 can only be activated by commands from the CPU.
Since the value of 3 can be manipulated, it is impossible to change it from the outside, so the above processing sequence is highly secure.

〔発明の効果〕〔Effect of the invention〕

以上説明した様に本発明圧体わるシングルチッ7”?イ
クロコンピュータにおいては、従来のテストモード機能
を内蔵したシングルチップマイクロコンピュータに対し
、CPU制御部内にテストモード♂「町フラグ(内蔵プ
ログラム領域がマスクROMの場合)を内蔵するか、ま
たは内蔵メモリ内にテストモード許可パラメータ(内蔵
プログラム領域がFROMの場合)を設定することによ
り、これらの値をマイクロプログラムにより判定し、テ
ストモードの許可1M止を決定することができる。よっ
て製品の出荷時にテストモード許可フラグをセットする
かもしくはテストモード許可パラメータに%Q〃以外の
データを書き込んでテストモード機能を禁止すハば、内
献メモリのプログラム及びデータがチップ外部に読み出
せず、内蔵ソフトウェア及びデータ保護において多大な
効果がある。
As explained above, in the single-chip 7" microcomputer using the pressure body of the present invention, unlike the conventional single-chip microcomputer with a built-in test mode function, the test mode By setting the test mode permission parameter (in case the built-in program area is FROM) in the built-in memory (for mask ROM), these values are determined by the microprogram and the test mode permission stops at 1M. Therefore, if you set the test mode permission flag at the time of product shipment or write data other than %Q to the test mode permission parameter to disable the test mode function, the internal memory program and Data cannot be read outside the chip, which has a great effect on built-in software and data protection.

また本発明に係るシングルチップマイクロコンピュータ
においては前述したようにマイクロプログラムにより、
テストモード許可フラグもしくはテストモード許可パラ
メータのチェック、及びテストモード機能の動作制御を
行なっているので、上記処理シーケンスの解読が非常に
困難であり、内蔵のプログラム及びデータに対し、非常
に高度なセキュリティ効果が得られる。
Furthermore, in the single-chip microcomputer according to the present invention, as described above, the microprogram
Since the test mode permission flag or test mode permission parameter is checked and the operation of the test mode function is controlled, it is extremely difficult to decipher the above processing sequence, and the built-in programs and data are subject to extremely high security. Effects can be obtained.

【図面の簡単な説明】[Brief explanation of drawings]

第1図は本発明に係わるシングルチップマイクロコンピ
ュータの第1の実施例のブロック構成図、第2図は本発
明に係わるシングルチップマイクロコンピュータの第2
の実施例のブロック構成図、第3図は従来のテストモー
ド機能を内蔵したシングルチップマイクロコンピュータ
のブロック構成図、第4図は第3図における内蔵ROM
ブロック3の構成図である。 1・・・・・・アドレスバス 2・・・・・・データバス 3・・・・・・内jl[ROMブロック4・・・・・・
命令レジスタ 5・・・・・・CPU制御部 6・・・・・・アキュムレータ 7・・・・・・テンポラリレジスタ 8・・・・・・算術論理演算ユニット 9・・・・・・RAM 10・・・・・・ボート 31・・・・・・プログラムカウンタ 32・・・・・・内蔵ROM 33・・・・・・テストモード制御部 34・・・・・・プログラムカウンタリセット線35・
・・・・・プログラムカウンタインクリメント線36・
・−・・・テストモード要求線 37・・・・・・バス 101・・・・・・実行部 103・・・…マスクROMブロック 103−1・・・・・・プログラムカウンタ103−2
・・・・・・マスクROM 103−3・・・・・・バス 105・・・・・・CPU制御部 105−1・・・・・・マイクロアドレス設定回路10
5−2・・・・・・マイクロプログラムカウンタ105
−3・・・・・・マイクロROM105−4・・・・・
・デコーダ 105−5“°°°°°テストモード許可フラグ105
−6・−・・・・テストモード要求線203・・・・・
・PROMブロック 203−1・・・・・・プログラムカウンタ203−2
・・・・・・FROM 203−3・・・・・・テストモード許可パラメータ2
03−4・・・・・・バス 代理人 弁理士  内 原   晋  ゛竿 l IM 芽   り   図 半J 図C従来例)′ 茅 4n(iAロ未未刊列
FIG. 1 is a block diagram of a first embodiment of a single-chip microcomputer according to the present invention, and FIG. 2 is a block diagram of a second embodiment of a single-chip microcomputer according to the present invention.
FIG. 3 is a block diagram of a single-chip microcomputer with a built-in conventional test mode function, and FIG. 4 is a block diagram of the built-in ROM in FIG. 3.
FIG. 3 is a configuration diagram of block 3. 1... Address bus 2... Data bus 3... Inner jl [ROM block 4...
Instruction register 5... CPU control unit 6... Accumulator 7... Temporary register 8... Arithmetic logic unit 9... RAM 10. ...Boat 31 ...Program counter 32 ...Built-in ROM 33 ...Test mode control section 34 ...Program counter reset line 35
...Program counter increment line 36.
...Test mode request line 37...Bus 101...Execution unit 103...Mask ROM block 103-1...Program counter 103-2
...Mask ROM 103-3 ... Bus 105 ... CPU control section 105-1 ... Micro address setting circuit 10
5-2...Micro program counter 105
-3...Micro ROM105-4...
・Decoder 105-5 “°°°°° test mode permission flag 105
-6...Test mode request line 203...
・PROM block 203-1...Program counter 203-2
......FROM 203-3...Test mode permission parameter 2
03-4...Bus agent Patent attorney Susumu Uchihara ゛Kan l IM Mere Figure 1 J Figure C Conventional example)' Kaya 4n (iAro unpublished column

Claims (1)

【特許請求の範囲】[Claims] 単一半導体基盤上にコンピュータ機能及びテストモード
機能を集積したシングルチップマイクロコンピュータに
おいて、ユーザソフトウェア格納用のメモリと、命令機
能を実行するマイクロプログラムメモリと、前記マイク
ロプログラムメモリに格納された処理ルーチンの開始ア
ドレスを設定するアドレス設定回路と、テストモード機
能の実行許可を指定する手段とを有し、テストモード機
能実行要求時に前記マイクロプログラムメモリのテスト
モード処理ルーチンを実行し、テストモード機能実行許
可の場合は、前記メモリに格納されたソフトウェアに対
し所定のデータ処理を施すことによりテストを行ない、
テスト終了後に前記実行許可を指定する手段を禁止状態
に設定することを特徴とするシングルチップマイクロコ
ンピュータ。
A single-chip microcomputer that integrates computer functions and test mode functions on a single semiconductor substrate includes a memory for storing user software, a microprogram memory for executing instruction functions, and a processing routine stored in the microprogram memory. It has an address setting circuit for setting a start address, and a means for specifying execution permission of a test mode function, and executes a test mode processing routine in the microprogram memory when a test mode function execution request is made, and specifies permission for test mode function execution. In this case, the software stored in the memory is tested by performing predetermined data processing,
A single-chip microcomputer characterized in that the means for specifying execution permission is set to a prohibited state after a test is completed.
JP61095561A 1986-04-23 1986-04-23 Single chip microcomputer Expired - Lifetime JPH081606B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP61095561A JPH081606B2 (en) 1986-04-23 1986-04-23 Single chip microcomputer

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP61095561A JPH081606B2 (en) 1986-04-23 1986-04-23 Single chip microcomputer

Publications (2)

Publication Number Publication Date
JPS62251841A true JPS62251841A (en) 1987-11-02
JPH081606B2 JPH081606B2 (en) 1996-01-10

Family

ID=14141000

Family Applications (1)

Application Number Title Priority Date Filing Date
JP61095561A Expired - Lifetime JPH081606B2 (en) 1986-04-23 1986-04-23 Single chip microcomputer

Country Status (1)

Country Link
JP (1) JPH081606B2 (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPH0484348A (en) * 1990-07-27 1992-03-17 Nec Corp Rom data protecting system

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPS57182865A (en) * 1981-05-06 1982-11-10 Mitsubishi Electric Corp Microprocessor
JPS59153240A (en) * 1983-02-21 1984-09-01 Hitachi Ltd Secret protection system of program in single chip microcomputer
JPS6083157A (en) * 1983-10-14 1985-05-11 Toshiba Corp One chip microcomputer
JPS60245057A (en) * 1984-05-21 1985-12-04 Hitachi Ltd One-chip microcomputer

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPS57182865A (en) * 1981-05-06 1982-11-10 Mitsubishi Electric Corp Microprocessor
JPS59153240A (en) * 1983-02-21 1984-09-01 Hitachi Ltd Secret protection system of program in single chip microcomputer
JPS6083157A (en) * 1983-10-14 1985-05-11 Toshiba Corp One chip microcomputer
JPS60245057A (en) * 1984-05-21 1985-12-04 Hitachi Ltd One-chip microcomputer

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPH0484348A (en) * 1990-07-27 1992-03-17 Nec Corp Rom data protecting system

Also Published As

Publication number Publication date
JPH081606B2 (en) 1996-01-10

Similar Documents

Publication Publication Date Title
US4959860A (en) Power-on password functions for computer system
US5432950A (en) System for securing a data processing system and method of operation
US4246638A (en) Method and apparatus for controlling usage of a programmable computing machine
JP2682700B2 (en) IC card
US7421534B2 (en) Data protection for non-volatile semiconductor memory using block protection flags
CN101238473A (en) A secure terminal, a routine and a method of protecting a secret key
US8607061B2 (en) Flash device security method utilizing a check register
US10923203B2 (en) Semiconductor device and method of operating semiconductor device
US20200272581A1 (en) Method for protecting memory against unauthorized access
JPH04215194A (en) Ic card
CN113557500A (en) Multi-mode protected memory
US20040186947A1 (en) Access control system for nonvolatile memory
US6510501B1 (en) Non-volatile memory read/write security protection feature selection through non-volatile memory bits
US20080034150A1 (en) Data processing circuit
JP2000148594A (en) Read protection circuit for rom data
JPS62251841A (en) Single chip microcomputer
JPH03204053A (en) Read-only memory
US11379580B1 (en) Mixed storage of data fields
US5644781A (en) Microcomputer having a security function for stored data
JP3234959B2 (en) Microcomputer and card incorporating the same
JPS6356749A (en) Single chip microcomputer
JPS6356750A (en) Single chip microcomputer
JPH01123342A (en) Writing protecting circuit for memory
CN114968117A (en) Memory protection system
JPH02162434A (en) Single chip microcomputer