JPH05151017A - Microcomputer - Google Patents

Microcomputer

Info

Publication number
JPH05151017A
JPH05151017A JP3316762A JP31676291A JPH05151017A JP H05151017 A JPH05151017 A JP H05151017A JP 3316762 A JP3316762 A JP 3316762A JP 31676291 A JP31676291 A JP 31676291A JP H05151017 A JPH05151017 A JP H05151017A
Authority
JP
Japan
Prior art keywords
test
macro
input
bus
output
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.)
Pending
Application number
JP3316762A
Other languages
Japanese (ja)
Inventor
Kaoru Saito
薫 斉藤
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.)
Oki Electric Industry Co Ltd
Original Assignee
Oki Electric Industry Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Oki Electric Industry Co Ltd filed Critical Oki Electric Industry Co Ltd
Priority to JP3316762A priority Critical patent/JPH05151017A/en
Publication of JPH05151017A publication Critical patent/JPH05151017A/en
Pending legal-status Critical Current

Links

Landscapes

  • Test And Diagnosis Of Digital Computers (AREA)
  • Microcomputers (AREA)
  • For Increasing The Reliability Of Semiconductor Memories (AREA)

Abstract

PURPOSE:To properly perform a function test of unit such as each macro block in the microcomputer with simple control without increasing the number of external terminals exclusive for test. CONSTITUTION:At the time of test, a macro selection signal is outputted from a test circuit 60, and one of a CPU core 31, peripheral function macro 32 to 34, or RAM macro 35 is selected for test. The test pattern is supplied from the test circuit 60 to the block for test through a test bus 70. through which the block for test executes tests according to the test pattern. The result of the test is returned through the test bus 70 to the test circuit 60. In the text circuit 60, the test result and the expected valve sent from the test bus 70 are compared to be discriminated.

Description

【発明の詳細な説明】Detailed Description of the Invention

【0001】[0001]

【産業上の利用分野】本発明は、CPUコアを内部に持
つ1チップのマイクロコンピュータ、特にそのテスト回
路に関するものである。
BACKGROUND OF THE INVENTION 1. Field of the Invention The present invention relates to a one-chip microcomputer having a CPU core inside, and more particularly to a test circuit therefor.

【0002】[0002]

【従来の技術】従来、このような分野の技術としては、
例えば特開平2−289999号公報に記載されるもの
があった。従来、中央処理装置(CPU)や各種周辺ハ
ードウェアを含む機能ブロック、メモリブロック、及び
ユーザ定義の回路から構成される機能ブロックの各レイ
アウトデータをコンピュータ上で接続してマイクロコン
ピュータを開発することにより、開発期間の短縮を図る
技術が提案されている。この場合、マイクロコンピュー
タのテストを速やかに、かつ正確に行うことが重大な課
題となってくる。このようなマイクロコンピュータの構
成例を図2に示す。
2. Description of the Related Art Conventionally, as a technique in such a field,
For example, there is one described in JP-A-2-289999. Conventionally, by connecting each layout data of a functional block including a central processing unit (CPU) and various peripheral hardware, a memory block, and a functional block including a user-defined circuit on a computer, a microcomputer is developed. , A technology for shortening the development period has been proposed. In this case, it is a serious problem to test the microcomputer promptly and accurately. An example of the configuration of such a microcomputer is shown in FIG.

【0003】図2は、前記文献に記載された従来のマイ
クロコンピュータの構成ブロック図である。このマイク
ロコンピュータ10は、1チップで構成されるもので、
マイクロコンピュータ全体をプログラム制御するCPU
及びバスインタフェース回路を有するCPUコア11
と、各種の外部機器を制御するための周辺機能マクロ1
2〜14と、データの読出し及び書込みが可能なランダ
ムアクセスメモリマクロ(RAMマクロ)15とを有
し、それらが上位アドレスバス16、下位アドレスバス
17、及びデータバス18を介して相互に接続されてい
る。CPUコア11は、RAMマクロ15に対してテス
トを行うためにメモリリード信号19及びメモリライト
信号20を該RAMマイクロ15に供給するようになっ
ている。各周辺機能マクロ12〜14は、それぞれ外部
デバイスとのインタフェースを行う外部の第1,第2,
第3の端子群21〜23に接続されている。
FIG. 2 is a block diagram showing the configuration of the conventional microcomputer described in the above document. This microcomputer 10 is composed of one chip,
CPU for program control of the entire microcomputer
And CPU core 11 having a bus interface circuit
And peripheral function macro 1 for controlling various external devices
2 to 14 and a random access memory macro (RAM macro) 15 capable of reading and writing data, which are connected to each other via an upper address bus 16, a lower address bus 17, and a data bus 18. ing. The CPU core 11 supplies a memory read signal 19 and a memory write signal 20 to the RAM micro 15 in order to test the RAM macro 15. Each of the peripheral function macros 12 to 14 has external first, second, and second interfaces for interfacing with external devices.
It is connected to the third terminal groups 21 to 23.

