JP2829183B2 - Microprocessor device - Google Patents

Microprocessor device

Info

Publication number
JP2829183B2
JP2829183B2 JP4055522A JP5552292A JP2829183B2 JP 2829183 B2 JP2829183 B2 JP 2829183B2 JP 4055522 A JP4055522 A JP 4055522A JP 5552292 A JP5552292 A JP 5552292A JP 2829183 B2 JP2829183 B2 JP 2829183B2
Authority
JP
Japan
Prior art keywords
time
watchdog timer
bit
program
state
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.)
Expired - Fee Related
Application number
JP4055522A
Other languages
Japanese (ja)
Other versions
JPH05257748A (en
Inventor
定俊 十河
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.)
Yokogawa Electric Corp
Original Assignee
Yokogawa Electric 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 Yokogawa Electric Corp filed Critical Yokogawa Electric Corp
Priority to JP4055522A priority Critical patent/JP2829183B2/en
Publication of JPH05257748A publication Critical patent/JPH05257748A/en
Application granted granted Critical
Publication of JP2829183B2 publication Critical patent/JP2829183B2/en
Anticipated expiration legal-status Critical
Expired - Fee Related legal-status Critical Current

Links

Landscapes

  • Debugging And Monitoring (AREA)

Description

【発明の詳細な説明】DETAILED DESCRIPTION OF THE INVENTION

【0001】[0001]

【産業上の利用分野】本発明は、ウォッチドックタイマ
ーを備えたマイクロプロセッサ装置に関し、更に詳しく
は、プログラムの暴走の外部通知あるいは暴走を復帰さ
せる手段として広く使用されているウォッチドックタイ
マー(WDT)を、マルチタスクが走行するマイクロプ
ロセッサ装置(例えば分散形制御装置など)で有効に使
用できるようにしたマイクロプロセッサ装置に関する。
BACKGROUND OF THE INVENTION 1. Field of the Invention The present invention relates to a microprocessor device provided with a watchdog timer, and more particularly to a watchdog timer (WDT) which is widely used as an external notice of program runaway or a means for restoring runaway. The present invention relates to a microprocessor device which can be effectively used in a microprocessor device (for example, a distributed control device or the like) on which a multitask runs.

【0002】[0002]

【従来の技術】ウォッチドックタイマーは、一般的にハ
ードウェアによって構成され、マイクロプロセッサ上で
走行するプログラムが定めた「ウォッチドックタイマー
をリセットする」入出力処理(I/O処理)を一定時間
以上行わない時に、「ウォッチドックタイマーがタイム
アップ」し、外部にマイクロプロセッサの動作が異常で
あることを示す警報を出力するように構成されている。
この場合、マイクロプロセッサを直ちに停止するなどの
処理を行いプログラムが暴走するのを防止するのが一般
的である。
2. Description of the Related Art A watchdog timer is generally constituted by hardware, and performs input / output processing (I / O processing) for resetting a watchdog timer defined by a program running on a microprocessor for a predetermined time or more. When not performed, the "watchdog timer expires" and an alarm is output to the outside indicating that the operation of the microprocessor is abnormal.
In this case, processing such as immediately stopping the microprocessor is generally performed to prevent the program from running away.

【0003】従って、ウォッチドックタイマーを用いる
ようなプロセッサ装置においては、プログラムは、一定
の周期以上で前述したような、「ウォッチドックタイマ
ーをリセットする」入出力処理を行う必要がある。ここ
で、ウォッチドックタイマーに設定されるタイムアップ
時間は、プロセッサ上を走行するプログラムの基本周期
と、各処理によって間延びした場合の許容される時間等
を考慮して決定される。
Therefore, in a processor device using a watchdog timer, the program needs to perform the above-mentioned "reset the watchdog timer" input / output processing at a fixed cycle or more. Here, the time-up time set in the watchdog timer is determined in consideration of the basic cycle of the program running on the processor, the allowable time when the process is extended by each process, and the like.

