JPS5985505A - Programable controller having state pattern comparing function - Google Patents

Programable controller having state pattern comparing function

Info

Publication number
JPS5985505A
JPS5985505A JP57195687A JP19568782A JPS5985505A JP S5985505 A JPS5985505 A JP S5985505A JP 57195687 A JP57195687 A JP 57195687A JP 19568782 A JP19568782 A JP 19568782A JP S5985505 A JPS5985505 A JP S5985505A
Authority
JP
Japan
Prior art keywords
pattern
input
output
memory
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.)
Pending
Application number
JP57195687A
Other languages
Japanese (ja)
Inventor
Kiyoto Hirase
平瀬 清人
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.)
Omron Corp
Original Assignee
Tateisi Electronics Co
Omron Tateisi Electronics Co
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 Tateisi Electronics Co, Omron Tateisi Electronics Co filed Critical Tateisi Electronics Co
Priority to JP57195687A priority Critical patent/JPS5985505A/en
Publication of JPS5985505A publication Critical patent/JPS5985505A/en
Pending legal-status Critical Current

Links

Classifications

    • GPHYSICS
    • G05CONTROLLING; REGULATING
    • G05BCONTROL OR REGULATING SYSTEMS IN GENERAL; FUNCTIONAL ELEMENTS OF SUCH SYSTEMS; MONITORING OR TESTING ARRANGEMENTS FOR SUCH SYSTEMS OR ELEMENTS
    • G05B19/00Programme-control systems
    • G05B19/02Programme-control systems electric
    • G05B19/04Programme control other than numerical control, i.e. in sequence controllers or logic controllers
    • G05B19/05Programmable logic controllers, e.g. simulating logic interconnections of signals according to ladder diagrams or function charts
    • G05B19/058Safety, monitoring

Landscapes

  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Engineering & Computer Science (AREA)
  • Automation & Control Theory (AREA)
  • Testing And Monitoring For Control Systems (AREA)
  • Programmable Controllers (AREA)

Abstract

PURPOSE:To simplify a fault processing system by storing a state pattern in an auxiliary memory when the state pattern is coincident with a set pattern and replacing the data. CONSTITUTION:It is always monitored to decide whether the data on the input/ output state of an input/output memory 7 is coincident with the state pattern of some input/output data which are set and registered previously. When this coincidence is detected, the pattern number is displayed to a program console 8. At the same time, the data on the number is stored in an auxiliary memory of a working memory 3. For the display of the console 8, each digit of a display device 8B is set opposite to each input/output data, and either ON or OFF ternary state is displayed at the digit position. Then the contents are read out of the auxiliary memory after a user instruction, i.e. a fault processing instruction is read out. Then the processing, e.g. an output of alarm, the discontinuation of program, etc. is carried out in accordance with the contents of the auxiliary memory.

Description

【発明の詳細な説明】 (1)発明の分野 この発明は、継電器ラダー図式で代表されるスキ1?ニ
ング式のプログラマブル・コントローラに関し、特に、
ニー11プログラム実行時の入出hデータの変化を状態
パターンとして捉えて特定の状態パターンと一致したと
きにこれを表示環るとともに、そのパターンの識別デー
タをコ〜ザ命令の演算対象どするようにしたものに関す
る。
DETAILED DESCRIPTION OF THE INVENTION (1) Field of the Invention This invention is based on the following features represented by a relay ladder diagram. In particular, regarding programmable controllers with
Knee 11 Changes in input/output h data during program execution are captured as a state pattern, and when they match a specific state pattern, this is displayed, and the identification data of that pattern is used as the calculation target of the co-za instruction. related to what was done.

(2)従来技術とその問題点 最近の多くのプログラマブル・コントローラは、継電器
ラダー図で表わされたシーケンス回路図を所定のプログ
ラミング言語で表現し、そのニー11プログラムを高速
で繰り返し実行(スキャニング)するようになっている
(2) Prior art and its problems Many recent programmable controllers express a sequence circuit diagram represented by a relay ladder diagram in a predetermined programming language, and repeatedly execute the knee 11 program at high speed (scanning). It is supposed to be done.

この種のプログラマブル・コントローラを実際に使用す
る場合において、シーケンス制御の進行状況を把握する
ために、あるいは正常なシーケンス制御では起こり得な
いような異常状態になったことを知るために、さらには
異常を生じたときのシーケンス制御状態を知る等の目的
で、シーケンス制御の要所要所で所定の表示をするとと
もに、該表示内容に対応して例えば警報を発する等の適
宜な異常処理をすることが良く行なわれる。従来の11
]グラマプル・コン1〜ローラでは、上記のシーケンス
制御の進行状態の表示およびこれに対応した異常処理を
するために、ニー:Pプログラム中にその所定の表示回
路や警報出力等の異常処理回路(継電器ラダー回路)を
組込んでいた。しかしこの方式では、ユーザプログラム
中に占める1−記表示回路や異常処理回路の用模が大き
くなると、実際に有効に使用できるユーザプログラムエ
リアが少なくなってしまうという問題がある。また、上
記表示回路等に係わる入出力データが多くなると、それ
らの間の論理ffIa1%を正確に認識して所望の」−
記表示回路等を構成するのは非常に面倒となり、プログ
ラマブル・コントローラおよび制御対象システムに熟知
した者でなければこれを行なうことができなくなる。ま
た、上記表示回路や異常処理回路のために多数の出力リ
レーを使ってしまうと、本来の制御の目的で使用できる
出力リレーの数が少なくなるという問題もある。
When actually using this type of programmable controller, it is necessary to check the progress of sequence control, or to know that an abnormal state has occurred that would not occur under normal sequence control. For the purpose of knowing the sequence control status when a problem occurs, a predetermined display is displayed at key points in the sequence control, and appropriate abnormality processing such as issuing an alarm can be performed in response to the displayed content. well done. Conventional 11
] In Grammapul Controller 1 to Roller, in order to display the progress status of the above-mentioned sequence control and handle the corresponding abnormality, the specified display circuit and abnormality processing circuit such as alarm output ( A relay ladder circuit) was incorporated. However, with this method, there is a problem in that as the number of display circuits and abnormality processing circuits that occupy a large portion of the user program increases, the user program area that can actually be effectively used decreases. In addition, when the input/output data related to the display circuit etc. increases, the logic ffIa1% between them can be accurately recognized and the desired value can be calculated.
Configuring the display circuit and the like is very troublesome and can only be done by a person who is familiar with programmable controllers and systems to be controlled. Furthermore, if a large number of output relays are used for the display circuit or abnormality processing circuit, there is a problem that the number of output relays that can be used for the original control purpose decreases.

