JPH07261814A - Interruption synchronizing method for dual system of pc - Google Patents

Interruption synchronizing method for dual system of pc

Info

Publication number
JPH07261814A
JPH07261814A JP6072487A JP7248794A JPH07261814A JP H07261814 A JPH07261814 A JP H07261814A JP 6072487 A JP6072487 A JP 6072487A JP 7248794 A JP7248794 A JP 7248794A JP H07261814 A JPH07261814 A JP H07261814A
Authority
JP
Japan
Prior art keywords
interruption
signal
interrupt
processors
match
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
JP6072487A
Other languages
Japanese (ja)
Inventor
Masanori Ikeda
正規 池田
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.)
Yaskawa Electric Corp
Original Assignee
Yaskawa 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 Yaskawa Electric Corp filed Critical Yaskawa Electric Corp
Priority to JP6072487A priority Critical patent/JPH07261814A/en
Publication of JPH07261814A publication Critical patent/JPH07261814A/en
Pending legal-status Critical Current

Links

Abstract

PURPOSE:To switch a control system and a stand-by system in the dual system of asynchronous PCs by enabling actuation only with a matching interruption signal while the states of the two systems match each other right after a synchronous instruction is executed by a processor. CONSTITUTION:An interruption processing part A and an interruption processing part B are of the same circuit constitution and both processors A and B constitute the dual system. In this case, an interruption signal A is held by a register 7 and inputted to a coincidence detecting circuit 8 with a SYNC-A signal outputted from a synchronous port A with a synchronous instruction of the processor A. The coincidence detecting circuit 8 decides whether or not the interruption signals of the systems A and B match each other when an RDY-A signal is active, and outputs an interruption request to the processors only with the matching interruption signal A when the RDY-A signal rises. Thus, interruption processing is performed only when the synchronization of the two processors A and B is completed, so the internal states of the two processors A and B can be matched with each other.

Description

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

【0001】[0001]

【産業上の利用分野】本発明は、プログラマブルコント
ローラ(以下、PCと略す)のデュアルシステムにおけ
る割込み同期方法に関する。
BACKGROUND OF THE INVENTION 1. Field of the Invention The present invention relates to an interrupt synchronization method in a dual system of a programmable controller (hereinafter abbreviated as PC).

【0002】[0002]

【従来の技術】処理装置を2重構成とし、制御処理を行
っている処理装置(以下、制御系と称す)がダウンした
場合、制御処理を行っていない処理装置(以下、待機系
と称す)へ制御処理を切り替えるようにしたデュアルシ
ステムは、PCの障害対策として有効な手段であるが、
リアルタイム処理を必要とするシステムでは、この制御
処理の切り替えを即時に行わなければならないので、待
機系についても常に制御系と同じ内部状態を維持しなけ
ればならない。従来技術では、2つの同期した処理装置
が同一のプログラムと同一のデータを使用することによ
り、2つの処理装置の内部状態を常に同一の状態とし、
必要に応じて制御系と待機系の切り換えを行っている。
この場合、2重化されたメモリやI/Oの内容を一致さ
せるため、メモリやI/Oへの書き込みは、制御系・待
機系いずれに対しても、制御系の処理装置によってのみ
行い、メモリやI/Oへの読み込みは制御系・待機系そ
れぞれのメモリやI/Oに対応する処理装置によって行
われる。
2. Description of the Related Art When a processing device has a dual structure and a processing device performing control processing (hereinafter referred to as a control system) goes down, a processing device not performing control processing (hereinafter referred to as a standby system) The dual system, in which the control process is switched to, is an effective measure for PC failure,
In a system that requires real-time processing, this control processing must be switched immediately, so the standby system must always maintain the same internal state as the control system. In the prior art, the two synchronized processing devices use the same program and the same data, so that the internal states of the two processing devices are always the same.
The control system and the standby system are switched as needed.
In this case, in order to match the contents of the duplicated memory and I / O, writing to the memory and I / O is performed only for the control system and the standby system only by the processing unit of the control system. Reading into the memory or I / O is performed by the processing device corresponding to the memory or I / O of each of the control system and the standby system.

【0003】[0003]