【0004】図4は、従来のこの種のウォッチドックタ
イマーを備えたマイクロプロセッサ装置において、ウォ
ッチドックタイマーのリセット動作の一例を示すフロー
チャートである。
FIG. 4 is a flowchart showing an example of a reset operation of a watchdog timer in a conventional microprocessor device having such a watchdog timer.

【0005】ここでは、プロセッサによって実行される
タスクを実現するプログラムが3個存在していて、それ
ぞれが持つ基本周期、すなわちプログラムSYSMは、
100msec、プログラムCTLTは、1sec、プ
ログラムPMONは1sec毎に、WDTサブルーチン
を呼ぶように構成してある。
Here, there are three programs for realizing the tasks to be executed by the processor, and the basic cycle of each program, that is, the program SYSM, is
The program CTLT is configured to call the WDT subroutine every 1 second, and the program PMON is called every 1 second.

【0006】ウォッチドックタイマーのサブルーチン
は、それが呼ばれると、予め用意されているリセットパ
ターンを示すレジスタの対応ビット(この例では3個の
プログラムに対応して、a,b,cの3個ある)をオン
にする。そして、レジスタに用意された3つのビット
a,b,cの全てがオンがなったら、すなわち、3個の
プログラムの全てからウォッチドックタイマーのサブル
ーチンが呼ばれたら、ウォッチドックタイマーを構成し
ているハードウェアに対して、そのリセットを要求す
る。また、各ビットa,b.cを全てクリアする。
When the subroutine of the watchdog timer is called, there are three corresponding bits (a, b, and c corresponding to three programs in this example) of a register indicating a reset pattern prepared in advance. ) Is turned on. Then, if all of the three bits a, b, and c prepared in the register are turned on, that is, if the subroutine of the watchdog timer is called from all three programs, the watchdog timer is configured. Request the hardware to reset it. Each bit a, b. Clear all c.

【0007】これにより、ウォッチドックタイマーは、
マイクロプロセッサの動作が正常であれば、基本的に1
秒に一度はリセットされることとなり、タイムアップす
ることはない。
Thus, the watchdog timer is
If the operation of the microprocessor is normal, basically 1
It will be reset once every second and the time will not be up.

【0008】これに対して、3つのタスクを実現するプ
ログラムのいずれか1つのプログラムでもその走行を停
止すると、リセットパターンを示すレジスタのビット
a,b,cのいずれかがオンとならず、ウォッチドック
タイマーはリセットされなくなる。このために、タイム
アップ時間になった時点でウォッチドックタイマーはタ
イムアップし、プロセッサ異常を出力する。
On the other hand, if the running of any one of the programs for realizing the three tasks is stopped, any of the bits a, b, and c of the register indicating the reset pattern is not turned on, and the watch The dock timer no longer resets. For this reason, when the time-up time comes, the watchdog timer times out, and outputs a processor abnormality.

【0009】ここで、ウォッチドックタイマーに設定さ
れるタイムアップ時間は、プロセッサ上を走行するプロ
グラムの基本周期と、各処理によって間延びする場合の
許容される時間等を考慮して決定されるが、例えばマン
マシンインターフェイス機能を有するプロセッサ装置に
おいては、キーボードやその他のポインティングディバ
イスからの信号を優先して処理するタスクが多くなり、
このためにプログラムの定周期の間延びする許容度が大
きくなる。この為に、ウォッチドックタイマーに設定す
るタイムアップ時間は、間延びする許容度を考慮して例
えば10sec程度と長く設定しておくこととなる。
Here, the time-up time set in the watchdog timer is determined in consideration of the basic cycle of the program running on the processor and the allowable time when the processing is delayed by each processing. For example, in a processor device having a man-machine interface function, there are many tasks that preferentially process signals from a keyboard and other pointing devices,
For this reason, the tolerance that extends during the fixed period of the program is increased. For this reason, the time-up time set in the watchdog timer is set to be long, for example, about 10 seconds in consideration of the prolonged tolerance.