(3)発明の目的 この発明の目的は、シーケンス制御の進行状態を入出力
データのパターンとして捉え、ユーザ10グラムとは別
に複数の状態パターンを設定しておき、実際の制御時の
状態パターンが設定した状態パターンと一致したときに
そのパターンの識別番号を表示するとともに、その識別
番号のデータをユーザ命令の演算対象とするようにした
プログラマブル・コントローラを提供することにある。
(3) Purpose of the Invention The purpose of the present invention is to capture the progress state of sequence control as a pattern of input/output data, set a plurality of state patterns separately from the user 10 grams, and make sure that the state pattern during actual control is An object of the present invention is to provide a programmable controller that displays an identification number of a set state pattern when the pattern matches the set state pattern, and uses the data of the identification number as a calculation target of a user command.

(4)発明の構成と効宋 上記の目的を達成するために、この発明は、全入出力デ
ータについてオン、オフまたはいずれでも良いの3値で
表わした任意の状態パターンを複数パターン設定して記
憶しておく手段と、ユーザプログラムの実行と並行して
、実際の人出ノコデータの状態が上記記憶された状態パ
ターンのいずれかと一致するかどうかを比較する手段と
、この比較手段で一致が検出されたとき、その一致した
状態パターンの識別番号を表示する手段と、上記比較手
段でτ一致が検出されたとき、その一致した状態゛パタ
ーンの識別番号のデータを、ユーザ命令にて任意にアク
しスして演粋処1ψの対象として利用可能な補助メモリ
に格納するデータ更新手段とを設置゛Jたことを特徴と
りる。
(4) Structure and Effects of the Invention In order to achieve the above object, this invention sets a plurality of arbitrary state patterns expressed in three values of on, off, or either for all input/output data. means for storing it, means for comparing whether the state of the actual manned saw data matches any of the stored state patterns in parallel with the execution of the user program, and a match detected by the comparing means. means for displaying the identification number of the matched state pattern, and when a τ match is detected by the comparison means, the data of the identification number of the matched state pattern is accessed arbitrarily by a user command. The present invention is characterized in that a data updating means for storing data in an auxiliary memory that can be used as a target of the calculation process 1ψ is installed.

1−記構成の状態パターン比較機能を備えたプログラマ
ブル・コントローラにあっては、ユーザプログラム中に
シーケンス制御の進行状態を表示するための表示回路や
警報出力等のための異常処理回路を組込むのでtitな
く、ユーザプログラムとは別個に特定の制御状態を示す
入出力データのパターンを任意に複数パターン設定して
おけば、ユーザプログラムの実行中に1,111111
状態が設定したパターンと一致したときに、そのパター
ンの識別番号が表示されるとともに、その識別?l@が
ユーザ命令にてアクセス可能に補助メモリに格納される
ので、ニー1アブ11グラムにおいては、このデータを
演算処理の対象とすべくプログラミングするだけで、簡
単に所定の異常処理をなすことができる。
In a programmable controller equipped with the status pattern comparison function configured as described in 1-1, a display circuit for displaying the progress status of sequence control and an abnormality processing circuit for alarm output etc. are incorporated into the user program. If you arbitrarily set multiple input/output data patterns that indicate specific control states separately from the user program, 1,111111
When the status matches the set pattern, the identification number of that pattern is displayed, and the identification number? Since l@ is stored in the auxiliary memory so that it can be accessed by user commands, in the Knee 1 AB 11 Gram, it is possible to easily perform predetermined abnormality processing by simply programming this data to be subject to arithmetic processing. I can do it.

従って、状態表示および状態出力、つまり状態監視のた
めにユーザプログラムをいたずらに冗長にすることがな
く、限られたユーザプログラム容量を有効に実質的なシ
ーケンス制御に利用することができる。また、状態監視
がユーザプロゲラ18とは完全に切り離されているので
、状@監視の機OLを変更するときに誤ってニーIFプ
ログラムの論理まで破壊してしまうというようなミスが
なくなる。
Therefore, the user program is not unnecessarily redundant for status display and status output, that is, status monitoring, and the limited user program capacity can be effectively utilized for substantial sequence control. Furthermore, since the status monitoring is completely separated from the user programmer 18, there is no possibility of mistakes such as accidentally destroying the logic of the knee IF program when changing the status @monitoring machine OL.