【発明が解決しようとする課題】このようなシステムで
は、2つの処理装置を同期させるためには周波数の高い
クロックの同期が必要となるため、同期回路が複雑とな
り、また2つの処理装置を2つのモジュールに分割する
ことが困難となるため、信頼性が低下するが、2つの処
理装置のクロックを非同期とすることで、複雑な切り換
え回路や同期回路の使用を避けることができる。しかし
ながら、クロックが非同期であるため制御系、待機系そ
れぞれの処理装置の実行プログラムステップにずれが生
じるため、割り込みを受付けるプログラムステップにず
れが生じるという問題があり、また、両処理装置の実行
プログラムステップにずれが生じない場合でも、割込信
号の伝送経路の違いその他の原因で割り込み信号自体が
両制御系に対して非同期である場合は、前者と同様に、
割り込みを受付けるプログラムステップにずれが生じる
という問題がある。したがって、2つの処理装置が非同
期であるデュアルシステムにおいては、単に同期命令に
より両処理装置の実行ステップの同期を取って割込信号
を受付けるだけでは、割込のタインミングがずれる恐れ
があり、その結果2つの処理装置の内部状態が異なる可
能性がある。本発明は、非同期のPCのデュアルシステ
ムにおいて、このような問題を解決し、割込信号自体が
非同期の場合でも割込みの同期をとる手段を提供する。
In such a system, since it is necessary to synchronize high-frequency clocks in order to synchronize the two processing devices, the synchronization circuit becomes complicated, and the two processing devices need to be synchronized. Although it is difficult to divide the module into two modules, the reliability is reduced. However, by making the clocks of the two processing devices asynchronous, it is possible to avoid the use of complicated switching circuits and synchronization circuits. However, since the clocks are asynchronous, there is a problem in that the program steps for accepting an interrupt are misaligned because the program steps executed by the processing devices of the control system and the standby system are misaligned. Even if there is no deviation, if the interrupt signal itself is asynchronous with respect to both control systems due to the difference in the transmission path of the interrupt signal and other reasons, as in the former case,
There is a problem that the program steps that accept interrupts are misaligned. Therefore, in a dual system in which two processing units are asynchronous, there is a risk that the timing of the interrupt will shift if the execution steps of both processing units are synchronized by a synchronization instruction and the interrupt signal is received. The internal states of the two processing devices may be different. The present invention solves such a problem in an asynchronous PC dual system and provides a means for synchronizing interrupts even when the interrupt signal itself is asynchronous.

【0004】[0004]

【課題を解決するための手段】上記問題を解決するた
め、本発明は、複数のプログラムを割込み信号により切
り替えて実行する非同期式PCのデュアルシステムの割
込み同期方法において、両PCがプログラムで定められ
た同期命令を実行した結果、両PCの内部状態が一致し
た状態にある時、両PCへの外部割込み信号が一致した
場合のみ両PCへの割込みを受け付けるようにしたもの
である。
In order to solve the above problems, the present invention provides an asynchronous PC dual system interrupt synchronization method for switching a plurality of programs by interrupt signals and executing them, and both PCs are defined by the programs. As a result of executing the synchronization instruction, when the internal states of both PCs match, the interrupts to both PCs are accepted only when the external interrupt signals to both PCs match.

【0005】[0005]

【作用】上記手段により、2つの処理装置の同期を完了
した時点でのみ割り込み処理を行わせるため、2つの処
理装置の内部状態を一致させることができる。
By the above means, the interrupt processing is performed only when the synchronization of the two processing devices is completed, so that the internal states of the two processing devices can be matched.

【0006】[0006]