【0010】[0010]

【発明が解決しようとする課題】しかしながら、ウォッ
チドックタイマーのタイムアップ時間を余り長く設定す
ると、プログラムの暴走を検知するまでの時間が長くな
り、致命的なプログラムの暴走を停止できなくなる不具
合が生ずる。
However, if the time-up time of the watchdog timer is set too long, the time required to detect a program runaway becomes longer, and a fatal program runaway cannot be stopped. .

【0011】本発明は、このような点に鑑みてなされた
もので、ウォッチドックタイマーのタイムアップ時間
を、見掛上長い時間に設定できるようにしながら、致命
的なクロックの停止やその他のトラブルの検出を確実に
行なえるウォッチドックタイマーを備えたマイクロプロ
セッサ装置を提供することを目的とする。
SUMMARY OF THE INVENTION The present invention has been made in view of the above-described circumstances, and allows a time-out time of a watchdog timer to be set to an apparently long time, while causing a fatal clock stop and other troubles. It is an object of the present invention to provide a microprocessor device provided with a watchdog timer capable of surely detecting an error.

【0012】[0012]

【課題を解決するための手段】このような目的を達成す
る本発明は、プログラムの正常な走行を監視するウォッ
チドックタイマーを備えたマルチタスクを実行するマイ
クロプロセッサ装置であって、各タスクを実行するプロ
グラムの正常走行によりオンになるビットをそれぞれの
プログラムに対応して有するリセットパターンレジスタ
手段と、このリセットパターンレジスタ手段の各ビット
の状態を所定の周期で参照するビット参照手段と、この
ビット参照手段によるビット参照の時点で、いずれかの
ビットがオフ状態のままである時間を測定するオフ状態
時間測定手段と、前記ビット参照手段により全ての参照
ビットがオン状態を示しているとき前記ウォッチドック
タイマーにリセット信号を出力すると共に、前記オフ状
態時間測定手段が測定したいずれかのビットがオフ状態
である時間が所定の時間以上継続する場合、前記ウォッ
チドックタイマーへのリセット信号出力を行わないよう
にするWDT制御手段とを設けたことを特徴とするマイ
クロプロセッサ装置である。
SUMMARY OF THE INVENTION In order to achieve the above object, the present invention relates to a microprocessor device for executing a multitask having a watchdog timer for monitoring a normal running of a program. Reset pattern register means having a bit corresponding to each program to be turned on by normal running of a program to be executed, bit reference means for referring to the state of each bit of the reset pattern register means at a predetermined cycle, Means for measuring the time during which any bit remains off at the time of bit reference by the means; and the watchdog when all reference bits indicate an on state by the bit reference means. A reset signal is output to the timer, and the off-state time measuring means is A microprocessor provided with WDT control means for not outputting a reset signal to the watchdog timer when the time during which any of the specified bits is in the off state continues for a predetermined time or more. Device.

【0013】[0013]

【作用】ウォッチドックタイマーのタイムアップ時間
は、それを長く設定すればそれだけ、各種のプログラム
の定周期の間延び許容度が大きくなるが、致命的なプロ
グラムの停止の検出が遅れる。
The longer the time period of the watchdog timer is set, the longer the set period of the various programs becomes, the longer the tolerance increases, but the detection of a fatal program stop is delayed.

【0014】ビット参照手段は、リセットパターンレジ
スタ手段の各ビット状態を所定の周期で参照している。
オフ状態時間測定手段は、リセットパターンレジスタ手
段のいずれかのビット状態がオフ状態のままであれば、
カウンタを計数してそのオフ状態が継続する時間を測定
する。
The bit reference means refers to each bit state of the reset pattern register means at a predetermined cycle.
The off-state time measuring means, if any bit state of the reset pattern register means remains off,
The counter is counted to measure the time during which the off state continues.

