JPWO2019220605A1 - Simulation device and simulation program - Google Patents

Simulation device and simulation program Download PDF

Info

Publication number
JPWO2019220605A1
JPWO2019220605A1 JP2018561076A JP2018561076A JPWO2019220605A1 JP WO2019220605 A1 JPWO2019220605 A1 JP WO2019220605A1 JP 2018561076 A JP2018561076 A JP 2018561076A JP 2018561076 A JP2018561076 A JP 2018561076A JP WO2019220605 A1 JPWO2019220605 A1 JP WO2019220605A1
Authority
JP
Japan
Prior art keywords
virtual
unit
real
data
plc
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Granted
Application number
JP2018561076A
Other languages
Japanese (ja)
Other versions
JP6570772B1 (en
Inventor
黒木 大輔
大輔 黒木
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Mitsubishi Electric Corp
Original Assignee
Mitsubishi Electric Corp
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Mitsubishi Electric Corp filed Critical Mitsubishi Electric Corp
Application granted granted Critical
Publication of JP6570772B1 publication Critical patent/JP6570772B1/en
Publication of JPWO2019220605A1 publication Critical patent/JPWO2019220605A1/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

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
    • GPHYSICS
    • G05CONTROLLING; REGULATING
    • G05BCONTROL OR REGULATING SYSTEMS IN GENERAL; FUNCTIONAL ELEMENTS OF SUCH SYSTEMS; MONITORING OR TESTING ARRANGEMENTS FOR SUCH SYSTEMS OR ELEMENTS
    • G05B17/00Systems involving the use of models or simulators of said systems
    • G05B17/02Systems involving the use of models or simulators of said systems electric

Abstract

シミュレーション装置(7)が、PLCの動作を模擬する仮想PLCと、他のPLCシステムとの間で通信を行うユニットであるネットワークユニットの動作を模擬する仮想ネットワークユニットと、を含んだ仮想PLCシステムを構築し、仮想PLCシステムの模擬動作にかかる演算を行うシミュレーション部(3)と、実機の実PLCと、他のPLCシステムとの間で通信を行うユニットである実機の実ネットワークユニットと、を含んだ第1の実PLCシステムに接続し、仮想PLCシステムと第1の実PLCシステムとの間でデータ中継を行う通信ボード(31)と、を備え、シミュレーション部(3)は、仮想PLCシステムに対応する第2の実PLCシステムを動作させる際に用いられるプログラムと同じプログラムに基づき、通信ボード(31)を介して第1の実PLCシステムから受信したデータを用いて、仮想PLCシステムの模擬動作を行う。A simulation device (7) includes a virtual PLC system that includes a virtual PLC that simulates the operation of a PLC and a virtual network unit that simulates the operation of a network unit that is a unit that communicates with another PLC system. It includes a simulation unit (3) that is constructed and performs a calculation related to the simulated operation of the virtual PLC system, a real PLC of the real machine, and a real network unit of the real machine that is a unit that communicates with another PLC system. And a communication board (31) which is connected to the first real PLC system and relays data between the virtual PLC system and the first real PLC system, and the simulation unit (3) is connected to the virtual PLC system. Based on the same program used when operating the corresponding second real PLC system, the simulated operation of the virtual PLC system is performed using the data received from the first real PLC system via the communication board (31). I do.

Description

本発明は、プログラマブルロジックコントローラのシミュレーションを実行するシミュレーション装置およびシミュレーションプログラムに関する。   The present invention relates to a simulation device and a simulation program that execute a simulation of a programmable logic controller.

プログラマブルロジックコントローラ(PLC:Programmable Logic Controller)と通信機能を有したネットワークユニットとを備えたPLCシステムが、複数接続されて構成された大規模システムがある。この大規模システムが構築される際には、PLCが実行するPLCプログラムの動作を確認するためにシミュレーションが実行される。   There is a large-scale system configured by connecting a plurality of PLC systems each including a programmable logic controller (PLC) and a network unit having a communication function. When this large-scale system is constructed, a simulation is executed to confirm the operation of the PLC program executed by the PLC.

特許文献1に記載のPLCテスト支援システムは、実機のPLCである実PLCの動作を模擬する仮想PLCに、PC(Personal Computer)との間で行われる通信データの送受信を模擬させることによって、通信データの内容をテストしている。   The PLC test support system described in Patent Document 1 performs communication by causing a virtual PLC that simulates the operation of a real PLC that is a PLC of a real machine to simulate transmission and reception of communication data that is performed with a PC (Personal Computer). Testing the content of the data.

特開平9−114689号公報Japanese Patent Laid-Open No. 9-114689

しかしながら、上記特許文献1の技術では、仮想ネットワークが無い状態でシーケンスプログラムであるPLCプログラムをテストする場合、接続先の他のネットワークの振る舞いを模擬するために、別途テスト用のPLCプログラムを作成するか、または元の実機用のPLCプログラムにテスト用の処理を書き加えたテスト用のPLCプログラムを作成する必要があった。   However, in the technique of Patent Document 1, when a PLC program that is a sequence program is tested in the absence of a virtual network, a separate test PLC program is created to simulate the behavior of another network at the connection destination. Alternatively, it is necessary to create a test PLC program in which the test process is added to the original PLC program for the actual machine.

本発明は、上記に鑑みてなされたものであって、テスト用のPLCプログラムを作成することなく、実コントローラシステムと仮想コントローラシステムとが互いにやりとりしながら行われる動作を確認することができるシミュレーション装置を得ることを目的とする。   The present invention has been made in view of the above, and a simulation apparatus capable of confirming an operation performed while a real controller system and a virtual controller system interact with each other without creating a PLC program for testing. Aim to get.

上述した課題を解決し、目的を達成するために、本発明のシミュレーション装置は、プログラマブルロジックコントローラの動作を模擬する仮想プログラマブルロジックコントローラと、他のコントローラシステムとの間で通信を行うユニットであるネットワークユニットの動作を模擬する仮想ネットワークユニットと、を含んだ仮想コントローラシステムを構築し、仮想コントローラシステムの模擬動作にかかる演算を行うシミュレーション部を備える。また、本発明のシミュレーション装置は、実機の実プログラマブルロジックコントローラと、他のコントローラシステムとの間で通信を行うユニットである実機の実ネットワークユニットと、を含んだ第1の実コントローラシステムに接続し、仮想コントローラシステムと第1の実コントローラシステムとの間でデータ中継を行う通信部と、を備える。シミュレーション部は、仮想コントローラシステムに対応する第2の実コントローラシステムを動作させる際に用いられるプログラムと同じプログラムに基づき、通信部を介して第1の実コントローラシステムから受信したデータを用いて、仮想コントローラシステムの模擬動作を行う。   In order to solve the above-mentioned problems and achieve an object, a simulation device of the present invention is a network that is a unit that communicates between a virtual programmable logic controller that simulates the operation of a programmable logic controller and another controller system. A virtual controller unit including a virtual network unit that simulates the operation of the unit is built, and a simulation unit that performs a calculation related to the simulated operation of the virtual controller system is provided. In addition, the simulation device of the present invention is connected to a first real controller system including a real programmable logic controller of a real machine and a real network unit of a real machine that is a unit that communicates with another controller system. And a communication unit that relays data between the virtual controller system and the first real controller system. The simulation unit uses the data received from the first real controller system via the communication unit based on the same program as the program used when operating the second real controller system corresponding to the virtual controller system. Simulates the controller system.

本発明にかかるシミュレーション装置は、テスト用のPLCプログラムを作成することなく、実コントローラシステムと仮想コントローラシステムとが互いにやりとりしながら行われる動作を確認することができるという効果を奏する。   The simulation apparatus according to the present invention has an effect that it is possible to confirm the operation performed while the real controller system and the virtual controller system interact with each other without creating a PLC program for testing.

実施の形態にかかるシミュレーション装置が適用されるFA(Factory Automation)システムの構成を示す図The figure which shows the structure of FA(Factory Automation) system to which the simulation apparatus concerning embodiment is applied. 実施の形態にかかるシミュレーション装置の構成を示す図The figure which shows the structure of the simulation apparatus concerning embodiment. 実施の形態にかかる仮想環境の構成を示す図The figure which shows the structure of the virtual environment concerning embodiment. 実施の形態にかかる仮想PLCシステムが備える接続部の第1の構成例を示す図The figure which shows the 1st structural example of the connection part with which the virtual PLC system concerning embodiment is equipped. 実施の形態にかかる仮想PLCシステムが備える接続部の第2の構成例を示す図The figure which shows the 2nd structural example of the connection part with which the virtual PLC system concerning embodiment is equipped. 実施の形態にかかるシミュレーション装置によるPLCシステム間の第1のデータ中継処理手順を示すフローチャートThe flowchart which shows the 1st data relay processing procedure between PLC systems by the simulation apparatus concerning embodiment. 実施の形態にかかるシミュレーション装置によるPLCシステム間の第2のデータ中継処理手順を示すフローチャートThe flowchart which shows the 2nd data relay process procedure between PLC systems by the simulation apparatus concerning embodiment. 実施の形態にかかるシミュレーション装置を実現するハードウエア構成を示す図The figure which shows the hardware constitutions which implement|achieve the simulation apparatus concerning embodiment.

以下に、本発明の実施の形態にかかるシミュレーション装置およびシミュレーションプログラムを図面に基づいて詳細に説明する。なお、この実施の形態によりこの発明が限定されるものではない。   Hereinafter, a simulation device and a simulation program according to an embodiment of the present invention will be described in detail with reference to the drawings. The present invention is not limited to this embodiment.

実施の形態.
図1は、実施の形態にかかるシミュレーション装置が適用されるFAシステムの構成を示す図である。図2は、実施の形態にかかるシミュレーション装置の構成を示す図である。
Embodiment.
FIG. 1 is a diagram showing a configuration of an FA system to which a simulation device according to an embodiment is applied. FIG. 2 is a diagram showing the configuration of the simulation apparatus according to the embodiment.

FAシステム150は、工場の生産工程の自動化を図るシステムであり、シミュレーション装置7と、実PLCシステム100−1,100−2,100−3とを有している。実PLCシステム100−1,100−2,100−3は、それぞれ実機のPLCである実PLCを備えている。実PLCシステム100−1,100−2,100−3で用いられる通信プロトコルは、それぞれ異なるものであってもよいし同じものであってもよい。以下では、実PLCシステム100−1,100−2,100−3を、実PLCシステム群101Xという場合がある。   The FA system 150 is a system for automating the production process of a factory, and has a simulation device 7 and actual PLC systems 100-1, 100-2, 100-3. Each of the real PLC systems 100-1, 100-2, 100-3 includes a real PLC that is a PLC of a real machine. The communication protocols used in the actual PLC systems 100-1, 100-2, 100-3 may be different or the same. Below, the real PLC systems 100-1, 100-2, and 100-3 may be called real PLC system group 101X.

シミュレーション装置7は、PLCシステムを仮想的に動作させるための仮想PLCシステム200X,200Yを構築し、仮想PLCシステム200X,200Yをシミュレーションである模擬動作させるコンピュータである。コンピュータの例は、パーソナルコンピュータである。シミュレーション装置7は、ブリッジ32を介して実PLCシステム群101Xに接続される。シミュレーション装置7は、実PLCシステム群101Xとの間でデータを送受信しながら、仮想PLCシステム200X,200Yを模擬動作させる。これにより、シミュレーション装置7は、仮想PLCシステム200X,200Yおよび実PLCシステム群101Xを含んだFAシステム150の動作を検証する。   The simulation device 7 is a computer that constructs virtual PLC systems 200X and 200Y for virtually operating the PLC system and performs a simulated operation of the virtual PLC systems 200X and 200Y. An example of a computer is a personal computer. The simulation device 7 is connected to the real PLC system group 101X via the bridge 32. The simulation device 7 simulates the virtual PLC systems 200X and 200Y while transmitting and receiving data to and from the real PLC system group 101X. Thereby, the simulation device 7 verifies the operation of the FA system 150 including the virtual PLC systems 200X and 200Y and the real PLC system group 101X.

ブリッジ32は、実PLCシステム群101Xと仮想PLCシステム200X,200Yとの間のデータを中継する。ブリッジ32は、シミュレーション部3が、ブリッジソフトウエアを実行することによって実現される。実PLCシステム群101Xとブリッジ32との間、仮想PLCシステム200X,200Yとブリッジ32との間では、データパケットを用いてデータ通信が行われる。   The bridge 32 relays data between the real PLC system group 101X and the virtual PLC systems 200X and 200Y. The bridge 32 is realized by the simulation unit 3 executing bridge software. Data communication is performed using data packets between the real PLC system group 101X and the bridge 32, and between the virtual PLC systems 200X and 200Y and the bridge 32.

シミュレーション装置7は、入力部1と、記憶部2と、シミュレーション部3と、通信部の一例である通信ボード31と、表示制御部6とを備えている。入力部1は、シミュレーションを実行する際に用いられるデータを外部装置から受付けて、記憶部2およびシミュレーション部3に入力する。   The simulation device 7 includes an input unit 1, a storage unit 2, a simulation unit 3, a communication board 31 which is an example of a communication unit, and a display control unit 6. The input unit 1 receives data used when executing a simulation from an external device and inputs the data to the storage unit 2 and the simulation unit 3.

記憶部2は、シミュレーションを実行する際に用いられるデータを記憶する。記憶部2が記憶するデータの例は、PLC設定データ、シミュレーションプログラム、PLCプログラム、および構成情報である。   The storage unit 2 stores data used when executing a simulation. Examples of data stored in the storage unit 2 are PLC setting data, a simulation program, a PLC program, and configuration information.

PLCプログラムは、PLCが動作する際に用いられるプログラムである。構成情報は、仮想PLCシステム200X,200Yの構成を示す情報である。構成情報には、仮想PLCシステム200X,200Yに配置される構成要素のリストと、構成要素間の接続関係と、各構成要素の機能とが含まれている。また、PLC設定データは、PLCが動作する際に用いられるデータである。   The PLC program is a program used when the PLC operates. The configuration information is information indicating the configuration of the virtual PLC systems 200X and 200Y. The configuration information includes a list of components arranged in the virtual PLC systems 200X and 200Y, a connection relationship between the components, and a function of each component. The PLC setting data is data used when the PLC operates.

シミュレーション部3は、シミュレーションプログラムおよび構成情報を用いて仮想PLCシステム200X,200Yをシミュレーション装置7内に構築する。シミュレーション部3は、構築した仮想PLCシステム200X,200Y、PLC設定データおよびPLCプログラムを用いて仮想PLCシステム200X,200Yを模擬動作させる。   The simulation unit 3 constructs the virtual PLC systems 200X and 200Y in the simulation device 7 using the simulation program and the configuration information. The simulation unit 3 simulates the virtual PLC systems 200X and 200Y using the constructed virtual PLC systems 200X and 200Y, the PLC setting data, and the PLC program.

通信ボード31は、シミュレーション部3から送られてくるデータを、実PLCシステム群101Xに送信し、実PLCシステム群101Xから送られてくるデータを仮想PLCシステム200X,200Yに振り分ける。   The communication board 31 transmits the data sent from the simulation unit 3 to the real PLC system group 101X, and distributes the data sent from the real PLC system group 101X to the virtual PLC systems 200X and 200Y.

表示制御部6は、液晶モニタといった表示装置8に接続されており、シミュレーション部3によるシミュレーション結果を表示装置8に表示させる。シミュレーション結果は、仮想PLCシステム200X,200Yの模擬動作の結果である。   The display control unit 6 is connected to a display device 8 such as a liquid crystal monitor, and causes the display device 8 to display the simulation result of the simulation unit 3. The simulation result is a result of a simulation operation of the virtual PLC systems 200X and 200Y.

FAシステム150では、実コントローラシステムである実PLCシステム100−1〜100−3が実際の動作を実行し、仮想コントローラシステムである仮想PLCシステム200X,200Yが模擬動作を実行する。なお、実PLCシステム群101Xは、2つ以下の実PLCシステムであってもよいし、4つ以上の実PLCシステムであってもよい。また、シミュレーション装置7が構築する仮想PLCシステムは、3つ以上であってもよいし、1つであってもよい。   In the FA system 150, the actual PLC systems 100-1 to 100-3, which are actual controller systems, perform actual operations, and the virtual PLC systems 200X and 200Y, which are virtual controller systems, perform simulated operations. The actual PLC system group 101X may be two or less actual PLC systems or four or more actual PLC systems. The number of virtual PLC systems constructed by the simulation device 7 may be three or more, or may be one.

図3は、実施の形態にかかる仮想環境の構成を示す図である。図3では、シミュレーション装置7が構築する仮想環境300、および実PLCシステムの一例である実PLCシステム100の機能ブロック図を示している。実PLCシステム100は、実PLCシステム100−1,100−2,100−3の何れかである。   FIG. 3 is a diagram showing a configuration of a virtual environment according to the embodiment. FIG. 3 shows a functional block diagram of a virtual environment 300 constructed by the simulation apparatus 7 and a real PLC system 100 which is an example of a real PLC system. The real PLC system 100 is one of the real PLC systems 100-1, 100-2, 100-3.

仮想環境300は、シミュレーション部3によって構築される仮想PLCシステム200X,200Yと、ブリッジ32とを含んでいる。仮想PLCシステム200X,200Yにおける処理は、シミュレーション部3が実行するものである。仮想PLCシステム200X,200Yは、ブリッジ32に接続され、ブリッジ32は、通信ボード31に接続されている。通信ボード31は、実PLCシステム100に接続されている。なお、ここでは、仮想環境300が実PLCシステム100に接続されている場合について説明するが、仮想環境300は、実PLCシステム群101Xに接続されている。   The virtual environment 300 includes virtual PLC systems 200X and 200Y constructed by the simulation unit 3 and a bridge 32. The processing in the virtual PLC systems 200X and 200Y is executed by the simulation unit 3. The virtual PLC systems 200X and 200Y are connected to the bridge 32, and the bridge 32 is connected to the communication board 31. The communication board 31 is connected to the actual PLC system 100. Note that, here, a case where the virtual environment 300 is connected to the real PLC system 100 will be described, but the virtual environment 300 is connected to the real PLC system group 101X.

仮想PLCシステム200X,200Yは、実際のPLCシステムを模擬する仮想的なPLCシステムであり、実際のPLCシステムと同様の動作を仮想的に実行する。仮想PLCシステム200Xは、仮想PLC50A,50Bと、仮想的なネットワークユニット(NWU:NetWork Unit)である仮想NWU60Aと、仮想PLCシステム設定データ42Xとを備えている。仮想PLCシステム200Xでは、ライン接続またはスター接続といった伝送路形式で、仮想PLC50A,50Bと、仮想NWU60Aとが接続されている。伝送路形式は、構成情報に含まれる、構成要素間の接続関係に対応している。   The virtual PLC systems 200X and 200Y are virtual PLC systems simulating an actual PLC system, and virtually execute the same operation as the actual PLC system. The virtual PLC system 200X includes virtual PLCs 50A and 50B, a virtual NWU 60A that is a virtual network unit (NWU: NetWork Unit), and virtual PLC system setting data 42X. In the virtual PLC system 200X, the virtual PLCs 50A and 50B and the virtual NWU 60A are connected in a transmission line format such as line connection or star connection. The transmission path format corresponds to the connection relation between the constituent elements included in the configuration information.

また、仮想PLCシステム200Yは、仮想PLC50Cと、仮想NWU60Cと、仮想PLCシステム設定データ42Yとを備えている。仮想PLCシステム200Yでは、ライン接続またはスター接続といった伝送路形式で、仮想PLC50Cと、仮想NWU60Cとが接続されている。   Further, the virtual PLC system 200Y includes a virtual PLC 50C, a virtual NWU 60C, and virtual PLC system setting data 42Y. In the virtual PLC system 200Y, the virtual PLC 50C and the virtual NWU 60C are connected in a transmission line format such as line connection or star connection.

仮想システム設定データである仮想PLCシステム設定データ42Xは、仮想PLCシステム200Xに含まれる仮想PLC50A,50B、仮想NWU60Aといった各ユニットの配置情報と、仮想PLCシステム200X内におけるユニット間交信周期と、ネットワーク交信周期とを含んでいる。仮想PLCシステム200X内におけるユニット間交信周期は、仮想PLCシステム200X内のユニット間での交信周期である。ネットワーク交信周期は、FAシステム150内のPLCシステム間での交信周期である。   The virtual PLC system setting data 42X, which is the virtual system setting data, includes arrangement information of each unit such as the virtual PLCs 50A and 50B and the virtual NWU 60A included in the virtual PLC system 200X, a communication cycle between units in the virtual PLC system 200X, and a network communication. Cycle and. The inter-unit communication cycle in the virtual PLC system 200X is a communication cycle between units in the virtual PLC system 200X. The network communication cycle is a communication cycle between PLC systems in the FA system 150.

仮想PLCシステム設定データ42Yは、仮想PLCシステム200Yに含まれる仮想PLC50C、仮想NWU60Cといった各ユニットの配置情報と、仮想PLCシステム200Y内におけるユニット間交信周期と、ネットワーク交信周期とを含んでいる。仮想PLCシステム200Y内におけるユニット間交信周期は、仮想PLCシステム200Y内のユニット間での交信周期である。   The virtual PLC system setting data 42Y includes the arrangement information of each unit such as the virtual PLC 50C and the virtual NWU 60C included in the virtual PLC system 200Y, the inter-unit communication cycle in the virtual PLC system 200Y, and the network communication cycle. The inter-unit communication cycle in the virtual PLC system 200Y is a communication cycle between units in the virtual PLC system 200Y.

実PLCシステム100は、実PLC10と、実NWU20と、実PLCシステム設定データ41とを備えている。実PLCシステム100は、複数のユニットが装着されるベースユニットを備えており、このベースユニットに、実PLC10と、実NWU20とが装着されている。実PLCシステム設定データ41は、ベースユニットに装着される何れかのユニット内に格納されている。実システム設定データである実PLCシステム設定データ41は、実PLCシステム100に含まれる実PLC10、実NWU20といった各ユニットの配置情報と、実PLCシステム100内におけるユニット間交信周期と、ネットワーク交信周期とを含んでいる。実PLCシステム100内におけるユニット間交信周期は、実PLCシステム100内のユニット間での交信周期である。   The real PLC system 100 includes a real PLC 10, a real NWU 20, and a real PLC system setting data 41. The real PLC system 100 includes a base unit on which a plurality of units are mounted, and the real PLC 10 and the real NWU 20 are mounted on the base unit. The actual PLC system setting data 41 is stored in any unit mounted on the base unit. The actual PLC system setting data 41, which is the actual system setting data, includes the arrangement information of each unit such as the actual PLC 10 and the actual NWU 20 included in the actual PLC system 100, the communication cycle between the units in the actual PLC system 100, and the network communication cycle. Is included. The inter-unit communication cycle in the real PLC system 100 is a communication cycle between units in the real PLC system 100.

なお、実PLCシステム100がマスタのPLCシステムであり、仮想PLCシステム200XがローカルのPLCシステムである場合、シミュレーション部3は、実PLCシステム100から仮想PLCシステム設定データ42Xを取得してもよい。マスタのPLCシステムは、ローカルのPLCシステムから種々のデータを収集するとともに、収集したデータに基づいて、ローカルのPLCシステムを制御するPLCシステムである。シミュレーション部3が、実PLCシステム100から仮想PLCシステム設定データ42Xを取得する場合、仮想PLCシステム200Xは、ブリッジ32および通信ボード31を介して、実PLCシステム100から仮想PLCシステム設定データ42Xを受信する。また、シミュレーション部3は、仮想PLCシステム200Xに、実PLCシステム設定データ41を取得させ、取得した実PLCシステム設定データ41に基づいて、仮想PLCシステム設定データ42Xを生成してもよい。   When the real PLC system 100 is a master PLC system and the virtual PLC system 200X is a local PLC system, the simulation unit 3 may acquire the virtual PLC system setting data 42X from the real PLC system 100. The master PLC system is a PLC system that collects various data from the local PLC system and controls the local PLC system based on the collected data. When the simulation unit 3 acquires the virtual PLC system setting data 42X from the real PLC system 100, the virtual PLC system 200X receives the virtual PLC system setting data 42X from the real PLC system 100 via the bridge 32 and the communication board 31. To do. Further, the simulation unit 3 may cause the virtual PLC system 200X to acquire the real PLC system setting data 41, and generate the virtual PLC system setting data 42X based on the acquired real PLC system setting data 41.

仮想PLC50Aは、PLC設定データ51Aと、PLCプログラム52Aと、プログラム実行部53Aと、仮想時計54Aと、ユニット間交信部55Aと、ツール通信部56Aとを有している。   The virtual PLC 50A has PLC setting data 51A, a PLC program 52A, a program execution unit 53A, a virtual clock 54A, an inter-unit communication unit 55A, and a tool communication unit 56A.

仮想PLC50Bは、PLC設定データ51Bと、PLCプログラム52Bと、プログラム実行部53Bと、仮想時計54Bと、ユニット間交信部55Bと、ツール通信部56Bとを有している。   The virtual PLC 50B has PLC setting data 51B, a PLC program 52B, a program execution unit 53B, a virtual clock 54B, an inter-unit communication unit 55B, and a tool communication unit 56B.

仮想PLC50Cは、PLC設定データ51Cと、PLCプログラム52Cと、プログラム実行部53Cと、仮想時計54Cと、ユニット間交信部55Cと、ツール通信部56Cとを有している。   The virtual PLC 50C has PLC setting data 51C, a PLC program 52C, a program execution unit 53C, a virtual clock 54C, an inter-unit communication unit 55C, and a tool communication unit 56C.

実PLC10は、PLC設定データ11と、PLCプログラム12と、プログラム実行部13と、時計14と、ユニット間交信部15Cと、ツール通信部16とを有している。   The actual PLC 10 includes a PLC setting data 11, a PLC program 12, a program execution unit 13, a clock 14, an inter-unit communication unit 15C, and a tool communication unit 16.

仮想NWU60Aは、外部装置との通信を行うユニットであり、NWU設定データ61と、ユニット間交信部62Aと、仮想時計63Aと、ネットワーク交信部64Aと、メモリ65Aとを備えている。仮想NWU60Cは、NWU設定データ61と、ユニット間交信部62Cと、仮想時計63Cと、ネットワーク交信部64Cと、メモリ65Cとを備えている。実NWU20は、NWU設定データ61と、ユニット間交信部22と、時計23と、ネットワーク交信部24と、メモリ25とを備えている。   The virtual NWU 60A is a unit that communicates with an external device, and includes the NWU setting data 61, an inter-unit communication unit 62A, a virtual clock 63A, a network communication unit 64A, and a memory 65A. The virtual NWU 60C includes NWU setting data 61, an inter-unit communication unit 62C, a virtual clock 63C, a network communication unit 64C, and a memory 65C. The actual NWU 20 includes NWU setting data 61, an inter-unit communication unit 22, a clock 23, a network communication unit 24, and a memory 25.

仮想PLC50A〜50Cは、同様の構成要素を有しているので、ここでは仮想PLC50Aの構成要素について説明する。また、仮想NWU60A,60Cは、同様の構成要素を有しているので、ここでは仮想NWU60Aの構成要素について説明する。   Since the virtual PLCs 50A to 50C have the same components, the components of the virtual PLC 50A will be described here. Further, since the virtual NWUs 60A and 60C have similar components, only the components of the virtual NWU 60A will be described here.

PLC設定データ51Aは、仮想PLC50Aが動作する際に用いられるデータである。PLC設定データ51Aは、仮想PLC50Aが動作する際の動作条件といった種々の情報を含んでいる。   The PLC setting data 51A is data used when the virtual PLC 50A operates. The PLC setting data 51A includes various information such as operating conditions when the virtual PLC 50A operates.

PLCプログラム52Aは、仮想PLC50Aが模擬動作する際に用いられるプログラムである。PLCプログラム52Aは、仮想PLC50Aに対応する実PLCを動作させる際に用いるPLCプログラムと同じプログラムである。PLCプログラム52Aの例は、ラダープログラムといったシーケンスプログラムである。   The PLC program 52A is a program used when the virtual PLC 50A performs a simulated operation. The PLC program 52A is the same program as the PLC program used when operating the real PLC corresponding to the virtual PLC 50A. An example of the PLC program 52A is a sequence program such as a ladder program.

プログラム実行部53Aは、PLCプログラム52Aを実行する。また、プログラム実行部53Aは、ツール通信部56Aから設定情報が送信されてきた場合には、設定情報を用いてPLCプログラム52Aを実行する。また、プログラム実行部53Aは、PLCプログラム52Aの実行状況に従って仮想時計54Aの時刻を進行させる。プログラム実行部53Aは、PLCプログラム52Aの実行を開始すると、実行済みの命令に対応する消費時間を仮想時計54Aに送信する。   The program execution unit 53A executes the PLC program 52A. Further, when the setting information is transmitted from the tool communication unit 56A, the program execution unit 53A executes the PLC program 52A using the setting information. In addition, the program execution unit 53A advances the time of the virtual clock 54A according to the execution status of the PLC program 52A. When the execution of the PLC program 52A is started, the program execution unit 53A transmits the consumption time corresponding to the executed instruction to the virtual clock 54A.

仮想時計54Aは、プログラム実行部53AによるPLCプログラム52Aの実行状況に基づいて時刻が進められる仮想的な時計である。仮想時計54Aでは、仮想PLC50Aがリセットされた時刻が0である。仮想時計54Aは、PLCプログラム52Aの実行が開始されると、PLCプログラム52A内の命令ごとに決められた消費時間を累算していく。これにより、仮想時計54Aは、実行済みの命令に対応する時刻データを保持する。   The virtual clock 54A is a virtual clock whose time is advanced based on the execution status of the PLC program 52A by the program execution unit 53A. In the virtual clock 54A, the time when the virtual PLC 50A is reset is 0. When the execution of the PLC program 52A is started, the virtual clock 54A accumulates the consumption time determined for each instruction in the PLC program 52A. As a result, the virtual clock 54A holds time data corresponding to the executed instruction.

ユニット間交信部55Aは、仮想PLCシステム設定データ42Xに含まれるユニット識別子に基づいて、仮想PLCシステム200X内の他のユニットとの間でデータ通信を実行する。この場合において、ユニット間交信部55Aは、仮想時計54Aと仮想PLCシステム設定データ42Xに含まれるユニット間交信周期とに従って、仮想PLCシステム200X内の他のユニットとの間でデータ通信を実行する。ここでのユニット間交信部55Aは、仮想PLC50Bとの間のデータ通信と、仮想NWU60Aとの間のデータ通信とを実行する。   The inter-unit communication unit 55A executes data communication with other units in the virtual PLC system 200X based on the unit identifier included in the virtual PLC system setting data 42X. In this case, the inter-unit communication unit 55A executes data communication with other units in the virtual PLC system 200X according to the inter-unit communication cycle included in the virtual clock 54A and the virtual PLC system setting data 42X. The inter-unit communication unit 55A here executes data communication with the virtual PLC 50B and data communication with the virtual NWU 60A.

ユニット間交信部55Aは、PLCプログラム52Aを実行しているプログラム実行部53Aから、仮想PLC50Bへのデータ送信指示があると、仮想PLC50Aを送信元として、仮想PLC50Bのユニット間交信部55Bにデータを送信する。   When the program execution unit 53A executing the PLC program 52A issues a data transmission instruction to the virtual PLC 50B, the inter-unit communication unit 55A sends data to the inter-unit communication unit 55B of the virtual PLC 50B using the virtual PLC 50A as a transmission source. Send.

また、ユニット間交信部55Aは、PLCプログラム52Aを実行しているプログラム実行部53Aから、仮想NWU60Aへのデータ送信指示があると、仮想PLC50Aを送信元として、仮想NWU60Aのユニット間交信部62Aにデータを送信する。   When the program execution unit 53A executing the PLC program 52A issues a data transmission instruction to the virtual NWU 60A, the inter-unit communication unit 55A uses the virtual PLC 50A as a transmission source to notify the inter-unit communication unit 62A of the virtual NWU 60A. Send the data.

また、ユニット間交信部55Aは、PLCプログラム52Aを実行しているプログラム実行部53Aから、他のPLCシステムへのデータ送信指示があると、送信対象のデータにユニットの宛先と送信元の仮想PLC50Aのアドレスとを付与して仮想NWU60Aのユニット間交信部62Aに送信する。ユニットの宛先は、第1の識別情報であるネットワーク番号および第2の識別情報である局番で指定される。ネットワーク番号および局番については後述する。   In addition, the inter-unit communication unit 55A receives the data transmission instruction from the program execution unit 53A executing the PLC program 52A to another PLC system, and the virtual PLC 50A of the destination and the transmission source of the unit in the data to be transmitted. The address of the virtual NWU 60A is sent to the inter-unit communication unit 62A. The destination of the unit is designated by the network number which is the first identification information and the station number which is the second identification information. The network number and station number will be described later.

また、ユニット間交信部55Aは、ユニット間交信部55Bまたはユニット間交信部62Aから送られてくるデータを受信する。なお、ユニット間交信部55Aは、ユニット間交信部55Bまたはユニット間交信部62Aからデータを読み出してもよい。   Further, the unit-to-unit communication unit 55A receives the data sent from the unit-to-unit communication unit 55B or the unit-to-unit communication unit 62A. The inter-unit communication section 55A may read data from the inter-unit communication section 55B or the inter-unit communication section 62A.

ユニット間交信部55Aは、PLC設定データ51Aと、仮想時計54Aから読み出した時刻データとに基づいて、仮想PLC50Bおよび仮想NWU60Aの間で時刻同期を実行する。これにより、仮想時計54Aと、仮想時計54Bと、仮想時計63Aとの間で、仮想時計のすり合せが行われる。   The inter-unit communication unit 55A performs time synchronization between the virtual PLC 50B and the virtual NWU 60A based on the PLC setting data 51A and the time data read from the virtual clock 54A. As a result, the virtual clocks 54A, 54B, and 63A are matched with each other.

ツール通信部56Aは、図示しないエンジニアリングツールとの間でデータ通信を実行する。エンジニアリングツールは、仮想PLC50Aを動作させる際の種々の設定を行うためのツールである。ユーザからの指示に従ってエンジニアリングツールが種々の設定を行うと、ツール通信部56Aは、エンジニアリングツールで設定された設定情報を受信する。設定情報の例は、PLC設定データ51Aへの設定情報およびPLCプログラム52Aへの設定情報である。   The tool communication unit 56A executes data communication with an engineering tool (not shown). The engineering tool is a tool for performing various settings when operating the virtual PLC 50A. When the engineering tool makes various settings according to the instruction from the user, the tool communication unit 56A receives the setting information set by the engineering tool. Examples of setting information are setting information for the PLC setting data 51A and setting information for the PLC program 52A.

NWU設定データ61は、仮想PLCシステム200X内の各ユニットのアドレスと、局番との対応関係を含んでいる。仮想PLCシステム200X内では、局番が指定されることによって、仮想PLCシステム200X内のユニットのアドレスを特定することができる。   The NWU setting data 61 includes the correspondence between the address of each unit in the virtual PLC system 200X and the station number. In the virtual PLC system 200X, the address of a unit in the virtual PLC system 200X can be specified by designating the station number.

ユニット間交信部62Aは、ユニット間交信部55Aと同様の機能を有している。また、ユニット間交信部62Aは、実PLCシステム100または仮想PLCシステム200Yから仮想PLC50A,50Bへのデータがメモリ65Aに格納されている場合、このデータの宛先である仮想PLC50Aまたは仮想PLC50Bにデータを送信する。また、ユニット間交信部62Aは、仮想PLC50A,50Bから実PLCシステム100または仮想PLCシステム200Yを宛先としたデータを受信した場合には、このデータをメモリ65Aに格納する。また、ユニット間交信部62Aは、仮想NWU60Aを宛先としたデータがメモリ65Aに格納されている場合、このデータを仮想NWU60A内のメモリ65A以外のメモリに格納する。また、ユニット間交信部62Aは、仮想PLC50A,50Bから仮想NWU60Aを宛先としたデータを受信すると、受信したデータを仮想NWU60A内のメモリ65A以外のメモリに格納する。   The unit-to-unit communication unit 62A has the same function as the unit-to-unit communication unit 55A. Further, when the data from the real PLC system 100 or the virtual PLC system 200Y to the virtual PLCs 50A and 50B is stored in the memory 65A, the inter-unit communication unit 62A sends the data to the virtual PLC 50A or the virtual PLC 50B that is the destination of this data. Send. Further, when the unit-to-unit communication unit 62A receives data addressed to the real PLC system 100 or the virtual PLC system 200Y from the virtual PLCs 50A and 50B, the unit communication unit 62A stores this data in the memory 65A. Further, when the data addressed to the virtual NWU 60A is stored in the memory 65A, the inter-unit communication unit 62A stores this data in a memory other than the memory 65A in the virtual NWU 60A. Further, when the unit-to-unit communication unit 62A receives data addressed to the virtual NWU 60A from the virtual PLCs 50A and 50B, the unit communication unit 62A stores the received data in a memory other than the memory 65A in the virtual NWU 60A.

仮想時計63Aは、仮想時計54Bと同様の機能を有している。ネットワーク交信部64Aは、仮想PLCシステム設定データ42X内に含まれるネットワーク交信周期に従って、実PLCシステム100および仮想PLCシステム200Yとの間の交信を行う。ネットワーク交信部64Aは、実PLCシステム100または仮想PLCシステム200Yから送信されてきたデータをメモリ65Aに格納する。また、ネットワーク交信部64Aは、メモリ65Aに格納されている実PLCシステム100または仮想PLCシステム200Yへのデータをブリッジ32に送信する。   The virtual clock 63A has the same function as the virtual clock 54B. The network communication unit 64A communicates with the real PLC system 100 and the virtual PLC system 200Y according to the network communication cycle included in the virtual PLC system setting data 42X. The network communication unit 64A stores the data transmitted from the real PLC system 100 or the virtual PLC system 200Y in the memory 65A. Further, the network communication unit 64A transmits to the bridge 32 the data for the real PLC system 100 or the virtual PLC system 200Y stored in the memory 65A.

メモリ65Aは、実PLCシステム100または仮想PLCシステム200Yから送られてきたデータを格納し、仮想PLC50A,50Bに送られてきたデータを格納する。メモリ65Aは、ブリッジ32からデータを受信し、ブリッジ32にデータを送信する。   The memory 65A stores the data sent from the real PLC system 100 or the virtual PLC system 200Y, and stores the data sent to the virtual PLCs 50A and 50B. The memory 65A receives data from the bridge 32 and transmits data to the bridge 32.

なお、仮想PLCシステム200X,200Y、実PLCシステム100は、仮想の電源ユニット、仮想の入力ユニット、または仮想の出力ユニットを備えていてもよい。電源ユニットは、PLCシステムに電源供給を行うユニットであり、入力ユニットは、生産装置または設備装置に取り付けられたスイッチまたはセンサの信号を受付けるユニットであり、出力ユニットは、アクチュエータといった外部装置に制御指示を出力するユニットである。   The virtual PLC systems 200X and 200Y and the real PLC system 100 may include a virtual power supply unit, a virtual input unit, or a virtual output unit. The power supply unit is a unit that supplies power to the PLC system, the input unit is a unit that receives a signal from a switch or a sensor attached to the production device or the facility device, and the output unit is a control instruction to an external device such as an actuator. Is a unit that outputs.

また、仮想PLCシステム200Xは、1つの仮想PLCを有していてもよいし、3つ以上の仮想PLCを有していてもよい。また、仮想PLCシステム200Yは、複数の仮想PLCを有していてもよい。また、実PLCシステム100は、複数の実PLCを有していてもよい。   Further, the virtual PLC system 200X may have one virtual PLC or may have three or more virtual PLCs. Further, the virtual PLC system 200Y may have a plurality of virtual PLCs. Moreover, the real PLC system 100 may have a plurality of real PLCs.

ブリッジ32は、実PLCシステム100から送信されてきたデータを、データの宛先に基づいて、仮想PLCシステム200Xまたは仮想PLCシステム200Yに送信する。また、ブリッジ32は、仮想PLCシステム200Xから送信されてきたデータを、データの宛先に基づいて、通信ボード31または仮想PLCシステム200Yに送信する。また、ブリッジ32は、仮想PLCシステム200Yから送信されてきたデータを、データの宛先に基づいて、通信ボード31または仮想PLCシステム200Xに送信する。   The bridge 32 transmits the data transmitted from the real PLC system 100 to the virtual PLC system 200X or the virtual PLC system 200Y based on the destination of the data. Further, the bridge 32 transmits the data transmitted from the virtual PLC system 200X to the communication board 31 or the virtual PLC system 200Y based on the destination of the data. Moreover, the bridge 32 transmits the data transmitted from the virtual PLC system 200Y to the communication board 31 or the virtual PLC system 200X based on the destination of the data.

通信ボード31は、仮想環境300で用いられている仮想PLCネットワークの第1の通信プロトコルである通信プロトコルと、実PLCシステム100で用いられている実PLCネットワークの第2の通信プロトコルである通信プロトコルと、の間のプロトコル変換を行う。   The communication board 31 is a first communication protocol of the virtual PLC network used in the virtual environment 300 and a second communication protocol of the real PLC network used in the real PLC system 100. And protocol conversion between and.

実PLC10は、仮想PLC50A〜50Cと同様の構成要素を有している。仮想PLC50A〜50Cの構成要素は、仮想的な構成要素であるのに対し、実PLC10の構成要素は、実際の装置としての構成要素である。したがって、仮想PLC50A〜50Cが備える仮想時計54A〜54Cは、仮想的な時計であるのに対し、実PLC10が備える時計14は、実際の時計である。   The real PLC 10 has the same components as the virtual PLCs 50A to 50C. The constituent elements of the virtual PLCs 50A to 50C are virtual constituent elements, whereas the constituent elements of the real PLC 10 are constituent elements as an actual device. Therefore, the virtual timepieces 54A to 54C included in the virtual PLCs 50A to 50C are virtual timepieces, while the timepiece 14 included in the real PLC 10 is an actual timepiece.

また、実NWU20は、仮想NWU60A,60Cと同様の構成要素を有している。仮想NWU60A,60Cの構成要素は、仮想的な構成要素であるのに対し、実NWU20の構成要素は、実際の装置としての構成要素である。したがって、仮想NWU60A,60Cが備える仮想時計63A,63Cは、仮想的な時計であるのに対し、実NWU20が備える時計23は、実際の時計である。   The real NWU 20 has the same components as the virtual NWUs 60A and 60C. The constituent elements of the virtual NWUs 60A and 60C are virtual constituent elements, whereas the constituent elements of the real NWU 20 are constituent elements as actual devices. Therefore, the virtual clocks 63A and 63C included in the virtual NWUs 60A and 60C are virtual clocks, while the clock 23 included in the real NWU 20 is an actual clock.

なお、仮想PLCシステム200X,200Yは、複数の仮想NWUを備えていてもよい。また、実PLCシステム100は、複数の実NWUを備えていてもよい。1つのPLCシステムが複数のNWUを備えることにより、PLCシステムは、設定の異なる複数のネットワークに接続することが可能となる。   The virtual PLC systems 200X and 200Y may include a plurality of virtual NWUs. Further, the real PLC system 100 may include a plurality of real NWUs. Since one PLC system includes a plurality of NWUs, the PLC system can be connected to a plurality of networks having different settings.

ここで、ブリッジ32および通信ボード31の構成について説明する。図4は、実施の形態にかかる仮想PLCシステムが備える接続部の第1の構成例を示す図である。   Here, the configurations of the bridge 32 and the communication board 31 will be described. FIG. 4 is a diagram illustrating a first configuration example of the connection unit included in the virtual PLC system according to the embodiment.

接続部30Aは、実環境301と仮想環境300とを接続する。実環境301には、実PLCシステム100が配置され、仮想環境300には、仮想PLCシステム200X,200Yが配置されている。   The connection unit 30A connects the real environment 301 and the virtual environment 300. The real PLC system 100 is arranged in the real environment 301, and the virtual PLC systems 200X and 200Y are arranged in the virtual environment 300.

接続部30Aは、ソフトウエアまたはファームウエアで実現されるブリッジ32と、専用のハードウエアで実現される通信ボード31とを有している。ブリッジ32は、通信ボード31に接続され、通信ボード31は、実PLCシステム100に接続されている。   The connection unit 30A includes a bridge 32 implemented by software or firmware and a communication board 31 implemented by dedicated hardware. The bridge 32 is connected to the communication board 31, and the communication board 31 is connected to the real PLC system 100.

通信ボード31は、実PLCシステム100から送られてくるデータに基づいて、実PLCシステム100で用いられている実PLCネットワークの通信プロトコルを特定する。また、通信ボード31は、仮想PLCシステム200X,200Yで用いられている仮想PLCネットワークの通信プロトコルを記憶している。   The communication board 31 specifies the communication protocol of the real PLC network used in the real PLC system 100 based on the data sent from the real PLC system 100. The communication board 31 also stores the communication protocol of the virtual PLC network used in the virtual PLC systems 200X and 200Y.

通信ボード31は、実PLCシステム100と仮想PLCシステム200X,200Yとの間でデータを送受信する際に、データのプロトコル変換を行う。仮想PLCシステム200X,200Yで用いられる仮想PLCネットワークの通信プロトコルの一例は、TCP/IP(Transmission Control Protocol/Internet Protocol)である。   The communication board 31 performs protocol conversion of data when transmitting and receiving data between the real PLC system 100 and the virtual PLC systems 200X and 200Y. An example of a communication protocol of the virtual PLC network used in the virtual PLC systems 200X and 200Y is TCP/IP (Transmission Control Protocol/Internet Protocol).

通信ボード31は、ブリッジ32からデータが送られてきた場合には、送られてきたデータを、実PLCシステム100が用いる通信プロトコルに変換して実PLCシステム100に送信する。また、通信ボード31は、実PLCシステム100からデータが送られてきた場合には、送られてきたデータを、仮想PLCシステム200X,200Yが用いる通信プロトコルに変換してブリッジ32に送信する。   When data is sent from the bridge 32, the communication board 31 converts the sent data into a communication protocol used by the real PLC system 100 and sends it to the real PLC system 100. Further, when data is sent from the real PLC system 100, the communication board 31 converts the sent data into a communication protocol used by the virtual PLC systems 200X and 200Y and sends the data to the bridge 32.

ブリッジ32は、データ解析部33と、データ作成部34と、記憶部35とを備えている。記憶部35は、ネットワーク番号と仮想NWU60A,60Cのアドレスとの対応関係を記憶しておく。具体的には、記憶部35は、仮想PLCシステム200Xのネットワーク番号と仮想NWU60Aのアドレスとの対応関係と、仮想PLCシステム200Yのネットワーク番号と仮想NWU60Cのアドレスとの対応関係とを記憶しておく。   The bridge 32 includes a data analysis unit 33, a data creation unit 34, and a storage unit 35. The storage unit 35 stores the correspondence between the network number and the addresses of the virtual NWUs 60A and 60C. Specifically, the storage unit 35 stores the correspondence relationship between the network number of the virtual PLC system 200X and the address of the virtual NWU 60A and the correspondence relationship between the network number of the virtual PLC system 200Y and the address of the virtual NWU 60C. ..

ブリッジ32は、記憶部35が記憶している情報に基づいて、実PLCシステム100と、仮想PLCシステム200Xと、仮想PLCシステム200Yとの間のデータ中継を行う。   The bridge 32 relays data between the real PLC system 100, the virtual PLC system 200X, and the virtual PLC system 200Y based on the information stored in the storage unit 35.

データ解析部33は、仮想PLCシステム200Xから、実PLCシステム100または仮想PLCシステム200Yを宛先としたデータを受信する。また、データ解析部33は、仮想PLCシステム200Yから、実PLCシステム100または仮想PLCシステム200Xを宛先としたデータを受信する。また、データ解析部33は、実PLCシステム100から通信ボード31を介して、仮想PLCシステム200Xまたは仮想PLCシステム200Yを宛先としたデータを受信する。   The data analysis unit 33 receives, from the virtual PLC system 200X, data addressed to the real PLC system 100 or the virtual PLC system 200Y. Further, the data analysis unit 33 receives, from the virtual PLC system 200Y, data addressed to the real PLC system 100 or the virtual PLC system 200X. Further, the data analysis unit 33 receives the data addressed to the virtual PLC system 200X or the virtual PLC system 200Y from the real PLC system 100 via the communication board 31.

データ解析部33は、ネットワーク番号と仮想NWUのアドレスとの対応関係に基づいて、受信したデータを、実PLCシステム100、仮想PLCシステム200Xまたは仮想PLCシステム200Yの何れかに振り分ける。   The data analysis unit 33 distributes the received data to one of the real PLC system 100, the virtual PLC system 200X, or the virtual PLC system 200Y based on the correspondence between the network number and the address of the virtual NWU.

データ解析部33は、仮想PLCシステム200Yから受信したデータの宛先が仮想PLCシステム200X内のユニットである場合、受信したデータを仮想NWU60Aのメモリ65Aに書き込む。また、データ解析部33は、仮想PLCシステム200Xから受信したデータの宛先が仮想PLCシステム200Y内のユニットである場合、受信したデータを仮想NWU60Cのメモリ65Cに書き込む。   When the destination of the data received from the virtual PLC system 200Y is a unit in the virtual PLC system 200X, the data analysis unit 33 writes the received data in the memory 65A of the virtual NWU 60A. Further, when the destination of the data received from the virtual PLC system 200X is a unit in the virtual PLC system 200Y, the data analysis unit 33 writes the received data in the memory 65C of the virtual NWU 60C.

また、データ解析部33は、仮想PLCシステム200X,200Yから受信したデータの宛先が実PLCシステム100内のユニットである場合、受信したデータをデータ作成部34に送信し、データ作成部34からフォーマット変換後のデータを受信する。データ解析部33は、データの宛先が実PLCシステム100内のユニットである場合、フォーマット変換後のデータを通信ボード31に送信する。   Further, when the destination of the data received from the virtual PLC systems 200X and 200Y is a unit in the real PLC system 100, the data analysis unit 33 transmits the received data to the data creation unit 34, and the data creation unit 34 formats the data. Receive the converted data. When the destination of the data is a unit in the actual PLC system 100, the data analysis unit 33 transmits the data after the format conversion to the communication board 31.

また、データ解析部33は、実PLCシステム100から受信したデータの宛先が仮想PLCシステム200X,200Y内のユニットである場合、受信したデータをデータ作成部34に送信し、データ作成部34からフォーマット変換後のデータを受信する。以下、フォーマット変換前のデータと、フォーマット変換後のデータとをともにデータという場合がある。   Further, when the destination of the data received from the real PLC system 100 is a unit in the virtual PLC systems 200X and 200Y, the data analysis unit 33 transmits the received data to the data creation unit 34, and the data creation unit 34 formats the data. Receive the converted data. Hereinafter, both the data before format conversion and the data after format conversion may be referred to as data.

データ解析部33は、受信したデータの宛先が仮想PLCシステム200Xまたは仮想PLCシステム200Yである場合、宛先のネットワーク番号に対応する仮想NWUのアドレスを特定する。そして、データ解析部33は、特定した仮想NWUのアドレスに対してデータを送信する。具体的には、データ解析部33は、データの宛先が、仮想PLCシステム200X内のユニットである場合、受信したデータを仮想NWU60Aのメモリ65Aに書き込む。また、データ解析部33は、データの宛先が、仮想PLCシステム200Y内のユニットである場合、受信したデータを仮想NWU60Cのメモリ65Cに書き込む。   When the destination of the received data is the virtual PLC system 200X or the virtual PLC system 200Y, the data analysis unit 33 identifies the address of the virtual NWU corresponding to the network number of the destination. Then, the data analysis unit 33 transmits the data to the specified virtual NWU address. Specifically, when the data destination is a unit in the virtual PLC system 200X, the data analysis unit 33 writes the received data in the memory 65A of the virtual NWU 60A. Further, when the destination of the data is a unit in the virtual PLC system 200Y, the data analysis unit 33 writes the received data in the memory 65C of the virtual NWU 60C.

これにより、データの宛先が仮想PLC50A,50Bまたは仮想NWU60Aである場合、データ解析部33は、データを仮想NWU60Aのメモリ65Aに送信する。また、データの宛先が仮想PLC50Cまたは仮想NWU60Cである場合、データ解析部33は、データを仮想NWU60Cのメモリ65Cに送信する。   Accordingly, when the data destination is the virtual PLC 50A, 50B or the virtual NWU 60A, the data analysis unit 33 transmits the data to the memory 65A of the virtual NWU 60A. When the data destination is the virtual PLC 50C or the virtual NWU 60C, the data analysis unit 33 transmits the data to the memory 65C of the virtual NWU 60C.

データ作成部34は、実PLCシステム100から受信したデータの宛先が仮想PLCシステム200Xまたは仮想PLCシステム200Y内のユニットである場合、受信したデータを、仮想PLCシステム200Xまたは仮想PLCシステム200Y内で処理可能なデータにフォーマット変換する。   When the destination of the data received from the real PLC system 100 is a unit in the virtual PLC system 200X or the virtual PLC system 200Y, the data creation unit 34 processes the received data in the virtual PLC system 200X or the virtual PLC system 200Y. Convert format to possible data.

データ作成部34は、仮想PLCシステム200Xまたは仮想PLCシステム200Yから受信したデータの宛先が実PLCシステム100内のユニットである場合、受信したデータを、実PLCシステム100内で処理可能なデータにフォーマット変換する。   When the destination of the data received from the virtual PLC system 200X or the virtual PLC system 200Y is a unit within the real PLC system 100, the data creation unit 34 formats the received data into data that can be processed within the real PLC system 100. Convert.

図5は、実施の形態にかかる仮想PLCシステムが備える接続部の第2の構成例を示す図である。図5の各構成要素のうち図4に示す接続部30Aと同一機能を達成する構成要素については同一符号を付しており、重複する説明は省略する。   FIG. 5 is a diagram illustrating a second configuration example of the connection unit included in the virtual PLC system according to the embodiment. Among the constituent elements of FIG. 5, constituent elements that achieve the same functions as those of the connecting section 30A shown in FIG.

接続部30Bは、実PLCシステム100および仮想PLCシステム200X,200Yに接続されている。接続部30Bは、通信ボード31の代わりに、通信部の一例であるソフトウエアプロトコルスタック29を有している。すなわち、接続部30Bは、ソフトウエアまたはファームウエアで実現されるブリッジ32と、ソフトウエアまたはファームウエアで実現されるソフトウエアプロトコルスタック29とを有している。ブリッジ32は、ソフトウエアプロトコルスタック29に接続され、ソフトウエアプロトコルスタック29は、実PLCシステム100に接続されている。   The connection unit 30B is connected to the real PLC system 100 and the virtual PLC systems 200X and 200Y. The connection unit 30B has a software protocol stack 29, which is an example of a communication unit, instead of the communication board 31. That is, the connection unit 30B has a bridge 32 realized by software or firmware and a software protocol stack 29 realized by software or firmware. The bridge 32 is connected to the software protocol stack 29, and the software protocol stack 29 is connected to the real PLC system 100.

ソフトウエアプロトコルスタック29は、通信ボード31と同様の機能を有している。通信ボード31は、ハードウエアでプロトコル変換を行うのに対し、ソフトウエアプロトコルスタック29は、ソフトウエアまたはファームウエアでプロトコル変換を行う。すなわち、ソフトウエアプロトコルスタック29は、ソフトウエアまたはファームウエアで、実PLCシステム100の通信プロトコルと、仮想PLCシステム200X,200Yの通信プロトコルとの間のプロトコル変換を行う。   The software protocol stack 29 has the same function as the communication board 31. The communication board 31 performs protocol conversion by hardware, while the software protocol stack 29 performs protocol conversion by software or firmware. That is, the software protocol stack 29 is software or firmware and performs protocol conversion between the communication protocol of the real PLC system 100 and the communication protocols of the virtual PLC systems 200X and 200Y.

つぎに、仮想PLCシステム200X,200Yと実PLCシステム100との間のデータ中継処理手順について説明する。以下の図6および図7では、通信ボード31を用いて、実PLCシステム100と仮想PLCシステム200Xとの間でデータ中継が行われる場合について説明する。   Next, a data relay processing procedure between the virtual PLC systems 200X and 200Y and the real PLC system 100 will be described. In FIGS. 6 and 7 below, a case where data communication is performed between the real PLC system 100 and the virtual PLC system 200X using the communication board 31 will be described.

図6は、実施の形態にかかるシミュレーション装置によるPLCシステム間の第1のデータ中継処理手順を示すフローチャートである。図6では、宛先を仮想PLCシステム200Xの仮想PLC50Aとしたデータが、実PLCシステム100から送信されてきた場合のデータ中継処理について説明する。   FIG. 6 is a flowchart showing a first data relay processing procedure between PLC systems by the simulation apparatus according to the embodiment. In FIG. 6, a data relay process in the case where data whose destination is the virtual PLC 50A of the virtual PLC system 200X is transmitted from the real PLC system 100 will be described.

通信ボード31は、実PLCシステム100からネットワーク番号および局番が付与されたデータを受信する(ステップS10)。通信ボード31は、実PLCシステム100からのデータを、仮想PLCシステム200Xで用いられる通信プロトコルにプロトコル変換する(ステップS11)。通信ボード31は、プロトコル変換後のデータをデータ解析部33に送信する。   The communication board 31 receives the data to which the network number and the station number are added from the actual PLC system 100 (step S10). The communication board 31 protocol-converts the data from the real PLC system 100 into a communication protocol used in the virtual PLC system 200X (step S11). The communication board 31 transmits the data after the protocol conversion to the data analysis unit 33.

データ解析部33は、実PLCシステム100からのデータをデータ作成部34に送信する。データ作成部34は、実PLCシステム100からのデータを仮想PLCシステム200X内で処理可能なデータにフォーマット変換してデータ解析部33に送信する。   The data analysis unit 33 transmits the data from the actual PLC system 100 to the data creation unit 34. The data creation unit 34 format-converts the data from the real PLC system 100 into data that can be processed in the virtual PLC system 200X, and sends the data to the data analysis unit 33.

データ解析部33は、実PLCシステム100からのデータに付与されているネットワーク番号に基づいて、実PLCシステム100からのデータを格納する仮想NWUのアドレスを特定する。すなわち、データ解析部33は、ネットワーク番号に対応する仮想NWUのアドレスを特定する。ここでのデータ解析部33は、ネットワーク番号に対応する仮想NWUのアドレスとして仮想NWU60Aのアドレスを特定する。そして、データ解析部33は、ネットワーク番号に対応する仮想NWU60Aに、実PLCシステム100からのデータを送信する(ステップS12)。   The data analysis unit 33 identifies the address of the virtual NWU that stores the data from the real PLC system 100, based on the network number given to the data from the real PLC system 100. That is, the data analysis unit 33 identifies the address of the virtual NWU corresponding to the network number. The data analysis unit 33 here identifies the address of the virtual NWU 60A as the address of the virtual NWU corresponding to the network number. Then, the data analysis unit 33 transmits the data from the real PLC system 100 to the virtual NWU 60A corresponding to the network number (step S12).

この後、データが書き込まれた仮想NWU60Aは、実PLCシステム100からのデータに付与されている局番に対応するユニットにデータを送信する(ステップS13)。具体的には、仮想NWU60Aがデータの宛先となっているユニットを特定する。すなわち、データ解析部33は、局番に対応するユニットのアドレスを特定する。ここでのデータ解析部33は、局番に対応するユニットのアドレスとして仮想PLC50Aのアドレスを特定する。そして、データ解析部33は、局番に対応する仮想PLC50Aに、実PLCシステム100からのデータを送信する。   After that, the virtual NWU 60A to which the data has been written transmits the data to the unit corresponding to the station number given to the data from the real PLC system 100 (step S13). Specifically, the virtual NWU 60A identifies the unit that is the destination of the data. That is, the data analysis unit 33 identifies the address of the unit corresponding to the station number. The data analysis unit 33 here identifies the address of the virtual PLC 50A as the address of the unit corresponding to the station number. Then, the data analysis unit 33 transmits the data from the real PLC system 100 to the virtual PLC 50A corresponding to the station number.

図7は、実施の形態にかかるシミュレーション装置によるPLCシステム間の第2のデータ中継処理手順を示すフローチャートである。図7では、宛先を実PLCシステム100の実PLC10としたデータが、仮想PLCシステム200Xから送信されてきた場合のデータ中継処理について説明する。   FIG. 7 is a flowchart showing a second data relay processing procedure between PLC systems by the simulation apparatus according to the embodiment. In FIG. 7, a data relay process in the case where data whose destination is the real PLC 10 of the real PLC system 100 is transmitted from the virtual PLC system 200X will be described.

データ解析部33は、仮想PLCシステム200Xの仮想NWU60Aから、ネットワーク番号および局番が付与されたデータを受信する(ステップS21)。ここでのネットワーク番号は、実PLCシステム100に対応するものであり、局番は、実PLC10に対応するものである。   The data analysis unit 33 receives the data to which the network number and the station number are added from the virtual NWU 60A of the virtual PLC system 200X (step S21). The network number here corresponds to the real PLC system 100, and the station number corresponds to the real PLC 10.

データ解析部33は、仮想NWU60Aからのデータをデータ作成部34に送信する。データ作成部34は、仮想NWU60Aからのデータを実PLCシステム100内で処理可能なデータにフォーマット変換してデータ解析部33に送信する。   The data analysis unit 33 transmits the data from the virtual NWU 60A to the data creation unit 34. The data creation unit 34 format-converts the data from the virtual NWU 60A into data that can be processed in the actual PLC system 100, and sends the data to the data analysis unit 33.

データ解析部33は、フォーマット変換されたデータを通信ボード31に送信する。通信ボード31は、データ解析部33からのデータを、実PLCシステム100で用いられる通信プロトコルにプロトコル変換する(ステップS22)。   The data analysis unit 33 transmits the format-converted data to the communication board 31. The communication board 31 protocol-converts the data from the data analysis unit 33 into a communication protocol used in the actual PLC system 100 (step S22).

データ解析部33は、仮想PLCシステム200Xからのデータに付与されているネットワーク番号に基づいて、仮想PLCシステム200Xからのデータを格納する実NWUのアドレスを特定する。すなわち、データ解析部33は、ネットワーク番号に対応する実NWUのアドレスを特定する。ここでのデータ解析部33は、ネットワーク番号に対応する実NWUのアドレスとして実NWU20のアドレスを特定する。そして、データ解析部33は、ネットワーク番号に対応する実NWU20に、仮想PLCシステム200Xからのデータを送信する(ステップS23)。これにより、実PLCシステム100の実NWU20が、ネットワーク番号および局番が付与されたデータを受信し、実NWU20が、受信したデータを実PLC10に送信する。   The data analysis unit 33 identifies the address of the real NWU that stores the data from the virtual PLC system 200X, based on the network number given to the data from the virtual PLC system 200X. That is, the data analysis unit 33 identifies the address of the real NWU corresponding to the network number. The data analysis unit 33 here identifies the address of the real NWU 20 as the address of the real NWU corresponding to the network number. Then, the data analysis unit 33 transmits the data from the virtual PLC system 200X to the real NWU 20 corresponding to the network number (step S23). As a result, the real NWU 20 of the real PLC system 100 receives the data to which the network number and the station number are given, and the real NWU 20 transmits the received data to the real PLC 10.

仮想PLCシステム200X,200Yの模擬動作の結果は、表示制御部6が表示装置8に表示させる。これにより、ユーザは、仮想PLCシステム200X,200Yの模擬動作の結果を確認することができる。また、実PLCシステム100の動作結果は、ユーザが実PLCシステム100を見ることによって確認することができる。   The display controller 6 causes the display device 8 to display the result of the simulated operation of the virtual PLC systems 200X and 200Y. Thereby, the user can confirm the result of the simulated operation of the virtual PLC systems 200X and 200Y. Further, the operation result of the real PLC system 100 can be confirmed by the user looking at the real PLC system 100.

FAシステム150が構築される場合、最終的には、シミュレーション装置7によって模擬動作が行われた実PLCシステムが作製され、この実PLCシステムが、実PLCシステム100−1〜100−3に接続される。この場合において、シミュレーション装置7が無ければ、FAシステム150を構成する全ての実PLCシステムが完成するまで、FAシステム150の動作を確認できない。   When the FA system 150 is constructed, finally, a real PLC system simulated by the simulation device 7 is produced, and this real PLC system is connected to the real PLC systems 100-1 to 100-3. It In this case, without the simulation device 7, the operation of the FA system 150 cannot be confirmed until all the actual PLC systems constituting the FA system 150 are completed.

一方、本実施の形態では、シミュレーション装置7を用いて模擬動作を実行しているので、FAシステム150を構成する全ての実PLCシステムが完成する前に、FAシステム150の動作を確認できる。これにより、完成済みの実PLCシステム100−1〜100−3に対しては、残りのPLCシステムが完成するまでの間に仮想PLCシステム200X,200Yとの間で互いにやりとりしながら行われる動作の確認を行うことができる。したがって、未完成の実PLCシステムがあってもFAシステム150の動作確認を開始できるので、最終的なFAシステム150の動作確認を早期に完了させることができる。また、シミュレーション装置7を用いてFAシステム150の動作確認を行うので、低コストでFAシステム150の動作確認を行うことができる。   On the other hand, in the present embodiment, since the simulation operation is executed by using the simulation device 7, the operation of the FA system 150 can be confirmed before all the real PLC systems constituting the FA system 150 are completed. Thus, for the completed real PLC systems 100-1 to 100-3, the operations performed while exchanging with the virtual PLC systems 200X and 200Y until the remaining PLC systems are completed. Confirmation can be done. Therefore, the operation check of the FA system 150 can be started even if there is an incomplete actual PLC system, and thus the final operation check of the FA system 150 can be completed early. Further, since the operation check of the FA system 150 is performed using the simulation device 7, the operation check of the FA system 150 can be performed at low cost.

例えば、実PLCシステム100の一例である装置aが完成しており、実PLCシステム100の一例である装置bが完成していない状態であっても、本実施の形態では、シミュレーション装置7が装置bを模擬動作させることができるので、装置aと装置bとの間の動作確認のテストを行うことができる。これにより、テスト工期を短縮することができる。   For example, even if the device a that is an example of the actual PLC system 100 is completed and the device b that is an example of the actual PLC system 100 is not completed, in the present embodiment, the simulation device 7 is the device. Since b can be simulated, the operation confirmation test between the device a and the device b can be performed. As a result, the test construction period can be shortened.

また、装置aをA県で作製し、装置bをB県で作製しており、装置a,bの据え付けをC県で行う場合に、C県での据え付け前に、装置aがA県にあり、装置bがB県にある状態で、装置aと装置bとの間の動作確認のテストを行うことができる。この場合、A県では、シミュレーション装置7が、装置bの動作を模擬して実際の装置aとの間の動作を確認し、B県では、シミュレーション装置7が、装置aの動作を模擬して実際の装置bとの間の動作を確認する。これにより、テスト工期を短縮することができる。   Further, when the device a is manufactured in A prefecture and the device b is manufactured in B prefecture, and the installation of the devices a and b is performed in C prefecture, the device a is installed in A prefecture before the installation in C prefecture. Yes, the operation confirmation test between the device a and the device b can be performed while the device b is in the B prefecture. In this case, in A prefecture, the simulation device 7 simulates the operation of the device b to confirm the operation with the actual device a, and in B prefecture, the simulation device 7 simulates the operation of the device a. The operation with the actual device b is confirmed. As a result, the test construction period can be shortened.

また、シミュレーション装置7は、実際に発生すると装置a,bが壊れてしまうような異常ケースのテストを行うことができるので、テスト範囲を拡大することができる。   Further, the simulation device 7 can perform a test of an abnormal case in which the devices a and b are broken when the device actually occurs, so that the test range can be expanded.

なお、本実施の形態では、1つのコンピュータであるシミュレーション装置7が、複数の仮想PLCシステムである仮想PLCシステム200X,200Yを構築する場合について説明したが、複数のコンピュータで複数の仮想PLCシステムを構築してもよい。この場合、1つのコンピュータで1つの仮想PLCシステムを構築し、各コンピュータが接続される。接続されたコンピュータ間におけるデータの送受信および同期には、TCP/IPなどが用いられる。   In this embodiment, the case where the simulation device 7 which is one computer constructs the virtual PLC systems 200X and 200Y which are a plurality of virtual PLC systems has been described, but a plurality of virtual PLC systems can be implemented by a plurality of computers. May be built. In this case, one computer constitutes one virtual PLC system, and each computer is connected. TCP/IP or the like is used for data transmission/reception and synchronization between the connected computers.

ここで、シミュレーション装置7のハードウエア構成について説明する。図8は、実施の形態にかかるシミュレーション装置を実現するハードウエア構成を示す図である。シミュレーション装置7は、プロセッサ401、メモリ402、入力装置403、および通信装置404を含むハードウエア400で実現される。   Here, the hardware configuration of the simulation apparatus 7 will be described. FIG. 8 is a diagram showing a hardware configuration for realizing the simulation apparatus according to the embodiment. The simulation device 7 is realized by hardware 400 including a processor 401, a memory 402, an input device 403, and a communication device 404.

入力装置403は、シミュレーション装置7に対して文字を含む各種情報を入力するための装置であり、キーボード、マウス、ポインティングデバイスおよびタッチパネルが例示されるが、これらに限定されるものではない。また、入力装置403は、ユーザによる各種操作を受け付ける場合に使用される。   The input device 403 is a device for inputting various information including characters to the simulation device 7, and is exemplified by a keyboard, a mouse, a pointing device, and a touch panel, but is not limited to these. The input device 403 is used when receiving various operations by the user.

通信装置404は、実PLCシステム群101Xとの間で通信を実行する。通信ボード31は、通信装置404によって実現される。   The communication device 404 executes communication with the actual PLC system group 101X. The communication board 31 is realized by the communication device 404.

シミュレーション部3は、プロセッサ401およびメモリ402により実現される。プロセッサ401は、CPU(Central Processing Unit:中央処理装置)、処理装置、演算装置、マイクロプロセッサ、マイクロコンピュータ、又はDSP(Digital Signal Processor)ともいう。記憶部2は、メモリ402により実現される。メモリ402は、RAM(Random Access Memory)、ROM(Read Only Memory)などを含んでいる。   The simulation unit 3 is realized by the processor 401 and the memory 402. The processor 401 is also called a CPU (Central Processing Unit), a processing device, an arithmetic device, a microprocessor, a microcomputer, or a DSP (Digital Signal Processor). The storage unit 2 is realized by the memory 402. The memory 402 includes a RAM (Random Access Memory), a ROM (Read Only Memory), and the like.

プロセッサ401は、メモリ402に記憶されたプログラムを読み出して実行することにより、シミュレーション部3の機能を実現する。このプログラムは、シミュレーション部3が実行する手順をコンピュータに実行させるものであるともいえる。すなわち、シミュレーション部3の機能は、ソフトウエア、ファームウエア、又はソフトウエアとファームウエアとの組合せにより実現される。ソフトウエア及びファームウエアはプログラムとして記述され、メモリ402に記憶される。   The processor 401 realizes the function of the simulation unit 3 by reading and executing the program stored in the memory 402. It can be said that this program causes a computer to execute the procedure executed by the simulation unit 3. That is, the function of the simulation unit 3 is realized by software, firmware, or a combination of software and firmware. The software and firmware are described as programs and stored in the memory 402.

なお、シミュレーション部3の機能について、一部を専用のハードウエアで実現し、一部をソフトウエアまたはファームウエアで実現するようにしてもよい。また、ソフトウエアプロトコルスタック29も、シミュレーション部3と同様の構成を有したハードウエア400で実現することができる。   The functions of the simulation unit 3 may be partially implemented by dedicated hardware and partially implemented by software or firmware. Further, the software protocol stack 29 can also be realized by the hardware 400 having the same configuration as the simulation unit 3.

このように実施の形態によれば、接続部30Aが、実環境301と仮想環境300との間でプロトコル変換を行うので、実PLCシステム100と仮想PLCシステム200X,200Yとの間でデータを送受信することができる。これにより、実PLC10と仮想PLC50A〜50Cとの間を相互干渉させることができる。したがって、FAシステム150の全体を実環境で構築することなく、実PLC10と仮想PLC50A〜50Cとの間で行われる動作を確認することができる。   As described above, according to the embodiment, since the connection unit 30A performs the protocol conversion between the real environment 301 and the virtual environment 300, data is transmitted and received between the real PLC system 100 and the virtual PLC systems 200X and 200Y. can do. This allows mutual interference between the real PLC 10 and the virtual PLCs 50A to 50C. Therefore, the operation performed between the real PLC 10 and the virtual PLCs 50A to 50C can be confirmed without constructing the entire FA system 150 in the real environment.

また、FAシステム150の全体を実環境で構築することなく、仮想PLCシステム設定データ42X,42Y、および実PLCシステム設定データ41を用いたFAシステム150の動作を確認することができる。また、FAシステム150の全体を実環境で構築することなく、PLCプログラム12,52A,52B,52Cで得られる演算結果を用いてFAシステム150の動作を確認することができる。   Further, the operation of the FA system 150 using the virtual PLC system setting data 42X, 42Y and the actual PLC system setting data 41 can be confirmed without constructing the entire FA system 150 in the actual environment. Further, the operation of the FA system 150 can be confirmed using the calculation results obtained by the PLC programs 12, 52A, 52B, 52C without constructing the entire FA system 150 in an actual environment.

また、データ解析部33が、実PLCシステム群101Xからのデータを、データに付与されているネットワーク番号に基づいて、仮想PLCシステム200X,200Yの何れかに振り分けるので、複数の実PLCシステムと複数の仮想PLCシステムとの間でデータ中継を行うことができる。   In addition, since the data analysis unit 33 distributes the data from the real PLC system group 101X to one of the virtual PLC systems 200X and 200Y based on the network number given to the data, a plurality of real PLC systems and a plurality of real PLC systems are provided. Data can be relayed to and from the virtual PLC system.

以上の実施の形態に示した構成は、本発明の内容の一例を示すものであり、別の公知の技術と組み合わせることも可能であるし、本発明の要旨を逸脱しない範囲で、構成の一部を省略、変更することも可能である。   The configurations described in the above embodiments are examples of the content of the present invention, and can be combined with another known technique, and the configurations of the configurations are not departing from the scope of the present invention. It is also possible to omit or change parts.

1 入力部、2 記憶部、3 シミュレーション部、6 表示制御部、7 シミュレーション装置、8 表示装置、10 実PLC、11,51A,51B,51C PLC設定データ、12,52A,52B,52C PLCプログラム、13,53A,53B,53C プログラム実行部、14,23 時計、15C,22,55A,55B,55C,62A,62C ユニット間交信部、16,56A,56B,56C ツール通信部、20 実NWU、24,64A,64C ネットワーク交信部、25,65A,65C メモリ、29 ソフトウエアプロトコルスタック、30A,30B 接続部、31 通信ボード、32 ブリッジ、33 データ解析部、34 データ作成部、35 記憶部、41 実PLCシステム設定データ、42X,42Y 仮想PLCシステム設定データ、50A,50B,50C 仮想PLC、54A,54B,54C,63A,63C 仮想時計、60A,60C 仮想NWU、61 NWU設定データ、100,100−1,100−2,100−3 実PLCシステム、150 FAシステム、200X,200Y 仮想PLCシステム、300 仮想環境、301 実環境。   1 input unit, 2 storage unit, 3 simulation unit, 6 display control unit, 7 simulation device, 8 display device, 10 real PLC, 11, 51A, 51B, 51C PLC setting data, 12, 52A, 52B, 52C PLC program, 13, 53A, 53B, 53C Program execution part, 14, 23 Clock, 15C, 22, 55A, 55B, 55C, 62A, 62C Inter-unit communication part, 16, 56A, 56B, 56C Tool communication part, 20 real NWU, 24 , 64A, 64C network communication unit, 25, 65A, 65C memory, 29 software protocol stack, 30A, 30B connection unit, 31 communication board, 32 bridge, 33 data analysis unit, 34 data creation unit, 35 storage unit, 41 actual PLC system setting data, 42X, 42Y virtual PLC system setting data, 50A, 50B, 50C virtual PLC, 54A, 54B, 54C, 63A, 63C virtual clock, 60A, 60C virtual NWU, 61 NWU setting data, 100, 100-1 , 100-2, 100-3 real PLC system, 150 FA system, 200X, 200Y virtual PLC system, 300 virtual environment, 301 real environment.

上述した課題を解決し、目的を達成するために、本発明のシミュレーション装置は、プログラマブルロジックコントローラの動作を模擬する仮想プログラマブルロジックコントローラと、他のコントローラシステムとの間で第1の通信プロトコルで通信を行うユニットであるネットワークユニットの動作を模擬する仮想ネットワークユニットと、を含んだ仮想コントローラシステムを構築し、仮想コントローラシステムの模擬動作にかかる演算を行うシミュレーション部を備える。また、本発明のシミュレーション装置は、実機の実プログラマブルロジックコントローラと、他のコントローラシステムとの間で第2の通信プロトコルで通信を行うユニットである実機の実ネットワークユニットと、を含んだ第1の実コントローラシステムに接続し、第1の通信プロトコルと第2の通信プロトコルとの間のプロトコル変換を行うことによって、仮想コントローラシステムと第1の実コントローラシステムとの間でデータ中継を行う通信部を備える。シミュレーション部は、仮想コントローラシステムに対応する第2の実コントローラシステムを動作させる際に用いられるプログラムと同じプログラムに基づき、通信部を介して第1の実コントローラシステムから受信したデータを用いて、仮想コントローラシステムの模擬動作を行う。 In order to solve the above-mentioned problems and achieve the object, the simulation apparatus of the present invention communicates with a virtual programmable logic controller that simulates the operation of a programmable logic controller and another controller system using a first communication protocol. A virtual controller system that includes a virtual network unit that simulates the operation of a network unit that is a unit that performs a virtual controller system is provided, and a simulation unit that performs calculation related to the simulated operation of the virtual controller system is provided. In addition, the simulation device of the present invention includes a first real programmable logic controller, and a first real network unit that is a unit that communicates with another controller system according to the second communication protocol . connected to the real controller system, by performing protocol conversion between the first communication protocol and a second communication protocol, a communication unit for performing data relay between the virtual controller system and the first actual controller system Prepare The simulation unit uses the data received from the first real controller system via the communication unit based on the same program as the program used when operating the second real controller system corresponding to the virtual controller system. Simulates the controller system.

Claims (12)

プログラマブルロジックコントローラの動作を模擬する仮想プログラマブルロジックコントローラと、他のコントローラシステムとの間で通信を行うユニットであるネットワークユニットの動作を模擬する仮想ネットワークユニットと、を含んだ仮想コントローラシステムを構築し、前記仮想コントローラシステムの模擬動作にかかる演算を行うシミュレーション部と、
実機の実プログラマブルロジックコントローラと、他のコントローラシステムとの間で通信を行うユニットである実機の実ネットワークユニットと、を含んだ第1の実コントローラシステムに接続し、前記仮想コントローラシステムと前記第1の実コントローラシステムとの間でデータ中継を行う通信部と、
を備え、
前記シミュレーション部は、前記仮想コントローラシステムに対応する第2の実コントローラシステムを動作させる際に用いられるプログラムと同じプログラムに基づき、前記通信部を介して前記第1の実コントローラシステムから受信したデータを用いて、前記仮想コントローラシステムの模擬動作を行う、
ことを特徴とするシミュレーション装置。
A virtual controller system including a virtual programmable logic controller that simulates the operation of the programmable logic controller and a virtual network unit that simulates the operation of a network unit that is a unit that communicates with other controller systems, A simulation unit that performs a calculation related to a simulated operation of the virtual controller system;
The virtual controller system and the virtual controller system are connected to a first real controller system including a real programmable logic controller of the real machine and a real network unit of the real machine that is a unit that communicates with another controller system. Communication unit that relays data with the real controller system of
Equipped with
The simulation unit, based on the same program used when operating the second real controller system corresponding to the virtual controller system, the data received from the first real controller system via the communication unit. Using, to perform a simulated operation of the virtual controller system,
A simulation device characterized by the above.
前記シミュレーション部による模擬動作の結果を表示制御する表示制御部をさらに備える、
ことを特徴とする請求項1に記載のシミュレーション装置。
Further comprising a display control unit for displaying and controlling the result of the simulation operation by the simulation unit,
The simulation apparatus according to claim 1, wherein:
前記仮想コントローラシステムは、第1の通信プロトコルで通信を実行し、
前記第1の実コントローラシステムは、第2の通信プロトコルで通信を実行し、
前記通信部は、前記第1の通信プロトコルと前記第2の通信プロトコルとの間のプロトコル変換を行うことによって、前記仮想コントローラシステムと前記第1の実コントローラシステムとの間でデータ中継を行う、
ことを特徴とする請求項1または2に記載のシミュレーション装置。
The virtual controller system performs communication with a first communication protocol,
The first actual controller system executes communication with a second communication protocol,
The communication unit performs data conversion between the virtual controller system and the first real controller system by performing protocol conversion between the first communication protocol and the second communication protocol.
The simulation apparatus according to claim 1 or 2, wherein
前記仮想コントローラシステムは複数であり、
前記シミュレーション部は、前記通信部を介して前記第1の実コントローラシステムから受信したデータを用いて、それぞれの前記仮想コントローラシステムの模擬動作を行う、
ことを特徴とする請求項1から3の何れか1つに記載のシミュレーション装置。
The virtual controller system is a plurality,
The simulation unit uses the data received from the first actual controller system via the communication unit to perform a simulated operation of each of the virtual controller systems,
The simulation device according to any one of claims 1 to 3, wherein.
前記第1の実コントローラシステムは複数であり、
前記シミュレーション部は、前記通信部を介して複数の前記第1の実コントローラシステムから受信したデータを用いて、前記仮想コントローラシステムの模擬動作を行う、
ことを特徴とする請求項1から4の何れか1つに記載のシミュレーション装置。
A plurality of the first real controller systems,
The simulation unit performs a simulation operation of the virtual controller system using data received from the plurality of first real controller systems via the communication unit.
The simulation apparatus according to any one of claims 1 to 4, characterized in that
前記実プログラマブルロジックコントローラから送られてくるデータには、前記仮想コントローラシステムを識別する第1の識別情報が含まれ、
前記通信部は、前記第1の識別情報に対応する前記仮想コントローラシステムに、前記実プログラマブルロジックコントローラから送られてきたデータを送信する、
ことを特徴とする請求項4に記載のシミュレーション装置。
The data sent from the real programmable logic controller includes first identification information for identifying the virtual controller system,
The communication unit transmits the data sent from the real programmable logic controller to the virtual controller system corresponding to the first identification information,
The simulation device according to claim 4, wherein
前記実プログラマブルロジックコントローラから送られてくるデータには、前記仮想コントローラシステム内で前記仮想プログラマブルロジックコントローラと前記仮想ネットワークユニットとを識別する第2の識別情報が含まれ、
前記仮想ネットワークユニットは、前記第2の識別情報が前記仮想プログラマブルロジックコントローラに対応するものであれば、前記実プログラマブルロジックコントローラから送られてきたデータを前記仮想プログラマブルロジックコントローラに送信する、
ことを特徴とする請求項1から3の何れか1つに記載のシミュレーション装置。
The data sent from the real programmable logic controller includes second identification information for identifying the virtual programmable logic controller and the virtual network unit in the virtual controller system,
If the second identification information corresponds to the virtual programmable logic controller, the virtual network unit transmits the data sent from the real programmable logic controller to the virtual programmable logic controller,
The simulation device according to any one of claims 1 to 3, wherein
前記通信部は、
前記第1の通信プロトコルと前記第2の通信プロトコルとの間のプロトコル変換を行う通信ボードとを備えている、
ことを特徴とする請求項3に記載のシミュレーション装置。
The communication unit is
A communication board for performing protocol conversion between the first communication protocol and the second communication protocol,
The simulation device according to claim 3, wherein
前記通信部は、
前記第1の通信プロトコルと前記第2の通信プロトコルとの間のプロトコル変換を行うソフトウエアプロトコルスタックとを備えている、
ことを特徴とする請求項3に記載のシミュレーション装置。
The communication unit is
A software protocol stack that performs protocol conversion between the first communication protocol and the second communication protocol,
The simulation device according to claim 3, wherein
前記シミュレーション部は、前記仮想コントローラシステム内の構成要素間の接続関係に基づいて、前記仮想コントローラシステムの模擬動作を行う、
ことを特徴とする請求項1から9の何れか1つに記載のシミュレーション装置。
The simulation unit performs a simulated operation of the virtual controller system based on a connection relationship between components in the virtual controller system,
The simulation device according to claim 1, wherein
前記シミュレーション部は、前記第1の実コントローラシステムに設定されるデータである実システム設定データに基づいて、前記仮想コントローラシステムに設定されるデータである仮想システム設定データを生成する、
ことを特徴とする請求項1から10の何れか1つに記載のシミュレーション装置。
The simulation unit generates virtual system setting data, which is data set in the virtual controller system, based on actual system setting data, which is data set in the first actual controller system,
The simulation device according to any one of claims 1 to 10, characterized in that.
プログラマブルロジックコントローラの動作を模擬する仮想プログラマブルロジックコントローラと、他のコントローラシステムとの間で通信を行うユニットであるネットワークユニットの動作を模擬する仮想ネットワークユニットと、を含んだ仮想コントローラシステムを構築する構築ステップと、
実機の実プログラマブルロジックコントローラと、他のコントローラシステムとの間で通信を行うユニットである実機の実ネットワークユニットと、を含んだ第1の実コントローラシステムに接続した通信部を介して前記仮想コントローラシステムと前記第1の実コントローラシステムとの間でデータ中継を行うとともに、前記仮想コントローラシステムに対応する第2の実コントローラシステムを動作させる際に用いられるプログラムと同じプログラムに基づき、前記通信部を介して前記第1の実コントローラシステムから受信したデータを用いて、前記仮想コントローラシステムの模擬動作にかかる演算を行うシミュレーションステップと、
をコンピュータに実行させる、
ことを特徴とするシミュレーションプログラム。
Construction for constructing a virtual controller system including a virtual programmable logic controller that simulates the operation of a programmable logic controller and a virtual network unit that simulates the operation of a network unit that is a unit that communicates with other controller systems Steps,
The virtual controller system via a communication unit connected to a first real controller system including a real programmable logic controller of the real machine and a real network unit of the real machine that is a unit that communicates with another controller system. And relays data between the first real controller system and the second real controller system corresponding to the virtual controller system based on the same program as that used for operating the second real controller system. And a simulation step of performing a calculation related to a simulated operation of the virtual controller system using the data received from the first actual controller system.
To run on your computer,
A simulation program characterized by that.
JP2018561076A 2018-05-17 2018-05-17 Simulation apparatus and simulation program Active JP6570772B1 (en)

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
PCT/JP2018/019199 WO2019220605A1 (en) 2018-05-17 2018-05-17 Simulation device and simulation program

Publications (2)

Publication Number Publication Date
JP6570772B1 JP6570772B1 (en) 2019-09-04
JPWO2019220605A1 true JPWO2019220605A1 (en) 2020-05-28

Family

ID=67844847

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2018561076A Active JP6570772B1 (en) 2018-05-17 2018-05-17 Simulation apparatus and simulation program

Country Status (4)

Country Link
JP (1) JP6570772B1 (en)
CN (1) CN112119358A (en)
DE (1) DE112018007477T5 (en)
WO (1) WO2019220605A1 (en)

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP7047965B1 (en) * 2021-08-03 2022-04-05 株式会社安川電機 Controller and system construction method
JP7297178B1 (en) 2022-08-01 2023-06-23 三菱電機株式会社 Simulation program, simulation device, simulation system and simulation method

Family Cites Families (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP3362349B2 (en) * 1997-08-29 2003-01-07 オムロン株式会社 Emulation method and emulator device
JP2001209407A (en) * 2000-01-25 2001-08-03 Omron Corp Simulator for executing plc program
JP2004259112A (en) * 2003-02-27 2004-09-16 Omron Corp Evaluation system, evaluation method, and motion controller
JP2009294697A (en) * 2008-06-02 2009-12-17 Nec Electronics Corp Simulation method and simulation program
US9392017B2 (en) * 2010-04-22 2016-07-12 The Trustees Of Columbia University In The City Of New York Methods, systems, and media for inhibiting attacks on embedded devices
DE112014002985B4 (en) * 2014-04-30 2019-04-11 Mitsubishi Electric Corporation Simulation system and programmable controller
CN105406996B (en) * 2015-10-30 2018-10-12 国家电网公司 A kind of method of intelligent substation station level MMS communication emulation

Also Published As

Publication number Publication date
JP6570772B1 (en) 2019-09-04
DE112018007477T5 (en) 2021-01-21
CN112119358A (en) 2020-12-22
WO2019220605A1 (en) 2019-11-21

Similar Documents

Publication Publication Date Title
EP2790101B1 (en) System and method for automated virtual commissioning of an industrial automation system
EP2778816B1 (en) System and method for testing a distributed control system of an industrial plant
US20090013092A1 (en) Method for virtual COM port modbus gateway ethernet I/O
JP6481267B2 (en) Programmable display
JP5240490B2 (en) Operation training system and operation training method
JP6570772B1 (en) Simulation apparatus and simulation program
CN112034732B (en) Semi-physical satellite simulation system and simulation method
US11165745B2 (en) Control system, controller, and control method
US9122502B2 (en) Configurator with embedded firmware for offline instrument user settings implementation
JP5996125B2 (en) System construction support device
JP2010157103A (en) Verification system and operation verification apparatus
JP2008165324A (en) Program creation support device
JP2013122682A (en) Simulation device for monitoring system
JP2009020716A (en) Tool device and method for creating message transmission program
JP3946312B2 (en) PC remote support system and method
JP2010097554A (en) Data simulation system
JP2008519346A (en) Mutual simulation apparatus and method
JP2005251116A (en) Programming tool
WO2020026906A1 (en) Support apparatus, setting method, and setting program
JPH0736516A (en) Simulating device
KR20120082148A (en) Logic simulator of process control system for offshore plnat
JP2003140711A (en) Simulator for process controller and its program and program recording medium
JP2009294697A (en) Simulation method and simulation program
JPH0756495A (en) Virtual controller
JP2009048288A (en) Field equipment development support system

Legal Events

Date Code Title Description
A621 Written request for application examination

Free format text: JAPANESE INTERMEDIATE CODE: A621

Effective date: 20181120

A871 Explanation of circumstances concerning accelerated examination

Free format text: JAPANESE INTERMEDIATE CODE: A871

Effective date: 20181120

A975 Report on accelerated examination

Free format text: JAPANESE INTERMEDIATE CODE: A971005

Effective date: 20190222

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20190305

A521 Request for written amendment filed

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20190426

TRDD Decision of grant or rejection written
A01 Written decision to grant a patent or to grant a registration (utility model)

Free format text: JAPANESE INTERMEDIATE CODE: A01

Effective date: 20190709

A61 First payment of annual fees (during grant procedure)

Free format text: JAPANESE INTERMEDIATE CODE: A61

Effective date: 20190806

R150 Certificate of patent or registration of utility model

Ref document number: 6570772

Country of ref document: JP

Free format text: JAPANESE INTERMEDIATE CODE: R150

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250