【実施例】以下、本発明の実施例を図に基づいて説明す
る。図1において、1は割込処理部A、2は割込処理部
B、3は処理装置A、4は処理装置B、5は同期ポート
A、6はOR回路、7はレジスタ回路、8は一致検出回
路である。割込処理部Aと割込処理部Bは同一の回路構
成で、処理装置とともにデュアルシステムを構成してい
る。処理装置Aと処理装置BのCPUクロックは非同期
で動作しているため、クロック周波数等のばらつきによ
り実行プログラムステップが徐々にズレてくる。図の同
期ポートはそのズレを補正するためのもので、以下その
動作を説明する。処理装置Aが同期命令(同期ポートA
をアクセスする命令)を実行すると、SYNC_A信号
がアクティブとなる。このときSYNC_Bが非アクテ
ィブであれば、RDY_Aはアクティブにならず、処理
装置Aは同期命令でウェイト状態を保つ。SYNC_B
がアクティブになると、RDY_Aがアクティブとな
り、ウェイト状態が解除され処理が再開される。他方、
処理装置Bでも同期命令(同期ポートAをアクセスする
命令)を実行すると、SYNC_B信号がアクティブと
なる。このときSYNC_Aが非アクティブであれば、
RDY_Bアクティブにならず、処理装置BはIN命令
でウェイト状態を保つ。SYNC_Aがアクティブにな
ると、RDY_Bがアクティブとなり、ウェイト状態が
解除され処理が再開される。RDY_AとRDY_B
(システムBのRDY信号)はともにSYNC_AとS
YNC_Bの論理積(AND信号)であり、処理装置A
と処理装置Bのウェイトが解除されるタイミングのずれ
は、それぞれのシステムクロックの位相ズレのみに抑え
られる。そのため同期命令実行後の命令開始のずれは無
くなり、同期命令直後の2つ処理装置の内部状態は完全
に一致する。つぎに、外部割込処理の方法について説明
する。処理装置Aの同期命令により同期ポートから出力
されるSYNC_A信号により、割り込み信号はレジス
タにホールドされ、一致検出回路に入力される。一致検
出回路はRDY_A信号がアクティブ時にシステムAと
Bの割り込み信号の一致、不一致の判定をおこない、R
DY_A信号の立ち上がり時に一致した割り込み信号の
みで処理装置に割り込み要求を出力する。不一致の割り
込み信号は、外部割り込み信号が未処理のまま破棄され
ることがないように、一時一致検出回路内のレジスタに
記憶され、次の同期命令時に外部割り込み信号と論理和
(OR)を取り、再び一致検出回路に入力される。
Embodiments of the present invention will be described below with reference to the drawings. In FIG. 1, 1 is an interrupt processing unit A, 2 is an interrupt processing unit B, 3 is a processing device A, 4 is a processing device B, 5 is a synchronous port A, 6 is an OR circuit, 7 is a register circuit, and 8 is It is a match detection circuit. The interrupt processing unit A and the interrupt processing unit B have the same circuit configuration and constitute a dual system together with the processing device. Since the CPU clocks of the processing device A and the processing device B are operating asynchronously, the execution program steps are gradually displaced due to variations in clock frequency and the like. The synchronization port in the figure is for correcting the deviation, and its operation will be described below. The processing device A sends a synchronization instruction (synchronization port A
When the instruction for accessing (1) is executed, the SYNC_A signal becomes active. At this time, if SYNC_B is inactive, RDY_A does not become active, and the processing device A keeps the wait state by the synchronization instruction. SYNC_B
Becomes active, RDY_A becomes active, the wait state is released, and the process is restarted. On the other hand,
When the processor B also executes the synchronous instruction (the instruction to access the synchronous port A), the SYNC_B signal becomes active. At this time, if SYNC_A is inactive,
RDY_B does not become active, and the processor B keeps the wait state by the IN instruction. When SYNC_A becomes active, RDY_B becomes active, the wait state is released, and the process is restarted. RDY_A and RDY_B
(RDY signal of system B) is both SYNC_A and S
YNC_B is a logical product (AND signal), and the processing device A
The deviation of the timing when the wait of the processor B is released can be suppressed only by the phase shift of each system clock. Therefore, there is no deviation in the start of the instruction after the execution of the synchronous instruction, and the internal states of the two processors immediately after the synchronous instruction are completely the same. Next, a method of external interrupt processing will be described. The interrupt signal is held in the register by the SYNC_A signal output from the synchronous port according to the synchronous instruction of the processing device A, and is input to the coincidence detection circuit. When the RDY_A signal is active, the match detection circuit determines whether the interrupt signals of the systems A and B match or does not match, and
An interrupt request is output to the processing device only with the interrupt signal that coincides with the rising edge of the DY_A signal. The unmatched interrupt signal is stored in a register in the temporary match detection circuit so that the external interrupt signal is not unprocessed and discarded, and is logically ORed with the external interrupt signal at the next synchronization instruction. , Are again input to the match detection circuit.

【0007】[0007]

【発明の効果】以上述べたように、本発明によれば、割
込み処理は、処理装置の同期命令実行直後の2つの系の
状態が一致した状態で、一致した割込み信号によっての
み起動がかけられるので、割込が発生しても2つのシス
テムの状態が同期命令直後は常に一致するため、制御系
システムと待機系システムの切り替えが可能となる。ま
た、処理装置Aは、SYNC_Bと割込み信号_Bを強
制的にアクティブにすることにより、処理装置Bから切
り離されて単独動作となり、同様に、処理装置Bは、S
YNC_Aと割込み信号_Aを強制的にアクティブにす
ることにより、処理装置Bから切り離されて単独動作と
なるため、デュアルとシングル(それぞれ単独に動作)
の切り換えも簡単に行うことができる。
As described above, according to the present invention, the interrupt processing is activated only by the coincident interrupt signal in a state where the states of the two systems immediately after the execution of the synchronous instruction of the processing device coincide. Therefore, even if an interrupt occurs, the states of the two systems always match immediately after the synchronization instruction, so that the control system and the standby system can be switched. Further, the processing apparatus A is separated from the processing apparatus B and becomes an independent operation by forcibly activating SYNC_B and the interrupt signal_B, and similarly, the processing apparatus B is
By forcibly activating YNC_A and interrupt signal _A, it is separated from the processing unit B and operates independently, so dual and single (each operates independently)
Can also be easily switched.

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

【図1】本発明によるデュアルシステムの構成例。FIG. 1 is a configuration example of a dual system according to the present invention.

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

1 割込処理部A 2 割込処理部B 3 処理装置A 4 処理装置B 5 同期ポートA 6 OR回路 7 レジスタ回路 8 一致検出回路 1 Interruption processing unit A 2 Interruption processing unit B 3 Processing device A 4 Processing device B 5 Synchronization port A 6 OR circuit 7 Register circuit 8 Match detection circuit

───────────────────────────────────────────────────── フロントページの続き (51)Int.Cl.6 識別記号 庁内整理番号 FI 技術表示箇所 G06F 15/16 470 J G05B 19/05 F ─────────────────────────────────────────────────── ─── Continuation of the front page (51) Int.Cl. 6 Identification code Internal reference number FI Technical display location G06F 15/16 470 J G05B 19/05 F

Claims (1)

【特許請求の範囲】[Claims] 【請求項1】 複数のプログラムを割込み信号により切
り替えて実行する非同期式PCのデュアルシステムの割
込み同期方法において、 両PCがプログラムで定められた同期命令を実行した結
果、両PCの内部状態が一致した状態にある時、両PC
への外部割込み信号が一致した場合のみ両PCへの割込
みを受け付けることを特徴とするPCのデュアルシステ
ムにおける割込み同期方法。
1. In an asynchronous PC dual-system interrupt synchronization method for switching a plurality of programs by interrupt signals and executing them, the internal states of both PCs match as a result of execution of a synchronization instruction defined by the programs. Both PCs when in
An interrupt synchronization method in a dual system of PCs, characterized in that an interrupt to both PCs is accepted only when the external interrupt signals to PC match.
JP6072487A 1994-03-16 1994-03-16 Interruption synchronizing method for dual system of pc Pending JPH07261814A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP6072487A JPH07261814A (en) 1994-03-16 1994-03-16 Interruption synchronizing method for dual system of pc

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP6072487A JPH07261814A (en) 1994-03-16 1994-03-16 Interruption synchronizing method for dual system of pc

Publications (1)

Publication Number Publication Date
JPH07261814A true JPH07261814A (en) 1995-10-13

Family

ID=13490737

Family Applications (1)

Application Number Title Priority Date Filing Date
JP6072487A Pending JPH07261814A (en) 1994-03-16 1994-03-16 Interruption synchronizing method for dual system of pc

Country Status (1)

Country Link
JP (1) JPH07261814A (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2012523616A (en) * 2009-04-08 2012-10-04 フリースケール セミコンダクター インコーポレイテッド Debug signaling in multiprocessor data processing systems
WO2012169021A1 (en) * 2011-06-08 2012-12-13 株式会社日立製作所 Control method, control system, and program

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2012523616A (en) * 2009-04-08 2012-10-04 フリースケール セミコンダクター インコーポレイテッド Debug signaling in multiprocessor data processing systems
WO2012169021A1 (en) * 2011-06-08 2012-12-13 株式会社日立製作所 Control method, control system, and program

Similar Documents

Publication Publication Date Title
JP3982353B2 (en) Fault tolerant computer apparatus, resynchronization method and resynchronization program
US5226152A (en) Functional lockstep arrangement for redundant processors
JPH0773059A (en) Fault-tolerant computer system
KR20040007338A (en) Fault tolerant computer system re-synchronization method thereof and computer-readable storage medium having re-synchronization program thereof recorded thereon
US20040193735A1 (en) Method and circuit arrangement for synchronization of synchronously or asynchronously clocked processor units
EP1380951B1 (en) Fault tolerant information processing apparatus
JPH07261814A (en) Interruption synchronizing method for dual system of pc
JPH086800A (en) Data processor and microprocessor
JPH0736720A (en) Duplex computer equipment
JPH11175108A (en) Duplex computer device
JPS62187901A (en) Method for controlling duplex controller
JPH03219333A (en) Stand-by duplex system device
JPH10326199A (en) Interruption synchronizing device in dual system
JP2526835B2 (en) Duplex synchronous control system of programmable controller
JP3094516B2 (en) Retry method of information processing device
JPH07200334A (en) Duplicate synchronization operation system
JPH0635880A (en) Microprocessor
JP3331695B2 (en) Time synchronization method
JP3055906B2 (en) Emergency operation method
JPH06214606A (en) Input/output method for duplex pc system
JPH03268007A (en) Sequence controller
JPS6175436A (en) Microprogram controller
JP2000242317A (en) Programmable controller
JPH02110742A (en) Error detecting and synchronizing system for multi-processor
JPH07287608A (en) Dual synchronous controller of programmable controller

Legal Events

Date Code Title Description
EXPY Cancellation because of completion of term