JPS58161046A - Interruption controlling circuit - Google Patents

Interruption controlling circuit

Info

Publication number
JPS58161046A
JPS58161046A JP57042691A JP4269182A JPS58161046A JP S58161046 A JPS58161046 A JP S58161046A JP 57042691 A JP57042691 A JP 57042691A JP 4269182 A JP4269182 A JP 4269182A JP S58161046 A JPS58161046 A JP S58161046A
Authority
JP
Japan
Prior art keywords
vector address
interrupt
signal
interruption
program
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Granted
Application number
JP57042691A
Other languages
Japanese (ja)
Other versions
JPH0259492B2 (en
Inventor
Teruichi Watanabe
渡辺 照一
Yasuo Matsuzawa
松沢 泰生
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.)
Hitachi Microcomputer System Ltd
Hitachi Ltd
Original Assignee
Hitachi Ltd
Hitachi Microcomputer Engineering Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Hitachi Ltd, Hitachi Microcomputer Engineering Ltd filed Critical Hitachi Ltd
Priority to JP57042691A priority Critical patent/JPS58161046A/en
Publication of JPS58161046A publication Critical patent/JPS58161046A/en
Publication of JPH0259492B2 publication Critical patent/JPH0259492B2/ja
Granted legal-status Critical Current

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Quality & Reliability (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)

Abstract

PURPOSE:To prevent the runaway of a program, by generating a power-on reset signal to return the program to the initial state when a vector address generation start signal is issued or an interruption request disappears erroneously because of a malfunction. CONSTITUTION:When an interruption is caused from a timer, a terminal, or the like, an interruption start signal Pi is outputted from timers 1 and 2 and INTs 1 and 2 to an arithmetic logical unit 3, and saving of contents of registers 4a- 4d to a memory 7 is started after an executing instuction is terminated. If the interruption is started by the malfunction of a timer counter or the like to output a vector address generation start signal Ps or to lose the interruption request, the state of no interruption signal from timers 1 and 2 or INTs 1 and 2 to a vector address generating part 10 is set. Then, a signal from a power-on reset terminal RES is inputted to the generating part 10 through a NOR gate 8 and an OR gate 9, and a specific vector address is generated from the generating part 10 and is loaded to a program counter 4d, and registers 4a-4d are set to the initial state.

Description

【発明の詳細な説明】 この発明は、ベクタアドレス方式の割込み制御回路に関
し、特に、誤まってペクタアドレス発生開始信号が発生
された場合に、パワーオンリセットさせるようにした割
込み制御回路VCIllする。
DETAILED DESCRIPTION OF THE INVENTION The present invention relates to a vector address type interrupt control circuit, and in particular to an interrupt control circuit VCIll that performs a power-on reset when a vector address generation start signal is generated by mistake. .

ペクタアドレス方式の割込み制御が適用されたマイクロ
コンビエータにおいては、コンビ鼻−タが端末装置から
の外部割込み要求や、タイマカウンタからのタイマ割込
み要求あるいはソフトウェアによる内部割込み要求等を
受けたときに1割込み要求の内容に応じて予め設定され
ているペクタアドレス(間接指定アドレス)を発生する
。そして、ペクタアドレスにより指定されたメモリエリ
ア内に格納されている内容(割込みプログラムの最初の
命令が格納されている番地を示すアドレス)をプログラ
ムカウンタに貌み込む0次に、このアドレスが示す領域
に記憶されている命令が、命令レジスタに入って解観さ
れ、プログラムは割込みルーチンヘジャンプして、最初
の命令が奥行されるようkされ【いる。
In a micro combiator to which interrupt control using the vector address method is applied, when the combiator receives an external interrupt request from a terminal device, a timer interrupt request from a timer counter, or an internal interrupt request from software, 1 A preset vector address (indirectly specified address) is generated according to the contents of the interrupt request. Then, the contents stored in the memory area specified by the vector address (the address indicating the address where the first instruction of the interrupt program is stored) are transferred to the program counter. The instructions stored in the area are read into the instruction register, the program jumps to the interrupt routine, and the first instruction is read in depth.

しかしながら、ベクタアドレス方式の割込み制御におい
ては、タイマカウンタ等から誤まって割込み要求信号が
出力されたり、あるいは割込み要求があってからペクタ
アドレスが発生されるまでに割込み要求が消滅しズしま
5ことがある。
However, in the vector addressing method of interrupt control, an interrupt request signal may be output by mistake from a timer counter, etc., or the interrupt request may disappear between the time the interrupt request is issued and the vector address is generated5. Sometimes.