【0004】このような構成のマイクロコンピュータ1
0において、例えばRAMマクロ15内のRAMセルの
テストを行う場合、CPUコア11が有する命令を用い
て該CPUコア内のバスインタフェース回路を起動し、
テストを行う。即ち、RAMマクロ15のデータ読出し
テストを行う場合、CPUコア11は上位アドレスバス
16及び下位アドレスバス17へ所定のアドレスを出力
してデータバス18をハイインピーダンスにする。そし
て、メモリリード信号19を出力してRAMマクロ15
内のデータを読取る。また、RAMマクロ15へのデー
タの書込みテストを行う場合、CPUコア11は、上位
アドレスバス16及び下位アドレスバス17へ所定のア
ドレスを出力し、データバス18へ書込みデータを出力
する。そして、メモリライト信号20をRAMマクロ1
5へ出力して書込みテストを行う。
The microcomputer 1 having such a configuration
0, for example, when testing a RAM cell in the RAM macro 15, the bus interface circuit in the CPU core 11 is activated using an instruction included in the CPU core 11,
Do the test. That is, when performing the data read test of the RAM macro 15, the CPU core 11 outputs a predetermined address to the upper address bus 16 and the lower address bus 17 to make the data bus 18 high impedance. Then, the memory read signal 19 is output to output the RAM macro 15
Read the data in. When performing a data write test on the RAM macro 15, the CPU core 11 outputs a predetermined address to the upper address bus 16 and the lower address bus 17, and outputs write data to the data bus 18. Then, the memory write signal 20 is sent to the RAM macro 1
It outputs to 5 and the writing test is done.

【0005】この種のマイクロコンピュータ10では、
CPU機能を使用してRAMマクロ15のテストを行っ
ているため、CPUコア11の機能が故障している場合
には、RAMマクロ15の機能確認が行われなかった
り、また該CPUコア11の故障かあるいはRAMマク
ロ15の故障かが判定できないという欠点がある。
In this type of microcomputer 10,
Since the RAM macro 15 is tested using the CPU function, if the function of the CPU core 11 is broken, the function of the RAM macro 15 is not confirmed or the CPU core 11 is broken. There is a drawback that it cannot be determined whether or not the RAM macro 15 has failed.

【0006】そこで、前記文献の技術では、RAMマク
ロ専用のテスト端子を外部に設け、そのテスト端子にリ
ード信号及びライト信号を入力し、RAMマクロ15へ
の読出し動作、及び書込み動作を行うためのアドレス、
データ及び制御信号を第1,第2,第3の端子群21〜
23及び周辺機能マクロ12〜14を介して上位アドレ
スバス16、下位アドレスバス17及びデータバス18
に対して入出力することにより、CPUコア11を動作
させないでRAMマクロ15のテストを行うようになっ
ている。これにより、CPUコア11の動作が正常であ
るかどうかに関係なく、RAMマクロ15のテストが可
能になる。
Therefore, in the technique of the above-mentioned document, a test terminal dedicated to the RAM macro is provided outside, and a read signal and a write signal are input to the test terminal to perform a read operation and a write operation to the RAM macro 15. address,
Data and control signals are sent to the first, second, and third terminal groups 21 to 21.
23 and the peripheral function macros 12 to 14 through the upper address bus 16, the lower address bus 17, and the data bus 18.
The RAM macro 15 is tested without operating the CPU core 11 by inputting and outputting the RAM macro 15. As a result, the RAM macro 15 can be tested regardless of whether the operation of the CPU core 11 is normal.

【0007】[0007]

【発明が解決しようとする課題】しかしながら、上記構
成のマイクロコンピュータ10では、RAMマクロ専用
の外部のテスト端子を設け、そのテスト端子を用いてR
AMマクロ15に対してテストが行えるので、該RAM
マクロ15のテストに関しては容易になるが、その他の
CPUコア11や周辺機能マクロ12〜14に対するテ
ストについては、何等考慮されていない。そのため、C
PUコア11や周辺機能マクロ12〜14に対してテス
トを行う場合、それらに対するテスト専用の外部端子を
設け、その外部端子からテスト信号を入力してテストを
行うことが考えられる。しかし、このような方法では、
テスト専用の外部端子数が増大するという欠点がある。
そこで、第1〜第3の端子群21〜23等を利用してテ
スト用の信号を入力し、CPUコア11や周辺機器マク
ロ12〜14のテストを行うことも可能であるが、テス
トのための制御が複雑になる。従って、テスト専用の外
部端子数を増大させることなく、簡単な制御で、CPU
コア11や各マクロブロックの単体の機能テストを完全
に行うことが困難であった。
However, in the microcomputer 10 having the above-described structure, an external test terminal dedicated to the RAM macro is provided, and the test terminal is used for the R test.
Since the AM macro 15 can be tested, the RAM
Although the test of the macro 15 is easy, the test of the other CPU cores 11 and the peripheral function macros 12 to 14 is not considered at all. Therefore, C
When performing a test on the PU core 11 and the peripheral function macros 12 to 14, it is conceivable to provide an external terminal dedicated to the test for them and input a test signal from the external terminal to perform the test. But in this way,
There is a drawback that the number of external terminals dedicated to testing increases.
Therefore, it is possible to test the CPU core 11 and the peripheral device macros 12 to 14 by inputting a test signal by using the first to third terminal groups 21 to 23. Control becomes complicated. Therefore, the CPU can be easily controlled without increasing the number of external terminals dedicated to the test.
It was difficult to perform a complete functional test of the core 11 and each macro block.

【0008】本発明は、前記従来技術が持っていた課題
として、テスト専用の外部端子数を増大させることな
く、簡単な制御で、マイクロコンピュータ内の各マイク
ロブロックの単体の機能テストを完全に行うことが困難
な点について解決したマイクロコンピュータを提供する
ものである。
The present invention has the problem that the above-mentioned conventional technique has a function test of each microblock in a microcomputer completely by simple control without increasing the number of external terminals dedicated to the test. The present invention provides a microcomputer that solves the above problems.