【0015】WDT制御手段は、ビット参照手段からの
信号を受け、リセットパターンレジスタ手段の各ビット
状態が全てオン状態になったとき、ウォッチドックタイ
マーにリセット信号を出力する。また、オフ状態時間測
定手段が測定したいずれかのビットがオフ状態である時
間が、所定の時間以上継続する場合ウォッチドックタイ
マーへのリセット信号出力を行なわないようにする。
The WDT control means receives a signal from the bit reference means, and outputs a reset signal to the watchdog timer when all the bit states of the reset pattern register means are turned on. Further, when the time during which any of the bits measured by the off-state time measuring means is in the off state continues for a predetermined time or more, the reset signal is not output to the watchdog timer.

【0016】これにより、ウォッチドックタイマーのタ
イムアップ時間を見掛上は所定の時間の長い時間に設定
でき、プログラムの停止等の致命的な事態では、早いタ
イムアップ時間が設定されることとなる。
Thus, the time-up time of the watchdog timer can be apparently set to a long time, and in a fatal situation such as a stop of the program, a fast time-up time is set. .

【0017】[0017]

【実施例】以下、図面を用いて本発明の実施例を詳細に
説明する。図1は、本発明の一実施例を示す構成ブロッ
ク図である。図において、1はマイクロプロセッサ(C
PU)であり、ここでは、3個のタスク1,タスク2,
タスク3を実行しているものとし、各タスクを実現する
主要な3つのプログラム11,12,13は、それぞれ
0.1sec、1sec,1secの周期を基本周期と
して起動されている。2はこのマイクロプロセッサ1の
動作を監視するウォッチドックタイマー(WDT)であ
る。
Embodiments of the present invention will be described below in detail with reference to the drawings. FIG. 1 is a configuration block diagram showing one embodiment of the present invention. In the figure, 1 is a microprocessor (C
PU), where three tasks 1, task 2,
It is assumed that the task 3 is executed, and the three main programs 11, 12, and 13 for realizing each task are activated with a cycle of 0.1 sec, 1 sec, and 1 sec, respectively, as a basic cycle. Reference numeral 2 denotes a watchdog timer (WDT) for monitoring the operation of the microprocessor 1.

【0018】3は各タスクを実行するプログラム11,
12,13の正常走行によりオンになるビットa,b,
cをそれぞれのプログラムに対応して有するリセットパ
ターンレジスタ手段、4はリセットパターンレジスタ手
段3の各ビットa,b,cの状態を所定の周期、例えば
100msecの周期で参照するビット参照手段、5は
ビット参照手段4によるビット参照の時点で、いずれか
のビットがオフ状態のままである時間を測定するオフ状
態時間測定手段で、カウンタ6を有している。
3 is a program 11 for executing each task,
Bits a, b, which are turned on by normal running of 12, 13
reset pattern register means 4 having c corresponding to each program; 4, bit reference means for referring to the state of each bit a, b, c of the reset pattern register means 3 at a predetermined cycle, for example, a cycle of 100 msec; Off-state time measuring means for measuring the time during which any bit remains off at the time of bit reference by the bit referring means 4 and having a counter 6.

【0019】7はビット参照手段4により全ての参照ビ
ットがオン状態を示しているとき、ウォッチドックタイ
マー2にリセット信号を出力し、また、オフ状態時間測
定手段5が測定したいずれかのビットがオフ状態である
時間が、所定の時間以上継続する場合、ウォッチドック
タイマー2へのリセット信号の出力を行なわないように
するWDT制御手段である。
Reference numeral 7 denotes a reset signal which is output to the watchdog timer 2 when all the reference bits indicate the ON state by the bit reference means 4, and any one of the bits measured by the OFF state time measuring means 5 is WDT control means for preventing the reset signal from being output to the watchdog timer 2 when the off state continues for a predetermined time or more.