従来の!イクロプロセッ?(以下CPLjと称する)で
は、このような場合には、最初の割込み簀求信号が入っ
て来ると、奥行中の命令を最後まで続行した後K、割込
み要求に対する応答を開始する。そして1割込み要求の
内容Kかかわらず、先ず、インデックレジスタやプログ
ラムカウンタ。
Traditional! Ikroproset? (hereinafter referred to as CPLj), in such a case, when the first interrupt request signal comes in, it continues the instruction in progress to the end and then starts responding to the interrupt request. Regardless of the contents of one interrupt request, the index register or program counter is first read.

アキ、−ムレ−タウコンディジ曹ンコードレジスタの内
容が、メモリ(RAM)のスタック領域に退避される。
The contents of the code register are saved in the stack area of memory (RAM).

このレジスタ類の退避は、ベクタアドレスが発生される
前に行なわれ、退避が終了してからベクタアドレスが発
生して、割込みプログラムにブランチするようKされて
いる。
The registers are saved before the vector address is generated, and after the save is completed, the vector address is generated and branched to the interrupt program.

そのため、タイマカウンタ等の誤動作によりベクタアド
レス発生部に対して発生開始信号が出力されたり、ある
いは、割込み要求信号を受けてからベクタアドレスが発
生される前に割込み要求が消滅してしまうと、本来実行
されるべきでないプログラムが実行されたり、プログラ
ムが暴走したりするおそれがあった。
Therefore, if a generation start signal is output to the vector address generation section due to a malfunction of a timer counter, etc., or if an interrupt request disappears after receiving an interrupt request signal but before a vector address is generated, There was a risk that a program that should not be executed might be executed or the program might run out of control.

そこで、この発明は、タイマカウンタ尋の誤動作によっ
て、誤まってベクタアドレス発生開始信号が出されたり
、あるいはベクタアドレス発生直前に割込み要求が消滅
したような場合には、ハード的にパワーオンリセット信
号を発生させることkより、プログラムを初期状態へ戻
してやり、これkよって、プ交ダラムの暴t  システ
ムへの悪影響を鋳圧することを目的とする。
Therefore, in the case where a vector address generation start signal is erroneously issued due to a malfunction of the timer counter, or when an interrupt request disappears immediately before vector address generation, the power-on reset signal is generated by hardware. The purpose of this is to return the program to its initial state by causing the program to return to its initial state, thereby eliminating the negative impact on the system.

以下図INK基づいてこの1iIIII#を説明する。This 1iIII# will be explained below based on the figure INK.

縞1sは本発WRIIC係る割込み制御a路の一実施例
を示す、CPU内部のベクタアドレス発生部10には、
タイ11およびタイマ2からのタイマ割込み備考やlN
Tl、lNTlからの外sin込み信号あるいはソフト
フェアによる割込み信号部が入力されるようkされてい
る。また、タイ−fl、  2およびlNTl、2は、
割込み要求が入ると、CPU内−の演算鍮看エニツ)3
1’C対して割込み開蛤償−1lPl を出力するよう
kされている。
The stripe 1s shows an example of the interrupt control path a according to the present WRIIC.
Timer interrupt notes and lN from tie 11 and timer 2
An external sin interrupt signal from Tl, NTl or an interrupt signal section by software is inputted. In addition, ties-fl, 2 and lNTl, 2 are
When an interrupt request is received, the calculations within the CPU are executed.
It is configured to output interrupt compensation -1lPl for 1'C.

演算論珊瓢ニット3は、アキ轟−五レータ4m。Arithmetic logic Sankyo knit 3 is Aki Todoroki-Gorata 4m.

インデックスレジスタ4b、コンディジ曹ンコードレジ
スタ4c、 プログラムカウンタ4(IIのレジスタ類
とともに、アドレスバス5およびデータバス・を介して
、メモリ7に@@されている。メモリ7はROM(リー
ド−オンリ・メモリ)とRAM(ランダム0アクセス・
メモリ)とを含む。
The index register 4b, condition code register 4c, and program counter 4 (II) registers are connected to the memory 7 via the address bus 5 and the data bus.The memory 7 is a ROM (read-only). memory) and RAM (random 0 access/
memory).