【0009】[0009]

【課題を解決するための手段】第1の発明は、前記課題
を解決するために、マイクロコンピュータ全体をプログ
ラム制御するCPUを有するCPUコアと、前記CPU
により制御されて前記プログラムを実行する複数のマク
ロブロックとが、1チップ内に搭載されたマイクロコン
ピュータにおいて、次のような手段を設けている。即
ち、この第1の発明では、マクロ選択信号に基づき、前
記CPUコア及び前記複数のマクロブロックのそれぞれ
の入出力を制御する複数の入出力制御手段と、前記各入
出力制御手段を介して前記CPUコア及び前記複数のマ
クロブロックにそれぞれ共通接続されたテストバスと、
前記テストバスに接続され、前記マクロ選択信号を出力
して前記CPUコア及びマクロブロックのいずれか一つ
を選択し、そのテスト対象に対しテストパターンを供給
してテストを実行させるテスト回路とを、前記1チップ
内に設けている。
In order to solve the above-mentioned problems, a first invention is a CPU core having a CPU for program-controlling the entire microcomputer, and the above-mentioned CPU.
A plurality of macroblocks controlled by the above and executing the above-mentioned program are provided in a microcomputer mounted in one chip, and the following means are provided. That is, in the first aspect of the invention, a plurality of input / output control means for controlling the input / output of each of the CPU core and the plurality of macroblocks based on the macro selection signal, and the above-mentioned A test bus commonly connected to the CPU core and the plurality of macro blocks;
A test circuit which is connected to the test bus, outputs the macro selection signal, selects one of the CPU core and the macro block, and supplies a test pattern to the test target to execute the test; It is provided in the one chip.

【0010】第2の発明では、第1の発明の入出力制御
手段を、前記マクロ選択信号によって入力の選択を行う
マルチプレクサと出力の制御を行う出力ゲートとで構成
している。さらに、前記テスト回路は、前記マクロ選択
信号を発生するマクロ選択信号発生手段、前記テストパ
ターンを発生するテストパターン発生器、及び前記テス
ト対象からのテスト結果と期待値とを比較判定する判定
手段を有している。
According to a second aspect of the invention, the input / output control means of the first aspect comprises a multiplexer for selecting an input by the macro selection signal and an output gate for controlling the output. Further, the test circuit includes a macro selection signal generating means for generating the macro selection signal, a test pattern generator for generating the test pattern, and a determination means for comparing and determining a test result from the test target and an expected value. Have

【0011】[0011]

【作用】第1の発明によれば、以上のようにマイクロコ
ンピュータを構成したので、テスト時においてテスト回
路はマクロ選択信号を出力し、テストバスを介してCP
Uコア及びマクロブロック内の各入出力制御手段へ与え
る。すると、これらの入出力制御手段によってCPUコ
アあるいはマクロブロックのうちのテスト対象となるも
のが選択される。そして、テスト回路からテストパター
ンが発生し、そのテストパターンがテストバスを介して
テスト対象となるブロックへ送られる。テスト対象とな
るブロックでは、テストパターンに基づきテストを実行
し、そのテスト結果をテストバスを介してテスト回路へ
戻す。テスト回路では、送られてきたテスト結果と期待
値の一致/不一致を判定し、テスト対象の良否の判定を
行う。
According to the first aspect of the invention, since the microcomputer is configured as described above, the test circuit outputs the macro selection signal during the test, and the CP is sent via the test bus.
It is given to each input / output control means in the U core and the macro block. Then, one of the CPU cores or macro blocks to be tested is selected by these input / output control means. Then, a test pattern is generated from the test circuit, and the test pattern is sent to the block to be tested via the test bus. The block to be tested executes a test based on the test pattern and returns the test result to the test circuit via the test bus. The test circuit determines whether the sent test result matches the expected value or not, and determines whether the test target is good or bad.

【0012】第2の発明では、テスト回路内のマクロ選
択信号発生手段からマクロ選択信号が出力され、そのマ
クロ選択信号により、テスト対象に設けられた入出力手
段内のマルチプレクサ及び出力ゲートによって該テスト
対象のテストの入出力が制御される。テスト回路内のテ
ストパターン発生器からテストパターンが発生される
と、そのテストパターンが入出力制御手段内のマルチプ
レクサを介してテスト対象となるブロックへ送られ、該
ブロックでテストが行われ、そのテスト結果が出力ゲー
トを介してテストバスへ送られる。テストバスから送ら
れてきたテスト結果は、テスト回路内の判定手段で期待
値と比較判定される。これにより、テスト専用の外部端
子数を増大させることなく、簡単な制御で、各ブロック
の機能テストが的確に行える。従って、前記課題を解決
できるのである。
In the second invention, the macro selection signal is output from the macro selection signal generating means in the test circuit, and the test is performed by the multiplexer and the output gate in the input / output means provided for the test subject by the macro selection signal. Input / output of the target test is controlled. When a test pattern is generated from the test pattern generator in the test circuit, the test pattern is sent to the block to be tested through the multiplexer in the input / output control means, the block is tested, and the test is performed. The result is sent to the test bus via the output gate. The test result sent from the test bus is compared and judged with the expected value by the judging means in the test circuit. As a result, the functional test of each block can be accurately performed with simple control without increasing the number of external terminals dedicated to the test. Therefore, the above problem can be solved.

【0013】[0013]