【0020】ここで、ビット参照手段4〜WDT制御手
段7は、マイクロプロセッサ1とは別のブロックで示し
てあるが、マイクロプロセッサ1内のプログラムによっ
て実現するようにしてもよい。
Here, the bit reference means 4 to the WDT control means 7 are shown in separate blocks from the microprocessor 1, but may be realized by a program in the microprocessor 1.

【0021】このように構成した装置の動作を説明すれ
ば、以下の通りである。図2は、マイクロプロセッサ1
が行なう動作と、ウォッチドックタイマーのリセット動
作の一例を示すフローチャートである。
The operation of the above-configured device will be described below. FIG. 2 shows a microprocessor 1
5 is a flowchart showing an example of the operation performed by the device and a reset operation of the watchdog timer.

【0022】マイクロプロセッサ1は、各プログラム1
1,12,13により、タスク1,タスク2,タスク3
がそれぞれの基本周期で実行され、マルチタスクを実現
している。各タスクが終了すると、その都度、リセット
パターンレジスタ3の対応するビットa,b,cをオン
「1」にセットする(ステップ1)。
The microprocessor 1 controls each program 1
Task 1, task 2, task 3
Are executed in each basic cycle to realize multitasking. When each task is completed, each time the corresponding bits a, b, and c of the reset pattern register 3 are set to ON "1" (step 1).

【0023】ウォッチドックタイマーのリセット動作を
行なうフローチャートWDTRSTは、システムクロッ
クにより、100msec周期でコールされるサブルー
チンとなっていて、ビット参照手段4はこの周期で、リ
セットパターンレジスタ3の各ビットa,b,cのいず
れかが、オフ状態「0」のままか判断する(ステップ
2)。ここで、全てのビットa,b,cがいずれもオン
状態「1」の場合(すなわち各プログラムが正常に走行
していて、Noの判断の場合)、WDT制御手段7は、
全てのビットa,b,cをオフ状態「0」とし、カウン
タ6の計数値を0にクリアし(ステップ3)、ウォッチ
ドックタイマー2にリセット信号を出力する(ステップ
4)。これにより、ウォッチドックタイマー2は、リセ
ットされてタイムアップしない。
The flowchart WDTRST for performing the reset operation of the watchdog timer is a subroutine called at a period of 100 msec by the system clock, and the bit reference means 4 performs the bit a and b of the reset pattern register 3 at this period. , C remain off ("0") (step 2). Here, when all the bits a, b, and c are in the on state “1” (that is, when each program is running normally and the determination is No), the WDT control means 7
All bits a, b and c are turned off "0", the count value of the counter 6 is cleared to 0 (step 3), and a reset signal is output to the watchdog timer 2 (step 4). As a result, the watchdog timer 2 is reset and does not time up.

【0024】ステップ2において、いずれかのビットが
オンのままの場合(Yesの判断の場合)、オフ状態継
続時間測定手段5は、カウンタ6の計数値Tを1だけ更
新(T=T+1)し(ステップ5)、続いて、その計数
値Tが、以下の関係にあるか否かを判断する。
In step 2, if any one of the bits remains on (in the case of Yes), the off-state duration measuring means 5 updates the count value T of the counter 6 by 1 (T = T + 1). (Step 5) Subsequently, it is determined whether or not the count value T has the following relationship.

【0025】 (T+TWDT)<Tmax …(1) ただし、Tはカウンタの計数値 Tmaxは仕様上(見掛上)のWDTタイムアウト時間
で、例えば40が設定される。ここで計数値「1」は、
フローチャートWDTRSTが、システムクロックによ
り、100msec周期でコールされので、100ms
ecと等価であり、「40」は、4000msec(4
秒)に相当することとなる。
(T + TWDT) <Tmax (1) where T is the count value of the counter, and Tmax is a WDT timeout time on the specification (apparent), for example, 40 is set. Here, the count value “1” is
Since the flowchart WDTRST is called at a period of 100 msec by the system clock, 100 ms
ec, and “40” is 4000 msec (4
Second).