また、状態監視をするために条イ1となる入出力データ
が多数でかつそれらの論理関係が複雑であっても、単に
入出力データの静的なパターンとして捉えるので、必要
な状態監視をするための設定登録も非常に容易で分りや
すいものどなる。
In addition, even if there is a large number of input/output data and the logical relationship between them is complex, it is simply treated as a static pattern of input/output data, so necessary status monitoring can be performed. Registration of settings is also very easy and easy to understand.

(5)実施例の説明 第1図はこの発明を適用したプログラマブル・コントロ
ーラの全体の概略構成を示丈ブロック図である。このプ
ログラマブル・コントローラは、全体の制御の中枢とな
るCPU1(中央処理ユニット)と、CPU1によって
実行されるシステムプ(]ダラムを格納したシステムプ
ログラムメモリ2ど、Cr’ U 1ににって各種可変
データの一時格納エリア、としτ使われるワーキングメ
モリ3およd表示用ワーキングメモリ4と、使用者が任
意に設定したシー1)ンス制翻プログラムが格納される
コーププログラムメモリ5と、外部入力信号が与えられ
る入力インターフ[−スおよび外部出力信号を送出する
出力インターフエースを含んだ入出力装置6(入力装置
と出力装置の総称)と、入出力装置6に対応しノζ入出
力データのバッファメモリどなる入出カメモリ7と、C
P tJ 1に各種の動作指令を与えlこりユーザプロ
グラムの作成入力ウモニタ指令入力を行なったり、その
入力時の表示やモニタ表示等がなされるプログラムコン
ソール8とを備えている。
(5) Description of Embodiments FIG. 1 is a block diagram showing the overall schematic structure of a programmable controller to which the present invention is applied. This programmable controller has a CPU 1 (central processing unit) that is the center of overall control, a system program memory 2 that stores a system program executed by the CPU 1, and various variable programs in Cr' U 1. A working memory 3 used as a temporary storage area for data, a working memory 4 for display, a cooperative program memory 5 in which a sequence control program arbitrarily set by the user is stored, and an external input signal An input/output device 6 (collective term for input device and output device) including an input interface [-] to which is given and an output interface that sends out external output signals, and a buffer for input/output data corresponding to the input/output device 6. Memory roaring input/output memory 7 and C
It is provided with a program console 8 on which various operation commands are given to the PtJ 1, user program creation inputs, monitor commands inputted, and displays at the time of input, monitor displays, etc. are provided.

[記入出力装置6は入カニニットと出カニニットとに別
れてぞれぞれユニット化されており、各コニツ1〜は8
点ずつの入力端子または出力端子を備えている1、第1
図の符号9は入出力装置6の各]ニラ1〜の端子板を示
している。各端子板9に付加゛しである数字は入出力番
号を示す。つまり、この実施例における入出力装置5は
8つの入出カコニットから構成され、全体として8X8
=64の入出力信号を扱えるようになっており、各入出
力信号(入出力端子)には1〜67Iの入出カ番月が割
り付けられている。
[The input/output device 6 is divided into an incoming unit and an outgoing unit, and each unit is divided into units, and each unit 1 to 8
1, with point-by-point input or output terminals;
Reference numeral 9 in the figure indicates a terminal plate for each of the input/output devices 6. The numbers added to each terminal board 9 indicate input/output numbers. In other words, the input/output device 5 in this embodiment is composed of eight input/output units, and the total size is 8×8.
=64 input/output signals can be handled, and each input/output signal (input/output terminal) is assigned an input/output number from 1 to 67I.

上記プログラムコンソール8は、チンキーヤ)命令コー
ドキーやその他のファンクションキーを含むキーボード
8△と、命令コード、アドレスあるいはエラーメツセー
ジ等を文字で表示づるためのドットマ1〜リクス式の表
示器8Bとを備えている。
The program console 8 is equipped with a keyboard 8△ including a command code key and other function keys, and a dot-mark type display 8B for displaying command codes, addresses, error messages, etc. in characters. ing.

また第2図に示すように、ワーキングメモリ3は、演痺
用■リア3Aと、タイマー命令の現在1「1が格納され
るエリア3Bと、カウンタ命令の現在値が格納されるエ
リア3cと、補助出力(内部リレー)のデータが格納さ
れるエリア3Dとに別れる。また入出カメモリ7は、入
出力装置6にお【ノる1〜64の各入出力データが格納
される64ビツトの:[リアを有している。そして、L
配hr−リア3Dには、この入出カメモリ7に格納され
る人出カデータのF IIデータ(64)の番地に続け
て、65〜112の各補助出力データが格納され、この
うe 1..09ヘ−112の4ビツトのエリアがこの
発明に係る補助メモリとして利用される。
Further, as shown in FIG. 2, the working memory 3 includes a paralysis rear 3A, an area 3B where the current 1 "1" of the timer command is stored, and an area 3c where the current value of the counter command is stored. The input/output memory 7 is divided into an area 3D where the data of the auxiliary output (internal relay) is stored.The input/output memory 7 is divided into an area 3D where the data of the auxiliary output (internal relay) is stored. It has a rear and an L
In the HR rear 3D, each auxiliary output data 65 to 112 is stored following the address of the FII data (64) of the people output data stored in the input/output memory 7, and e1. .. A 4-bit area from 09 to 112 is used as an auxiliary memory according to the present invention.

周知のように、この秤のプログラマブル・コントローラ
にお(−)るユーザプログラムの実行動作は、コーザブ
[]グラムメモリ5からコーザ命令を順番に読出し、各
1−り“命令に従って入出カメモリ7に格納されている
入出力データ間の演樟処理をし、かつその演算処理対象
によって指定の出力データを更新することであり、また
このユーザプログラム、の実行と同期して入出力装置5
に与えられる入出力データを入出カメモリ7の所定エリ
アに書込むとともに(入力更新)、入出カメモリ7の所
定エリアの出力データを入出力装置6に転送する(出力
更新)動作が行なわれ、これにより入出力装置6に与え
られる外部入力信号と入出力装置6から出力する外部出
力信号との関係において、1−ザブログラムにて指定さ
れたシーケンス状態が作り出される訳である。このユー
ザプログラムでの演算処理対象となるのは入出力装置6
の入出力データだけでなく、先に説明したタイマー命令
、カウンタ命令および補助出力に関Jるデータも含まれ
るのは周知の通りである。
As is well known, the execution operation of the user program in the programmable controller of this scale is to sequentially read out the Coza commands from the Cozab[]gram memory 5 and store them in the input/output memory 7 in accordance with each ``instruction''. The purpose of this process is to carry out calculation processing between the input and output data currently being processed, and to update specified output data according to the object of the calculation process.
The input/output data given to the input/output memory 7 is written to a predetermined area of the input/output memory 7 (input update), and the output data of the predetermined area of the input/output memory 7 is transferred to the input/output device 6 (output update). In the relationship between the external input signal applied to the input/output device 6 and the external output signal outputted from the input/output device 6, a sequence state specified by the 1-program is created. The input/output device 6 is subject to calculation processing in this user program.
It is well known that the data includes not only the input/output data of , but also data related to the timer command, counter command, and auxiliary output described above.

この発明に係るプログラマブル・コン1〜1]−ラでは
、上記のユーザプログラムの実行機能に加えて、入出カ
メモリ7の入出力状態のデータが予め設定登録しである
いくつかの入出力データの状態パターンに一致するか否
かを常時監視lノ、一致した場合にそのパターンの番号
をプログラムコンソール8に表示する機能およびその番
号のデータを上記エリア3Dの上記補助メモリに格納す
る機能を備えている。
In the programmable controllers 1 to 1 according to the present invention, in addition to the above-mentioned user program execution function, the input/output state data of the input/output memory 7 can be set and registered in advance to perform several input/output data states. It constantly monitors whether or not it matches a pattern, and if it matches, it has the function of displaying the number of the pattern on the program console 8 and the function of storing the data of that number in the auxiliary memory of the area 3D. .

第3図に示すように、コーププログラムメモリ5は、ユ
ーザ命令列が格納されるJリア5Aと、タイマー命令の
設定値が格納されるエリア5Bと、カウンタ命令の設定
値が格納されるエリア5Cの仙に、この発明の要旨に係
わるパターンメモリ5Dのエリアが設定されている。パ
ターンメモリ5Dは、符号50〜59で示す10パター
ン分の工リアから4zす、各エリアには0〜9のパター
ン番号が対応付1−Jられている。1パタ一ン分のパタ
ーンメモ1人工97′は、更にオフパターンエリアと〕
フパターン1リアの2つに分かれている。そしてオフパ
ターンエリアおよびオフパターンエリアども人出カメモ
リ7と1対1に対応する611ビツトの容量を持ってい
る。つまり、1パタ一ン分のエリアは6/lX2=12
8ピツトの容量がらなっている。
As shown in FIG. 3, the cooperative program memory 5 includes a J rear 5A where user command sequences are stored, an area 5B where setting values of timer commands are stored, and an area 5C where setting values of counter commands are stored. An area of a pattern memory 5D related to the gist of the present invention is set at the bottom. The pattern memory 5D has pattern numbers 1-J associated with patterns 0-9 in each area from the area of 10 patterns indicated by reference numerals 50-59. Pattern memo 1 for 1 pattern 1 artificial 97' is also an off pattern area]
It is divided into two parts: one rear and one rear. The off-pattern area and the off-pattern area each have a capacity of 611 bits in one-to-one correspondence with the attendance memory 7. In other words, the area for one pattern is 6/lX2=12
It has a capacity of 8 pits.

この発明のプログラマブル・コントローラでは64ピッ
1−の全入出力データについてオン、オフまたはいり”
れでも良いの3!Iriで表わした任意の状態パターン
を−1−記パターンメモリ5Dに10パターン分設定(
)て記憶しておくことができる。一つのパターンを設定
するには、例えば入出力番号1についてオンと登録する
場合、オフパターンエリアのM@1のビットを1″にす
る。また入出力番号2についてオフを設定0録する場合
、オフパターンエリアの番号2のビットを110 I+
にする。
In the programmable controller of this invention, all input/output data of 64 pins can be turned on, off or on.
It's okay 3! Set 10 arbitrary state patterns expressed by Iri in the -1- pattern memory 5D (
) can be memorized. To set one pattern, for example, if input/output number 1 is registered as on, set the M@1 bit in the off pattern area to 1''.Also, if input/output number 2 is set to off and recorded as 0, Set bit number 2 of off pattern area to 110 I+
Make it.