【実施例】図1は、本発明の実施例を示すマイクロコン
ピュータの構成ブロック図である。このマイクロコンピ
ュータ30は、従来と同様に1チップで構成されるもの
で、CPU及びバスインタフェース回路を有するCPU
コア31と、各種の機能を有する複数のマクロブロッ
ク、例えば外部機器制御用の周辺機能マクロ32〜34
及びデータ格納用のRAMマクロ35とを備え、それら
が上位アドレスバス36、下位アドレスバス37及びデ
ータバス38で相互に接続されている。
DESCRIPTION OF THE PREFERRED EMBODIMENTS FIG. 1 is a block diagram of a microcomputer showing an embodiment of the present invention. This microcomputer 30 is composed of one chip as in the conventional case, and has a CPU and a bus interface circuit.
The core 31 and a plurality of macro blocks having various functions, for example, peripheral function macros 32 to 34 for controlling external devices.
And a RAM macro 35 for storing data, which are connected to each other by an upper address bus 36, a lower address bus 37 and a data bus 38.

【0014】各周辺機能マクロ32〜34は、外部機器
を制御するためにそれぞれ異なる機能を有し、それらに
は外部デバイスとのインタフェースを行う外部の第1,
第2,第3の端子群41〜43がそれぞれ接続されてい
る。これらの各周辺機能マクロ32〜34は、モードレ
ジスタやラッチ等を有し、それらが所定のアドレスにマ
ッピングしてあり、下位アドレスバス37を介してCP
Uコア31からアドレスが与えられ、さらにデータバス
38を介してCPUコア31とのデータの授受を行うよ
うになっている。RAMマクロ35は、上位アドレスバ
ス36、下位アドレスバス37及びデータバス38を介
してCPUコア31と接続され、該CPUコア31によ
ってデータの書込み及び読出しが制御される。
Each of the peripheral function macros 32 to 34 has a different function for controlling an external device, and each of them has an external first and an external function for interfacing with an external device.
The second and third terminal groups 41 to 43 are connected to each other. Each of these peripheral function macros 32 to 34 has a mode register, a latch, etc., which are mapped to a predetermined address, and the CP via the lower address bus 37.
An address is given from the U core 31, and data is exchanged with the CPU core 31 via the data bus 38. The RAM macro 35 is connected to the CPU core 31 via an upper address bus 36, a lower address bus 37, and a data bus 38, and the CPU core 31 controls writing and reading of data.

【0015】本実施例のマイクロコンピュータ30で
は、CPUコア31、周辺機能マクロ32〜34、及び
RAMマクロ35のテストを行うための起動用等の制御
信号の入力端子51、テスト結果の出力端子52、及び
テスト回路60が設けられている。外部の入力端子51
及び出力端子52に接続されたテスト回路60は、テス
トバス70を介してCPUコア31、周辺機能マクロ3
2〜34及びRAMマクロ35にそれぞれ接続されてい
る。このテスト回路60では、テスト起動等を行う制御
信号が入力端子51から入力されると、テストバス70
を介してテストすべきマクロブロックを選択し、その選
択対象となるマクロブロックに対し、テストパターンを
供給してテストを実行させる機能を有している。
In the microcomputer 30 of the present embodiment, a control signal input terminal 51 for starting and a test result output terminal 52 for testing the CPU core 31, the peripheral function macros 32 to 34, and the RAM macro 35 are provided. , And a test circuit 60 are provided. External input terminal 51
The test circuit 60 connected to the output terminal 52 is connected to the CPU core 31 and the peripheral function macro 3 via the test bus 70.
2 to 34 and the RAM macro 35, respectively. In this test circuit 60, when a control signal for starting a test is input from the input terminal 51, the test bus 70
It has a function of selecting a macro block to be tested via the, and supplying a test pattern to the selected macro block to execute the test.

【0016】図3は、図1中のテスト回路の構成例を示
すブロック図である。このテスト回路60は、入力端子
51から起動用等の制御信号が入力されると、テスト回
路全体を制御するための各種の制御信号を発生するコン
トロール回路61を有している。該コントロール回路6
1の出力側には、テスト対象となるマクロブロックを選
択するためのマクロ選択信号発生手段(例えば、エンコ
ーダ)62、各マクロブロックのテストパターンを発生
するテストパターン発生器63、及びテスト対象からの
テスト結果と期待値とを比較判定して判定結果を出力端
子52から出力する判定手段(例えば、比較器)64が
接続されている。
FIG. 3 is a block diagram showing a configuration example of the test circuit shown in FIG. The test circuit 60 has a control circuit 61 that generates various control signals for controlling the entire test circuit when a control signal for activation or the like is input from the input terminal 51. The control circuit 6
On the output side of 1, a macro selection signal generating means (for example, an encoder) 62 for selecting a macro block to be tested, a test pattern generator 63 for generating a test pattern of each macro block, and a test target A determination unit (for example, a comparator) 64 that compares the test result with the expected value and outputs the determination result from the output terminal 52 is connected.

【0017】また、コントロール回路61の出力側に
は、該コントロール回路61の出力によって開閉制御さ
れるゲート65〜67が接続されている。ゲート65
は、エンコーダ62から出力されるマクロ選択信号BS
をマクロ選択出力端子68を介してテストバス70へ出
力する機能を有している。ゲート66は、テストパター
ン発生器63から発生されるテストパターンをデータ出
力端子69を介してテストバス70へ出力する機能を有
している。さらに、ゲート67は、データ出力端子69
からの入力を比較器64へ送る機能を有している。
Further, the output side of the control circuit 61 is connected to gates 65 to 67 whose opening / closing is controlled by the output of the control circuit 61. Gate 65
Is a macro selection signal BS output from the encoder 62.
Is output to the test bus 70 via the macro selection output terminal 68. The gate 66 has a function of outputting the test pattern generated from the test pattern generator 63 to the test bus 70 via the data output terminal 69. Further, the gate 67 has a data output terminal 69.
It has a function of sending the input from the comparator to the comparator 64.