【0026】TWDTはハードウェア指定のWDT2の
タイムアウト時間で、例えば10(1000msec)
が設定される。ステップ6において、カウンタ6の計数
値Tが「30」(すなわち、全てのビットa,b,cが
オン状態でない状態、つまり、3タスクの少なくとも1
つが動いていない状況が、3000msec続いた状
態)未満であるとき(Yesの判断)、ステップ4に移
行し、WDT制御手段7はウォッチドックタイマー2に
リセット信号を出力する。これに対して、ステップ5に
おいて、カウンタ6の計数値Tが「30」以上であれば
(Noの判断)、ウォッチドックタイマー2に対してリ
セット信号を出力しない。
TWDT is a timeout period of WDT2 specified by hardware, for example, 10 (1000 msec)
Is set. In step 6, the count value T of the counter 6 is "30" (that is, all bits a, b, and c are not in the ON state, that is, at least one of the three tasks).
When the state where the one is not moving is less than 3000 msec (determination of Yes), the process proceeds to step 4, and the WDT control means 7 outputs a reset signal to the watchdog timer 2. On the other hand, in step 5, if the count value T of the counter 6 is “30” or more (No determination), the reset signal is not output to the watchdog timer 2.

【0027】以上のような動作により、ウォッチドック
タイマーのリセット動作を行なうサブルーチンWDTR
STが、WDT2のリセットを行わなくなるのは、連続
して30回(3sec)、サブルーチンWDTRSTが
コールされる間、全てのビットa,b,cがオン状態に
ならない時のみで、それは、3つのタスク中、いずれか
1つ以上が3sec間プログラム走行を停止したことを
示している場合となる。
With the above operation, the subroutine WDTR for resetting the watchdog timer is performed.
The ST does not reset the WDT2 only when all the bits a, b, and c are not turned on for 30 consecutive times (3 seconds) while the subroutine WDTRST is called. During the task, one or more of the tasks indicate that the program running has been stopped for 3 seconds.

【0028】そして、サブルーチンWDTRSTがウォ
ッチドックタイマー2をリセットしなくなった後、更に
カウンタの計数値Tが「10」、すなわち1sec、各
ビットa,b,cのいずれかが、オン状態にならない場
合、ウォッチドックタイマー2がタイムアップする。以
上により、見掛上のウォッチドックタイマー2のタイム
アップ時間は、4secとなる。
After the subroutine WDTRST does not reset the watchdog timer 2, the counter value T of the counter is "10", that is, 1 second, and any one of the bits a, b, and c does not turn on. , The watchdog timer 2 times out. As described above, the time-up time of the apparent watchdog timer 2 is 4 seconds.

【0029】これに対して、クロック停止や、サブルー
チンWDTRSTがコールされないなどの場合には、1
sec後ウォッチドックタイマー2はタイムアップす
る。このように、重大なトラブルであるクロック停止等
ではウォッチドックタイマーを1secと言った短いタ
イムアップ時間とするのに対して、タスクの走行停止等
のトラブルに対しては、4secと言った長いタイムア
ップ時間を設定することができる。
On the other hand, when the clock is stopped or the subroutine WDTRST is not called, 1
After sec, the watchdog timer 2 times out. In this way, the watchdog timer has a short time-up time of 1 sec for a serious trouble such as a clock stop, whereas a long time of 4 sec for a trouble such as a stoppage of a task. You can set up time.