また入出力番号3についてUオンオフいずれでも良い」
を設定登録づ゛る場合、オフパターンエリアの番@3お
よびオンパターンエリアの番号3のピッ]〜をいずれも
0°′にしておく。このようにして6/1ビット分の状
態パターンを41意に設定することができる。
Also, for input/output number 3, either U on or off is fine.
When setting and registering, set both the number @3 of the off-pattern area and the number 3 of the on-pattern area to 0°'. In this way, 41 unique state patterns can be set for 6/1 bits.

第4図はCP LJ 1によって実行されるシス戸ノ、
プログラムの概要を示プーフローチp −1−である。
Figure 4 shows the system executed by CP LJ 1,
An overview of the program is shown below.

1ス下このフローチャートに従って説明Jるど、jずイ
ニシャル処理100.表示処理101ど実行、  して
次にプログラムコンソール8のモードキーを読取り(ス
テップ102>、プログラム実行モードか否かを判断す
る(ステップ1o3)。次にプ[1グラムコンンール8
のキー入力を読取り、−1−人力に応じた処理を行なう
(ステップ104.105>。クリアキーが入力された
場合、所定のクリア処理を行ないクリア状態の表示パタ
ーンをレジスタにプリレットしくステップ106,10
9゜110>、表示処理101に戻る。プ【:1グラム
実行モード以外のモードに設定され、パター22才込み
キーが押されると、パターン用込み処理が実行される(
ステップ107,108)。
First step below: Initial processing 100.Explanation according to this flowchart. Display processing 101 is executed, and then the mode key of the program console 8 is read (step 102>, and it is determined whether it is in the program execution mode (step 1o3).
Reads the key input and performs processing according to -1-manpower (steps 104 and 105>. When the clear key is input, predetermined clearing processing is performed and the clear state display pattern is stored in the register. Step 106, 10
9°110>, the process returns to display processing 101. [: When a mode other than 1 gram execution mode is set and the putter 22 insert key is pressed, pattern insert processing is executed (
Steps 107, 108).

」記パターン書込み処理10Bの一つの具体例を第5図
のフローチャートに示している。パターンメモリみ処理
は、要するにプ「1グラlいコンソール8のキーボード
8Aを操作し、これから設定しようとするパターン番号
を特定でること、およびそのパターン番号にス・j応し
て64ビツトの各入出力データをオンと設定登録するか
、オフと設定登録づるか、あるいはオン・オフのいずれ
でも良いと設定づ−るかを特定覆ることの人力を受GJ
て、パターンメモリ51′)にお(Jる該当パターン番
号のエリア50−59のいり゛れかに先に説明したよう
なオンパターンおよびオフパターンを作成する処理であ
る。またこの設定登録の操作を容易にするために、操作
途中のAンオフパターンをプログラム二1ンソール8の
表示器8Bに表示J−る処理である。
A specific example of the pattern writing process 10B is shown in the flowchart of FIG. In short, pattern memory processing involves operating the keyboard 8A of the single-grain console 8, specifying the pattern number to be set, and setting each 64-bit input in accordance with that pattern number. It takes human effort to specify whether to register the output data as on, register it as off, or set it as either on or off.
This is a process of creating an on pattern and an off pattern as described above in areas 50 to 59 of the corresponding pattern number in the pattern memory 51'. In order to facilitate this process, the A-on-off pattern that is being operated is displayed on the display 8B of the program console 8.

この表示例としては、64ビツトの各入出力データに表
示器8Bの各桁を対応さU、その桁位置にオン、オフあ
るいはいずれでも良いの3値の状態を表示器るものであ
る。
As an example of this display, each digit of the display 8B corresponds to each 64-bit input/output data, and a three-value state of on, off, or any of the following is displayed at that digit position.

次に、ユーザプログラムの実行モードについて第4図に
従い説明する。モードキーをプログラム実行モードにす
ると1表示器813に実行モードを示す表示を行なうた
めの処理が4イさll′l(スーjツブ111)、ステ
ップ112以降のプログラム実行処理に進む。まず上述
した入力更新が行なわれ(ステップ112)、次にニー
−アブログラムメモリ5をアドレッシングするためのプ
ログラムカウンタPCがクリアされ(ステップ113)
1次に表示処理が行なわれ(ステップ114)、次にプ
ログラムカウンタPCでアドレッシングされるところの
1−ザ命令をメモリ5から読取り(ステップ115)、
その命令がコーザプログラムの最後のEND命令か否か
を判断しくステップ116〉、END命令でない場合に
その命令を実行しくステップ117)、次にプログラ1
8カウンタρCを歩進しくステップ11B)、ステップ
114に戻り、上記と同様に次の命令を読出して実行J
る。
Next, the execution mode of the user program will be explained with reference to FIG. When the mode key is set to the program execution mode, the process for displaying the execution mode on the 1 display 813 proceeds to step 4 (step 111) and the program execution process from step 112 onwards. First, the above-mentioned input update is performed (step 112), and then the program counter PC for addressing the knee program memory 5 is cleared (step 113).
First, display processing is performed (step 114), and then the 1-the instruction to be addressed by the program counter PC is read from the memory 5 (step 115).
It is determined whether the instruction is the last END instruction of the coser program (Step 116), and if it is not an END instruction, the instruction is executed (Step 117).
8 increments the counter ρC (step 11B), returns to step 114, reads and executes the next command in the same manner as above.
Ru.

ユーザプログラムの#I後まで実行すると、ステップ1
16から119に進み、キーボード8からの入力を読取
り、イのキー人力に応じた処理を行なう(ステップ12
0)、クリアキーもパターン処理キ丁−し操作されてい
ない場合、ステップ121.122を経てステップ12
6に進んで出力更新を行ない、再びステップ112から
実行する。
If the user program is executed after #I, step 1
Step 16 to step 119 reads the input from the keyboard 8, and performs processing according to the human power of the key A (step 12).
0), if the clear key is also not operated, the process goes through steps 121 and 122 to step 12.
The process advances to step 6 to update the output, and executes again from step 112.

クリア1−一が押された場合には、所定のクリア処理と
ともに表示をクリーアする処理がなされ(ステップ12
4,125)、その後ステップ126に進む。パターン
処理キーをオンにしている場合、本発明の要部となるパ
ターン比較処理(ステップ123)が実1jさね、その
後ステップ126の出力更新を行ない、再びステップ1
12からのユーリ゛プ1]ダラムの実行処理に進む。
When clear 1-1 is pressed, processing to clear the display is performed along with a predetermined clearing process (step 12).
4, 125), and then proceeds to step 126. When the pattern processing key is turned on, the pattern comparison processing (step 123), which is the main part of the present invention, is executed, and then the output is updated in step 126, and step 1 is executed again.
12] Proceed to execution processing of Durham.

