JPH0895611A - Programmable controller and its maintenance tool - Google Patents
Programmable controller and its maintenance toolInfo
- Publication number
- JPH0895611A JPH0895611A JP6257289A JP25728994A JPH0895611A JP H0895611 A JPH0895611 A JP H0895611A JP 6257289 A JP6257289 A JP 6257289A JP 25728994 A JP25728994 A JP 25728994A JP H0895611 A JPH0895611 A JP H0895611A
- Authority
- JP
- Japan
- Prior art keywords
- data
- simulation
- unit
- memory
- control program
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Pending
Links
Landscapes
- Programmable Controllers (AREA)
Abstract
Description
【0001】[0001]
【産業上の利用分野】本発明は、監視や制御のためのプ
ログラマブルコントローラの制御プログラムをデバック
するのに好適なプログラマブルコントローラおよびその
保守ツールに関する。BACKGROUND OF THE INVENTION 1. Field of the Invention The present invention relates to a programmable controller suitable for debugging a control program of a programmable controller for monitoring and control, and a maintenance tool therefor.
【0002】[0002]
【従来の技術】図15に従来のプログラマブルコントロ
ーラのブロック構成図を示す。2. Description of the Related Art FIG. 15 shows a block diagram of a conventional programmable controller.
【0003】図において、プログラマブルコントローラ
1は、主制御部2と外部入出力部3とプログラム格納部
4とデータメモリ部5とから構成され、データ線6によ
って接続されている。In the figure, a programmable controller 1 comprises a main control unit 2, an external input / output unit 3, a program storage unit 4 and a data memory unit 5, which are connected by a data line 6.
【0004】主制御部2は、演算処理部としてのマイク
ロプロセッサを備え、プログラム格納部4に格納された
制御プログラムに従ってデータメモリ部5の演算用デー
タを用いて演算処理を実行してその結果をデータメモリ
部5へ格納する。The main control unit 2 includes a microprocessor as an arithmetic processing unit, executes arithmetic processing using the arithmetic data in the data memory unit 5 according to a control program stored in the program storage unit 4, and outputs the result. The data is stored in the data memory unit 5.
【0005】外部入出力部3は、プラントのデータを取
り込みデータメモリ部5へ格納する一方、データメモリ
部5へ格納されたデータをプラントへ出力するインター
フェースである。The external input / output unit 3 is an interface that takes in plant data and stores it in the data memory unit 5, and outputs the data stored in the data memory unit 5 to the plant.
【0006】プログラム格納部4は、後述する保守ツー
ルにより作成された制御プログラムを格納する。データ
メモリ部5は、演算用のデータを格納する。The program storage unit 4 stores a control program created by a maintenance tool described later. The data memory unit 5 stores data for calculation.
【0007】上記したプログラマブルコントローラ1で
は、図16に示す制御プログラムによる処理が実行さ
れ、まず、外部入出力部3を介してプラントから取込ま
れたデータがデータメモリ部5の指定されたビットアド
レスへ順次格納される(S1)。In the programmable controller 1 described above, the processing by the control program shown in FIG. 16 is executed. First, the data taken in from the plant via the external input / output unit 3 is assigned to the designated bit address of the data memory unit 5. Are sequentially stored in (S1).
【0008】次に、プログラム格納部4から制御プログ
ラムが順次取出され(S2)、命令コードに従ってデー
タメモリ部5へ格納されたデータを用いて演算処理が順
次実行され、演算処理された結果がデータメモリ部5の
指定されたビットアドレスへ格納される(S3,S
4)。Next, the control program is sequentially taken out from the program storage unit 4 (S2), the arithmetic processing is sequentially executed using the data stored in the data memory unit 5 according to the instruction code, and the result of the arithmetic processing is the data. It is stored in the designated bit address of the memory unit 5 (S3, S
4).
【0009】全ての制御プログラムの命令の処理が終了
すると、データメモリ部5の内容が外部入出力部3から
プラントへ出力される(S5)。これによって、プラン
ト機器の制御がプログラマブルコントローラ1によって
される。上記処理は、所定周期で繰り返し実行される。When the processing of all the control program instructions is completed, the contents of the data memory section 5 are output from the external input / output section 3 to the plant (S5). As a result, the programmable controller 1 controls the plant equipment. The above process is repeatedly executed at a predetermined cycle.
【0010】例えば、制御プログラムの一部分が図17
に示すものとすると、主制御部2は、命令P1で外部入
力データに対応するデータメモリ部5のビットアドレス
「0001」と「0002」のAND(論理積)を演算
出力し、その結果をビットアドレス「0006」へ格納
する。For example, a part of the control program is shown in FIG.
Then, the main control unit 2 calculates and outputs the AND (logical product) of the bit addresses “0001” and “0002” of the data memory unit 5 corresponding to the external input data by the instruction P1, and outputs the result as a bit. Store at address “0006”.
【0011】次に、主制御部2は命令P2で外部入力デ
ータに対応するデータメモリ部5のビットアドレス「0
003」と「0004」のOR(論理和)を演算し、そ
の結果をビットアドレス「0007」へ格納する。Next, the main control unit 2 issues a bit address "0" of the data memory unit 5 corresponding to the external input data by the instruction P2.
An OR (logical sum) of "003" and "0004" is calculated, and the result is stored in the bit address "0007".
【0012】さらに、命令P3でビットアドレス「00
06」と「0007」と外部入力データに対応する「0
005」とのOR(論理和)を演算し、その結果をビッ
トアドレス「0008」へ格納する。Further, the bit address "00" is given by the instruction P3.
06 ”and“ 0007 ”and“ 0 ”corresponding to external input data
An OR (logical sum) with "005" is calculated, and the result is stored in the bit address "0008".
【0013】そして、主制御部2はビットアドレス「0
008」のデータに応じて命令P4でオンディレイタイ
マを動作または不動作させる。制御プログラムは、この
ような演算処理が多数組合せられた多数の処理ステップ
からなり、大規模で、かつ、複雑な構成となっている。Then, the main control unit 2 sets the bit address "0".
The on-delay timer is activated or deactivated by the instruction P4 according to the data of "008". The control program includes a large number of processing steps in which a large number of such arithmetic processes are combined, and has a large-scale and complicated structure.
【0014】ところで、プログラマブルコントローラ1
が用いる制御プログラムは外部の図示省略するプログラ
ム作成装置によって作成されて伝送手段によってプログ
ラマブルコントローラ1のプログラム格納部4に格納さ
れる。このとき、作成された制御プログラムに誤りがな
いように、いわゆるデバックが、従来、次のように実行
されていた。By the way, the programmable controller 1
The control program used by is created by an external program creating device (not shown) and is stored in the program storage unit 4 of the programmable controller 1 by the transmitting means. At this time, so-called debugging has conventionally been executed as follows so that the created control program is correct.
【0015】まず、プログラマブルコントローラ1に設
ける外部入出力部3との接続部にプラントを模擬するス
イッチや電圧発生器等を接続し、また、表示灯やブザー
等を接続して外部入出力部3を介してデータメモリ部5
へ外部入出力データを格納していた。また、プログラマ
ブルコントローラ1と図示省略する保守ツールを接続し
て、保守ツールから外部入出力部3をバイパスさせて外
部入出力部3からのデータに相当する模擬用データを格
納していた。First, a switch simulating a plant, a voltage generator, or the like is connected to a connection portion with the external input / output unit 3 provided in the programmable controller 1, and an indicator light, a buzzer, or the like is connected to the external input / output unit 3. Through the data memory unit 5
External input / output data was stored in. Further, the programmable controller 1 is connected to a maintenance tool (not shown), the external I / O unit 3 is bypassed from the maintenance tool, and the simulation data corresponding to the data from the external I / O unit 3 is stored.
【0016】そして、データメモリ部5に格納された外
部入出力データと模擬用データとを用いて制御プログラ
ムのデバックが実行されていた。Then, the debug of the control program is executed using the external input / output data and the simulation data stored in the data memory unit 5.
【0017】[0017]
【発明が解決しようとする課題】しかしながら、上記し
た従来のプログラマブルコントローラ1では、デバック
のために煩雑な手間と多大の時間を要し、効率が大変悪
いという問題がある。However, the above-mentioned conventional programmable controller 1 has a problem that it requires a lot of trouble and a lot of time for debugging, and the efficiency is very poor.
【0018】まず、第1に、デバックのために模擬用デ
ータを全ての処理ステップについて設定することができ
ないという問題がある。First, there is a problem that the simulation data cannot be set for all processing steps due to debugging.
【0019】一般に、制御プログラムは、外部入力デー
タを用いて第一段の処理がされた後にその演算の結果デ
ータを用いて次段の条件判定や演算処理がされるという
多数の処理ステップから構成されている。In general, the control program is composed of a large number of processing steps in which the external stage input data is used to perform the first stage process, and then the result data of the operation is used to perform the next stage condition determination and arithmetic process. Has been done.
【0020】このような場合に、外部入出力部3から入
力可能な外部入力データに対応するビットアドレスでは
模擬用データの設定が容易にできるが、演算処理結果に
対応するビットアドレスへの模擬用データの設定は簡単
ではなかった。In such a case, although it is possible to easily set the simulation data with the bit address corresponding to the external input data that can be input from the external input / output unit 3, it is possible to simulate the bit address corresponding to the operation processing result. Setting the data was not easy.
【0021】これを簡単な例で説明すると、図17に示
す制御プログラムでは、外部入力データに対応するビッ
トアドレス「0001」,「0002」,「000
3」,「0004」,「0005」のビットの内容は、
外部入出力部3から任意に設定することができるが、命
令P3による演算出力であるビットアドレス「000
8」のビットの内容を任意に設定することができなかっ
た。Explaining this as a simple example, in the control program shown in FIG. 17, bit addresses "0001", "0002", "000" corresponding to external input data are given.
The contents of the bits "3", "0004", and "0005" are
Although it can be arbitrarily set from the external input / output unit 3, the bit address "000" which is the operation output by the instruction P3 is output.
The content of the 8 "bit could not be set arbitrarily.
【0022】この場合、従来、強制的に模擬のためビッ
トアドレス「0008」を「1」にしようとすると、前
段の処理ステップの内容に応じて、例えば、ビットアド
レス「0005」を「1」あるいは、命令P1または命
令P2のビットアドレス「0006」,「0007」の
いずれかが「1」となるようにビットアドレス「000
1」「0002」若しくはビットアドレス「0003」
「0004」のビットの内容を設定する手間を要した。In this case, when the bit address "0008" is conventionally forced to be set to "1" for simulation, for example, the bit address "0005" is set to "1" or "1" depending on the content of the processing step of the preceding stage. , The bit address “000” so that either the bit address “0006” or “0007” of the instruction P1 or the instruction P2 becomes “1”.
1 "" 0002 "or bit address" 0003 "
It takes time and effort to set the contents of the bit “0004”.
【0023】このような模擬データの設定作業は、制御
プログラムのアルゴリズムが大規模で複雑となると、デ
バックのための模擬データの設定に多大な時間を要する
という問題があった。Such a simulation data setting operation has a problem that it takes a lot of time to set the simulation data for debugging when the algorithm of the control program becomes large-scale and complicated.
【0024】また、第2に、プログラマブルコントロー
ラ1をデバックするとき専用の保守ツールや専用の各種
試験器が占有され、上記のようにデバックに多くの時間
を要するとその間次のプログラマブルコントローラ1の
デバックに移ることができず、生産効率が悪いという問
題があった。Secondly, when the programmable controller 1 is debugged, a dedicated maintenance tool and various dedicated testers are occupied, and if it takes a lot of time for debugging as described above, the debugging of the next programmable controller 1 will be interrupted. However, there was a problem that production efficiency was poor.
【0025】また、第3に、図17で説明した制御プロ
グラムでは、命令P3のビットアドレス「0008」へ
ビット「1」を設定しても、一度演算すれば更新されて
ビットアドレス「0008」がビット「0」となってし
まうことがあり再び設定し直す必要があった。Thirdly, in the control program described with reference to FIG. 17, even if the bit "1" is set to the bit address "0008" of the instruction P3, the bit address "0008" is updated by the operation once. The bit might be "0", and it was necessary to set it again.
【0026】また、第4に、デバック作業は、例えば、
1ケ月に亘ることもあり、その間にプログラマブルコン
トローラ1の電源を切る必要となる場合も少なくない。
この場合に、データメモリ部5はメモリのバックアップ
がされていないため、電源を切れば、次の日に再度デバ
ックのための模擬データを設定し直す手間を要するとい
う問題があった。Fourthly, the debugging work is, for example,
It may take one month, and it is often the case that the programmable controller 1 needs to be powered off during that period.
In this case, since the memory of the data memory unit 5 is not backed up, there is a problem that if the power is turned off, it is necessary to reset simulated data for debugging again on the next day.
【0027】そこで、本発明は、簡単で、かつ、短時間
にしかも効率的に、デバックのための模擬用データを設
定可能とするプログラマブルコントローラおよびその保
守ツールを提供することを目的とする。Therefore, an object of the present invention is to provide a programmable controller and a maintenance tool for the same which are capable of setting simulation data for debugging easily and efficiently in a short time.
【0028】[0028]
【課題を解決するための手段】請求項1の発明は、プラ
ントデータを取込みプラントへデータを出力する外部入
出力部と、演算処理のための制御専門言語による制御プ
ログラムを格納するプログラム格納部と、演算用データ
とその演算結果データを格納する演算用メモリと制御プ
ログラムの動作模擬をする模擬用データを格納する演算
用メモリとビットアドレスが対応して設けられる模擬用
メモリとからなるデータメモリ部と、演算用メモリと模
擬用メモリのそれぞれにビットアドレスが対応して設け
られビットアドレス毎にいずれの演算用メモリまたは模
擬用メモリのデータを取出すか、あるいはデータの書込
みを禁止する情報を模擬実行情報として予め設定する条
件メモリ部と、保守ツールから入力された動作模擬のた
めの模擬用データを模擬用メモリへ格納する一方、模擬
実行情報を条件メモリ部へ格納する保守伝送部と、演算
用メモリの演算用データを用いて制御プログラムによっ
て演算を実行し、その演算結果データを演算用メモリへ
格納する一方、制御プログラムがデータ取出し命令で、
かつ、条件メモリ部の対応するビットアドレスが模擬実
行のとき模擬用メモリの模擬用データを取出して制御プ
ログラムによって演算し、制御プログラムがデータの書
込み命令で、かつ、条件メモリ部の対応するビットアド
レスが模擬実行のときデータの書込みを禁止する主制御
部とを設けるようにしたものである。According to a first aspect of the present invention, there is provided an external input / output unit for receiving plant data and outputting the data to the plant, and a program storage unit for storing a control program in a control specialized language for arithmetic processing. , A data memory unit comprising a calculation memory for storing calculation data and calculation result data thereof, a calculation memory for storing simulation data for simulating the operation of a control program, and a simulation memory provided with corresponding bit addresses And the arithmetic memory and the simulation memory are provided with corresponding bit addresses, and the data of which arithmetic memory or simulation memory is taken out for each bit address or the information that prohibits the writing of data is simulated is executed. Condition memory part preset as information and simulation data input from the maintenance tool for operation simulation The maintenance transmission unit that stores the simulation execution information in the condition memory unit while storing it in the simulation memory and the calculation data in the calculation memory executes the calculation by the control program, and the calculation result data is stored in the calculation memory. While storing, the control program is a data extraction command,
Moreover, when the corresponding bit address of the condition memory section is the simulation execution, the simulation data of the simulation memory is taken out and operated by the control program, and the control program is a data write command and the corresponding bit address of the condition memory section. Is provided with a main control unit that prohibits writing of data during simulated execution.
【0029】請求項2の発明は、制御プログラムを画面
に表示する表示部と、オペレータが情報を入力する入力
部と、制御プログラムを格納するプログラム格納部と、
模擬用データを設定する模擬データ設定部と、設定され
た模擬用データと模擬実行情報とをプログラマブルコン
トローラへ伝送する伝送部と、入力部を介してプログラ
ム格納部から制御プログラムを取り出して、表示部へ表
示すると共に、表示された制御プログラムに基づいて入
力部から入力された模擬用データと模擬実行情報とを模
擬データ設定部へ設定し、この模擬データ設定部に設定
された模擬データと模擬実行情報とを伝送部へ渡す制御
部とを設けるようにしたものである。According to a second aspect of the present invention, a display unit for displaying the control program on the screen, an input unit for the operator to input information, and a program storage unit for storing the control program,
A simulation data setting unit for setting simulation data, a transmission unit for transmitting the set simulation data and simulation execution information to the programmable controller, and a control program taken out from the program storage unit via the input unit and displayed on the display unit. The simulation data and the simulation execution information input from the input section are set in the simulation data setting section based on the displayed control program, and the simulation data and the simulation execution set in the simulation data setting section are set. A control unit for transferring information and information to the transmission unit is provided.
【0030】請求項3の発明は、請求項2記載のプログ
ラマブルコントローラの保守ツールにおいて、プログラ
マブルコントローラに設定された模擬実行のためのデー
タを格納する模擬データ保存部を設け、要求により模擬
実行のためのデータを伝送部を介して取込んで模擬デー
タ保存部へ格納する一方、この模擬データ保存部に格納
されたデータを取出しプログラマブルコントローラへ設
定するように伝送部へ出力する手段を制御部に設けるよ
うにしたものである。According to a third aspect of the present invention, in the programmable controller maintenance tool according to the second aspect, a simulated data storage unit for storing data for the simulated execution set in the programmable controller is provided, and the simulated execution is performed upon request. The control unit is provided with means for taking in the data of the above data via the transmission unit and storing it in the simulated data storage unit, and outputting the data stored in this simulated data storage unit to the transmission unit so as to set it in the programmable controller. It was done like this.
【0031】請求項4の発明は、請求項2または請求項
3記載のプログラマブルコントローラの保守ツールにお
いて、模擬用データと模擬実行によって得られる演算結
果データを予め想定してデータベースに登録する模擬デ
ータ登録部を設け、この模擬データ登録部に登録された
模擬用データを順次プログラマブルコントローラへ設定
して制御プログラムの模擬実行によって得られた演算結
果データと想定した演算結果データとから制御プログラ
ムの検証をする手段を制御部に設けるようにしたもので
ある。According to a fourth aspect of the present invention, in the programmable controller maintenance tool according to the second or third aspect, simulated data registration is performed in which the simulation data and the operation result data obtained by the simulation execution are assumed in advance and registered in the database. Section is provided, and the simulation data registered in the simulation data registration section are sequentially set in the programmable controller to verify the control program from the calculation result data obtained by the simulation execution of the control program and the assumed calculation result data. The means is provided in the control unit.
【0032】[0032]
【作用】請求項1の発明によれば、制御プログラムがデ
ータの取出し命令で、かつ、条件メモリ部の対応するビ
ットアドレスが模擬実行でないとき、演算用メモリのデ
ータを用いて命令の実行がされる。また、制御プログラ
ムがデータ取出し命令で、かつ、条件メモリ部の対応す
るビットアドレスが模擬実行のとき、模擬用メモリのデ
ータを用いて命令の実行がされる。一方、制御プログラ
ムがデータの書込み命令で、かつ、条件メモリ部の対応
するビットアドレスが模擬実行でないとき、演算用メモ
リへデータの書込みが実行される。また、制御プログラ
ムがデータ書込み命令で、かつ、条件メモリ部の対応す
るビットアドレスの模擬実行のとき、データの書込みが
禁止される。これによって、予め条件メモリ部の所定の
ビットアドレスに模擬実行を設定すれば制御プログラム
の命令がデータの取出しのとき、模擬用メモリのデータ
が用いられ、データの書込みのときは、書込み禁止され
る。従って、制御プログラムの前の処理でされた結果に
より所定のビットアドレスのデータが上書きされること
がなく、任意のビットアドレスに模擬データを設定で
き、デバック時間の大幅な短縮が図られる。According to the first aspect of the present invention, when the control program is a data fetching instruction and the corresponding bit address of the condition memory section is not the simulated execution, the instruction is executed using the data in the operation memory. It Further, when the control program is a data fetching instruction and the corresponding bit address of the condition memory unit is simulated execution, the instruction is executed using the data in the simulation memory. On the other hand, when the control program is a data write command and the corresponding bit address of the condition memory unit is not simulated execution, data writing is executed in the arithmetic memory. Further, when the control program is a data write command and the simulated execution of the corresponding bit address of the condition memory section is performed, the data write is prohibited. As a result, if simulation execution is set in advance at a predetermined bit address of the condition memory unit, the data of the simulation memory is used when the instruction of the control program fetches the data, and the write is prohibited when the data is written. . Therefore, the result of the previous process of the control program does not overwrite the data of the predetermined bit address, the simulated data can be set to an arbitrary bit address, and the debug time can be greatly shortened.
【0033】請求項2の発明によれば、表示部に表示さ
れる制御プログラムを見ながら任意のビットアドレスに
模擬用データを設定することができるからデバック時間
の短縮が図れる。According to the second aspect of the invention, the debugging data can be shortened because the simulation data can be set to an arbitrary bit address while looking at the control program displayed on the display section.
【0034】請求項3の発明によれば、必要なときプロ
グラマブルコントローラの模擬用データを保守ツールへ
取込み保存し、デバック時に再びプログラマブルコント
ローラへ設定するようにしたからデバックが即座に開始
することができ、デバック作業が効率的となる。According to the invention of claim 3, debugging data can be immediately started because the simulation data of the programmable controller is taken in and saved in the maintenance tool when necessary and set again in the programmable controller when debugging. , Debugging work becomes efficient.
【0035】請求項4の発明によれば、予め保守ツール
に模擬用データを登録しておき、順次模擬用データをプ
ログラマブルコントローラへ設定してデバックするため
にデバック時間の短縮が図られる。According to the fourth aspect of the present invention, since the simulation data is registered in the maintenance tool in advance and the simulation data is sequentially set in the programmable controller for debugging, the debugging time can be shortened.
【0036】[0036]
【実施例】以下、本発明の実施例について図面を参照し
て説明する。Embodiments of the present invention will be described below with reference to the drawings.
【0037】図1は、本発明の第1実施例を示すプログ
ラマブルコントローラのブロック構成図であり、従来例
を示す図15と同一符号は同一部分または相当部分を示
し、図1において、図15と異なる点は、条件メモリ部
7と保守伝送部8を追設すると共に、データメモリ部5
の構成を異にしデータメモリ部9として保守ツール10
を接続している。FIG. 1 is a block diagram of a programmable controller showing the first embodiment of the present invention. The same reference numerals as those of FIG. 15 showing a conventional example indicate the same or corresponding portions, and in FIG. The difference is that the condition memory unit 7 and the maintenance transmission unit 8 are additionally provided and the data memory unit 5 is added.
Maintenance tool 10 as a data memory unit 9 having a different configuration.
Are connected.
【0038】ここで、条件メモリ部7は、データメモリ
部9に格納される演算用データと模擬用データのいずれ
のデータを用いて演算処理するか、あるいは、演算処理
結果を書込禁止するか否かを模擬実行情報として予め設
定するものである。Here, the condition memory unit 7 uses which of the calculation data and the simulation data stored in the data memory unit 9 for the calculation processing, or whether the calculation processing result is write-protected. Whether or not it is set in advance as simulated execution information.
【0039】保守伝送部8は、模擬実行のために保守ツ
ール10から入力された模擬用データをデータメモリ部
9の模擬用メモリへ格納する一方、模擬実行情報を条件
メモリ部7へ格納するものである。The maintenance transmission unit 8 stores the simulation data input from the maintenance tool 10 in the simulation memory of the data memory unit 9 for the simulation execution, and also stores the simulation execution information in the condition memory unit 7. Is.
【0040】データメモリ部9は、演算用データを格納
する演算用メモリと、この演算用メモリとビットアドレ
スが対応して模擬用データを格納する模擬用メモリとか
らなっている。The data memory unit 9 is composed of a calculation memory for storing calculation data and a simulation memory for storing simulation data in which bit addresses correspond to the calculation memory.
【0041】次に、デバックに先立って保守ツール10
とプログラマブルコントローラ1Aとが接続される。そ
して、保守ツール10からオペレータの操作によりデー
タメモリ部9の模擬用メモリのビットアドレスに模擬デ
ータが格納され、条件メモリ部7の対応するビットアド
レスに模擬実行情報が格納される。Next, prior to debugging, the maintenance tool 10
And the programmable controller 1A are connected. Then, the operator operates the maintenance tool 10 to store the simulation data in the bit address of the simulation memory of the data memory unit 9, and the simulation execution information in the corresponding bit address of the condition memory unit 7.
【0042】すなわち、データメモリ部9は、図2に示
すように、ビットアドレス0〜nに対してビット「1」
または「0」を格納するエリアを有する演算用メモリ9
aと、この演算用メモリ9aと同一のアドレス空間とし
てビットアドレスが対応する模擬用メモリを設け、ビッ
トアドレス0〜nに対してビット「1」または「0」の
模擬データを格納するエリアを有している。That is, as shown in FIG. 2, the data memory unit 9 has bit "1" for the bit addresses 0 to n.
Or an arithmetic memory 9 having an area for storing "0"
a and a simulation memory corresponding to the bit address as the same address space as the arithmetic memory 9a is provided, and an area for storing the simulation data of the bit "1" or "0" is provided for the bit addresses 0 to n. are doing.
【0043】また、条件メモリ部7は、図3に示すよう
に、保守ツール10の演算用メモリ9aおよび模擬用メ
モリ9bと同一アドレス空間としてビットアドレスが対
応してビットアドレス0〜nに対してビット「1」また
は「0」を格納するようになっている。As shown in FIG. 3, the condition memory unit 7 has the same address space as the arithmetic memory 9a and the simulation memory 9b of the maintenance tool 10, and the bit addresses correspond to the bit addresses 0 to n. It is designed to store a bit "1" or "0".
【0044】上記構成のプログラマブルコントローラ1
Aへ模擬データを設定するとき、データメモリ部9の模
擬用メモリ9bのビットアドレスへ模擬用データを設定
すると共に、模擬実行情報として条件メモリ部7の模擬
用メモリ9bに対応するビットアドレスに「1」とし模
擬実行を設定する。Programmable controller 1 having the above configuration
When setting the simulation data to A, the simulation data is set to the bit address of the simulation memory 9b of the data memory unit 9 and the bit address corresponding to the simulation memory 9b of the condition memory unit 7 is set as "simulation execution information". 1 ”and set simulated execution.
【0045】例えば、図17で説明した制御プログラム
の場合、図4に示すように命令P1,P2,P3,P4
に対応して処理ステップ毎に命令AND,OUT等とビ
ットアドレスが記述されている。ビットアドレス「00
08」にビット「0」を模擬設定するとき、保守ツール
10から保守伝送部8を介してデータメモリ部9の模擬
用メモリ9bのビットアドレス「0008」にビット
「0」を設定し、さらに、条件メモリ部7の同じビット
アドレス「0008」にビット「1」を設定しておく。For example, in the case of the control program described with reference to FIG. 17, as shown in FIG. 4, instructions P1, P2, P3 and P4 are used.
Corresponding to, the instruction AND, OUT, etc. and the bit address are described for each processing step. Bit address "00
When the bit “0” is set to “08” by simulation, the maintenance tool 10 sets the bit “0” to the bit address “0008” of the simulation memory 9b of the data memory unit 9 via the maintenance transmission unit 8, and further, Bit “1” is set in the same bit address “0008” of the condition memory unit 7.
【0046】次に、プログラマブルコントローラ1Aを
デバックするとき、図5に示す手順により処理がされ、
外部入出力部3を介してデータがデータメモリ部9の演
算用メモリ9aへ格納される(S11)。Next, when the programmable controller 1A is debugged, processing is performed according to the procedure shown in FIG.
The data is stored in the arithmetic memory 9a of the data memory unit 9 via the external input / output unit 3 (S11).
【0047】続いて、図6に示す如く、命令コードとビ
ットアドレスとからなる制御プログラムの処理ステップ
50の1行がプログラム格納部4から取り出される(S
12)。Subsequently, as shown in FIG. 6, one line of the processing step 50 of the control program consisting of the instruction code and the bit address is fetched from the program storage section 4 (S).
12).
【0048】このとき、取り出された制御プログラムの
命令が書込みでないとき、命令の中のビットアドレスが
取出され、条件メモリ部7から対応するビットアドレス
の模擬実行か否かの情報が取り出される(S13〜S1
6)。At this time, if the instruction of the fetched control program is not a write command, the bit address in the instruction is fetched, and the information as to whether or not the corresponding bit address is simulated is fetched from the condition memory unit 7 (S13). ~ S1
6).
【0049】ここで、模擬実行でない、つまり、条件ビ
ット=1でないとき、演算用メモリ9aからデータを取
り出して命令コードに従った演算がされる(S17〜S
19)。また、模擬実行、つまり、条件ビット=1のと
き模擬用メモリに予め設定されたデータが取出され命令
コードに従った演算がされる(S17,S19,S2
0)。Here, when the simulation is not executed, that is, when the condition bit is not 1, the data is taken out from the operation memory 9a and the operation is performed according to the instruction code (S17 to S).
19). Further, simulated execution, that is, when the condition bit = 1, preset data is taken out to the simulated memory and operation is performed according to the instruction code (S17, S19, S2).
0).
【0050】一方、判断S14の処理で制御プログラム
の命令が書込みのとき、命令の中のビットアドレスが取
出され条件メモリ部7から対応するビットアドレスから
模擬実行か否かの情報が取り出される。On the other hand, when the instruction of the control program is written in the processing of judgment S14, the bit address in the instruction is taken out, and the information on whether or not the simulation is executed is taken out from the corresponding bit address from the condition memory unit 7.
【0051】ここで、模擬実行、つまり、条件ビット=
1のときデータの書込みがされず、次の処理に移行し、
模擬実行でない、つまり、条件ビット=1でないとき、
演算用メモリ9aへデータが書き込まれる(S21〜S
24)。Here, simulated execution, that is, condition bit =
When it is 1, the data is not written and the next processing is executed.
When it is not simulated execution, that is, when the condition bit is not 1,
Data is written in the arithmetic memory 9a (S21 to S
24).
【0052】例えば、図17で説明すると、処理S12
でビットアドレス「0008」の命令は「OUT」書込
みである。このため、判断S14で処理S21,S22
へ移行する。これにより、条件メモリ部7について取り
出されたビットアドレスに対応するビット情報が取り出
される(S22)。For example, referring to FIG. 17, the process S12.
Therefore, the instruction of the bit address "0008" is "OUT" writing. Therefore, in the determination S14, the processing S21, S22
Move to. As a result, the bit information corresponding to the extracted bit address of the condition memory unit 7 is extracted (S22).
【0053】ここで、条件メモリ部7のビットアドレス
「0008」がビット「1」とすると、データの書込み
が禁止され、次の処理に移行する(S23)。次の処理
に移行するとプログラム格納部4から次の命令「TS
W」が取り出される(S12)。これは、書込み命令で
ないから命令の中からビットアドレス「0008」が取
り出される(S13〜S15)。Here, if the bit address "0008" of the condition memory unit 7 is set to bit "1", the writing of data is prohibited and the process proceeds to the next process (S23). When the next processing is started, the next instruction “TS
"W" is taken out (S12). Since this is not a write command, the bit address "0008" is fetched from the command (S13 to S15).
【0054】続いて、条件メモリ部7のビットアドレス
「0008」にはビット「1」が設定されている。これ
により、模擬用メモリ9bからビット「0」が取り出さ
れる(S16〜S20)。命令コードに従って処理がさ
れ、ビット「0」の実行のためオンディレイタイマが不
動作の状態となる。Subsequently, a bit "1" is set in the bit address "0008" of the condition memory unit 7. As a result, the bit "0" is fetched from the simulation memory 9b (S16 to S20). Processing is performed according to the instruction code, and the on-delay timer becomes inoperative due to the execution of bit "0".
【0055】全ての制御プログラムの処理が終了する
と、データメモリ部9の内容が外部へ出力される(S2
5)。When all the control programs have been processed, the contents of the data memory unit 9 are output to the outside (S2).
5).
【0056】このように、データメモリ部9の模擬用メ
モリ9bの任意のビットアドレスのビット内容を設定
し、これをデバック時に模擬用データとして実行するか
条件メモリ部7へ設定することができる。In this way, it is possible to set the bit content of an arbitrary bit address of the simulation memory 9b of the data memory unit 9 and execute this as simulation data at the time of debugging or set it in the condition memory unit 7.
【0057】この結果、プログラマブルコントローラ1
Aは、図17のビットアドレス「0008」のような場
合、前段の演算処理によって模擬用データの内容が書換
えられることがなく、任意の処理ステップについて実行
条件に左右されない模擬用データの設定ができ、デバッ
ク作業の効率化が図られる。As a result, the programmable controller 1
In the case of the bit address "0008" in FIG. 17, the content of the simulation data is not rewritten by the arithmetic processing in the preceding stage, and the simulation data A can be set regardless of the execution condition for any processing step. The efficiency of debugging work can be improved.
【0058】次に、本発明の第2実施例を図7を参照し
て説明する。Next, a second embodiment of the present invention will be described with reference to FIG.
【0059】図7は、本発明に適用する保守ツールのブ
ロック構成図を示し、保守ツール10は、表示部11と
入力部12とプログラム格納部13と模擬データ設定部
14と伝送部15と制御部16とからなっている。FIG. 7 shows a block diagram of a maintenance tool applied to the present invention. The maintenance tool 10 includes a display unit 11, an input unit 12, a program storage unit 13, a simulated data setting unit 14, a transmission unit 15, and a control unit. And part 16.
【0060】ここで、表示部11は、制御プログラム等
を表示するものである。入力部12はオペレータが表示
部11の表示に従って情報を入力するものである。Here, the display unit 11 displays a control program and the like. The input unit 12 is used by the operator to input information in accordance with the display on the display unit 11.
【0061】プログラム格納部13は、プログラマブル
コントローラ1Aのプログラム格納部4に格納されてい
る制御プログラムと同じプログラムを格納する。模擬デ
ータ設定部14は、模擬用データを設定する。The program storage unit 13 stores the same program as the control program stored in the program storage unit 4 of the programmable controller 1A. The simulation data setting unit 14 sets simulation data.
【0062】伝送部15は、模擬データ設定部14によ
って設定された模擬データと模擬実行情報とをプログラ
マブルコントローラ1Aへ伝送する。制御部16は、入
力部12を介してプログラム格納部13から制御プログ
ラムを取出し表示部11へ表示すると共に、表示された
制御プログラムに基づいて入力部12によって模擬デー
タと模擬実行情報とを模擬データ設定部14へ設定し、
設定された模擬データと模擬実行情報を伝送部15へ渡
す。The transmission section 15 transmits the simulation data set by the simulation data setting section 14 and the simulation execution information to the programmable controller 1A. The control unit 16 retrieves the control program from the program storage unit 13 via the input unit 12 and displays the control program on the display unit 11, and based on the displayed control program, uses the input unit 12 to generate simulated data and simulated execution information. Set in the setting section 14,
The set simulation data and simulation execution information are passed to the transmission unit 15.
【0063】以上のように構成される保守ツール10
は、具体的に図8に示すような外観となっており、本体
部17に図7に示すプログラム格納部13と模擬データ
設定部14と伝送部15と制御部16とが内装され、表
示部11には、前面に表示画面11aを有して、入力部
12としてキーホード12aとマウス12bを備えてい
る。Maintenance tool 10 configured as described above
Specifically, the external appearance is as shown in FIG. 8, and the main body 17 is internally provided with the program storage unit 13, the simulated data setting unit 14, the transmission unit 15, and the control unit 16 shown in FIG. 11 has a display screen 11a on the front surface, and is provided with a keyboard 12a and a mouse 12b as an input unit 12.
【0064】上記する保守ツール10では、図9に示す
手順により処理がされ、まず、オペレータがキーホード
12aからデバックの模擬データ設定のための要求をす
ると、制御部16がプログラム格納部13から制御プロ
グラムの一部を取出す。そして、制御部16が表示部1
1の表示画面11aに図10に示すように制御プログラ
ムを図をもって表示する(S31)。この表示画面51
には、図17に示す制御プログラムの一部分が表示さ
れ、プログラマブルコントローラ1Aのデータメモリ部
9の演算用メモリ9aの対応するビットアドレスに各ビ
ット内容(1)または(0)が表示されている。In the maintenance tool 10 described above, processing is performed according to the procedure shown in FIG. 9. First, when the operator makes a request for setting debug simulation data from the keyboard 12a, the control unit 16 causes the program storage unit 13 to control the control program. Take out a part of. Then, the control unit 16 makes the display unit 1
The control program is graphically displayed on the display screen 11a of No. 1 as shown in FIG. 10 (S31). This display screen 51
Shows a part of the control program shown in FIG. 17, and each bit content (1) or (0) is displayed at the corresponding bit address of the arithmetic memory 9a of the data memory unit 9 of the programmable controller 1A.
【0065】この状態で、命令P3のビットアドレス
「0008」へ模擬データを設定するとき、オペレータ
がキーホード12aまたはマウス12bを用いて表示画
面51上の「0008」の表示部分を特定して選択する
(S32)。これに応じて、制御部16は表示部11の
表示画面51の「0008」へ模擬用データを入力する
キー入力の促す模擬用設定ウィンドウが図11に示すよ
うに表示される(S33)。この表示画面52の模擬用
設定ウィンドウ52aは、「命令」「ビットアドレス」
52a1と模擬用データのビット内容を設定するエリア
52a2と模擬実行を設定するエリア52a3となって
いる。In this state, when setting the simulated data to the bit address "0008" of the instruction P3, the operator specifies and selects the display portion of "0008" on the display screen 51 by using the keyboard 12a or the mouse 12b. (S32). In response to this, the control unit 16 displays a simulation setting window for prompting a key input to input simulation data to “0008” on the display screen 51 of the display unit 11 as shown in FIG. 11 (S33). The simulation setting window 52a of the display screen 52 has "instruction" and "bit address".
52a1 and an area 52a2 for setting bit contents of the simulation data and an area 52a3 for setting simulation execution.
【0066】ここで、オペレータがキーホード12aま
たはマウス12bによりビットアドレス「0008」へ
ビット「0」を模擬データとして設定入力する。さら
に、模擬実行情報として「実行」のエリア52a3をマ
ウス12b等で選択する(S34)。Here, the operator sets and inputs the bit "0" as simulated data to the bit address "0008" by the key board 12a or the mouse 12b. Further, the "execution" area 52a3 is selected by the mouse 12b or the like as the simulated execution information (S34).
【0067】こうして設定された模擬データと模擬実行
情報とが模擬データ設定部14から伝送部15へ渡さ
れ、保守ツール10からプログラマブルコントローラ1
Aの保守伝送部8へ伝送される(S35,S36)。The simulated data and the simulated execution information set in this way are passed from the simulated data setting unit 14 to the transmission unit 15, and the maintenance tool 10 causes the programmable controller 1 to operate.
It is transmitted to the maintenance transmission unit 8 of A (S35, S36).
【0068】これにより、プログラマブルコントローラ
1Aでは、図2で説明したデータメモリ部9の模擬用メ
モリ9bのビットアドレス「0008」にビット「0」
を設定し、さらに図3で説明した条件メモリ部7のビッ
トアドレス「0008」にビット「1」を設定する。As a result, in the programmable controller 1A, the bit "0" is assigned to the bit address "0008" of the simulation memory 9b of the data memory unit 9 described with reference to FIG.
Then, the bit "1" is set to the bit address "0008" of the condition memory unit 7 described with reference to FIG.
【0069】この結果設定されたビットアドレス「00
08」のビットは、前段の演算結果に無関係にビット
「1」として模擬することができる。As a result, the bit address "00" set
The bit "08" can be simulated as a bit "1" regardless of the operation result of the preceding stage.
【0070】このように、保守ツール10に表示される
表示画面11aの制御プログラムの図を見ながら入力部
12からの操作によって簡単に短時間に模擬データと模
擬実行情報を設定できるからデバックの効率を向上させ
ることができる。As described above, it is possible to easily set the simulation data and the simulation execution information in a short time by operating the input unit 12 while viewing the control program on the display screen 11a displayed on the maintenance tool 10. Can be improved.
【0071】次に、本発明の第3実施例を図12を参照
して説明する。Next, a third embodiment of the present invention will be described with reference to FIG.
【0072】図示する保守ツール20は、表示部11と
入力部12とプログラム格納部13と模擬データ設定部
14と伝送部15と制御部21と模擬データ保存部22
とからなっている。The maintenance tool 20 shown in the figure has a display unit 11, an input unit 12, a program storage unit 13, a simulated data setting unit 14, a transmission unit 15, a control unit 21, and a simulated data storage unit 22.
It consists of
【0073】ここで、表示部11は、制御プログラムを
図式化して表示するものである。入力部12は、オペレ
ータが表示部11に表示された制御プログラムに従って
情報を入力するものである。Here, the display unit 11 displays the control program as a diagram. The input unit 12 is used by the operator to input information in accordance with the control program displayed on the display unit 11.
【0074】プログラム格納部13は、プログラマブル
コントローラ1Aの制御プログラムと同じ制御プログラ
ムを格納するものである。模擬データ設定部14は模擬
用データを設定するものである。模擬データ保存部22
は、プログラマブルコントローラ1Aのデータメモリ部
9と条件メモリ部7との内容を格納するものである。伝
送部15は、プログラマブルコントローラ1Aと保守ツ
ール20との間でデータ伝送するものである。The program storage unit 13 stores the same control program as that of the programmable controller 1A. The simulation data setting unit 14 sets simulation data. Simulation data storage unit 22
Stores the contents of the data memory unit 9 and the condition memory unit 7 of the programmable controller 1A. The transmission unit 15 transmits data between the programmable controller 1A and the maintenance tool 20.
【0075】制御部21は、要求によりプログラマブル
コントローラ1Aのデータメモリ部9と条件メモリ部7
の内容を読出し模擬データ保存部22へ格納すると共
に、模擬データ保存部22へ格納されたデータを取出し
プログラマブルコントローラ1Aのデータメモリ部9と
条件メモリ部7へデータを設定するものである。The control section 21 requests the data memory section 9 and the condition memory section 7 of the programmable controller 1A.
Is read out and stored in the simulated data storage unit 22, and the data stored in the simulated data storage unit 22 is taken out and set in the data memory unit 9 and the condition memory unit 7 of the programmable controller 1A.
【0076】以上の構成で、デバックのとき、保守ツー
ル20にプログラマブルコントローラ1Aを接続し、模
擬用データが作成され、模擬データ設定部14によって
伝送部15を介してプログラマブルコントローラ1Aへ
伝送される。次に、入力部12から要求があると、制御
部21がプログラマブルコントローラ1Aの条件メモリ
部7とデータメモリ部のデータの伝送要求を伝送部15
を介してプログラマブルコントローラ1Aの保守伝送部
へ出力する。With the above configuration, at the time of debugging, the programmable controller 1A is connected to the maintenance tool 20, the simulation data is created, and is transmitted by the simulation data setting unit 14 to the programmable controller 1A via the transmission unit 15. Next, when there is a request from the input unit 12, the control unit 21 sends a transmission request for the data of the condition memory unit 7 and the data memory unit of the programmable controller 1A to the transmission unit 15.
To the maintenance transmission section of the programmable controller 1A via.
【0077】これに対して、プログラマブルコントロー
ラ1Aの保守伝送部がデータメモリ部と条件メモリ部の
データを保守ツール20の伝送部15へ伝送する。伝送
された上記データは制御部21により模擬データ保存部
22へ格納される。On the other hand, the maintenance transmission section of the programmable controller 1A transmits the data in the data memory section and the condition memory section to the transmission section 15 of the maintenance tool 20. The transmitted data is stored in the simulated data storage unit 22 by the control unit 21.
【0078】また、入力部12から要求があると、模擬
データ保存部22に保存されたデータを伝送部15を介
してプログラマブルコントローラ1Aへ伝送する。プロ
グラマブルコントローラ1Aの保守伝送部はデータをデ
ータメモリ部と条件メモリ部へ設定する。When the input section 12 makes a request, the data stored in the simulated data storage section 22 is transmitted to the programmable controller 1A via the transmission section 15. The maintenance transmission unit of the programmable controller 1A sets the data in the data memory unit and the condition memory unit.
【0079】例えば、デバックのための模擬データと模
擬実行情報の設定やデバック作業が遅れ次の日に持ち越
すようなとき、一般に、プログラマブルコントローラ1
Aの電源が切られるためにプログラマブルコントローラ
1Aのデータメモリ部と条件メモリ部の内容を伝送部1
5を介して読み出して模擬データ保存部22へ保存す
る。For example, when the setting of simulation data and simulation execution information for debugging and the debugging work are delayed and carried over to the next day, the programmable controller 1 is generally used.
Since the power of A is turned off, the contents of the data memory section and the condition memory section of the programmable controller 1A are transferred to the transmission section 1
It is read out via 5 and stored in the simulated data storage unit 22.
【0080】次の日になると、プログラマブルコントロ
ーラ1Aの電源投入後に保守ツール20から前日保存さ
れたデータをデータ伝送部15を介してプログラマブル
コントローラ1Aへ伝送し、データメモリ部と条件メモ
リ部へデータを格納する。On the next day, after the power of the programmable controller 1A is turned on, the maintenance tool 20 transmits the data stored on the previous day to the programmable controller 1A via the data transmission unit 15 to transfer the data to the data memory unit and the condition memory unit. Store.
【0081】これにより、プログラマブルコントローラ
1Aのデータメモリ部と条件メモリ部の内容が直ちに電
源遮断前の状態に復元される。従って、即座にデバック
の作業を実行することができる。As a result, the contents of the data memory section and the condition memory section of the programmable controller 1A are immediately restored to the state before the power was turned off. Therefore, the debugging work can be executed immediately.
【0082】このようにプログラマブルコントローラ1
Aのデータメモリ部と条件メモリ部との内容を保守ツー
ル20が保存し、復元するためにデバック時の中断また
は再開が容易にできデバックの効率が向上する。特に、
大規模の制御プログラムを保存するプログラマブルコン
トローラのデバックでは、1ケ月もの長期に亘るものが
あり、デバック作業は中断や再開の繰り返しの連続的作
業であるため模擬用データが確実に保存できれば作業能
率が一層向上する。Thus, the programmable controller 1
Since the maintenance tool 20 saves and restores the contents of the data memory unit and the condition memory unit of A, it is possible to easily suspend or resume the debugging and improve the debugging efficiency. In particular,
Programmable controller debugging that saves a large-scale control program can take a long period of one month. Debugging work is a continuous work that is interrupted and restarted repeatedly. Further improve.
【0083】次に、本発明の第4実施例を図13を参照
して説明する。Next, a fourth embodiment of the present invention will be described with reference to FIG.
【0084】図示する保守ツール30は、表示部11と
入力部12とプログラム格納部13と模擬データ設定部
14と伝送部15と制御部31と模擬データ登録部32
とからなっている。The illustrated maintenance tool 30 includes a display unit 11, an input unit 12, a program storage unit 13, a simulated data setting unit 14, a transmission unit 15, a control unit 31, and a simulated data registration unit 32.
It consists of
【0085】ここで、模擬データ登録部32は、予め実
行しようとする模擬用データを作成して内部のファイル
に格納しておくものである。Here, the simulated data registration unit 32 creates simulated data to be executed in advance and stores it in an internal file.
【0086】以上の構成で、保守ツール30では、模擬
データ登録部32によってデバック対象の制御プログラ
ムの部分について予め複数の模擬用データを作成して模
擬用ファイルへ格納しておく。With the above configuration, in the maintenance tool 30, a plurality of simulation data are created in advance by the simulation data registration unit 32 for the portion of the control program to be debugged and stored in the simulation file.
【0087】例えば、図17に示すような制御プログラ
ムでは、ビットアドレス「0008」のビットが「1」
となる条件を想定する。この場合、ビットアドレス「0
006」または「0007」あるいはビットアドレス
「0008」のいずれかがビット「1」となるときであ
る。For example, in the control program as shown in FIG. 17, the bit of the bit address "0008" is "1".
Assume the following condition. In this case, the bit address "0
It is when either "006" or "0007" or the bit address "0008" becomes the bit "1".
【0088】この制御プログラムの一部分をデバックす
るために保守ツール30のみによって図14に示す如く
のケース1〜ケース8を想定し、ビットアドレス「00
05」「0006」「0007」にビットを設定すると
共に、期待結果データとしてビットアドレス「000
8」にビットを設定した模擬用データを作成し、模擬デ
ータファイルに格納しておく。In order to debug a part of this control program, it is assumed that Case 1 to Case 8 as shown in FIG.
Bits are set to "05", "0006", and "0007", and bit address "000" is set as expected result data.
The simulation data with the bit set to "8" is created and stored in the simulation data file.
【0089】次に、プログラマブルコントローラ1Aと
保守ツール30とを接続したとき、制御部31によって
模擬データ登録部32の模擬データファイルから模擬用
データが取出され伝送部15を介して伝送される。プロ
グラマブルコントローラ1Aでは、模擬用データが条件
メモリ部とデータメモリ部へ格納される。Next, when the programmable controller 1 A and the maintenance tool 30 are connected, the control unit 31 extracts the simulation data from the simulation data file of the simulation data registration unit 32 and transmits it via the transmission unit 15. In the programmable controller 1A, the simulation data is stored in the condition memory unit and the data memory unit.
【0090】そして、プログラマブルコントローラ1A
で制御プログラムにより処理が実行される。その後に保
守ツール30がプログラマブルコントローラ1Aの処理
結果を取込み期待結果データとの比較をして検証する。
これを模擬データファイルの最後の模擬用データまで順
次実行する。Programmable controller 1A
Then, the processing is executed by the control program. After that, the maintenance tool 30 takes in the processing result of the programmable controller 1A and compares it with the expected result data for verification.
This is sequentially executed up to the last simulation data of the simulation data file.
【0091】例えば、図14の例では、ケース1から開
始してケース8まで順次模擬用データを設定し、処理実
行し、結果の検証がされる。これによって、デバック作
業が効率的に行われる。For example, in the example of FIG. 14, the simulation data is sequentially set from case 1 to case 8, the processing is executed, and the result is verified. As a result, debugging work is efficiently performed.
【0092】[0092]
【発明の効果】以上説明したように請求項1の発明によ
れば、予め条件メモリ部の所定のビットアドレスに模擬
実行を設定すれば制御プログラムの命令がデータの取出
しのとき、模擬用メモリのデータが用いられ、データの
書込みのときは、書込み禁止される。従って、制御プロ
グラムの前の処理でされた結果により所定のビットアド
レスのデータが上書きされることがなく、任意のビット
アドレスに模擬データを設定でき、デバック時間の短縮
が図られる。As described above, according to the first aspect of the present invention, if the simulated execution is set in advance at the predetermined bit address of the condition memory section, when the instruction of the control program fetches the data, Data is used, and when writing data, writing is prohibited. Therefore, the data of the predetermined bit address is not overwritten by the result of the previous process of the control program, and the simulated data can be set to an arbitrary bit address, and the debug time can be shortened.
【0093】請求項2の発明によれば、表示部に表示さ
れる制御プログラムを見ながら任意のビットアドレスに
模擬用データを設定することができるからデバック時間
の短縮が図れる。According to the second aspect of the invention, it is possible to set the simulation data at an arbitrary bit address while looking at the control program displayed on the display section, so the debug time can be shortened.
【0094】請求項3の発明によれば、必要なときプロ
グラマブルコントローラの模擬用データを保守ツールへ
取込み保存し、デバック時に再びプログラマブルコント
ローラへ設定するようにしたからデバックが即座に開始
することができ、デバック作業が効率的となる。According to the invention of claim 3, debugging data can be immediately started because the simulation data of the programmable controller is taken in and saved in the maintenance tool when necessary and set again in the programmable controller when debugging. , Debugging work becomes efficient.
【0095】請求項4の発明によれば、予め保守ツール
に模擬用データを登録しておき、順次模擬用データをプ
ログラマブルコントローラへ設定してデバックするため
にデバック時間の短縮が図られる。According to the fourth aspect of the present invention, since the simulation data is registered in the maintenance tool in advance and the simulation data is sequentially set in the programmable controller and debugged, the debug time can be shortened.
【図1】本発明の第1実施例を示すプログラマブルコン
トローラの構成図である。FIG. 1 is a configuration diagram of a programmable controller showing a first embodiment of the present invention.
【図2】図1に備えるデータメモリ部のファイル構成図
である。FIG. 2 is a file configuration diagram of a data memory unit included in FIG.
【図3】図1に備える条件メモリ部のファイル構成図で
ある。FIG. 3 is a file configuration diagram of a condition memory unit provided in FIG.
【図4】制御プログラムの一例を示す説明図である。FIG. 4 is an explanatory diagram showing an example of a control program.
【図5】図1のプログラマブルコントローラの処理手順
を示すフローチャートである。5 is a flowchart showing a processing procedure of the programmable controller of FIG.
【図6】制御プログラムの1行を示す説明図である。FIG. 6 is an explanatory diagram showing one line of a control program.
【図7】本発明の第2実施例を示す保守ツールの構成図
である。FIG. 7 is a configuration diagram of a maintenance tool showing a second embodiment of the present invention.
【図8】図7の保守ツールの外観図である。8 is an external view of the maintenance tool of FIG.
【図9】図7の保守ツールの処理手順を示すフローチャ
ートである。9 is a flowchart showing a processing procedure of the maintenance tool of FIG.
【図10】図7に備える表示部の表示画面の第1の例を
示す説明図である。FIG. 10 is an explanatory diagram showing a first example of a display screen of a display unit included in FIG.
【図11】図7に備える表示部の表示画面の第2の例を
示す説明図である。FIG. 11 is an explanatory diagram showing a second example of the display screen of the display unit provided in FIG. 7.
【図12】本発明の第3実施例を示す保守ツールの構成
図である。FIG. 12 is a configuration diagram of a maintenance tool showing a third embodiment of the present invention.
【図13】本発明の第4実施例を示す保守ツールの構成
図である。FIG. 13 is a configuration diagram of a maintenance tool showing a fourth embodiment of the present invention.
【図14】図13の模擬データ登録部に備える模擬デー
タファイルを示す説明図である。FIG. 14 is an explanatory diagram showing a simulated data file provided in the simulated data registration unit of FIG.
【図15】従来例を示すプログラマブルコントローラの
構成図である。FIG. 15 is a block diagram of a programmable controller showing a conventional example.
【図16】図15の処理手順を示すフローチャートであ
る。16 is a flowchart showing a processing procedure of FIG.
【図17】制御プログラムの一例を示す説明図である。FIG. 17 is an explanatory diagram showing an example of a control program.
1 プログラマブルコントローラ 2 主制御部 3 外部入出力部 4 プログラム格納部 7 条件メモリ部 8 保守伝送部 9 データメモリ部 10,20 保守ツール 11 表示部 12 入力部 13 プログラム格納部 14 模擬データ設定部 15 伝送部 16,21,31 制御部 22 模擬データ保存部 32 模擬データ登録部 1 programmable controller 2 main control unit 3 external input / output unit 4 program storage unit 7 condition memory unit 8 maintenance transmission unit 9 data memory unit 10 and 20 maintenance tool 11 display unit 12 input unit 13 program storage unit 14 simulated data setting unit 15 transmission Part 16, 21, 31 Control part 22 Simulated data storage part 32 Simulated data registration part
Claims (4)
タを出力する外部入出力部と、 演算処理のための制御専門言語による制御プログラムを
格納するプログラム格納部と、 演算用データとその演算結果データを格納する演算用メ
モリと前記制御プログラムの動作模擬をする模擬用デー
タを格納し前記演算用メモリとビットアドレスが対応し
て設けられる模擬用メモリとからなるデータメモリ部
と、 前記演算用メモリと前記模擬用メモリのそれぞれにビッ
トアドレスが対応して設けられビットアドレス毎にいず
れの前記演算用メモリまたは前記模擬用メモリのデータ
を取出すか、あるいは、データの書込みを禁止する情報
を模擬実行情報として予め設定する条件メモリ部と、 保守ツールから入力された動作模擬のための前記模擬用
データを前記模擬用メモリへ格納する一方、前記模擬実
行情報を前記条件メモリ部へ格納する保守伝送部と、 前記演算用メモリの演算用データを用いて制御プログラ
ムによって演算を実行し、その演算結果データを前記演
算用メモリへ格納する一方、制御プログラムがデータ取
出し命令で、かつ、前記条件メモリ部の対応するビット
アドレスが模擬実行のとき前記模擬用メモリの模擬用デ
ータを取出して制御プログラムによって演算し、制御プ
ログラムがデータの書込み命令で、かつ、前記条件メモ
リ部の対応するビットアドレスが模擬実行のときデータ
の書込みを禁止する主制御部とを備えたことを特徴とす
るプログラマブルコントローラ。1. An external input / output unit that takes in plant data and outputs the data to a plant, a program storage unit that stores a control program in a control specialized language for arithmetic processing, and stores arithmetic data and its arithmetic result data. And a simulation memory for storing simulation data for simulating the operation of the control program, the simulation memory having bit addresses corresponding to the simulation memory, and the simulation memory and the simulation. A bit address is provided corresponding to each of the memory for use, and data for which of the arithmetic memory or the simulation memory is taken out for each bit address, or information for prohibiting data writing is preset as simulation execution information. Condition memory part and the simulation data input from the maintenance tool to simulate the operation. While storing in the simulation memory, a maintenance transmission unit for storing the simulation execution information in the condition memory unit, and a calculation by the control program using the calculation data in the calculation memory, and the calculation result data While storing in the calculation memory, when the control program is a data fetching instruction and the corresponding bit address of the condition memory unit is a simulation execution, the simulation data in the simulation memory is fetched and calculated by the control program, A programmable controller comprising: a control program which is a data write command, and a main control unit which prohibits data write when a corresponding bit address of the condition memory unit is simulated execution.
と、 オペレータが情報を入力する入力部と、 前記制御プログラムを格納するプログラム格納部と、 模擬用データを設定する模擬データ設定部と、 設定された模擬用データと模擬実行情報とをプログラマ
ブルコントローラへ伝送する伝送部と、 前記入力部を介して前記プログラム格納部から制御プロ
グラムを取り出して、前記表示部へ表示すると共に、表
示された制御プログラムに基づいて入力部から入力され
た模擬用データと模擬実行情報とを前記模擬データ設定
部へ設定し、この模擬データ設定部に設定された模擬デ
ータと模擬実行情報とを前記伝送部へ渡す制御部とを備
えたことを特徴とするプログラマブルコントローラの保
守ツール。2. A display unit for displaying a control program on a screen, an input unit for an operator to input information, a program storage unit for storing the control program, a simulation data setting unit for setting simulation data, and a setting. A transmission unit for transmitting the simulated data and simulated execution information to a programmable controller, and taking out a control program from the program storage unit via the input unit, displaying the control program on the display unit, and displaying the control program. Control for setting the simulation data and the simulation execution information input from the input unit to the simulation data setting unit based on the above, and passing the simulation data and the simulation execution information set in the simulation data setting unit to the transmission unit. A maintenance tool for a programmable controller, which is provided with a section.
された模擬実行のためのデータを格納する模擬データ保
存部を設け、要求により前記模擬実行のためのデータを
前記伝送部を介して取込んで前記模擬データ保存部へ格
納する一方、この模擬データ保存部に格納された前記デ
ータを取出し前記プログラマブルコントローラへ設定す
るように前記伝送部へ出力する手段を前記制御部に設け
ることを特徴とする請求項2記載のプログラマブルコン
トローラの保守ツール。3. A simulation data storage unit for storing data for simulation execution set in the programmable controller is provided, and the data for simulation execution is fetched via the transmission unit upon request to generate the simulation data. 3. The control unit is provided with means for storing the data in the storage unit and outputting the data stored in the simulated data storage unit to the transmission unit so as to set the data in the programmable controller. Programmable controller maintenance tool.
る演算結果データを予め想定してデータベースに登録す
る模擬データ登録部を設け、この模擬データ登録部に登
録された模擬用データを順次前記プログラマブルコント
ローラへ設定して制御プログラムの模擬実行によって得
られた演算結果データと前記想定した演算結果データと
から制御プログラムの検証をする手段を前記制御部に設
けたことを特徴とする請求項2または請求項3記載のプ
ログラマブルコントローラの保守ツール。4. A simulation data registration unit is provided for preliminarily assuming simulation data and calculation result data obtained by simulation execution in a database, and the simulation data registered in this simulation data registration unit is sequentially provided in the programmable controller. 3. The control unit is provided with means for verifying the control program from the calculation result data obtained by setting and setting the calculation result data and the assumed calculation result data. Maintenance tool for the programmable controller described in 3.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP6257289A JPH0895611A (en) | 1994-09-28 | 1994-09-28 | Programmable controller and its maintenance tool |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP6257289A JPH0895611A (en) | 1994-09-28 | 1994-09-28 | Programmable controller and its maintenance tool |
Publications (1)
Publication Number | Publication Date |
---|---|
JPH0895611A true JPH0895611A (en) | 1996-04-12 |
Family
ID=17304312
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
JP6257289A Pending JPH0895611A (en) | 1994-09-28 | 1994-09-28 | Programmable controller and its maintenance tool |
Country Status (1)
Country | Link |
---|---|
JP (1) | JPH0895611A (en) |
Citations (9)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JPS5523563A (en) * | 1978-08-09 | 1980-02-20 | Hitachi Ltd | Computer system |
JPS57185511A (en) * | 1981-05-11 | 1982-11-15 | Sharp Corp | Loader for sequence controller |
JPS62271003A (en) * | 1986-05-20 | 1987-11-25 | Toshiba Corp | Programmable controller |
JPS6368904A (en) * | 1986-09-10 | 1988-03-28 | Asahi Chem Ind Co Ltd | Method and device for checking programmable controller |
JPS63316105A (en) * | 1987-06-18 | 1988-12-23 | Mitsubishi Electric Corp | Simulation device for programmable controller |
JPH0458303A (en) * | 1990-06-28 | 1992-02-25 | Toshiba Corp | Programmable controller |
JPH05282163A (en) * | 1992-03-30 | 1993-10-29 | Hitachi Ltd | Information processing equipment |
JPH05297913A (en) * | 1992-04-17 | 1993-11-12 | Toshiba Corp | Programmable controller |
JPH06242819A (en) * | 1993-02-18 | 1994-09-02 | Fanuc Ltd | Signal state control system for programmable controller |
-
1994
- 1994-09-28 JP JP6257289A patent/JPH0895611A/en active Pending
Patent Citations (9)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JPS5523563A (en) * | 1978-08-09 | 1980-02-20 | Hitachi Ltd | Computer system |
JPS57185511A (en) * | 1981-05-11 | 1982-11-15 | Sharp Corp | Loader for sequence controller |
JPS62271003A (en) * | 1986-05-20 | 1987-11-25 | Toshiba Corp | Programmable controller |
JPS6368904A (en) * | 1986-09-10 | 1988-03-28 | Asahi Chem Ind Co Ltd | Method and device for checking programmable controller |
JPS63316105A (en) * | 1987-06-18 | 1988-12-23 | Mitsubishi Electric Corp | Simulation device for programmable controller |
JPH0458303A (en) * | 1990-06-28 | 1992-02-25 | Toshiba Corp | Programmable controller |
JPH05282163A (en) * | 1992-03-30 | 1993-10-29 | Hitachi Ltd | Information processing equipment |
JPH05297913A (en) * | 1992-04-17 | 1993-11-12 | Toshiba Corp | Programmable controller |
JPH06242819A (en) * | 1993-02-18 | 1994-09-02 | Fanuc Ltd | Signal state control system for programmable controller |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
US5483440A (en) | Remote control apparatus and control method thereof | |
US20060253842A1 (en) | Modelling of programmable devices | |
JP5589901B2 (en) | Software verification support apparatus, software verification support method, and software verification support program | |
JPH0895611A (en) | Programmable controller and its maintenance tool | |
JPH06242819A (en) | Signal state control system for programmable controller | |
WO2001097035A1 (en) | Automatic evaluation method and automatic evaluation system and storage medium storing automatic evaluation program | |
JPH08278809A (en) | Plant controller | |
WO2022185418A1 (en) | Debugging assistance program, debugging assistance device, debugging assistance method, and machine learning device | |
JP2001209412A (en) | Simulator for sequence program | |
JPS5949609A (en) | Programmable controller equipped with simulation performing function | |
JP3443184B2 (en) | Programmer for programmable controller | |
JPH0233178B2 (en) | ||
JPH07253876A (en) | Program generating device | |
JPS63159905A (en) | Forcible on/off system for input/output of programmable controller | |
JP2837455B2 (en) | Distributed control device and program test method thereof | |
JPH04373036A (en) | Software testing device for computer system | |
JP2703368B2 (en) | Test output device switching device | |
JP3325397B2 (en) | Simulation system for programs executed by programmable controllers | |
JPH0417444B2 (en) | ||
WO2001097034A1 (en) | Automatic evaluation method and automatic evaluation system and storage medium storing automatic evaluation program | |
JPH02250123A (en) | Simulation system for timer operation in software simulator | |
JPH11110005A (en) | Process simulator for distributed control system | |
JPH02235150A (en) | Information processor | |
JPS61204708A (en) | Function checking system for sequence control device | |
JPH01292445A (en) | Firmware debugging system |