ROM内部には、割込み要求の内容に応じて上記ペクタ
アドレス発生部10から発生されるベクタアドレスの指
示するエリアに、対応する割込みプログラムの格納位電
を示す番地(アドレス)が記憶されている。また、メモ
リ7内の上記番地の示すエリアには1割込みプログラム
の最初の命令が格納されている。
Inside the ROM, an address indicating a storage potential of a corresponding interrupt program is stored in an area designated by a vector address generated from the vector address generating section 10 according to the contents of an interrupt request. . Further, the first instruction of one interrupt program is stored in the area indicated by the above address in the memory 7.

上記タイマ1,2およびlNTl、2からベクタアドレ
ス尭生部り1m対して供給される各種の割込み信号は、
NORゲー)8にも入力され、NORゲート8の出力は
ORゲート9の一方の入力端子に入力されている。OR
ゲート9の他方の入力端子にはJ5パワーオンリセット
端子RE8かもの信号が入力されており、oaj−トs
の出力は前記ベクタアドレス発生Ill OK供給され
ている。−さらk、ペクタアドレス発生部10には、前
記演算論理ユニット3から出力されるベクタアドレス発
生開始信号Psが供給されるようkされている。ベクタ
アドレス発生111Gは、上記闘始儒号?易が入って来
ると、−イマ1,2あるいはlNTl、2からの割込み
信号に基づいて、割込み要求の内容に応じたベクタアド
レスを発生する。複数の割込み1号がベクタアドレス発
生11g10に入って来ている場合には、最も優先度の
高い割込み要求に応じたベクタアドレスを発生ずるよう
にされている。
The various interrupt signals supplied from the timers 1, 2 and lNTl, 2 to the vector address input section 1m are as follows:
The output of the NOR gate 8 is also input to one input terminal of the OR gate 9. OR
A signal from the J5 power-on reset terminal RE8 is input to the other input terminal of the gate 9, and the oaj-tos
The output of Ill OK is supplied to the vector address generator Ill OK. Furthermore, the vector address generation section 10 is configured to be supplied with the vector address generation start signal Ps output from the arithmetic logic unit 3. Is the vector address generation 111G the above Toushi Confucian code? When a request is received, a vector address corresponding to the contents of the interrupt request is generated based on the interrupt signal from -ima 1, 2 or lNTl, 2. When a plurality of interrupts No. 1 are received by the vector address generator 11g10, the vector address corresponding to the interrupt request with the highest priority is generated.

次に上記割込み制御回路の―作を説明する。Next, the operation of the above interrupt control circuit will be explained.

タイマや端本装置等からの割込み要求があると、タイマ
1.2あるい)tIs’r1,2から、割込みlI蛤備
号Piが演算論理エニツ)3に出力される。
When there is an interrupt request from a timer, an end device, etc., an interrupt signal Pi is output from the timer 1.2 or tIs'r1, 2 to the arithmetic logic unit 3.

すると、奥行中の命令が終了してから、レジスタ1m1
4a〜4dの退避が開始される。レジスタ類4a〜4−
の退避は、スタックポインタによって指示されたメモリ
(RAM)7内のスタック領域k、レジスタ類の内容を
願に格納させることにより行なわれる。
Then, after the instruction in depth is completed, register 1m1
Evacuation of 4a to 4d is started. Registers 4a to 4-
The saving is performed by storing the contents of the stack area k and registers in the memory (RAM) 7 indicated by the stack pointer.

レジスタ類の退避が終了すると、演算論理ユニット3か
らベクタアドレス発生III Ok対して、ベクタアド
レス発生開始信号Psが出力される。
When the saving of the registers is completed, a vector address generation start signal Ps is output from the arithmetic logic unit 3 to the vector address generation III Ok.

ベクタアドレス発生1110は1M鍮信号Psが入力さ
れたときに、タイ11.2あるいはlNT1.2からの
割込み信号が、少なくとも一つ入力されていると、最も
優先度の高い割込み要求に応じたベクタアドレスを発生
する。
If at least one interrupt signal from tie 11.2 or lNT 1.2 is input when the 1M signal Ps is input, the vector address generator 1110 generates a vector corresponding to the interrupt request with the highest priority. Generate an address.

このベクタアドレスは、プルグラムカウンターにロード
され、アドレスバス5を介してメ毫り(ROM)7に供
給される。ROMからは、このベクタアドレスにより指
定されたエリアに格納されている16ビツトのようなア
ドレスが、データバス6を介して読み出され、プログラ
ムカウンタ4dに入れられる。
This vector address is loaded into a program counter and supplied to a memory (ROM) 7 via an address bus 5. A 16-bit address stored in the area designated by this vector address is read from the ROM via the data bus 6 and entered into the program counter 4d.