第4図から明らかなように、パターン処理キーをオンに
している間は、コーザプ【1グラムの実行中にこれと並
行し、その−巡実行毎にパターン比較処理123が実行
される。このパターン比較処理123は、入出カメモリ
7の64ビツトの入出力データのiに態がパターンメモ
リ5Dに記憶された状態パターンのいずれかと一致する
かどうかを比較づるとともに、その比較処理に」:リ一
致が検出されたとき、その一致した状態パターンのパタ
ーン番号を表示器8Bに表示する処理を行なうとともに
、その識別番号のデータに対応づる1−記補助メモリの
109〜112のビットをプリセットする処理を行なう
ものである。
As is clear from FIG. 4, while the pattern processing key is turned on, the pattern comparison process 123 is executed in parallel with the execution of the Cozap 1 gram every time it is executed. This pattern comparison process 123 compares whether the i state of the 64-bit input/output data of the input/output memory 7 matches any of the state patterns stored in the pattern memory 5D, and also performs the comparison process. When a match is detected, the pattern number of the matched state pattern is displayed on the display 8B, and the bits 109 to 112 of the auxiliary memory corresponding to the identification number are preset. This is what we do.

上記パターン比較処理の詳細を第6図のフローチt −
、hに示している。第6図に従って説明すると、まずパ
ターン番号をOにしくステップ300)、そのパターン
番号に対応するパターンメモリの内のオフパターンを読
取り(ステップ301.302)、そのオフパターンの
64ピツ1へが全てO++か否かを判断しくステップ3
03)、全てO11である場合は次に同一1ニパタ一ン
番号のオンパターンを読取り(ステップ301,305
>、−でのオンパターンの64ビツトが全てll O1
1か否かを判断する(ステップ306)。オンパターン
も全て11011であるのはそのパターン番号に14何
も設定されていないと判断し、パターン番号を次の41
号にセットしくステップ316)、パターン番号が10
になったか否か、J−なわちパターン番号9までの処理
が終了したかどうかを判断しくステップ3.17 > 
、最後まで達していなtiJれば次のパターン番目につ
いてステップ301以降の上記の処理を行なう。
The details of the above pattern comparison process are explained in the flowchart t- in FIG.
, h. To explain according to FIG. 6, first, set the pattern number to O (step 300), read the off pattern in the pattern memory corresponding to that pattern number (steps 301 and 302), and all of the 64 bits 1 of the off pattern are read. Step 3 to determine whether it is O++ or not
03), if all are O11, then read the on pattern with the same 1 double pattern 1 number (steps 301, 305).
>, - all 64 bits of on pattern are ll O1
It is determined whether or not it is 1 (step 306). The reason why all the on patterns are 11011 is because 14 is not set for that pattern number, and the pattern number is changed to the next 41.
Step 316), the pattern number is 10.
Step 3.17>
, if tiJ has not reached the end, the above processing from step 301 onward is performed for the next pattern.