【0018】図1に示すマイクロコンピュータ30内の
CPUコア31、周辺機能マクロ32〜34、及びRA
Mマクロ35の入出力側には、テスト回路60から出力
されるマクロ選択信号BSに基づきそれらの各マクロブ
ロックの入出力を制御するための入出力制御手段がそれ
ぞれ設けられており、その構成例を図4に示す。
The CPU core 31, the peripheral function macros 32 to 34, and the RA in the microcomputer 30 shown in FIG.
Input / output control means for controlling the input / output of each of these macro blocks based on the macro selection signal BS output from the test circuit 60 is provided on the input / output side of the M macro 35. Is shown in FIG.

【0019】図4は、図1中の例えばCPUコア31内
に設けられる入出力制御手段の構成ブロック図である。
CPUコア31内のCPUコア本体80の入力側にマル
チプレクサ81が、出力側に出力ゲート82がそれぞれ
接続され、このマルチプレクサ81及び出力ゲート82
によって入出力制御手段が構成されている。マルチプレ
クサ81は、その入力側にデータバス38及びテストバ
ス70が接続され、さらにその出力側にCPUコア本体
80の入力側が接続され、該テストバス70から送られ
てくるマクロ選択信号BSに基づき該テストバス70の
入力を選択してCPUコア本体80へ与える機能を有し
ている。出力ゲート82は、CPUコア本体80の出力
側とテストバス70との間に接続され、該テストバス7
0から送られてくるマクロ選択信号BSに基づき、CP
Uコア本体80の出力をテストバス70へ出力する機能
を有している。
FIG. 4 is a configuration block diagram of the input / output control means provided in, for example, the CPU core 31 in FIG.
The multiplexer 81 is connected to the input side and the output gate 82 is connected to the output side of the CPU core body 80 in the CPU core 31, and the multiplexer 81 and the output gate 82 are connected.
The input / output control means is constituted by. The multiplexer 81 is connected to the data bus 38 and the test bus 70 on its input side, and is further connected to the input side of the CPU core body 80 on its output side. The multiplexer 81 outputs the multiplexer based on the macro selection signal BS sent from the test bus 70. It has a function of selecting an input of the test bus 70 and giving it to the CPU core body 80. The output gate 82 is connected between the output side of the CPU core body 80 and the test bus 70.
0 based on the macro selection signal BS sent from 0
It has a function of outputting the output of the U core body 80 to the test bus 70.

【0020】このような入出力制御手段は、図1の周辺
機能マクロ32〜34及びRAMマクロ35の各入出力
側にそれぞれ設けられている。以上のように構成される
マイクロコンピュータ30の動作を説明する。まず、図
1のマイクロコンピュータ30の通常の動作では、CP
Uコア31がプログラムをデコードし、そのデコード結
果に基づきRAMマクロ35を用いて演算処理等を行
い、その演算結果等を周辺機能マクロ32〜34へ与え
る。すると、周辺機能マクロ32〜34では、CPUコ
ア31からの制御に基づき、第1〜第3の端子群41〜
43を介して外部機器を制御する。
Such input / output control means is provided on each input / output side of the peripheral function macros 32 to 34 and the RAM macro 35 shown in FIG. The operation of the microcomputer 30 configured as above will be described. First, in normal operation of the microcomputer 30 of FIG.
The U core 31 decodes the program, performs arithmetic processing and the like using the RAM macro 35 based on the decoding result, and gives the arithmetic result and the like to the peripheral function macros 32 to 34. Then, in the peripheral function macros 32 to 34, based on the control from the CPU core 31, the first to third terminal groups 41 to 41.
An external device is controlled via 43.

【0021】次に、マイクロコンピュータ30内の各マ
クロブロックに対するテスト動作を説明する。例えば、
CPUコア31のテストを行う場合、マイクロコンピュ
ータ30の外部の入力端子51から、テスト回路起動用
の制御信号を入力する。すると、図3のテスト回路60
内のコントロール回路61が動作し、該テスト回路全体
を制御するための各種の制御信号を発生する。エンコー
ダ62は、コントロール回路61からの制御信号を符号
化してCPUコア31を選択するためのマクロ選択信号
BSを発生する。このマクロ選択信号BSは、ゲート6
5及びマクロ選択出力端子68を介してテストバス70
へ出力され、該テストバス70上のマクロ選択信号BS
がCPUコア31、周辺機能マクロ32〜34、及びR
AMマクロ35へ送られる。
Next, the test operation for each macroblock in the microcomputer 30 will be described. For example,
When testing the CPU core 31, a control signal for activating a test circuit is input from an external input terminal 51 of the microcomputer 30. Then, the test circuit 60 of FIG.
The control circuit 61 therein operates to generate various control signals for controlling the entire test circuit. The encoder 62 encodes the control signal from the control circuit 61 and generates a macro selection signal BS for selecting the CPU core 31. This macro selection signal BS is applied to the gate 6
5 and the macro selection output terminal 68
To the macro selection signal BS on the test bus 70.
Is a CPU core 31, peripheral function macros 32 to 34, and R
It is sent to the AM macro 35.