次に、このアドレスがアドレスノ(ス5を介して再びメ
毛り7に出力され、このアドレスに指示された番地に格
納され【いる命令が暁み出され、命令レジスタに入れら
れる。この命令は、所望の割込みプログラムの最初の命
令であって、この命令が実行されると、プログラムカウ
ンタ44がインクリメントされ【、次の命令がメ毫り7
から貌みして割込みプログラムが実行されて行く。
Next, this address is again output to the register 7 via the address register 5, and the instruction stored at the address specified by this address is retrieved and placed in the instruction register. is the first instruction of the desired interrupt program, and when this instruction is executed, the program counter 44 is incremented.
Then the interrupt program starts running.

割込み処理ルーチンの最後では、リターンインタラブド
命令が実行される。この命令によって。
At the end of the interrupt processing routine, a return interwoven instruction is executed. By this command.

メ毫り(肌AM)のスタック領域に退避されていた内容
が元のレジスタIg4a〜44に復帰される。
The contents saved in the stack area of the memory (hada AM) are restored to the original registers Ig4a-44.

これkよって、プログラムカウンタ44には1割込み前
の最後のアドレスが入り、元のプルグラ^が継続される
ようkなる。
As a result, the last address before one interrupt is stored in the program counter 44, so that the original program program can be continued.

ところで、上記動作は、ベクタアドレス発生時に、ペク
タアドレス発生6110に割込み信号カ少なくとも一つ
入力され曵いた場合の動作である。
By the way, the above operation is an operation when at least one interrupt signal is input to the vector address generation 6110 when a vector address is generated.

この場合には、NORゲー)1の入力の少なくとも一つ
がハイレベルであるため、NORゲート8の出力はロウ
レベルである。
In this case, since at least one of the inputs of NOR gate 1 is at high level, the output of NOR gate 8 is at low level.

ところが、タイマカウンタ勢が誤動作して割込みが開始
され、ベクタアドレス斃生開始信号P易が出力されたり
、あるいは、割込みWR始後後ペクタアドレス発生前割
込み要求が消滅すると、ベクタアドレス発生時に、タイ
11,2あるいはlNT1.2からベクタアドレス発生
部10に入力される割込み信号がない状II#!cされ
る。
However, if the timer counter malfunctions and an interrupt is started and the vector address death start signal P is output, or if the interrupt request disappears after the interrupt WR is started but before the vector address is generated, when the vector address is generated, Condition where there is no interrupt signal input to the vector address generation unit 10 from ties 11, 2 or lNT 1.2 II#! c.

しかし、タイマ1,2あるいはlNT1.2からの割込
み信号がすべて消滅すると、NORゲート80入力がす
べてロウレベルになって、出力がハイレベルに変化され
る。このNORゲート8のハイレベルの信号はORゲー
ト9を介してベクタアドレス発生部10に入力される。
However, when all the interrupt signals from timers 1 and 2 or lNT1.2 disappear, all the inputs of the NOR gate 80 become low level, and the output is changed to high level. This high level signal from NOR gate 8 is input to vector address generation section 10 via OR gate 9.

そのため、ベクタアドレス発生部10は、パワーオンリ
セット信号が入力された状態にされる。
Therefore, the vector address generation section 10 is brought into a state where the power-on reset signal is input.

これkよって、ベクタアドレス発生部10は、イニシャ
ライズルーチンのアドレスのような、パワーオンリセッ
ト特有のベクタアドレスを発生する。その結果、とのベ
クタアドレスはプログラムカウンタ4dにロードされ、
レジスタ11141〜4dが初期状態にセットされるよ
うになる。
Accordingly, the vector address generation section 10 generates a vector address unique to power-on reset, such as an address for an initialization routine. As a result, the vector address of is loaded into the program counter 4d,
Registers 11141-4d are now set to their initial states.

以上説明したようにこの発明は、タイマカウンタ等の誤
動作によりベクタアドレス発生開始信号のみが出力され
たり、コンビ島−夕が割込み要求を受は付けてからベク
タアドレスが発生される酋に割込み要求が消滅したよう
な場合には、ベクタアドレス発生Iiに対し、パワーオ
ンリセット信号が供給されるようkなる。これによって
、全てのデータが初期状態に復帰されて、プログラムが
再スタートされる。そのため、プログラムの暴走やシス
テムへの悪影響が防止され、システムの信頼性が陶土す
るという効果がある。
As explained above, this invention prevents the malfunction of a timer counter, etc., from outputting only a vector address generation start signal, or when an interrupt request is generated before a vector address is generated after Combi Island-Yu accepts the interrupt request. In such a case, a power-on reset signal is supplied to the vector address generation Ii. This restores all data to its initial state and restarts the program. This prevents programs from running out of control and adversely affecting the system, thereby improving the reliability of the system.

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