あるパターン番号のパターンメモリになんらかの状態パ
ターンが設定されていればステップ307に進む。その
場合、該当パターン番号のパターンメモリのオフパター
ンを読取り(ステップ307.30fl)、入出カメモ
リ7のデータと比較する(ステップ309)。この比較
は、パターンメモリのオフパターンの64ピツ]〜のデ
ータと、入出カメモリ7の64ビツトのデータとを、各
番号どうしに1ピツ]〜ずつ論理積をとることによって
行なわれる。そして、6/Iビツトと64ビ・ントの1
ピッI−ずつの論]!p積の結果が全て0″であるか否
かが次のステップ310で判断される。この結果が全て
II Ollである場合はオフパターンについて一致し
ており、一つでも1″が存在するとオフパターンについ
て一致していないことになる。
If some state pattern is set in the pattern memory of a certain pattern number, the process advances to step 307. In that case, the OFF pattern of the pattern memory with the corresponding pattern number is read (steps 307 and 30fl) and compared with the data in the input/output memory 7 (step 309). This comparison is performed by logically multiplying the 64-bit data of the off pattern in the pattern memory and the 64-bit data of the input/output memory 7 by 1 pit] for each number. And 6/I bit and 1 of 64 bit
Pi-I-Zuzuno Theory]! It is determined in the next step 310 whether or not the p-product results are all 0''. If all of the results are II Oll, the off pattern matches, and if there is even one 1'', the off pattern is determined. This means that the patterns do not match.