【0022】図4のCPUコア31では、マルチプレク
サ81がテストバス70側を選択するので、該テストバ
ス70を通じてCPUコア本体80への入力が可能とな
る。他の周辺機能マクロ32〜34及びRAMマクロ3
5では、テストバス70からの入力が不可能となる。
In the CPU core 31 of FIG. 4, since the multiplexer 81 selects the test bus 70 side, it is possible to input to the CPU core body 80 through the test bus 70. Other peripheral function macros 32 to 34 and RAM macro 3
In 5, the input from the test bus 70 becomes impossible.

【0023】次に、図3のテスト回路60では、テスト
パターン発生器63よりCPUコア31のテストパター
ンを発生する。このテストパターンは、ゲート66及び
データ出力端子69を介してテストバス70へ出力さ
れ、CPUコア31へ送られる。図4のCPUコア31
では、テストバス70から送られてきたテストパターン
をマルチプレクサ81を介してCPUコア本体80に入
力し、テストを実行する。このCPUコア本体80での
テスト結果は、出力ゲート82を介してテストバス70
へ出力され、テスト回路60へ戻される。
Next, in the test circuit 60 of FIG. 3, the test pattern generator 63 generates a test pattern for the CPU core 31. This test pattern is output to the test bus 70 via the gate 66 and the data output terminal 69 and sent to the CPU core 31. CPU core 31 of FIG.
Then, the test pattern sent from the test bus 70 is input to the CPU core body 80 via the multiplexer 81 to execute the test. The test result of the CPU core body 80 is transferred to the test bus 70 via the output gate 82.
Is output to the test circuit 60.

【0024】図3のテスト回路60では、テストバス7
0からデータ入力端子69及びゲート67を介して送ら
れてきたテスト結果を比較器64に入力し、該比較器6
4によってテスト結果と期待値との一致/不一致を比較
判定し、その判定結果を出力端子52からマイクロコン
ピュータ外部へ出力する。このようなシーケンスを繰り
返すことにより、CPUコア31に対するテストが完了
する。
In the test circuit 60 of FIG. 3, the test bus 7
The test result sent from 0 through the data input terminal 69 and the gate 67 is input to the comparator 64, and the comparator 6
In step 4, the test result and the expected value are compared / unmatched, and the judgment result is output from the output terminal 52 to the outside of the microcomputer. By repeating such a sequence, the test for the CPU core 31 is completed.

【0025】他の周辺機能マクロ32〜34及びRAM
マクロ35に対するテストも、前記と同様にして行われ
る。以上のように、本実施例では、マイクロコンピュー
タ30にテスト用の入力端子51及び出力端子52を外
部に設けると共に、該マイクロコンピュータ30の内部
にテスト回路60、テストバス70、及び入出力制御手
段を設けたので、該入力端子51から起動用の制御信号
を入力するのみで、CPUコア31、周辺機能マクロ3
2〜34、あるいはRAMマクロ35のテストを行い、
そのテスト結果を出力端子52から外部へ出力すること
ができる。従って、テストのための制御が簡単で、しか
もテスト専用の外部端子が入力端子51及び出力端子5
2の2つだけであり、テスト専用の外部端子数をそれほ
ど増大させることなく、簡単な制御で、CPUコア31
や各マクロブロックの単体の機能テストを的確に行うと
ができ、マイクロコンピュータ30の故障検出率を向上
できる。
Other peripheral function macros 32 to 34 and RAM
The test for the macro 35 is performed in the same manner as described above. As described above, in this embodiment, the microcomputer 30 is provided with the test input terminal 51 and the output terminal 52 outside, and the test circuit 60, the test bus 70, and the input / output control means are provided inside the microcomputer 30. Since the control signal for activation is input from the input terminal 51, the CPU core 31 and the peripheral function macro 3 are provided.
2-34, or test the RAM macro 35,
The test result can be output from the output terminal 52 to the outside. Therefore, the control for the test is simple, and the external terminals dedicated to the test are the input terminal 51 and the output terminal 5.
There are only two, and the CPU core 31 can be easily controlled without increasing the number of external terminals dedicated to the test so much.
It is possible to accurately perform a functional test of each of the macroblocks and to improve the failure detection rate of the microcomputer 30.

【0026】また、従来と同様に、第1〜第3の端子群
41〜43等を用いて外部からテスト信号をマイクロコ
ンピュータ30内に入力し、CPUコア31のCPU機
能を用いて周辺機能マクロ32〜34やRAMマクロ3
5のテストを行うことも可能である。
Further, as in the conventional case, a test signal is externally input into the microcomputer 30 using the first to third terminal groups 41 to 43 and the like, and the peripheral function macro is used by using the CPU function of the CPU core 31. 32-34 and RAM macro 3
It is also possible to perform the test of 5.

【0027】なお、本発明は、上記実施例に限定され
ず、種々の変形が可能である。その変形例としては、例
えば次のようなものがある。 (a) 図1では、テスト用入力端子51及び出力端子
52をマイクロコンピュータ30の外部に設けたが、C
PUコア31を起動するため等の既設の端子があれば、
それらを利用することも可能である。また、テスト用の
入力端子51は、マイクロコンピュータ30の外部に設
けているが、これを省略してCPUコア31からの制御
信号によってテスト回路60を起動するようにしてもよ
い。
The present invention is not limited to the above embodiment, but various modifications can be made. Examples of such modifications include the following. (A) In FIG. 1, the test input terminal 51 and the output terminal 52 are provided outside the microcomputer 30.
If there is an existing terminal for starting the PU core 31, etc.,
It is also possible to use them. Although the test input terminal 51 is provided outside the microcomputer 30, the test input terminal 51 may be omitted and the test circuit 60 may be activated by a control signal from the CPU core 31.