【0030】図3は、本発明の他の実施例を示す動作の
フローチャートである。図2の実施例では、3つのタス
クに対していずれも4secのタイムアップ時間を設定
したものであるが、この実施例では、各タスクに対して
異なった仕様上(見掛上)のウォッチドックタイマータ
イムアップ時間Tmaxa,Tmaxb,Tmaxcを
それぞれ設定するように構成し、その為に、各ビット毎
にカウンタを設け、対応するビットのオフ状態継続時間
をそれぞれのカウンタで計測して、各ビット毎に前述し
た(1)式の関係を判断するようにしたものである。
FIG. 3 is a flowchart showing the operation of another embodiment of the present invention. In the embodiment of FIG. 2, a time-up time of 4 sec is set for each of the three tasks. In this embodiment, however, watchdogs of different specifications (apparent) are used for each task. The timer time-up time Tmaxa, Tmaxb, Tmaxc is configured to be set, respectively. For this purpose, a counter is provided for each bit, and the OFF state continuation time of the corresponding bit is measured by each counter. Then, the relationship of the above-mentioned equation (1) is determined.

【0031】なお、以上の実施例では、いずれも3つの
タスクを実行する例であるが、更に多数のタスクを実行
する場合も同様に適用することが可能である。
In each of the above embodiments, three tasks are executed. However, the present invention can be similarly applied to a case where more tasks are executed.

【0032】[0032]

【発明の効果】以上詳細に説明したように、本発明によ
れば、見掛上のウォッチドックタイマーのタイムアップ
時間をハードウェアの持つWDTタイムアップ時間の設
定変更を行うことなく設定可能であり、ウォッチドック
タイマーのタイムアップ時間を見掛上は長い時間に設定
することで、プログラムの定周期走行の間延びに対する
許容度が大きくでき、しかも、クロック停止等の致命的
な事態では、早いタイムアップ時間が設定できる。従っ
て、信頼性を維持しながら設計上の自由度が増大するマ
イクロプロセッサ装置を提供できる。
As described above in detail, according to the present invention, the apparent time-up time of the watchdog timer can be set without changing the setting of the WDT time-up time possessed by hardware. By setting the time-up time of the watchdog timer to a seemingly long time, the tolerance for the extension of the program during the fixed cycle run can be increased. Time can be set. Therefore, it is possible to provide a microprocessor device in which the degree of freedom in design increases while maintaining reliability.

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

【図1】本発明の一実施例を示す構成ブロック図であ
る。
FIG. 1 is a configuration block diagram showing one embodiment of the present invention.

【図2】マイクロプロセッサが行なう動作と、ウォッチ
ドックタイマーのリセット動作の一例を示すフローチャ
ートである。
FIG. 2 is a flowchart illustrating an example of an operation performed by a microprocessor and an operation of resetting a watchdog timer.

【図3】本発明の他の実施例を示す動作のフローチャー
トである。
FIG. 3 is an operation flowchart showing another embodiment of the present invention.

【図4】従来の装置におけるウォッチドックタイマーの
リセット動作の一例を示すフローチャートである。
FIG. 4 is a flowchart illustrating an example of a reset operation of a watchdog timer in a conventional device.

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

1 マイクロプロセッサ(CPU) 11,12,13 タスク1,タスク2,タスク3を実
行するプログラム 2 ウォッチドックタイマー(WDT) 3 リセットパターンレジスタ手段 4 ビット参照手段 5 オフ状態時間測定手段 6 カウンタ 7 WDT制御手段
Reference Signs List 1 Microprocessor (CPU) 11, 12, 13 Program for executing task 1, task 2, task 3 2 Watchdog timer (WDT) 3 Reset pattern register means 4 Bit reference means 5 Off state time measuring means 6 Counter 7 WDT control means

Claims (1)