一致していない場合は先のステップ316に進む。If they do not match, the process advances to step 316.

一致している場合はステップ311以降に進み、次にオ
ンパターンについて一致するか否かが判断される。つま
り、該当番号のオンパターンを読取り(ステップ311
.312>、そのオンパターンの各ビットと、入出カメ
モリ7のデータの補数(反転論理)との論I!1′!伯
を1ビツトずつとることによってパターンの比較を行な
う(ステップ313)。この論理積の結果1qられた6
4ビツトが全て“0゛′か否かを判断するくステップ3
1/l)。
If they match, the process proceeds to step 311 and subsequent steps, and it is then determined whether or not the on pattern matches. In other words, read the on pattern of the corresponding number (step 311
.. 312>, the logic between each bit of the on pattern and the complement (inverted logic) of the data in the input/output memory 7 I! 1′! Comparison of patterns is performed by taking the numbers one bit at a time (step 313). The result of this logical product is 1q, which is 6.
Step 3: Determine whether all 4 bits are “0” or not.
1/l).

全て′0′′でない場合はパターンが不一致であり、イ
の場合は先のステップ316に進む。jqられlζ結果
が全て110 IIであるのはパターンが一致しだので
あり、その場合は、次のステップ315でそのパターン
番号を表示用レジスタにプリセットするとと6に、補助
メモリ(109〜112)にこのパターン?l qをプ
リセットする。なお、補助メモリを4ビツトとしたのは
、この実施例における状態パターンが10種であり、こ
れは109〜112の各ピッI〜の暖み付けでもって表
現できることによる。
If all are not ``0'', the patterns do not match, and if ``A'', the process advances to step 316. The reason why all the jq and lζ results are 110 II is because the patterns match. In that case, in the next step 315, the pattern number is preset in the display register and the auxiliary memory (109 to 112) is preset. This pattern? Preset lq. The reason why the auxiliary memory is 4 bits is because there are 10 types of state patterns in this embodiment, which can be expressed by warming each of the pitches 109 to 112.

これによって第4図のステップ114の表示処理におい
1て、表示器8Bに一致した状態パターンのパターン番
号が表示される。そして、次のステップ115で例えば
異常処理命令なるユーザ命令が読み出されると、上記補
助メモリ(109〜112)の内容が読み出され、これ
がステップ11Gの次のステップ117でその内容(4
ビツトの論理積)に応じた処理、例えば警報出ノJやプ
ログラム停止等適宜な処理がなされる。このステップ1
17の具体例を第7図に示しである。
As a result, in the display process of step 114 in FIG. 4, the pattern number of the matching state pattern is displayed on the display 8B. When a user command such as an abnormal processing command is read in the next step 115, the contents of the auxiliary memory (109 to 112) are read out, and the contents (4) are read in the next step 117 after step 11G.
(logical product of bits), appropriate processing such as issuing an alarm or stopping the program is performed. This step 1
Seventeen specific examples are shown in FIG.

第7図は異常処理命令が実行されるときのプログラムを
ラダー回路図で示したものである。補助メモリの各ピッ
1−は100から順に1.2.=1゜8の重み付けがな
され、図示の例はパターン番号が5″であるとき、出力
リレー12がオンする場合を示している。
FIG. 7 is a ladder circuit diagram showing a program when an abnormality processing instruction is executed. Each pin 1- of the auxiliary memory is sequentially numbered 1, 2, starting from 100. The illustrated example shows a case where the output relay 12 is turned on when the pattern number is 5''.

なお、入出カメモリ7の入出力データが設定されたすべ
ての状態パターンと不一致の場合、ステップ317から
318に進み、パターンが一致しない旨の表示を行ない
、次のステップ31って補助メモリ(109〜112)
の各ビットを全て11011にづ−る処理がなされる。
If the input/output data of the input/output memory 7 does not match all of the set state patterns, the process proceeds from step 317 to 318, where a display indicating that the patterns do not match is performed, and the next step 31 is to store the auxiliary memory (109 to 318). 112)
Processing is performed in which all bits of 11011 are set.

なお、−1!l1r一致が検出されると、表示されたパ
ターン番号J3よび補助メモリ(109〜112)の内
容は次に一致が検出されるまではそのまま保持される。
In addition, -1! When an l1r match is detected, the displayed pattern number J3 and the contents of the auxiliary memory (109-112) are held as they are until the next match is detected.

なお、上記実施例では、パターン番目を」−ド化して補
助メモリに格納したが、この発明はこれに限定されるも
のではなく、補助メモリの各ビットをパターン番号と1
対1に対応さ1!゛ても良いことは勿論である。この場
合にはパターン番号ど]対1に対応して出力リレーが駆
動されることになる。
Note that in the above embodiment, the pattern number is converted into a "-" code and stored in the auxiliary memory, but the present invention is not limited to this, and each bit of the auxiliary memory is converted into a pattern number and 1.
Corresponds to 1 to 1! Of course, it is okay to do so. In this case, the output relay will be driven in correspondence with pattern number 1 to 1.

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