【0028】(b) 図1ではテスト入力のバスとテス
ト結果のバスを1つのテストバス70で構成している
が、テスト入力用のバスとテスト結果のバスとを2つ設
けてもよい。
(B) In FIG. 1, the test input bus and the test result bus are constituted by one test bus 70, but two test input buses and test result buses may be provided.

【0029】(c) 図3に示すテスト回路60は、例
えばエンコーダ62を他のマクロ選択信号発生手段で構
成する等して、他の回路構成に変更することも可能であ
る。 (d) 図4に示す入出力制御手段は、各CPUコア3
1、周辺機能マクロ32〜34及びRAMマクロ35の
内部に設けているが、これらをそれらの外部に設けても
良く、さらにそれらのマクロブロック内にマルチプレク
サ31や出力ゲート82が予め設けられておれば、それ
らを利用することも可能である。さらに、この入出力制
御手段をマルチプレクサ81及び出力ゲート82以外の
回路で構成することも可能である。
(C) The test circuit 60 shown in FIG. 3 can be changed to another circuit configuration, for example, by configuring the encoder 62 with another macro selection signal generating means. (D) The input / output control means shown in FIG.
1. The peripheral function macros 32 to 34 and the RAM macro 35 are provided inside, but they may be provided outside thereof, and the multiplexer 31 and the output gate 82 are provided in advance in these macro blocks. However, it is possible to use them. Further, the input / output control means can be configured by circuits other than the multiplexer 81 and the output gate 82.

【0030】(e) 図1に示すマイクロコンピュータ
30内には、必要に応じて他のマクロブロック等を設け
ることも可能である。
(E) In the microcomputer 30 shown in FIG. 1, it is possible to provide other macroblocks or the like as needed.

【0031】[0031]

【発明の効果】以上詳細に説明したように、第1の発明
によれば、マイクロコンピュータの内部に複数の入出力
制御手段、テストバス、及びテスト回路を設けたので、
そのテスト回路によって該マイクロコンピュータ内のC
PUコアあるいは複数のマクロブロックのうちの任意の
ブロックのテストが行える。従って、テスト専用の外部
端子数をそれ程増大することなく、簡単な制御で、マイ
クロコンピュータ内の単体の機能テストを的確に行うこ
とができ、該マイクロコンピュータの故障検出率を向上
できる。
As described in detail above, according to the first invention, a plurality of input / output control means, a test bus, and a test circuit are provided inside the microcomputer.
The test circuit allows the C in the microcomputer to
A PU core or an arbitrary block of a plurality of macroblocks can be tested. Therefore, the function test of the single unit in the microcomputer can be accurately performed with simple control without increasing the number of external terminals dedicated to the test so much, and the failure detection rate of the microcomputer can be improved.

【0032】第2の発明によれば、入出力制御手段をマ
ルチプレクサ及び出力ゲートで構成したので、マクロ選
択信号によってテスト対象となるブロックのテストの入
出力が簡単に行える。さらに、テスト回路は、マクロ選
択信号発生手段、テストパターン発生回路、及び判定手
段を有するので、該テスト回路に対して起動をかけるこ
とにより、マクロ選択信号発生手段からマクロ選択信号
が出力され、そのマクロ選択信号によってテスト対象と
なるブロックが選択され、そのブロックに対してテスト
パターン発生器からテストパターンが供給され、該テス
ト対象のテストが行われてテスト結果が判定手段で比較
判定される。従って、各ブロックのテストを簡単な制御
で、精度良く実行できる。
According to the second aspect of the invention, since the input / output control means is composed of the multiplexer and the output gate, the test input / output of the block to be tested can be easily performed by the macro selection signal. Further, since the test circuit has the macro selection signal generating means, the test pattern generating circuit, and the judging means, the macro selection signal generating means outputs the macro selection signal by activating the test circuit. A block to be tested is selected by the macro selection signal, a test pattern is supplied to the block from the test pattern generator, the test of the test target is performed, and the test results are compared and judged by the judging means. Therefore, the test of each block can be accurately executed with simple control.

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

【図1】本発明の実施例を示すマイクロコンピュータの
構成ブロック図である。
FIG. 1 is a configuration block diagram of a microcomputer showing an embodiment of the present invention.

【図2】従来のマイクロコンピュータの構成ブロック図
である。
FIG. 2 is a configuration block diagram of a conventional microcomputer.

【図3】図1中のテスト回路の構成ブロック図である。3 is a configuration block diagram of a test circuit in FIG.

【図4】図1中のマイクロコンピュータ30内に設けら
れる入出力制御手段の構成ブロック図である。
4 is a configuration block diagram of an input / output control unit provided in a microcomputer 30 in FIG.

【符号の説明】[Explanation of symbols]

30 マイクロコンピュータ 31 CPUコア 32〜34 周辺機能マクロ 35 RAMマクロ 51 入力端子 52 出力端子 60 テスト回路 61 コントロール回路 62 エンコーダ 63 テストパターン発生器 64 比較器 70 テストバス 81 マルチプレクサ 82 出力ゲート 30 Microcomputer 31 CPU Core 32-34 Peripheral Function Macro 35 RAM Macro 51 Input Terminal 52 Output Terminal 60 Test Circuit 61 Control Circuit 62 Encoder 63 Test Pattern Generator 64 Comparator 70 Test Bus 81 Multiplexer 82 Output Gate