(57)【特許請求の範囲】(57) [Claims] 【請求項1】 プログラムの正常な走行を監視するウォ
ッチドックタイマーを備えたマルチタスクを実行するマ
イクロプロセッサ装置であって、 各タスクを実行するプログラムの正常走行によりオンに
なるビットをそれぞれのプログラムに対応して有するリ
セットパターンレジスタ手段と、 このリセットパターンレジスタ手段の各ビットの状態を
所定の周期で参照するビット参照手段と、 このビット参照手段によるビット参照の時点で、いずれ
かのビットがオフ状態のままである時間を測定するオフ
状態時間測定手段と、 前記ビット参照手段により全ての参照ビットがオン状態
を示しているとき前記ウォッチドックタイマーにリセッ
ト信号を出力すると共に、前記オフ状態時間測定手段が
測定したいずれかのビットがオフ状態である時間が所定
の時間以上継続する場合、前記ウォッチドックタイマー
へのリセット信号出力を行わないようにするWDT制御
手段とを設けたことを特徴とするマイクロプロセッサ装
置。
1. A microprocessor device for executing a multitask having a watchdog timer for monitoring normal running of a program, wherein a bit which is turned on by normal running of a program for executing each task is included in each program. Corresponding reset pattern register means; bit reference means for referring to the state of each bit of the reset pattern register means at a predetermined cycle; and at the time of bit reference by the bit reference means, any bit is in an off state An off-state time measuring means for measuring the time during which the bit-off state remains, and outputting a reset signal to the watchdog timer when all the reference bits indicate the on-state by the bit reference means; and The time during which any of the bits measured by the To continue the constant time or more, the microprocessor device being characterized in that provided the WDT control unit not to perform the reset signal output to the watchdog timer.
JP4055522A 1992-03-13 1992-03-13 Microprocessor device Expired - Fee Related JP2829183B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP4055522A JP2829183B2 (en) 1992-03-13 1992-03-13 Microprocessor device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP4055522A JP2829183B2 (en) 1992-03-13 1992-03-13 Microprocessor device

Publications (2)

Publication Number Publication Date
JPH05257748A JPH05257748A (en) 1993-10-08
JP2829183B2 true JP2829183B2 (en) 1998-11-25

Family

ID=13001050

Family Applications (1)

Application Number Title Priority Date Filing Date
JP4055522A Expired - Fee Related JP2829183B2 (en) 1992-03-13 1992-03-13 Microprocessor device

Country Status (1)

Country Link
JP (1) JP2829183B2 (en)

Families Citing this family (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPH09212389A (en) * 1996-01-31 1997-08-15 Sumitomo Electric Ind Ltd Method and device for detecting abnormal state of computer system
JP6787658B2 (en) * 2015-10-16 2020-11-18 コイト電工株式会社 Processing equipment, traffic signal equipment and information display equipment
JP6788145B2 (en) * 2020-06-24 2020-11-18 コイト電工株式会社 Processing equipment, traffic signal equipment and information display equipment

Also Published As

Publication number Publication date
JPH05257748A (en) 1993-10-08

Similar Documents

Publication Publication Date Title
JPS5868163A (en) System trouble detection system
US20020116670A1 (en) Failure supervising method and apparatus
JP2829183B2 (en) Microprocessor device
JP2870250B2 (en) Microprocessor runaway monitor
JPS63224446A (en) Communication system
JPS6388660A (en) Microprocessor system
JPH11282725A (en) Computer
JPS6389941A (en) Monitor and control equipment for microprocessor applied equipment
JP2749994B2 (en) Numerical control unit
JPS63280345A (en) Detection of program abnormality
JPH041831A (en) Monitor system for program runaway
JP2731386B2 (en) Control device
JPH0426738B2 (en)
JPH0991170A (en) Fault detector
JPH02259845A (en) Processor
JPH0346853B2 (en)
JPH02130646A (en) Abnormality detecting system for cpu
JPH09319408A (en) Interrupt signal monitor circuit and programmable controller
JPH0612293A (en) Runaway preventing method for microcomputer
JPH0293738A (en) Interruption processing system
JPH0830490A (en) Monitoring method for starting of plural programs
JPS59148961A (en) Monitoring system of operation of processor
JPH02148233A (en) Microcomputer
JPS6252647A (en) Monitoring system for run away of microprocessor
JPH02115967A (en) Microcomputer resetting method

Legal Events

Date Code Title Description
LAPS Cancellation because of no payment of annual fees