第1図はこの発明を適用したプログラマブル・コントロ
ーラの概略構成を示すブロック図、第2図は同上コント
ローラにおけるRAM領域のメモリマツプ、第3図は同
上コントローラにおけるユーザプログラムメモリのメモ
リマツプ、第4図。 第5図、第6図は同上コントローラにおけるCP()に
よって実行されるシステムプログラムの構成を示すフロ
ーチャート、第7図は補助メモリに格納したパターン番
号をユーザプログラムに組込んだ例を継電器ラダー図形
式で示す図である。 1・・・・・・CPU 5・・・・・・ユーザプログラムメモリ6・・・・・・
入出力装置 7・・・・・・入出カメモリ 8・・・・・・プログラ11コンソール3D・・・補助
メモリ 5D・・・パターンメモリ 特W[出願人 立石電機株式会社 第1図 第7図 第2図
FIG. 1 is a block diagram showing a schematic configuration of a programmable controller to which the present invention is applied, FIG. 2 is a memory map of the RAM area in the controller, FIG. 3 is a memory map of the user program memory in the controller, and FIG. Figures 5 and 6 are flowcharts showing the structure of the system program executed by CP() in the above controller, and Figure 7 shows an example of incorporating the pattern number stored in the auxiliary memory into the user program in relay ladder diagram form. It is a figure shown by. 1... CPU 5... User program memory 6...
Input/output device 7...Input/output memory 8...Program 11 Console 3D...Auxiliary memory 5D...Pattern memory special W [Applicant Tateishi Electric Co., Ltd. Fig. 1 Fig. 7 Figure 2

Claims (1)

【特許請求の範囲】[Claims] (1)スキャニング式のプログラマブル・コント[]−
ラにおいて、全入出力データについてAン。 Aフまたはいずれでも良いの3値で表わした任意の状態
パターンを複数パターン設定して記憶しておく手段と、
]−ザブログラムの実行と並行して、実際の入出力デー
タの状態が、に記記憶された状態パターンのいずれかと
一致するかどうかを比較する手段と、この比較手段で一
致が検出されたとき、その一致した状態パターンの識別
?l@を表示する手段と、−ヒ記比較手段で一致が検出
されたどき、その一致1ノだ状態パターンの識別11号
のデータを、ユーザ命令にて任意にアクセスして演算処
理の対象として利用可能な補助メモリに格納するデータ
更新手段とを設けたことを特徴とする状態パターン比較
機能を備えたプログラマブル・コントローラ。
(1) Scanning type programmable control []-
A for all input/output data. means for setting and storing a plurality of arbitrary state patterns expressed in three values of A-F or either;
] - means for comparing whether the state of the actual input/output data matches any of the state patterns stored in in parallel with the execution of the program; and when a match is detected by the comparing means; Identification of that matched state pattern? When a match is detected by the means for displaying l@ and the comparing means, the data of identification number 11 of the matching 1 status pattern is arbitrarily accessed by a user command and used as a target for calculation processing. A programmable controller with a state pattern comparison function, characterized in that the programmable controller is provided with means for updating data stored in available auxiliary memory.
JP57195687A 1982-11-08 1982-11-08 Programable controller having state pattern comparing function Pending JPS5985505A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP57195687A JPS5985505A (en) 1982-11-08 1982-11-08 Programable controller having state pattern comparing function

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP57195687A JPS5985505A (en) 1982-11-08 1982-11-08 Programable controller having state pattern comparing function

Publications (1)

Publication Number Publication Date
JPS5985505A true JPS5985505A (en) 1984-05-17

Family

ID=16345325

Family Applications (1)

Application Number Title Priority Date Filing Date
JP57195687A Pending JPS5985505A (en) 1982-11-08 1982-11-08 Programable controller having state pattern comparing function

Country Status (1)

Country Link
JP (1) JPS5985505A (en)

Citations (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPS57116559A (en) * 1981-01-13 1982-07-20 Meidensha Electric Mfg Co Ltd System operation state automatic recognition device

Patent Citations (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPS57116559A (en) * 1981-01-13 1982-07-20 Meidensha Electric Mfg Co Ltd System operation state automatic recognition device

Similar Documents

Publication Publication Date Title
US3264615A (en) Memory protection system
JPS58222310A (en) Programmable controller provided with state pattern comparison function
JPS60262204A (en) Programmable controller
JPH03137518A (en) Diagnosing apparatus of fault
EP0148951A1 (en) System for checking abnormality in programmable controller
JPS5985505A (en) Programable controller having state pattern comparing function
JPS6041102A (en) Sequence control device
JPH0377522B2 (en)
JP2701842B2 (en) Fault diagnosis device for programmable controller
JPS58144207A (en) Programmable controller
JPH08211906A (en) Controller unit
JPH02170204A (en) Condition setting system
JPS62251832A (en) Raising system for electronic apparatus
JP3224043B2 (en) Initial processing method of intelligent graphic operation panel
JPH01128147A (en) Arithmetic unit
JPS58172712A (en) Monitor system of sequence controller
JP2504408B2 (en) Power plant monitoring device
JPS59216228A (en) Processing system of character data conversion
JPH083751B2 (en) Operation sequence check method on operation panel
JPH0411881B2 (en)
JPS58132809A (en) Programmable controller
JPS6113343A (en) Console device
JPS58105304A (en) Monitor displaying system of programmable controller
JPS63279311A (en) Information processor
JPH02113302A (en) Programmable controller