11111!lは本−―に係る割込み制御回路の一実施
例を示す回路構成図である。 3・・・演g論橿エニット、5・・・アドレスバス、6
・・・データバス、Ps・・・ベクタアドレス発生開始
信号。
11111! FIG. 1 is a circuit configuration diagram showing an embodiment of an interrupt control circuit according to the present invention. 3...Engin g logic enit, 5...Address bus, 6
...Data bus, Ps...Vector address generation start signal.

Claims (1)

【特許請求の範囲】[Claims] マイクロプロセッサが割込み要求を受は付けると、自動
的にレジスタ類の退避が行なわれてから、割込み要求に
応じたペクタアドレスが発生されて、所望の割込みプロ
グラムが実行されるようkされているマイクロコンビ島
−タにおいて、誤動作によって割込みがかかってベクタ
アドレス発生開始信号がベクタアドレス発生郁に入力さ
れても、割込み信号がない場合には、パワーオンリセッ
ト用のペクタアドレスが発生されるようkされていると
とを特徴とする割込み制御回路。
When the microprocessor accepts an interrupt request, registers are automatically saved, a vector address corresponding to the interrupt request is generated, and the desired interrupt program is executed. In microcombi routers, even if an interrupt occurs due to a malfunction and a vector address generation start signal is input to the vector address generator, if there is no interrupt signal, a vector address for power-on reset is generated. An interrupt control circuit characterized by:
JP57042691A 1982-03-19 1982-03-19 Interruption controlling circuit Granted JPS58161046A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP57042691A JPS58161046A (en) 1982-03-19 1982-03-19 Interruption controlling circuit

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP57042691A JPS58161046A (en) 1982-03-19 1982-03-19 Interruption controlling circuit

Publications (2)

Publication Number Publication Date
JPS58161046A true JPS58161046A (en) 1983-09-24
JPH0259492B2 JPH0259492B2 (en) 1990-12-12

Family

ID=12643058

Family Applications (1)

Application Number Title Priority Date Filing Date
JP57042691A Granted JPS58161046A (en) 1982-03-19 1982-03-19 Interruption controlling circuit

Country Status (1)

Country Link
JP (1) JPS58161046A (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPH02240758A (en) * 1989-03-14 1990-09-25 Fujitsu Ltd Interruption vector control system
US5500809A (en) * 1992-08-31 1996-03-19 Sharp Kabushiki Kaisha Microcomputer system provided with mechanism for controlling operation of program

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPH02240758A (en) * 1989-03-14 1990-09-25 Fujitsu Ltd Interruption vector control system
US5500809A (en) * 1992-08-31 1996-03-19 Sharp Kabushiki Kaisha Microcomputer system provided with mechanism for controlling operation of program

Also Published As

Publication number Publication date
JPH0259492B2 (en) 1990-12-12

Similar Documents

Publication Publication Date Title
US4924382A (en) Debugging microprocessor capable of switching between emulation and monitor without accessing stack area
JP3676882B2 (en) Microprocessor and its peripheral devices
US5361348A (en) Debug circuit of a signal processor
KR960035262A (en) Method and apparatus for selective control of interrupt wait in data processing system
US4095268A (en) System for stopping and restarting the operation of a data processor
JPS6019220A (en) Microcomputer
US4807185A (en) Stack pointer control circuit
JP2001067235A (en) Interruption controller and microcomputer
JPS58161046A (en) Interruption controlling circuit
JPS5826043B2 (en) Processor reset method
JPS5916054A (en) Microprocessor
JPH0814779B2 (en) Initialization method for arithmetic and control unit
JPH0573296A (en) Microcomputer
KR100442290B1 (en) A circuit for controlling program counter
JPH0764886A (en) Processor provided with serial interface device
JPH01184545A (en) Microprocessor
JPH0531773B2 (en)
JP2004280789A (en) Semiconductor integrated circuit device, and microcomputer development supporting device
JPH0744407A (en) Backup device for microcomputer
JPH0554137B2 (en)
JPH0683986A (en) Single chip microcomputer
JPH03208132A (en) Single chip microcomputer
JPS62296236A (en) Interruption processor for microprocessor
JPS63298657A (en) Ipl system
JP2000076078A (en) Microcomputer