Claims (2)

【特許請求の範囲】[Claims] 【請求項1】 マイクロコンピュータ全体をプログラム
制御する中央処理装置を有するCPUコアと、前記中央
処理装置により制御されて前記プログラムを実行する複
数のマクロブロックとが、1チップ内に搭載されたマイ
クロコンピュータにおいて、 マクロ選択信号に基づき、前記CPUコア及び前記複数
のマクロブロックのそれぞれの入出力を制御する複数の
入出力制御手段と、 前記各入出力制御手段を介して前記CPUコア及び前記
複数のマクロブロックにそれぞれ共通接続されたテスト
バスと、 前記テストバスに接続され、前記マクロ選択信号を出力
して前記CPUコア及びマクロブロックのいずれか一つ
を選択し、そのテスト対象に対しテストパターンを供給
してテストを実行させるテスト回路とを、 前記1チップ内に設けたことを特徴とするマイクロコン
ピュータ。
1. A microcomputer in which a CPU core having a central processing unit for program controlling the entire microcomputer and a plurality of macroblocks controlled by the central processing unit to execute the program are mounted in one chip. A plurality of input / output control means for controlling the input / output of each of the CPU core and the plurality of macro blocks based on a macro selection signal, and the CPU core and the plurality of macros via the respective input / output control means. A test bus that is commonly connected to each block and a test bus that is connected to the test bus and outputs the macro selection signal to select one of the CPU core and the macro block and supply a test pattern to the test target. And a test circuit for executing a test are provided in the one chip. The microcomputer according to claim.
【請求項2】 請求項1記載のマイクロコンピュータに
おいて、 前記入出力制御手段は、前記マクロ選択信号によって入
力の選択を行うマルチプレクサと出力の制御を行う出力
ゲートとで構成し、 前記テスト回路は、前記マクロ選択信号を発生するマク
ロ選択信号発生手段、前記テストパターンを発生するテ
ストパターン発生器、及び前記テスト対象からのテスト
結果と期待値とを比較判定する判定手段を有することを
特徴とするマイクロコンピュータ。
2. The microcomputer according to claim 1, wherein the input / output control unit includes a multiplexer that selects an input according to the macro selection signal and an output gate that controls an output, and the test circuit includes: A micro selection signal generating means for generating the macro selection signal, a test pattern generator for generating the test pattern, and a determination means for comparing and determining a test result from the test target and an expected value. Computer.
JP3316762A 1991-11-29 1991-11-29 Microcomputer Pending JPH05151017A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP3316762A JPH05151017A (en) 1991-11-29 1991-11-29 Microcomputer

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP3316762A JPH05151017A (en) 1991-11-29 1991-11-29 Microcomputer

Publications (1)

Publication Number Publication Date
JPH05151017A true JPH05151017A (en) 1993-06-18

Family

ID=18080644

Family Applications (1)

Application Number Title Priority Date Filing Date
JP3316762A Pending JPH05151017A (en) 1991-11-29 1991-11-29 Microcomputer

Country Status (1)

Country Link
JP (1) JPH05151017A (en)

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US6327681B1 (en) 1996-03-21 2001-12-04 Hitachi, Ltd. Data processor with built-in DRAM
US6367044B1 (en) 1997-11-20 2002-04-02 Mitsubishi Denki Kabushiki Kaisha Semiconductor integrated circuit device
US7941702B2 (en) 2007-03-14 2011-05-10 Denso Corporation Electronic control unit

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US6327681B1 (en) 1996-03-21 2001-12-04 Hitachi, Ltd. Data processor with built-in DRAM
US6367044B1 (en) 1997-11-20 2002-04-02 Mitsubishi Denki Kabushiki Kaisha Semiconductor integrated circuit device
US7941702B2 (en) 2007-03-14 2011-05-10 Denso Corporation Electronic control unit

Similar Documents

Publication Publication Date Title
KR970004074B1 (en) Memory device and integrated circuit thereof
JPS6231439B2 (en)
US7143229B2 (en) Single-chip microcomputer with dynamic burn-in test function and dynamic burn-in testing method therefor
JPH04178580A (en) Self diagnostic device for semiconductor memory
US5339320A (en) Architecture of circuitry for generating test mode signals
US6675336B1 (en) Distributed test architecture for multiport RAMs or other circuitry
JPH05151017A (en) Microcomputer
US6327683B1 (en) Device scan testing
US20030237036A1 (en) Semiconductor integrated circuit with built-in self-test function and system including the same
KR19990079785A (en) Built-in magnetic test circuit
JP3955708B2 (en) Built-in self-test circuit
JP2001514784A (en) Integrated circuit with memory and test circuit
JP3943890B2 (en) Semiconductor device
JP2524529B2 (en) Pattern generator
KR200280380Y1 (en) Memory test device
JP2002365337A (en) Test circuit and digital circuit
KR930011426B1 (en) I.c. device having microprogram
JPH01113678A (en) Test circuit
JP3125950B2 (en) Application specific integrated circuits
JP3177975B2 (en) One-chip microcomputer
JP2861001B2 (en) I / O circuit
JP2004302727A (en) Operation check system of fpga
JPH04113580A (en) Semiconductor integrated circuit device
JPH02289999A (en) Microcomputer
JPS6011941A (en) Data processor

Legal Events

Date Code Title Description
A02 Decision of refusal

Free format text: JAPANESE INTERMEDIATE CODE: A02

Effective date: 20001017