JPH06332729A - Runaway detecting device - Google Patents
Runaway detecting deviceInfo
- Publication number
- JPH06332729A JPH06332729A JP5118900A JP11890093A JPH06332729A JP H06332729 A JPH06332729 A JP H06332729A JP 5118900 A JP5118900 A JP 5118900A JP 11890093 A JP11890093 A JP 11890093A JP H06332729 A JPH06332729 A JP H06332729A
- Authority
- JP
- Japan
- Prior art keywords
- runaway
- signal
- access
- runaway detection
- mpu
- 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
Links
Landscapes
- Debugging And Monitoring (AREA)
Abstract
Description
【0001】[0001]
【産業上の利用分野】本発明は、マイクロプロセッサを
中心とする制御システムにおける暴走検知装置に関する
ものである。BACKGROUND OF THE INVENTION 1. Field of the Invention The present invention relates to a runaway detecting device in a control system centering on a microprocessor.
【0002】[0002]
【従来の技術】マイクロプロセッサ(以下MPUとい
う)を中心とするシステムの主要部はMPU本体、プロ
グラムを格納するメモリ部およびハードウェアにおける
制御を行う制御部からなる。このようなシステムにおい
ては動作中に外部からのノイズなどの影響でプログラム
が正常に動作しなくなることがある。これは一般に暴走
と呼ばれている。一旦暴走が発生した場合はこれを検知
し、システムをリセットした後再び起動からやり直す必
要がある。暴走を検知し、システムのリセットを行う回
路を暴走検知回路と呼ぶ。2. Description of the Related Art The main part of a system centering on a microprocessor (hereinafter referred to as MPU) consists of an MPU main body, a memory part for storing programs, and a control part for controlling hardware. In such a system, the program may not operate normally due to the influence of external noise during operation. This is commonly called a runaway. When a runaway occurs once, it is necessary to detect it, reset the system, and restart the system. A circuit that detects a runaway and resets the system is called a runaway detection circuit.
【0003】従来の暴走の検知方法としては、タイマを
利用し周期アクセスを行うものなどが知られている。図
3に従来の暴走検知装置の一例を示す回路図である。1
は周期アクセスによる暴走検知を行うためのフリップフ
ロップ回路であり、2はフリップフロップ回路1によっ
て暴走が検知されたときにシステムにリセットをかける
ための信号をつくるフリップフロップ回路であり、3は
論理積である。またAはタイマによってつくられた一定
間隔で発生するパルス信号であり、BはMPUからの解
除信号であり、ソフトウェアによって設定する。Cはシ
ステムクロックであり、パルス信号Aはこのシステムク
ロックCに同期しているものとする。DおよびEはそれ
ぞれフリップフロップ回路1および論理積3の出力信号
である。Fはシステムにリセットをかけるための出力信
号とする。図4に図3の回路のタイミングチャートを示
す。ここで信号Aは説明のために10msとする。As a conventional method of detecting runaway, there is known a method of performing periodic access using a timer. FIG. 3 is a circuit diagram showing an example of a conventional runaway detection device. 1
Is a flip-flop circuit for detecting runaway by periodic access, 2 is a flip-flop circuit for generating a signal for resetting the system when the flip-flop circuit 1 detects runaway, and 3 is a logical product Is. A is a pulse signal generated by a timer at regular intervals, B is a release signal from the MPU, and is set by software. C is a system clock, and the pulse signal A is assumed to be synchronized with this system clock C. D and E are output signals of the flip-flop circuit 1 and the logical product 3, respectively. F is an output signal for resetting the system. FIG. 4 shows a timing chart of the circuit of FIG. Here, the signal A is 10 ms for explanation.
【0004】第1回目の信号Aが発生したところにおい
て信号Dがイネーブルになっているが、信号Bが発生し
ているために信号Dは解除される第2回目も同様であ
る。これが正常動作である。第3回目の信号Aが発生し
た後、第4回目の信号Aが発生するまでに信号Bが発生
しないために、信号Dは解除されず信号Eが発生する。
これを受けて信号Fがイネーブルとなり、システムにリ
セットがかかる。これが暴走を検知した動作である。The signal D is enabled when the signal A is generated for the first time, but the signal D is canceled because the signal B is generated for the second time. This is normal operation. Since the signal B is not generated until the fourth signal A is generated after the third signal A is generated, the signal D is not released and the signal E is generated.
In response to this, the signal F is enabled and the system is reset. This is the operation that detected the runaway.
【0005】以上説明した回路はシステムの起動時から
すぐに10ms毎の解除信号BをMPUから発生させな
ければならないが、システムの起動時は、ソフトウェア
においてメモリのチェックなどを行うために解除信号が
間に合わない場合が起こる。この対策のために図5に示
すような暴走検知許可回路を設ける。図5において1〜
3およびA〜Fは図3と同様である。4は暴走検知許可
用のフリップフロップ回路であり、5は論理積である。
また、GはMPUが出力する暴走検知許可信号であり、
Hはフリップフロップ回路4の出力信号であり、Iは論
理積5の出力信号である。この回路において、MPUが
暴走検知許可信号Gをイネーブルにしない限り暴走検知
装置は動作しない。すなわち、ソフトウェアの指示によ
って暴走検知装置の動作開始を変更できることになる。In the circuit described above, the release signal B must be generated from the MPU at intervals of 10 ms immediately after the system is started up. However, when the system is started up, the release signal is sent in order to check the memory by software. There are cases where it will not be in time. As a countermeasure, a runaway detection permission circuit as shown in FIG. 5 is provided. 1 to 1 in FIG.
3 and A to F are the same as in FIG. Reference numeral 4 is a runaway detection permission flip-flop circuit, and 5 is a logical product.
Further, G is a runaway detection permission signal output from the MPU,
H is an output signal of the flip-flop circuit 4, and I is an output signal of the logical product 5. In this circuit, the runaway detection device does not operate unless the MPU enables the runaway detection permission signal G. That is, it is possible to change the operation start of the runaway detection device according to the instruction of the software.
【0006】[0006]
【発明が解決しようとする課題】システムの起動時には
電圧変動や、ICの未接続などの影響で比較的暴走が発
生しやすい。しかし、従来の暴走検知装置においては、
周期アクセスに対してMPUからの暴走検知許可の制御
を行わない図3の場合は、起動時に正常動作にもかかわ
らず誤って暴走とみなすことがあり、一方暴走検知許可
制御を行う図4の場合には、起動時の暴走を検知できな
いという問題点を有していた。When the system is started up, a runaway is relatively likely to occur due to voltage fluctuations, unconnected ICs and the like. However, in the conventional runaway detection device,
In the case of FIG. 3 which does not control the runaway detection permission from the MPU for the cyclic access, it may be mistakenly regarded as a runaway despite the normal operation at startup, while in the case of FIG. 4 which performs the runaway detection permission control. Had a problem that runaway at startup could not be detected.
【0007】本発明は上記問題を解決するもので、シス
テムの起動時に周期アクセスの間に合わない処理をMP
Uが行う場合も、正常に暴走検知を行うことができる暴
走検知装置を提供することを目的とする。The present invention solves the above-mentioned problems, and it is possible to perform processing that cannot be performed in time for periodic access at system startup.
It is an object of the present invention to provide a runaway detection device that can normally detect runaway even when U performs it.
【0008】[0008]
【課題を解決するための手段】上記課題を解決するため
に、本発明の暴走検知装置は、MPUのメモリマップ上
に暴走検知許可を行うまではアクセスを行わない領域を
設けておき、その領域にMPUがアクセスを行った際に
暴走であるとみなし、さらに、周期アクセスによる暴走
検知許可を行った以降は、起動時に禁止していたメモリ
マップ上の領域にアクセスしても暴走とみなさないよう
にしたものである。In order to solve the above-mentioned problems, the runaway detecting apparatus of the present invention provides an area on the memory map of the MPU which is not accessed until the runaway detection is permitted, and the area is provided. When the MPU makes an access, it is considered to be a runaway, and after the runaway detection permission by the periodical access is made, even if an area on the memory map that was prohibited at startup is accessed, it is not considered a runaway. It is the one.
【0009】[0009]
【作用】本発明は、上記した構成により、システムの起
動時に周期アクセスの間に合わない処理をMPUが行う
場合も、正常に暴走検知を行うことができる。According to the present invention, due to the above-mentioned configuration, even when the MPU performs a process that is not in time for the periodic access when the system is activated, the runaway can be detected normally.
【0010】[0010]
【実施例】以下本発明の1暴走検知装置の一実施例につ
いて、図を参照しながら説明する。図1は本発明の一実
施例の暴走検知装置の回路図である。図1において、1
〜5、A〜Iは従来例と同様である。6はメモリマップ
上の特定の領域(以下リザーブ領域とする)のアクセス
を検知するためのフリップフロップであり、7は論理
積、8は論理和である。Jはリザーブ領域にアクセスが
あったことを示す信号であり、Kはフリップフロップ回
路4からの暴走検知許可信号Gの反転信号Hバーとリザ
ーブ領域のアクセス信号Jとの論理積の出力であり、L
はリザーブ領域の暴走検知信号であり、Mは周期アクセ
スによる暴走検知信号Eと、リザーブ領域からの暴走検
知信号Lとの論理和の出力信号である。DESCRIPTION OF THE PREFERRED EMBODIMENTS An embodiment of one runaway detecting device of the present invention will be described below with reference to the drawings. FIG. 1 is a circuit diagram of a runaway detecting device according to an embodiment of the present invention. In FIG. 1, 1
5 and A to I are the same as in the conventional example. Reference numeral 6 is a flip-flop for detecting access to a specific area (hereinafter, reserved area) on the memory map, 7 is a logical product, and 8 is a logical sum. J is a signal indicating that the reserved area has been accessed, K is an output of the logical product of the inverted signal H bar of the runaway detection permission signal G from the flip-flop circuit 4 and the access signal J of the reserved area, L
Is a runaway detection signal in the reserve area, and M is an output signal of the logical sum of the runaway detection signal E due to periodic access and the runaway detection signal L from the reserve area.
【0011】図2(a)に図1の回路の周期アクセスに
よる暴走検知のタイミングチャートを、図2(b)に図
1の回路のリザーブ領域アクセスによる暴走検知のタイ
ミングチャートを示す。図2(a)において、暴走検知
許可信号Gがディセーブルのときには解除信号Bが発生
しなくても暴走とは見なさずシステムにリセットをかけ
る信号Fはイネーブルにならない。また、暴走検知許可
信号Gをイネーブルにするとアクセス信号Jが発生して
も暴走にはならない。すなわちこのときリザーブ領域に
何らかのデバイスを割り付けてもシステムへの影響はな
い。しかし、解除信号Bが発生しないときは暴走とな
り、信号Fはイネーブルとなる。一方図2(b)におい
て、暴走検知許可信号Gがディセーブルのとき、アクセ
ス信号Jが発生すると信号A、信号Bの如何に関わらず
暴走となり、信号Fはイネーブルとなる。FIG. 2A shows a timing chart of runaway detection by periodic access of the circuit of FIG. 1, and FIG. 2B shows a timing chart of runaway detection by reserved area access of the circuit of FIG. In FIG. 2A, when the runaway detection permission signal G is disabled, even if the release signal B is not generated, it is not regarded as runaway and the signal F for resetting the system is not enabled. When the runaway detection permission signal G is enabled, the runaway does not occur even if the access signal J is generated. That is, at this time, assigning any device to the reserved area does not affect the system. However, when the release signal B is not generated, the runaway occurs and the signal F is enabled. On the other hand, in FIG. 2B, when the runaway detection permission signal G is disabled, when the access signal J is generated, the runaway occurs regardless of the signals A and B, and the signal F is enabled.
【0012】これにより、図1の回路においてはリザー
ブ領域に割り付けているデバイスに対し、MPUが暴走
検知許可信号をイネーブルにするまでは一切のアクセス
を行わず、暴走検知許可信号をイネーブルにした後にア
クセスを許可することになる。As a result, in the circuit of FIG. 1, no access is made to the device allocated to the reserved area until the MPU enables the runaway detection permission signal, and after the runaway detection permission signal is enabled. Access will be granted.
【0013】[0013]
【発明の効果】以上のように本発明によれば、MPUの
メモリマップ上に暴走検知許可を行うまではアクセスを
行わない領域を設けておき、その領域にMPUがアクセ
スを行った際に暴走であるとみなし、さらに周期アクセ
スによる暴走検知許可を行った以降は、起動時に禁止し
ていたメモリマップ上の領域にアクセスしても暴走とみ
なさないようにするものであり、これにより、システム
の起動時に周期アクセスの間に合わない処理をMPUが
行う場合も、正常に暴走検知を行うことができるもので
ある。As described above, according to the present invention, an area that is not accessed until the runaway detection is permitted is provided on the memory map of the MPU, and the runaway occurs when the MPU accesses the area. After the runaway detection is permitted by the periodical access, even if an area on the memory map that was prohibited at startup is accessed, it is not considered as a runaway. Even when the MPU performs processing that is not in time for periodic access at the time of startup, the runaway can be detected normally.
【図1】本発明の一実施例の暴走検知装置の回路図FIG. 1 is a circuit diagram of a runaway detection device according to an embodiment of the present invention.
【図2】図1の暴走検知装置のタイムチャートFIG. 2 is a time chart of the runaway detection device of FIG.
【図3】従来の暴走検知装置の一例を示す回路図FIG. 3 is a circuit diagram showing an example of a conventional runaway detection device.
【図4】図3の従来の暴走検知装置のタイムチャートFIG. 4 is a time chart of the conventional runaway detection device of FIG.
【図5】従来の暴走検知装置の他の例を示す回路図FIG. 5 is a circuit diagram showing another example of a conventional runaway detection device.
1 フリップフロップ回路 2 フリップフロップ回路 3 論理積 4 フリップフロップ回路 5 論理積 6 フリップフロップ回路 7 論理積 8 論理和 A タイマによるパルス信号 B MPUからの解除信号 C システムクロック D フリップフロップ1の出力信号 E 論理積3の出力信号 F リセットをかける出力信号 G 暴走検知許可信号 H フリップフロップ4の出力信号 I 論理積5の出力信号 J リザーブ領域のアクセス信号 K 論理積7の出力信号 L リザーブ領域の暴走検知信号 M 論理和8の出力信号 1 Flip-flop circuit 2 Flip-flop circuit 3 Logical product 4 Flip-flop circuit 5 Logical product 6 Flip-flop circuit 7 Logical product 8 Logical sum A Pulse signal by timer B Cancel signal from MPU C System clock D Output signal of flip-flop 1 E Output signal of logical product 3 F Output signal for resetting G Output signal of runaway detection H Output signal of flip-flop 4 Output signal of logical product 5 J Access signal of reserved area K Output signal of logical product 7 L Runaway detection of reserved area Signal M Output signal of logical OR 8
Claims (1)
るための暴走検知許可信号と、上記マイクロプロセッサ
のメモリマップ上に割り付けた前記暴走検知許可信号を
イネーブルにするまではアクセスを行わない領域とを有
し、前記領域に前記マイクロプロセッサがアクセスを行
った際に前記暴走検知許可信号がイネーブルでないとき
には暴走であるとみなし、イネーブルのときには暴走と
みなさない暴走検知装置。1. A runaway detection permission signal for detecting a runaway of a microprocessor, and an area which is not accessed until the runaway detection permission signal allocated on the memory map of the microprocessor is enabled. However, when the microprocessor accesses the area, the runaway detection device is considered to be runaway when the runaway detection permission signal is not enabled, and is not considered to be runaway when enabled.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP11890093A JP3176477B2 (en) | 1993-05-21 | 1993-05-21 | Runaway detection device |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP11890093A JP3176477B2 (en) | 1993-05-21 | 1993-05-21 | Runaway detection device |
Publications (2)
Publication Number | Publication Date |
---|---|
JPH06332729A true JPH06332729A (en) | 1994-12-02 |
JP3176477B2 JP3176477B2 (en) | 2001-06-18 |
Family
ID=14747955
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
JP11890093A Expired - Fee Related JP3176477B2 (en) | 1993-05-21 | 1993-05-21 | Runaway detection device |
Country Status (1)
Country | Link |
---|---|
JP (1) | JP3176477B2 (en) |
-
1993
- 1993-05-21 JP JP11890093A patent/JP3176477B2/en not_active Expired - Fee Related
Also Published As
Publication number | Publication date |
---|---|
JP3176477B2 (en) | 2001-06-18 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
JPH0743653B2 (en) | Interrupt controller | |
KR960035263A (en) | Multi-program execution control device and method | |
KR960705271A (en) | Execution of data processing instructions (EXECUTION OF DATA PROCESSING INSTRUCTIONS) | |
GB2248953A (en) | Dual-processor programmable controller and method of controlling the same | |
US5928348A (en) | Method of processing interrupt requests and information processing apparatus using the method | |
JPH06332729A (en) | Runaway detecting device | |
US20080059666A1 (en) | Microcontroller and debugging method | |
JPH0355657A (en) | Shared memory access method for multi-task/multi-processor system | |
JPH0635757A (en) | Abnormality detector of cpu | |
JPH02171935A (en) | Runaway preventing circuit for microprocessor | |
JP2903601B2 (en) | Microcomputer with built-in ROM | |
JP2570900B2 (en) | Access control device and access control method | |
JPH05181813A (en) | Exclusive control bit control system | |
JPS63250753A (en) | Memory access checking system | |
JPH01223521A (en) | Large scale integrated circuit | |
JPH03266110A (en) | Resetting device for computer | |
JPH01265337A (en) | Watchdog timer | |
JPH0251742A (en) | Preventing system for program runaway | |
JPH05216701A (en) | Recovery time adjusting circuit for input/output instruction | |
JPH06309182A (en) | Interrupt processing method | |
JPS6155769A (en) | Bus control system | |
JPH03100736A (en) | Patrol diagnostic device | |
JPH04517A (en) | Power supply control device | |
JPS6288038A (en) | Device for preventing erroneous display in microcomputer | |
JPS60204004A (en) | Sequence controller |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
LAPS | Cancellation because of no payment of annual fees |