JP6739689B1 - Programmable controller - Google Patents

Programmable controller Download PDF

Info

Publication number
JP6739689B1
JP6739689B1 JP2020519811A JP2020519811A JP6739689B1 JP 6739689 B1 JP6739689 B1 JP 6739689B1 JP 2020519811 A JP2020519811 A JP 2020519811A JP 2020519811 A JP2020519811 A JP 2020519811A JP 6739689 B1 JP6739689 B1 JP 6739689B1
Authority
JP
Japan
Prior art keywords
input
output
unit
programmable controller
controller
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.)
Active
Application number
JP2020519811A
Other languages
Japanese (ja)
Other versions
JPWO2021106064A1 (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 JP6739689B1 publication Critical patent/JP6739689B1/en
Publication of JPWO2021106064A1 publication Critical patent/JPWO2021106064A1/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
    • YGENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02PCLIMATE CHANGE MITIGATION TECHNOLOGIES IN THE PRODUCTION OR PROCESSING OF GOODS
    • Y02P90/00Enabling technologies with a potential contribution to greenhouse gas [GHG] emissions mitigation
    • Y02P90/02Total factory control, e.g. smart factories, flexible manufacturing systems [FMS] or integrated manufacturing systems [IMS]

Landscapes

  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Engineering & Computer Science (AREA)
  • Automation & Control Theory (AREA)
  • Programmable Controllers (AREA)

Abstract

プログラマブルコントローラ(1)は、記憶部(20)と、コントローラエミュレータ部(13)と、を備える。記憶部(20)は、模擬対象のプログラマブルコントローラで実行されるファームウェアおよび制御プログラムと、模擬対象のプログラマブルコントローラのハードウェアを模擬するのに必要なハードウェア情報と、を記憶する。コントローラエミュレータ部(13)は、模擬対象のプログラマブルコントローラにおけるハードウェアの動作を、ハードウェア情報に基づいて模擬する。コントローラエミュレータ部(13)は、模擬したハードウェア上で、ファームウェア(211a)および制御プログラム(221a)を実行する。記憶部(20)中のファームウェアおよびハードウェア情報は、模擬対象のプログラマブルコントローラに応じて変更可能である。The programmable controller (1) includes a storage unit (20) and a controller emulator unit (13). The storage unit (20) stores the firmware and the control program executed by the programmable controller to be simulated, and the hardware information necessary to simulate the hardware of the programmable controller to be simulated. The controller emulator unit (13) simulates the operation of hardware in the programmable controller to be simulated based on the hardware information. The controller emulator unit (13) executes the firmware (211a) and the control program (221a) on the simulated hardware. The firmware and hardware information in the storage unit (20) can be changed according to the programmable controller to be simulated.

Description

本発明は、仮想化技術を適用したプログラマブルコントローラに関する。 The present invention relates to a programmable controller to which virtualization technology is applied.

プログラマブルコントローラは、一般に、工場内での装置制御に用いられるコントローラであり、装置製造メーカ等のユーザによって作成された装置制御用の制御プログラムを実行する。プログラマブルコントローラは、故障または新製品への更新のために、置き換えられることがある。しかし、プログラマブルコントローラでは、製品毎にプログラム仕様が統一されていないので、同一メーカの新製品に置き換える場合でも、従来の制御プログラムをそのまま流用することはできない。そのため、置き換え後の製品に対応した制御プログラムの修正が必要となる。 The programmable controller is generally a controller used for device control in a factory and executes a control program for device control created by a user such as a device manufacturer. The programmable controller may be replaced due to a failure or an update to a new product. However, in the programmable controller, since the program specifications are not unified for each product, even when replacing with a new product of the same manufacturer, the conventional control program cannot be used as it is. Therefore, it is necessary to modify the control program corresponding to the replaced product.

特許文献1には、プロセス制御を対象とした制御システム向けに仮想化技術を適用したプロセス制御装置が開示されている。仮想化技術は、既存システム向けのソフトウェアを新しいハードウェア上で実行する技術である。特許文献1に記載のプロセス制御装置は、ハードウェア上に、ハードウェアの代わりとして動作する仮想化部を有する。また、特許文献1に記載のプロセス制御装置では、仮想化部上に、使用中のオペレーティングシステムを動作可能な状態としたまま、入れ替え後のオペレーティングシステムがインストールされる。また、入れ替え後のオペレーティングシステム上に、使用中の制御プログラムと同じ制御プログラムがインストールされる。そして、使用中のオペレーティングシステム上での制御プログラムの動作と、入れ替え後のオペレーティングシステム上での制御プログラムの動作と、を比較して、入れ替え後のオペレーティングシステム上で制御プログラムが正常に動作するかが判定される。正常に動作する場合には、入れ替え後のオペレーティングシステムに切り換えられるが、正常に動作しない場合には、インストールした新たなオペレーティングシステムが停止される。 Patent Document 1 discloses a process control device to which a virtualization technique is applied for a control system intended for process control. Virtualization technology is a technology that executes software for existing systems on new hardware. The process control device described in Patent Document 1 has, on hardware, a virtualization unit that operates in place of the hardware. Further, in the process control device described in Patent Document 1, the replaced operating system is installed on the virtualization unit while keeping the operating system in use in an operable state. Further, the same control program as the control program in use is installed on the replaced operating system. Then, compare the operation of the control program on the operating system in use with the operation of the control program on the operating system after the replacement, and check whether the control program operates normally on the operating system after the replacement. Is determined. If it operates normally, it is switched to the replaced operating system, but if it does not operate normally, the new installed operating system is stopped.

特開2015−5258号公報JP, 2005-5258, A

プログラマブルコントローラの置き換えを考えた場合、置き換え後のプログラマブルコントローラで、置き換え前のプログラマブルコントローラで実行していた制御プログラムを変更しないで実行できることが望ましい。通常、プログラマブルコントローラの場合には、製品によって、ハードウェアアーキテクチャの種類および搭載されているシステムソフトウェアであるファームウェアの種類は多数存在する。そのため、置き換え前と置き換え後との間でプログラマブルコントローラのハードウェアアーキテクチャおよびファームウェアが異なることが多くなる。特許文献1に記載のプロセス制御装置を置き換え後のプログラマブルコントローラに適用した場合には、置き換え前のプログラマブルコントローラ毎に、ハードウェアを模擬する仮想化部の改変が必要となる。特に、模擬対象のプログラマブルコントローラの命令セットアーキテクチャと、仮想化部を実行するコントローラに搭載されるハードウェアの命令セットアーキテクチャと、が異なる場合には、命令セットレベルでのエミュレーションが不可欠となり、様々な種類の仮想化部を用意する必要がある。これに対応するためには、異なるハードウェアを模擬する仮想化部を搭載した複数種類のプログラマブルコントローラを用意する方法が考えられるが、この方法では、製品種別が莫大な数となってしまうという問題があった。 When considering replacement of the programmable controller, it is desirable that the programmable controller after replacement can execute the control program that has been executed by the programmable controller before replacement without changing it. Generally, in the case of a programmable controller, depending on the product, there are many types of hardware architectures and types of installed system software, firmware. Therefore, the hardware architecture and firmware of the programmable controller are often different before and after replacement. When the process control device described in Patent Document 1 is applied to a programmable controller after replacement, it is necessary to modify a virtualization unit that simulates hardware for each programmable controller before replacement. In particular, when the instruction set architecture of the programmable controller to be simulated and the instruction set architecture of the hardware mounted on the controller that executes the virtualization unit are different, emulation at the instruction set level becomes essential and various It is necessary to prepare different types of virtualization units. In order to deal with this, a method of preparing a plurality of types of programmable controllers equipped with a virtualization unit simulating different hardware can be considered, but this method causes a huge number of product types. was there.

本発明は、上記に鑑みてなされたものであって、プログラマブルコントローラを置き換える際に、置き換え前のプログラマブルコントローラのハードウェアおよびファームウェアに依存することなく置き換え前の制御プログラムを変更せずに使用することができるプログラマブルコントローラを得ることを目的とする。 The present invention has been made in view of the above, and when a programmable controller is replaced, the control program before replacement is used without being changed without depending on the hardware and firmware of the programmable controller before replacement. The purpose is to obtain a programmable controller that can

上述した課題を解決し、目的を達成するために、本発明のプログラマブルコントローラは、記憶部と、コントローラエミュレータ部と、入出力端子と、入出力制御部と、入出力タイミング調整部と、を備える。記憶部は、模擬対象のプログラマブルコントローラで実行されるファームウェアおよび制御プログラムと、模擬対象のプログラマブルコントローラのハードウェアを模擬するのに必要なハードウェア情報と、を記憶する。コントローラエミュレータ部は、模擬対象のプログラマブルコントローラにおけるハードウェアの動作を、ハードウェア情報に基づいて模擬する。入出力端子は、入力機器および出力機器と接続される。入出力制御部は、入出力端子への情報の入出力を制御する。入出力タイミング調整部は、コントローラエミュレータ部でファームウェアおよび制御プログラムを実行したときの入出力制御部による仮想的な入出力から入出力端子への実際の入出力のタイミングを調整する。記憶部中のファームウェアおよびハードウェア情報は、模擬対象のプログラマブルコントローラに応じて変更可能である。記憶部は、入出力端子への入出力と、仮想的な入出力と、の間の対応関係を規定した入出力マッピング情報をさらに記憶する。コントローラエミュレータ部は、模擬したハードウェア上で、ファームウェアおよび制御プログラムを実行し、ファームウェアおよび制御プログラムを実行したときの仮想的な入出力を、入出力マッピング情報を参照して、入出力端子への入出力に変換する。コントローラエミュレータ部は、模擬対象のプログラマブルコントローラをファームウェアおよび制御プログラムにしたがって模擬するときに、実際の模擬対象のプログラマブルコントローラが制御プログラムを実行する際の実行時間を見積もり、実行時間に基づいて、実際の模擬対象のプログラマブルコントローラによる入出力の開始時刻を見積もる。入出力タイミング調整部は、開始時刻になるまで、入出力制御部による制御を待機させ、開始時刻になると、入出力制御部による入出力端子への入出力の制御を許可する。
In order to solve the problems described above and achieve the object, a programmable controller of the present invention includes a storage unit, a controller emulator unit, an input/output terminal, an input/output control unit, and an input/output timing adjustment unit. .. The storage unit stores firmware and a control program executed by the programmable controller that is the simulation target, and hardware information that is necessary to simulate the hardware of the programmable controller that is the simulation target. The controller emulator unit simulates the operation of hardware in the programmable controller to be simulated based on the hardware information. The input/output terminal is connected to the input device and the output device. The input/output control unit controls input/output of information to/from the input/output terminal. The input/output timing adjustment unit adjusts the timing of actual input/output from the virtual input/output to the input/output terminal by the input/output control unit when the controller emulator unit executes the firmware and the control program. The firmware and hardware information in the storage unit can be changed according to the programmable controller to be simulated. The storage unit further stores input/output mapping information that defines the correspondence between the input/output to the input/output terminal and the virtual input/output. The controller emulator section executes the firmware and control program on the simulated hardware, and refers to the input/output mapping information to see the virtual input/output when the firmware and control program are executed. Convert to input/output. When simulating the programmable controller to be simulated according to the firmware and the control program, the controller emulator section estimates the execution time when the programmable controller to be simulated actually executes the control program, and based on the execution time, the actual execution time is estimated. Estimate the start time of input/output by the simulated programmable controller. Input and output timing adjustment unit, until the start time, to wait for the control by the output control section, at the start time, you allow control of the input and output of input and output by the output control unit.

本発明にかかるプログラマブルコントローラは、プログラマブルコントローラを置き換える際に、置き換え前のプログラマブルコントローラのハードウェアおよびファームウェアに依存することなく置き換え前の制御プログラムを変更せずに使用することができるという効果を奏する。 INDUSTRIAL APPLICABILITY The programmable controller according to the present invention has an effect that, when the programmable controller is replaced, the control program before replacement can be used without changing, without depending on the hardware and firmware of the programmable controller before replacement.

実施の形態1によるプログラマブルコントローラの構成の一例を模式的に示すブロック図Block diagram schematically showing an example of the configuration of the programmable controller according to the first embodiment 実施の形態1における制御プログラムの実行に関わる各ブロックの関係の一例を模式的に示す図The figure which shows typically an example of the relationship of each block which concerns on execution of the control program in Embodiment 1. コントローラエミュレータ部とメモリ領域との間の関係の一例を示す図The figure which shows an example of the relationship between a controller emulator part and a memory area. 実施の形態1によるプログラマブルコントローラでのエミュレーション処理の手順の一例を示すフローチャート3 is a flowchart showing an example of a procedure of emulation processing in the programmable controller according to the first embodiment. 実施の形態1によるプログラマブルコントローラでの仮想出力をプログラマブルコントローラにおける実出力に変換する方法の一例を示す図The figure which shows an example of the method of converting the virtual output in the programmable controller by Embodiment 1 into the actual output in a programmable controller. 実施の形態2によるプログラマブルコントローラの構成の一例を模式的に示すブロック図The block diagram which shows typically an example of a structure of the programmable controller by Embodiment 2. 実施の形態2による入出力リフレッシュのタイミングの調整の一例を模式的に示すタイムチャートA time chart schematically showing an example of input/output refresh timing adjustment according to the second embodiment 実施の形態2によるプログラマブルコントローラでのエミュレーション処理の手順の一例を示すフローチャート6 is a flowchart showing an example of a procedure of emulation processing in the programmable controller according to the second embodiment. 実施の形態2によるエミュレーションによる仮想出力をプログラマブルコントローラにおける実出力に変換する方法の一例を示す図The figure which shows an example of the method of converting the virtual output by the emulation by Embodiment 2 into the actual output in a programmable controller. 実施の形態3によるプログラマブルコントローラの構成の一例を模式的に示すブロック図The block diagram which shows typically an example of a structure of the programmable controller by Embodiment 3. 実施の形態3によるエミュレーションによる仮想出力をプログラマブルコントローラにおける実出力に変換する方法の一例を示す図The figure which shows an example of the method of converting the virtual output by the emulation by Embodiment 3 into the actual output in a programmable controller. 実施の形態4によるプログラマブルコントローラの構成の一例を模式的に示すブロック図The block diagram which shows typically an example of a structure of the programmable controller by Embodiment 4. 同一演算部上で実行される複数のコントローラエミュレータ部の切り替えタイミングの一例を示す図The figure which shows an example of the switching timing of the several controller emulator parts performed on the same calculation part.

以下に、本発明の実施の形態にかかるプログラマブルコントローラを図面に基づいて詳細に説明する。なお、これらの実施の形態によりこの発明が限定されるものではない。 Below, the programmable controller concerning the embodiment of the present invention is explained in detail based on a drawing. The present invention is not limited to these embodiments.

以下の実施の形態では、プログラマブルコントローラを置き換える際に、置き換え前のプログラマブルコントローラの動作を、置き換え後のプログラマブルコントローラで模擬する場合を例に挙げて説明が行われる。すなわち、置き換え前のプログラマブルコントローラが、実施の形態によるプログラマブルコントローラで置き換えられる。以下では、実施の形態によるプログラマブルコントローラは、単に「プログラマブルコントローラ」と称され、置き換え対象となるプログラマブルコントローラは、「置き換え前のプログラマブルコントローラ」と称される。また、プログラマブルコントローラ上で「置き換え前のプログラマブルコントローラ」の動作が模擬されているときの仮想化された「置き換え前のプログラマブルコントローラ」は、「仮想コントローラ」と称される。また、「置き換え前のプログラマブルコントローラ」は、模擬対象のプログラマブルコントローラの1つである。 In the following embodiments, when the programmable controller is replaced, the operation of the programmable controller before replacement is simulated by the programmable controller after replacement as an example. That is, the programmable controller before replacement is replaced with the programmable controller according to the embodiment. Hereinafter, the programmable controller according to the embodiment is simply referred to as a “programmable controller”, and the programmable controller to be replaced is referred to as a “programmable controller before replacement”. A virtualized "pre-replacement programmable controller" when the operation of the "pre-replacement programmable controller" is simulated on the programmable controller is referred to as a "virtual controller". The "programmable controller before replacement" is one of the simulated programmable controllers.

実施の形態1.
図1は、実施の形態1によるプログラマブルコントローラの構成の一例を模式的に示すブロック図である。プログラマブルコントローラ1は、演算部10と、記憶部20と、通信インタフェース部30と、入出力インタフェース部40と、を備える。演算部10と、記憶部20と、通信インタフェース部30と、入出力インタフェース部40と、は、バス50を介して接続されている。
Embodiment 1.
FIG. 1 is a block diagram schematically showing an example of the configuration of the programmable controller according to the first embodiment. The programmable controller 1 includes a calculation unit 10, a storage unit 20, a communication interface unit 30, and an input/output interface unit 40. The arithmetic unit 10, the storage unit 20, the communication interface unit 30, and the input/output interface unit 40 are connected via a bus 50.

演算部10は、予め定められたハードウェアアーキテクチャに従って構成されたマイクロプロセッサおよびチップセットである。演算部10は、マイクロコンピュータまたはマイコンとも称される。演算部10は、プログラマブルコントローラ1のハードウェア上で、別の種類のプログラマブルコントローラ1のハードウェアについての制御プログラムが実行される実行環境を模擬する機能部である仮想化部11を有する。 The arithmetic unit 10 is a microprocessor and a chip set configured according to a predetermined hardware architecture. The arithmetic unit 10 is also called a microcomputer or a microcomputer. The arithmetic unit 10 has a virtualization unit 11 that is a functional unit that simulates an execution environment in which a control program for another type of hardware of the programmable controller 1 is executed on the hardware of the programmable controller 1.

仮想化部11は、管理部12と、コントローラエミュレータ部13と、マッピング情報生成部15と、メモリマップドI/O(Input/Output)領域14と、を有する。 The virtualization unit 11 includes a management unit 12, a controller emulator unit 13, a mapping information generation unit 15, and a memory mapped I/O (Input/Output) area 14.

管理部12は、演算部10で実行されるソフトウェアの管理を行う機能部である。実施の形態1では、管理部12は、複数のソフトウェアを並列して実行することを可能とするスケジューリング機能を有するオペレーティングシステム(Operating System:OS)である。 The management unit 12 is a functional unit that manages software executed by the calculation unit 10. In the first embodiment, the management unit 12 is an operating system (OS) having a scheduling function that enables a plurality of pieces of software to be executed in parallel.

コントローラエミュレータ部13は、置き換え前のプログラマブルコントローラにおけるハードウェアの動作を模擬する機能部である。また、コントローラエミュレータ部13は、記憶部20から読み出した置き換え前のプログラマブルコントローラで使用されるファームウェアおよび制御プログラムを模擬したハードウェア上で実行する機能部である。コントローラエミュレータ部13が模擬している置き換え前のプログラマブルコントローラが仮想コントローラとなる。コントローラエミュレータ部13は、置き換え前のプログラマブルコントローラに関する後述するハードウェア情報を使用して、命令を実行し、また置き換え前のプログラマブルコントローラにおけるマイコンの周辺機器の動作を模擬して、ファームウェアを実行する。さらに、コントローラエミュレータ部13は、ファームウェア上で、制御プログラムを実行する。 The controller emulator unit 13 is a functional unit that simulates the operation of hardware in the programmable controller before replacement. Further, the controller emulator unit 13 is a functional unit that executes the firmware and the control program used in the pre-replacement programmable controller read from the storage unit 20 on hardware that is simulated. The programmable controller before replacement, which is simulated by the controller emulator unit 13, becomes a virtual controller. The controller emulator unit 13 uses the hardware information to be described later regarding the programmable controller before replacement to execute an instruction, simulates the operation of the peripheral device of the microcomputer in the programmable controller before replacement, and executes the firmware. Further, the controller emulator unit 13 executes the control program on the firmware.

メモリマップドI/O領域14は、コントローラエミュレータ部13によるファームウェアおよび制御プログラムの模擬時に発生するマイコンの周辺機器との間の入出力を仮想化する領域である。メモリマップドI/O領域14は、一例では、置き換え前のプログラマブルコントローラのマイコンが有する入出力制御レジスタを仮想化したものである。メモリマップドI/O領域14には、エミュレーションするメモリ領域としてアドレスが割り当てられている。 The memory-mapped I/O area 14 is an area for virtualizing the input/output with the peripheral device of the microcomputer generated when the controller emulator unit 13 simulates the firmware and the control program. The memory-mapped I/O area 14 is, for example, a virtualization of the input/output control register of the microcomputer of the programmable controller before replacement. An address is assigned to the memory-mapped I/O area 14 as a memory area to be emulated.

マッピング情報生成部15は、プログラマブルコントローラ1の入出力端子の入出力番号と、置き換え前のプログラマブルコントローラの入出力端子の入出力番号と、を対応付けた入出力マッピング情報を生成する機能部である。マッピング情報生成部15は、生成した入出力マッピング情報を記憶部20の入出力マッピング情報記憶部24に保存する。マッピング情報生成部15は、一例では、置き換え前のプログラマブルコントローラにおける入出力番号と、プログラマブルコントローラ1の入出力番号と、が同じになるように入出力マッピング情報を生成する。また、マッピング情報生成部15は、一例では、制御プログラム中の入出力番号を参照して、制御プログラムでの入出力番号、すなわち置き換え前のプログラマブルコントローラにおける入出力番号と、プログラマブルコントローラ1の入出力番号と、を対応付ける。 The mapping information generation unit 15 is a functional unit that generates input/output mapping information in which the input/output numbers of the input/output terminals of the programmable controller 1 are associated with the input/output numbers of the input/output terminals of the programmable controller before replacement. .. The mapping information generation unit 15 stores the generated input/output mapping information in the input/output mapping information storage unit 24 of the storage unit 20. In one example, the mapping information generation unit 15 generates the input/output mapping information such that the input/output number of the programmable controller before replacement and the input/output number of the programmable controller 1 are the same. Further, in one example, the mapping information generation unit 15 refers to the input/output number in the control program, and the input/output number in the control program, that is, the input/output number in the programmable controller before replacement and the input/output in the programmable controller 1. Correspond the numbers and.

記憶部20は、ファームウェア記憶部21と、制御プログラム記憶部22と、ハードウェア情報記憶部23と、入出力マッピング情報記憶部24と、を有する。記憶部20は、記憶されたデータを書き換え可能な記憶装置であり、一例では、ハードディスク装置またはSSD(Solid State Drive)などの不揮発性の記憶装置である。また、記憶部20は、演算部10での処理を実行する際にプログラムをロードしたり、データを一時的に保持したりするRAM(Random Access Memory)などの揮発性の記憶装置を有していてもよい。 The storage unit 20 includes a firmware storage unit 21, a control program storage unit 22, a hardware information storage unit 23, and an input/output mapping information storage unit 24. The storage unit 20 is a storage device capable of rewriting stored data, and is a non-volatile storage device such as a hard disk device or an SSD (Solid State Drive) in one example. Further, the storage unit 20 has a volatile storage device such as a RAM (Random Access Memory) that loads a program and temporarily holds data when the processing in the arithmetic unit 10 is executed. May be.

ファームウェア記憶部21は、置き換え前のプログラマブルコントローラで実行されるファームウェアを記憶する機能部である。なお、置き換え前のプログラマブルコントローラは、模擬対象のプログラマブルコントローラの1つである。なお、ファームウェア記憶部21は、バイナリデータ形式のファームウェアを記憶する。制御プログラム記憶部22は、置き換え前のプログラマブルコントローラで実行される制御プログラムを記憶する機能部である。 The firmware storage unit 21 is a functional unit that stores firmware executed by the programmable controller before replacement. The programmable controller before replacement is one of the programmable controllers to be simulated. The firmware storage unit 21 stores firmware in binary data format. The control program storage unit 22 is a functional unit that stores a control program executed by the programmable controller before replacement.

ハードウェア情報記憶部23は、置き換え前のプログラマブルコントローラのハードウェアを模擬するのに必要なハードウェア情報を記憶する機能部である。ハードウェア情報は、コントローラエミュレータ部13が模擬する置き換え前のプログラマブルコントローラのハードウェアに依存するハードウェア構成情報を有する。ハードウェア構成情報は、メモリマップ、命令模擬処理、レジスタ構成、各レジスタ操作時の模擬処理などを含む。 The hardware information storage unit 23 is a functional unit that stores the hardware information necessary to simulate the hardware of the programmable controller before replacement. The hardware information has hardware configuration information that depends on the hardware of the programmable controller before replacement which is simulated by the controller emulator unit 13. The hardware configuration information includes a memory map, instruction simulation processing, register configuration, simulation processing when each register is operated, and the like.

入出力マッピング情報記憶部24は、入出力マッピング情報を記憶する機能部である。入出力マッピング情報は、プログラマブルコントローラ1の入出力インタフェース部40における入出力端子に付された入出力番号と、仮想コントローラにおける入出力端子に付された入出力番号と、を対応付けた情報である。仮想コントローラにおける入出力端子に付された入出力番号は、置き換え前のプログラマブルコントローラにおける入出力端子に付された入出力番号に対応する。入出力マッピング情報は、コントローラエミュレータ部13がメモリマップドI/O領域14にアクセスした場合に、メモリマップドI/O領域14の入出力番号を実際の入出力インタフェース部40の入出力端子の入出力番号に変換する際に使用される。 The input/output mapping information storage unit 24 is a functional unit that stores the input/output mapping information. The input/output mapping information is information in which the input/output numbers assigned to the input/output terminals in the input/output interface unit 40 of the programmable controller 1 and the input/output numbers assigned to the input/output terminals in the virtual controller are associated with each other. .. The input/output number given to the input/output terminal in the virtual controller corresponds to the input/output number given to the input/output terminal in the programmable controller before replacement. When the controller emulator unit 13 accesses the memory mapped I/O area 14, the input/output mapping information is the input/output number of the memory mapped I/O area 14 of the actual input/output interface section 40. Used when converting to input/output number.

通信インタフェース部30は、プログラマブルコントローラ1の外部機器であるヒューマンインタフェース70に接続される。ヒューマンインタフェース70は、プログラマブルコントローラ1の記憶部20に対してアクセス可能な装置である。ヒューマンインタフェース70は、例えば、パーソナルコンピュータなどの情報処理装置である。ヒューマンインタフェース70は、記憶部20にファームウェア、制御プログラム、ハードウェア情報または入出力マッピング情報を記憶したり、既に記憶部20に記憶されているファームウェア、制御プログラム、ハードウェア情報または入出力マッピング情報を記憶部20から削除したりすることができる。また、ヒューマンインタフェース70は、入出力マッピング情報の自動割付けを行った結果を受け取り、ユーザによる結果の確認を行うことが可能な装置である。さらに、ヒューマンインタフェース70は、入出力マッピング情報の内容を修正することが可能な装置である。例えば、ユーザは、ヒューマンインタフェース70で入出力マッピング情報を見ながら、プログラマブルコントローラ1の入出力端子への配線を行うことができる。また、ユーザは、入出力端子への配線を変更した場合には、ヒューマンインタフェース70で入出力マッピング情報を変更することができる。 The communication interface unit 30 is connected to a human interface 70 that is an external device of the programmable controller 1. The human interface 70 is a device that can access the storage unit 20 of the programmable controller 1. The human interface 70 is, for example, an information processing device such as a personal computer. The human interface 70 stores the firmware, the control program, the hardware information or the input/output mapping information in the storage unit 20, or stores the firmware, the control program, the hardware information or the input/output mapping information already stored in the storage unit 20. It can be deleted from the storage unit 20. The human interface 70 is a device that can receive a result of automatic allocation of input/output mapping information and confirm the result by the user. Further, the human interface 70 is a device capable of modifying the content of the input/output mapping information. For example, the user can perform wiring to the input/output terminal of the programmable controller 1 while viewing the input/output mapping information on the human interface 70. In addition, the user can change the input/output mapping information on the human interface 70 when the wiring to the input/output terminal is changed.

ハードウェア情報とファームウェアとは、置き換え前のプログラマブルコントローラの動作環境を規定するものである。そのため、模擬したい置き換え前のプログラマブルコントローラの動作環境であるハードウェア情報と、ファームウェアと、を、ヒューマンインタフェース70から記憶部20に書き込み、仮想化部11で実行されるようにすることで、置き換え前のプログラマブルコントローラの所望の動作を模擬することが可能となる。 The hardware information and the firmware define the operating environment of the programmable controller before replacement. Therefore, by writing the hardware information, which is the operating environment of the programmable controller to be simulated before the replacement, and the firmware, from the human interface 70 to the storage unit 20 so that the virtualization unit 11 executes the information. The desired operation of the programmable controller can be simulated.

入出力インタフェース部40は、入力端子41と、出力端子42と、入出力制御部43と、を有する。入力端子41は、入力機器と配線を介して接続される。入力機器の一例は、スイッチ、センサまたはロータリエンコーダである。出力端子42は、出力機器と配線を介して接続される。出力機器の一例は、リレー、バルブまたはアクチュエータである。入力端子41には、順番に入力番号「0」から「N」(Nは任意の自然数)までの番号が付される。出力端子42には、順番に出力番号「0」から「N」までの番号が付される。なお、図1では、入力番号「i」は「Input i」(iは0からNまでの自然数)と表記され、出力番号「i」は「Output i」と表記される。また、図1では、入力番号「0」の入力端子41には、スイッチ81が取り付けられ、出力番号「0」の出力端子42には、ランプ91が取り付けられている。この明細書では、入力端子41と出力端子42とは、まとめて入出力端子とも称され、入力機器と出力機器とは、まとめて入出力機器とも称される。 The input/output interface unit 40 has an input terminal 41, an output terminal 42, and an input/output control unit 43. The input terminal 41 is connected to an input device via wiring. An example of the input device is a switch, a sensor or a rotary encoder. The output terminal 42 is connected to the output device via a wire. An example of the output device is a relay, a valve or an actuator. The input terminals 41 are sequentially given input numbers “0” to “N” (N is an arbitrary natural number). The output terminals 42 are sequentially assigned output numbers “0” to “N”. In FIG. 1, the input number “i” is written as “Input i” (i is a natural number from 0 to N), and the output number “i” is written as “Output i”. Further, in FIG. 1, a switch 81 is attached to the input terminal 41 of the input number “0”, and a lamp 91 is attached to the output terminal 42 of the output number “0”. In this specification, the input terminal 41 and the output terminal 42 are collectively referred to as an input/output terminal, and the input device and the output device are collectively referred to as an input/output device.

入出力制御部43は、メモリマップドI/O領域14と、入力端子41および出力端子42を介した入出力機器と、の間のデータの受け渡しを制御する機能部である。具体的には、入出力制御部43は、入力端子41または出力端子42へのアクセスが発生した場合には、コントローラエミュレータ部13と協働して、入出力リフレッシュ処理を実行する。入出力リフレッシュ処理は、算出した出力情報を出力端子42を介して出力機器に設定し、入力端子41を介して入力機器からの入力情報を受け取る処理である。 The input/output control unit 43 is a functional unit that controls data transfer between the memory mapped I/O area 14 and the input/output device via the input terminal 41 and the output terminal 42. Specifically, when the input terminal 41 or the output terminal 42 is accessed, the input/output control unit 43 cooperates with the controller emulator unit 13 to execute the input/output refresh process. The input/output refresh process is a process of setting the calculated output information in the output device via the output terminal 42 and receiving the input information from the input device via the input terminal 41.

図1では、1台の入力機器と1台の出力機器とがプログラマブルコントローラ1に接続される場合が示されているが、プログラマブルコントローラ1に接続される入力機器と出力機器の台数は、限定されない。すなわち、複数台の入力機器または複数台の出力機器がプログラマブルコントローラ1に接続されてもよい。 Although FIG. 1 shows a case where one input device and one output device are connected to the programmable controller 1, the number of input devices and output devices connected to the programmable controller 1 is not limited. .. That is, a plurality of input devices or a plurality of output devices may be connected to the programmable controller 1.

また、置き換え前のプログラマブルコントローラでの入出力端子に対する入出力機器の接続のされ方が、プログラマブルコントローラ1での入出力端子に対する入出力機器の接続のされ方と異なる場合がある。このような場合には、プログラマブルコントローラ1の入出力端子に付された入出力番号と、置き換え前のプログラマブルコントローラの入出力端子に付された入出力番号と、の間の関係を対応付けた入出力マッピング情報が使用される。すなわち、コントローラエミュレータ部13は、入出力マッピング情報を用いて、出力情報の出力先を、メモリマップドI/O領域14中の仮想化された出力先からプログラマブルコントローラ1の実際の出力先に変換する。また、コントローラエミュレータ部13は、メモリマップドI/O領域14中の仮想化された入力元をプログラマブルコントローラ1での実際の入力元に変換し、入力情報を受け取る。 Further, the connection of the input/output device to the input/output terminal of the programmable controller before replacement may be different from the connection of the input/output device to the input/output terminal of the programmable controller 1. In such a case, the input/output number assigned to the input/output terminal of the programmable controller 1 and the input/output number assigned to the input/output terminal of the programmable controller before replacement are associated with each other. Output mapping information is used. That is, the controller emulator unit 13 uses the input/output mapping information to convert the output destination of the output information from the virtualized output destination in the memory mapped I/O area 14 to the actual output destination of the programmable controller 1. To do. Further, the controller emulator unit 13 converts the virtualized input source in the memory mapped I/O area 14 into an actual input source in the programmable controller 1 and receives input information.

図2は、実施の形態1における制御プログラムの実行に関わる各ブロックの関係の一例を模式的に示す図である。ここでは、コントローラエミュレータ部13、ファームウェア211aおよび制御プログラム221aをブロックとして示している。 FIG. 2 is a diagram schematically showing an example of the relationship between the blocks involved in the execution of the control program in the first embodiment. Here, the controller emulator unit 13, the firmware 211a, and the control program 221a are shown as blocks.

ファームウェア211aは、置き換え前のプログラマブルコントローラに搭載されるマイコンで実行可能なバイナリデータ形式のファイルとして提供される。 The firmware 211a is provided as a binary data format file that can be executed by the microcomputer installed in the programmable controller before replacement.

コントローラエミュレータ部13は、ファームウェア211aを示すバイナリファイルをデコードし、ソフトウェアで解釈して実行可能な命令セットシミュレータ(Instruction Set Simulator:ISS)である。また、コントローラエミュレータ部13は、管理部12上の1プロセスとして構成される。なお、ここでは、命令セットアーキテクチャが異なるハードウェア向けのファームウェア211aを実行するために、コントローラエミュレータ部13が具体的にISSであるとして説明しているが、同等機能を持つハードウェア機能によってコントローラエミュレータ部13が代替されてもよい。また、命令セットアーキテクチャが同一であるハードウェア向けのファームウェア211aを実行する場合には、コントローラエミュレータ部13のプロセスで直接ファームウェア211aを実行するように構成してもよい。 The controller emulator unit 13 is an instruction set simulator (ISS) capable of decoding a binary file indicating the firmware 211a, interpreting it with software, and executing the binary file. Further, the controller emulator unit 13 is configured as one process on the management unit 12. Here, the controller emulator unit 13 is specifically described as an ISS in order to execute the firmware 211a for hardware having a different instruction set architecture, but the controller emulator has a hardware function having an equivalent function. The part 13 may be replaced. Further, when executing the firmware 211a for hardware having the same instruction set architecture, the process of the controller emulator unit 13 may directly execute the firmware 211a.

制御プログラム221aは、置き換え前のプログラマブルコントローラが実行可能な形式に変換されたデータとして提供される。制御プログラム221aのデータ形式および実行方式は、プログラマブルコントローラごとに様々である。実行方式として、ファームウェア211aによってインタプリタ方式で実行される方式、制御プログラム221aを直接実行可能な専用ハードウェアを搭載する方式、あるいはこれらの両者を組み合わせた方式が想定される。実施の形態1では、ファームウェア211aが制御プログラム221aを直接解釈して実行するインタプリタ方式のものを対象とする。図2に示されるように、ファームウェア211aがコントローラエミュレータ部13上で実行されることで、制御プログラム221aを実行するためのロジックが実行され、その結果、制御プログラム221aの実行を実現することができる。 The control program 221a is provided as data converted into a format executable by the programmable controller before replacement. The data format and execution method of the control program 221a are different for each programmable controller. As an execution method, a method executed by the firmware 211a in an interpreter method, a method in which dedicated hardware capable of directly executing the control program 221a is installed, or a method in which both of them are combined is assumed. In the first embodiment, an interpreter method in which the firmware 211a directly interprets and executes the control program 221a is targeted. As shown in FIG. 2, by executing the firmware 211a on the controller emulator unit 13, the logic for executing the control program 221a is executed, and as a result, the execution of the control program 221a can be realized. ..

図3は、コントローラエミュレータ部とメモリ領域との間の関係の一例を示す図である。図3には、コントローラエミュレータ部13と、コントローラエミュレータ部13がエミュレーションするメモリ領域310と、コントローラエミュレータ部13のプロセスに割り付けられたメモリ空間350と、が示されている。 FIG. 3 is a diagram showing an example of the relationship between the controller emulator unit and the memory area. FIG. 3 shows the controller emulator unit 13, a memory area 310 emulated by the controller emulator unit 13, and a memory space 350 allocated to the process of the controller emulator unit 13.

メモリ領域310には、仮想コントローラに含まれるROM(Read Only Memory)、RAMおよびメモリマップドI/O領域14にメモリアドレスが割り当てられている。メモリマップドI/O領域14は、置き換え前のプログラマブルコントローラにおけるマイコンの周辺機器のレジスタ領域である。 In the memory area 310, memory addresses are assigned to the ROM (Read Only Memory), RAM, and memory-mapped I/O area 14 included in the virtual controller. The memory-mapped I/O area 14 is a register area of peripheral devices of the microcomputer in the programmable controller before replacement.

コントローラエミュレータ部13のプロセスに割り付けられたメモリ空間350には、プログラマブルコントローラ1向けの実行コードに変換された制御プログラム221aと、バイナリデータ形式のファームウェア211aと、ハードウェア情報231と、入出力マッピング情報241と、が配置されている。 In the memory space 350 allocated to the process of the controller emulator unit 13, the control program 221a converted into the execution code for the programmable controller 1, the firmware 211a in the binary data format, the hardware information 231, and the input/output mapping information. 241 are arranged.

置き換え前のプログラマブルコントローラについてのハードウェア情報231および入出力マッピング情報241と、模擬対象のプログラマブルコントローラで実行される制御プログラム221aおよびファームウェア211aと、は、コントローラエミュレータ部13のプロセスに割り付けられたメモリ空間350に展開される。制御プログラム221aは、メモリ領域310の制御プログラム221がプログラマブルコントローラ1向けの実行コードに変換されたものである。ファームウェア211aは、メモリ領域310のファームウェア211がバイナリデータ形式に変換されたものである。これらの制御プログラム221a、ファームウェア211a、ハードウェア情報231および入出力マッピング情報241は、必要に応じてコントローラエミュレータ部13から参照され、あるいは値の更新が行われる。 The hardware information 231 and the input/output mapping information 241 about the programmable controller before replacement, the control program 221a and the firmware 211a executed by the programmable controller to be simulated are the memory space allocated to the process of the controller emulator unit 13. Expanded to 350. The control program 221a is obtained by converting the control program 221 in the memory area 310 into an execution code for the programmable controller 1. The firmware 211a is obtained by converting the firmware 211 in the memory area 310 into a binary data format. The control program 221a, the firmware 211a, the hardware information 231, and the input/output mapping information 241 are referred to by the controller emulator unit 13 or their values are updated as necessary.

入出力マッピング情報241では、プログラマブルコントローラ1の入力端子41に付された入力番号が仮想コントローラの入力端子の入力番号に割り付けられる。そのため、プログラマブルコントローラ1における入力端子41の入力番号と、割り付けられる仮想コントローラを識別する情報およびこの仮想コントローラにおける入力端子の入力番号と、が対応付けられている。また、入出力マッピング情報241では、プログラマブルコントローラ1の出力端子42に付された出力番号が仮想コントローラに割り付けられる。そのため、プログラマブルコントローラ1における出力端子42の出力番号と、割り付けられる仮想コントローラを識別する情報およびこの仮想コントローラにおける出力端子の出力番号と、が対応付けられている。 In the input/output mapping information 241, the input number assigned to the input terminal 41 of the programmable controller 1 is assigned to the input number of the input terminal of the virtual controller. Therefore, the input number of the input terminal 41 in the programmable controller 1 is associated with the information for identifying the virtual controller to be assigned and the input number of the input terminal in this virtual controller. Further, in the input/output mapping information 241, the output number given to the output terminal 42 of the programmable controller 1 is assigned to the virtual controller. Therefore, the output number of the output terminal 42 in the programmable controller 1 is associated with the information for identifying the virtual controller to be assigned and the output number of the output terminal in this virtual controller.

コントローラエミュレータ部13は、CPU(Central Processing Unit)を含む演算部の動作を模擬するために、仮想プログラムカウンタ131と、仮想汎用レジスタ132と、を有する。仮想プログラムカウンタ131および仮想汎用レジスタ132の実体は、ともにコントローラエミュレータ部13のプロセス上の1データである。仮想汎用レジスタ132は、コントローラエミュレータ部13での演算処理の結果生じる任意のデータを格納する。 The controller emulator unit 13 has a virtual program counter 131 and a virtual general-purpose register 132 in order to simulate the operation of an arithmetic unit including a CPU (Central Processing Unit). The substance of the virtual program counter 131 and the virtual general-purpose register 132 is one piece of data on the process of the controller emulator unit 13. The virtual general-purpose register 132 stores arbitrary data generated as a result of arithmetic processing in the controller emulator unit 13.

仮想プログラムカウンタ131は、コントローラエミュレータ部13が現在実行しているメモリ領域上、すなわちエミュレーションするメモリ領域310上のアドレスを示すためのデータである。コントローラエミュレータ部13は、仮想プログラムカウンタ131に保持されるアドレスのファームウェア211を解釈し、実行する。このファームウェア211の実体は、コントローラエミュレータ部13のプロセスに割り付けられたメモリ空間350上のファームウェア211aである。そのため、コントローラエミュレータ部13は、仮想プログラムカウンタ131に保存されたアドレスを、メモリ空間350のアドレスに変換して、メモリ空間350から実際のバイナリデータ形式のファームウェア211aのデータの読出しを行う。 The virtual program counter 131 is data for indicating an address on the memory area currently executed by the controller emulator unit 13, that is, on the memory area 310 to be emulated. The controller emulator unit 13 interprets and executes the firmware 211 of the address held in the virtual program counter 131. The substance of the firmware 211 is the firmware 211a in the memory space 350 assigned to the process of the controller emulator unit 13. Therefore, the controller emulator unit 13 converts the address stored in the virtual program counter 131 into the address of the memory space 350, and reads the actual data of the firmware 211a in the binary data format from the memory space 350.

バイナリデータ形式のファームウェア211aを命令として解釈し、実行する場合のロジック、およびその解釈した命令を模擬するための処理は、ハードウェア情報231に保存されている。そのため、コントローラエミュレータ部13は、このハードウェア情報231を基に命令の模擬を行う。 The logic for interpreting and executing the binary data format firmware 211a as an instruction and the process for simulating the interpreted instruction are stored in the hardware information 231. Therefore, the controller emulator unit 13 simulates an instruction based on the hardware information 231.

ファームウェア211aの実行によって、エミュレーションするメモリ領域310のメモリマップドI/O領域14へのアクセスが発生した場合には、該当するハードウェア動作をソフトウェア的に模擬するための処理が実行される。マイコンの周辺機器の模擬処理は、ハードウェア情報231に保存されているので、このハードウェア情報231を基にコントローラエミュレータ部13はメモリマップドI/O領域14へのアクセスに関するハードウェア動作を模擬する。該当するハードウェア動作がプログラマブルコントローラ1の入出力を制御するためのものであった場合には、コントローラエミュレータ部13は、さらに入出力マッピング情報241を参照し、入出力マッピング情報241の割付けに従って、実際の入力端子41または出力端子42を介した情報の入出力を行う。例えば、コントローラエミュレータ部13は、アクセスする仮想的な入出力端子の入出力番号を実際の入出力端子の入出力番号に変換して、実際の入力端子41から入力情報を受け取り、あるいは実際の出力端子42へ出力情報を出力する。これは、コントローラエミュレータ部13で演算されたメモリマップドI/O領域14は、置き換え前のプログラマブルコントローラにおけるものであるため、プログラマブルコントローラ1における実際の入出力制御を行うレジスタの入出力番号へと変換が必要になるからである。 When access to the memory-mapped I/O area 14 of the memory area 310 to be emulated occurs due to execution of the firmware 211a, a process for simulating the corresponding hardware operation by software is executed. Since the simulation process of the peripheral device of the microcomputer is stored in the hardware information 231, the controller emulator unit 13 simulates the hardware operation related to the access to the memory mapped I/O area 14 based on this hardware information 231. To do. When the corresponding hardware operation is for controlling the input/output of the programmable controller 1, the controller emulator unit 13 further refers to the input/output mapping information 241, and according to the allocation of the input/output mapping information 241, Information is input and output through the actual input terminal 41 or output terminal 42. For example, the controller emulator unit 13 converts the input/output number of the virtual input/output terminal to be accessed into the input/output number of the actual input/output terminal, receives the input information from the actual input terminal 41, or outputs the actual output. Output information is output to the terminal 42. This is because the memory-mapped I/O area 14 calculated by the controller emulator unit 13 is in the programmable controller before replacement, so that the input/output number of the register that actually controls the input/output in the programmable controller 1 is changed. This is because conversion is necessary.

つぎに、このような構成のプログラマブルコントローラ1における動作について説明する。図4は、実施の形態1によるプログラマブルコントローラでのエミュレーション処理の手順の一例を示すフローチャートである。 Next, the operation of the programmable controller 1 having such a configuration will be described. FIG. 4 is a flowchart showing an example of the procedure of emulation processing in the programmable controller according to the first embodiment.

演算部10によって、コントローラエミュレータ部13が管理部12上のプロセスとして生成されると、コントローラエミュレータ部13は、置き換え前のプログラマブルコントローラについてのハードウェア情報231および入出力マッピング情報241と、置き換え前のプログラマブルコントローラで実行されるファームウェア211aおよび制御プログラム221aを記憶部20から読み出し、メモリ上にロードする(ステップS11)。 When the controller emulator unit 13 is generated as a process on the management unit 12 by the arithmetic unit 10, the controller emulator unit 13 causes the hardware information 231 and the input/output mapping information 241 of the programmable controller before replacement and the replacement information before replacement. The firmware 211a and the control program 221a executed by the programmable controller are read from the storage unit 20 and loaded on the memory (step S11).

次いで、コントローラエミュレータ部13は、仮想プログラムカウンタ131を、ファームウェア211を起動するアドレスであるファームウェア起動アドレスに設定する(ステップS12)。コントローラエミュレータ部13は、初期状態では命令フェッチを行うアドレスをエミュレーションするメモリ領域310上のファームウェア起動アドレスに設定する。 Next, the controller emulator unit 13 sets the virtual program counter 131 to the firmware activation address which is the address for activating the firmware 211 (step S12). In the initial state, the controller emulator unit 13 sets an address for instruction fetch as a firmware activation address on the memory area 310 to be emulated.

その後、コントローラエミュレータ部13は、仮想プログラムカウンタ131に設定されたファームウェア起動アドレスを、メモリにロードしたバイナリデータ形式のファームウェア211aのアドレスに変換し、該当するアドレスの1命令分のファームウェア211aをデコードし、実行する(ステップS13)。この処理は、マイコン命令デコード処理と称される。ここで、マイコンの命令には、通常演算、論理演算、浮動小数点演算、ジャンプ、比較、メモリ転送、NOP(no operation)、特権命令の様々な種別があるが、コントローラエミュレータ部13は、これらの命令を模擬するための処理を実行する。なお、特権命令には、制御レジスタ操作、割込みレベル変更、スーパバイザコール等がある。 After that, the controller emulator unit 13 converts the firmware activation address set in the virtual program counter 131 into the address of the firmware 211a in the binary data format loaded in the memory, and decodes the firmware 211a for one instruction at the corresponding address. , Are executed (step S13). This processing is called microcomputer instruction decoding processing. Here, the instruction of the microcomputer includes various types of normal operation, logical operation, floating point operation, jump, comparison, memory transfer, NOP (no operation), and privileged instruction. Performs processing to simulate an instruction. The privileged instruction includes control register operation, interrupt level change, supervisor call and the like.

例えば置き換え前のプログラマブルコントローラのマイコンが「ADD R1, R2, #100」という命令を持っているものとする。この命令は、「R1レジスタにR2レジスタの値と即値100とを加算した結果を格納する」という処理を実現するものである。仮想化部11のコントローラエミュレータ部13は、この命令に従って同等の処理を実行し、仮想汎用レジスタ132にその結果を格納する。 For example, it is assumed that the microcomputer of the programmable controller before replacement has an instruction "ADD R1, R2, #100". This instruction realizes the processing of "storing the result of adding the value of the R2 register and the immediate value 100 to the R1 register". The controller emulator unit 13 of the virtualization unit 11 executes equivalent processing according to this instruction and stores the result in the virtual general-purpose register 132.

次いで、コントローラエミュレータ部13は、実行対象の命令がメモリにアクセスする命令であるかを判定する(ステップS14)。実行対象の命令がメモリにアクセスする命令ではない場合(ステップS14でNoの場合)には、コントローラエミュレータ部13は、ハードウェア情報231を参照して、実行対象の命令処理を実行する(ステップS15)。この処理は、マイコン命令模擬処理と称される。 Next, the controller emulator unit 13 determines whether the instruction to be executed is a memory access instruction (step S14). If the instruction to be executed is not an instruction to access the memory (No in step S14), the controller emulator unit 13 refers to the hardware information 231 to execute the instruction processing to be executed (step S15). ). This processing is called microcomputer instruction simulation processing.

また、実行対象の命令がメモリにアクセスする命令である場合(ステップS14でYesの場合)には、コントローラエミュレータ部13は、アクセス先のアドレスがメモリマップドI/O領域14であるかを判定する(ステップS16)。アクセス先のアドレスがメモリマップドI/O領域14ではない場合(ステップS16でNoの場合)には、ステップS15のマイコン命令模擬処理が実行される。また、アクセス先のアドレスがメモリマップドI/O領域14である場合(ステップS16でYesの場合)には、コントローラエミュレータ部13は、ハードウェア情報231を参照して、実行対象の命令処理に対応する周辺機器についてのハードウェア模擬処理を実行する(ステップS17)。この処理は、マイコン周辺機器模擬処理と称される。ここでは、コントローラエミュレータ部13は、ハードウェア情報231にしたがってハードウェア動作を模擬する。また、コントローラエミュレータ部13は、アクセス対象がプログラマブルコントローラ1の入出力制御を行うレジスタにアクセスする場合には、入出力マッピング情報241にしたがって、実際の入出力端子を介した入力情報または出力情報の反映を行う。具体的には、コントローラエミュレータ部13は、入出力マッピング情報241を参照し、入出力制御部43を介して入出力マッピング情報241に割り付けられた出力機器への出力情報の出力または入力機器からの入力情報の取り込みを行う。 If the instruction to be executed is an instruction to access the memory (Yes in step S14), the controller emulator unit 13 determines whether the access destination address is the memory-mapped I/O area 14. Yes (step S16). If the access destination address is not the memory mapped I/O area 14 (No in step S16), the microcomputer instruction simulation process in step S15 is executed. If the access destination address is the memory-mapped I/O area 14 (Yes in step S16), the controller emulator unit 13 refers to the hardware information 231 to execute the instruction processing to be executed. Hardware simulation processing is performed for the corresponding peripheral device (step S17). This process is called a microcomputer peripheral device simulation process. Here, the controller emulator unit 13 simulates the hardware operation according to the hardware information 231. In addition, when the access target accesses a register that controls input/output of the programmable controller 1, the controller emulator unit 13 follows the input/output mapping information 241 to input or output the input information via the actual input/output terminal. Reflect. Specifically, the controller emulator unit 13 refers to the input/output mapping information 241, and outputs the output information to the output device assigned to the input/output mapping information 241 via the input/output control unit 43 or outputs from the input device. Import input information.

その後またはステップS15の後、コントローラエミュレータ部13は、仮想プログラムカウンタ131をファームウェア211のつぎの命令に対応するアドレスに設定し(ステップS18)、処理がステップS13に戻る。 After that or after step S15, the controller emulator unit 13 sets the virtual program counter 131 to the address corresponding to the next instruction of the firmware 211 (step S18), and the process returns to step S13.

図5は、実施の形態1によるプログラマブルコントローラでの仮想出力をプログラマブルコントローラにおける実出力に変換する方法の一例を示す図である。ここでは、置き換え前のプログラマブルコントローラにおける出力制御が、出力制御レジスタ341を用いて制御される仕様であるものとする。また、出力制御レジスタ341は、エミュレーションするメモリ領域310のアドレス「0x10001000」にマッピングされているレジスタであり、各ビット「b0」から「b15」が置き換え前のプログラマブルコントローラの各出力番号の出力端子に対応しているものとする。 FIG. 5 is a diagram showing an example of a method of converting a virtual output in the programmable controller according to the first embodiment into an actual output in the programmable controller. Here, it is assumed that the output control in the programmable controller before replacement is a specification controlled by using the output control register 341. The output control register 341 is a register mapped to the address “0x10001000” of the memory area 310 to be emulated, and each bit “b0” to “b15” is an output terminal of each output number of the programmable controller before replacement. Corresponding.

置き換え前のプログラマブルコントローラにおいて、例えば出力番号「1」の出力端子を「ON」にしたい場合には、出力制御レジスタ341の1ビット目を「1」に設定すればよい。 In the programmable controller before replacement, for example, when it is desired to turn on the output terminal of the output number “1”, the first bit of the output control register 341 may be set to “1”.

仮に、コントローラエミュレータ部13上のファームウェアで、すなわち仮想コントローラで、出力番号「1」,「2」の出力端子を「ON」にするための処理が実行された場合には、コントローラエミュレータ部13は、出力制御レジスタ341のハードウェア模擬処理を実行する。すなわち、コントローラエミュレータ部13は、出力制御レジスタ341に対応するメモリマップドI/O領域14中の仮想レジスタ141に仮想出力を行う。このとき、仮想レジスタ141の1ビット目の「X1」および2ビット目の「X2」のビットが「ON」にされる。この出力制御レジスタ341は、プログラマブルコントローラ1の入出力を制御するためのレジスタであるため、入出力マッピング情報241を参照した上で、プログラマブルコントローラ1の実際の入出力制御レジスタ441にハードウェア模擬処理の結果が出力される。つまり、入出力制御部43は、入出力制御レジスタ441の内容に基づいて、入力端子41または出力端子42の「ON」または「OFF」の制御を行う。 If the processing for turning on the output terminals of the output numbers “1” and “2” is executed by the firmware on the controller emulator unit 13, that is, by the virtual controller, the controller emulator unit 13 , Hardware simulation processing of the output control register 341 is executed. That is, the controller emulator unit 13 virtually outputs to the virtual register 141 in the memory mapped I/O area 14 corresponding to the output control register 341. At this time, the first bit “X1” and the second bit “X2” of the virtual register 141 are turned “ON”. Since this output control register 341 is a register for controlling the input/output of the programmable controller 1, the hardware simulation process is performed on the actual input/output control register 441 of the programmable controller 1 after referring to the input/output mapping information 241. The result of is output. That is, the input/output control unit 43 controls “ON” or “OFF” of the input terminal 41 or the output terminal 42 based on the content of the input/output control register 441.

図5の入出力マッピング情報241では、プログラマブルコントローラ1の出力番号「0」,「1」,「2」は、それぞれコントローラエミュレータ部13で模擬される仮想コントローラ上の出力番号「2」,「1」,「0」に対応付けられている。そのため、仮想コントローラ上の出力番号「0」,「1」,「2」の値がそれぞれ「0」,「1」,「1」である場合には、出力端子42の出力番号「0」,「1」,「2」の値はそれぞれ「1」,「1」,「0」に設定される。仮想コントローラ上の出力番号「3」以降の出力端子の値についても同様に、入出力マッピング情報241を参照して、対応付けられたプログラマブルコントローラ1の出力番号の出力端子42に設定される。図5の例では、仮想コントローラ上の出力番号「3」以降の値はすべて「0」である。 In the input/output mapping information 241, the output numbers “0”, “1”, and “2” of the programmable controller 1 are output numbers “2” and “1” on the virtual controller simulated by the controller emulator unit 13, respectively. ," 0". Therefore, when the output numbers “0”, “1” and “2” on the virtual controller are “0”, “1” and “1”, respectively, the output number of the output terminal 42 is “0”, The values of "1" and "2" are set to "1", "1", and "0", respectively. Similarly, the output terminal values after the output number “3” on the virtual controller are set in the output terminal 42 of the output number of the associated programmable controller 1 by referring to the input/output mapping information 241. In the example of FIG. 5, the values after the output number “3” on the virtual controller are all “0”.

実施の形態1では、コントローラエミュレータ部13は、ファームウェア211aの1命令分をデコードしながら実行し、同命令の模擬を行う。また命令のアクセス先がメモリマップドI/O領域14である場合にはハードウェアの模擬も同時に行う。コントローラエミュレータ部13は、1命令分の模擬が完了すると、次の命令を実行しながら模擬を行う処理を継続する。ここで、ファームウェア211aの実行時に参照する各命令の模擬処理およびメモリマップドI/O領域14にアクセスした場合のハードウェアの模擬処理は、ハードウェア情報231に保持されており、かつファームウェア211およびハードウェア情報231は通信インタフェース部30を通じて変更することが可能である。そのため、これらを入れ替えることによって、模擬対象のプログラマブルコントローラを自由に入れ替えることが可能となる。また、ハードウェアの模擬処理でプログラマブルコントローラ1の入出力端子にアクセスする際に参照する入出力マッピング情報241は、ユーザによって手動で変更できるため、コントローラエミュレータ部13上で模擬される仮想コントローラにおける仮想入出力と、プログラマブルコントローラ1の実際の入出力と、の対応付けを自由に変更することが可能となる。 In the first embodiment, the controller emulator unit 13 decodes and executes one instruction of the firmware 211a, and simulates the instruction. When the instruction access destination is the memory-mapped I/O area 14, hardware simulation is also performed at the same time. When the simulation for one instruction is completed, the controller emulator unit 13 continues the processing for performing the simulation while executing the next instruction. Here, the simulation processing of each instruction referred to when executing the firmware 211a and the simulation processing of the hardware when the memory mapped I/O area 14 is accessed are held in the hardware information 231, and the firmware 211 and The hardware information 231 can be changed through the communication interface unit 30. Therefore, by exchanging these, it is possible to freely interchange the programmable controller to be simulated. Further, since the input/output mapping information 241 referred to when accessing the input/output terminals of the programmable controller 1 in the simulation processing of hardware can be manually changed by the user, the virtual virtual controller in the virtual controller simulated on the controller emulator unit 13 can be used. It is possible to freely change the correspondence between the input/output and the actual input/output of the programmable controller 1.

なお、実施の形態1では、置き換え前のプログラマブルコントローラが、制御プログラムをファームウェアが直接解釈して実行する方式として説明したが、制御プログラム実行用の専用ハードウェアを搭載するプログラマブルコントローラを模擬する場合であっても、この専用ハードウェアを模擬するためのハードウェア情報を用意することで同様に制御プログラムの実行を模擬することができる。 In the first embodiment, the programmable controller before replacement is described as a method in which the firmware directly interprets and executes the control program, but in the case of simulating a programmable controller equipped with dedicated hardware for executing the control program. Even if there is, the execution of the control program can be similarly simulated by preparing the hardware information for simulating the dedicated hardware.

また、実施の形態1では、通信インタフェース部30を介して、ファームウェア211、制御プログラム221およびハードウェア情報231が入れ替えられたり、あるいは入出力マッピング情報241の内容が変更されたりした。しかし、プログラマブルコントローラ1が、これらの情報を保存した記憶媒体を取り付けるためのインタフェースを有し、プログラマブルコントローラ1が、このインタフェースを経由して記憶媒体からデータを読み出して模擬動作を行うように構成してもよい。記憶媒体の一例は、SDメモリカード、CD(Compact Disc)−ROM、DVD(Digital Versatile DiscまたはDigital Video Disc)−ROM、BD(Blu-ray(登録商標) Disc)−ROM、コンパクトフラッシュ(登録商標)、フロッピー(登録商標)ディスクなどである。 Further, in the first embodiment, the firmware 211, the control program 221, and the hardware information 231 are exchanged or the contents of the input/output mapping information 241 are changed via the communication interface unit 30. However, the programmable controller 1 has an interface for attaching a storage medium storing these pieces of information, and the programmable controller 1 is configured to read data from the storage medium via this interface and perform a simulated operation. May be. Examples of the storage medium include an SD memory card, a CD (Compact Disc)-ROM, a DVD (Digital Versatile Disc or Digital Video Disc)-ROM, a BD (Blu-ray (registered trademark) Disc)-ROM, and a compact flash (registered trademark). ), a floppy (registered trademark) disk, and the like.

実施の形態2.
図6は、実施の形態2によるプログラマブルコントローラの構成の一例を模式的に示すブロック図である。以下では、実施の形態1と異なる部分について説明する。また、実施の形態1と同一の構成要素には、同一の符号を付して、その説明を省略する。
Embodiment 2.
FIG. 6 is a block diagram schematically showing an example of the configuration of the programmable controller according to the second embodiment. Below, a part different from the first embodiment will be described. Further, the same components as those of the first embodiment are designated by the same reference numerals and the description thereof will be omitted.

実施の形態2では、コントローラエミュレータ部13は、置き換え前のプログラマブルコントローラでファームウェアの命令を実行するのに要する時間を見積もり、置き換え前のプログラマブルコントローラにおける入出力リフレッシュ処理の開始時刻を算出し、その結果を後述する入出力タイミング調整部431に通知する機能をさらに有する。具体的には、コントローラエミュレータ部13は、ファームウェア211aを1命令文デコードし、実行するたびに、置き換え前のプログラマブルコントローラで実際に命令が実行される時間である命令実行時間を見積もる。また、コントローラエミュレータ部13は、前回の入出力リフレッシュ処理が終了したときからの命令実行時間を積算した積算命令実行時間を算出する。そして、コントローラエミュレータ部13は、入出力リフレッシュ用のレジスタへのアクセスがあると、その時点における積算命令実行時間を用いて、置き換え前のプログラマブルコントローラで制御プログラムを実行するスキャン処理が終了する時刻、すなわち実際に入出力リフレッシュ処理が開始される時刻を見積もる。コントローラエミュレータ部13は、見積もった入出力リフレッシュ処理の開始時刻を入出力タイミング調整部431に出力する。 In the second embodiment, the controller emulator unit 13 estimates the time required to execute the firmware instruction in the programmable controller before replacement, calculates the start time of the input/output refresh process in the programmable controller before replacement, and Is further provided to the input/output timing adjustment unit 431 described later. Specifically, the controller emulator unit 13 decodes one instruction sentence of the firmware 211a, and each time it executes the firmware, estimates the instruction execution time, which is the time when the instruction is actually executed by the programmable controller before replacement. Further, the controller emulator unit 13 calculates the integrated instruction execution time by integrating the instruction execution time from the time when the previous input/output refresh process is completed. When the input/output refresh register is accessed, the controller emulator unit 13 uses the integrated instruction execution time at that time to finish the scan process for executing the control program on the programmable controller before replacement, That is, the time when the input/output refresh process is actually started is estimated. The controller emulator unit 13 outputs the estimated start time of the input/output refresh process to the input/output timing adjustment unit 431.

プログラマブルコントローラ1の入出力制御部43は、入出力タイミング調整部431をさらに有する。入出力タイミング調整部431は、プログラマブルコントローラ1における入出力リフレッシュを実施するタイミングを、置き換え前のプログラマブルコントローラにおける入出力リフレッシュを実施するタイミングと同等にする機能を有する。入出力タイミング調整部431は、コントローラエミュレータ部13が見積もった入出力リフレッシュ処理の開始時刻になるまで、入出力制御部43を待機状態にし、入出力リフレッシュ処理の開始時刻になると、入出力制御部43による入出力リフレッシュ処理の実行を可能にする。 The input/output control unit 43 of the programmable controller 1 further includes an input/output timing adjustment unit 431. The input/output timing adjustment unit 431 has a function of making the timing of performing the input/output refresh in the programmable controller 1 equal to the timing of performing the input/output refresh in the programmable controller before replacement. The input/output timing adjustment unit 431 puts the input/output control unit 43 in a standby state until the start time of the input/output refresh process estimated by the controller emulator unit 13, and at the start time of the input/output refresh process, the input/output control unit 431. The input/output refresh process by 43 can be executed.

図7は、実施の形態2による入出力リフレッシュのタイミングの調整の一例を模式的に示すタイムチャートである。図7では、上段に置き換え前のプログラマブルコントローラでの動作が示され、下段にコントローラエミュレータ部13上での動作が示されている。置き換え前のプログラマブルコントローラでの動作に示されるように、一般的に、プログラマブルコントローラは、制御プログラムを実行するスキャン511と、外部の入力機器の入力情報の取り込みまたは外部の出力機器への演算結果である出力情報の出力を行う入出力リフレッシュ521と、を繰り返し実行している。そして、これによって、装置等の制御が実現される。 FIG. 7 is a time chart schematically showing an example of input/output refresh timing adjustment according to the second embodiment. In FIG. 7, the operation in the programmable controller before replacement is shown in the upper part, and the operation in the controller emulator unit 13 is shown in the lower part. As shown in the operation in the programmable controller before the replacement, the programmable controller generally uses the scan 511 that executes the control program and the input result of the external input device or the calculation result to the external output device. The input/output refresh 521 that outputs certain output information is repeatedly executed. Then, the control of the device or the like is realized by this.

ここで、置き換え前のプログラマブルコントローラが旧式で演算速度が遅い場合を考える。このような場合には、置き換え前のプログラマブルコントローラ上でのスキャン511の実行に比して、コントローラエミュレータ部13上でのスキャン512の実行の方が早く終了する。そこで、実施の形態2では、このような場合において、コントローラエミュレータ部13上でのスキャン512の後に、入出力タイミング調整部431は、図7に示されるタイミング調整532の時間を設ける。これによって、置き換え前のプログラマブルコントローラにおける入出力リフレッシュ521と、コントローラエミュレータ部13上での入出力リフレッシュ522と、が、同じ時刻に開始されるように調整される。その結果、制御対象の機器からの入力と、同機器への出力タイミングが実機動作と同等になる。 Here, consider a case where the programmable controller before replacement is an old type and the operation speed is slow. In such a case, the execution of the scan 512 on the controller emulator unit 13 ends earlier than the execution of the scan 511 on the programmable controller before replacement. Therefore, in the second embodiment, in such a case, after the scan 512 on the controller emulator unit 13, the input/output timing adjustment unit 431 provides the time for the timing adjustment 532 shown in FIG. 7. As a result, the input/output refresh 521 in the programmable controller before replacement and the input/output refresh 522 on the controller emulator unit 13 are adjusted to start at the same time. As a result, the input timing from the device to be controlled and the output timing to the device are the same as the actual operation.

図8は、実施の形態2によるプログラマブルコントローラでのエミュレーション処理の手順の一例を示すフローチャートである。なお、以下では、実施の形態1の図4と異なる部分について説明する。 FIG. 8 is a flowchart showing an example of the procedure of emulation processing in the programmable controller according to the second embodiment. In the following, parts different from those of FIG. 4 of the first embodiment will be described.

ステップS11の後に、コントローラエミュレータ部13は、積算命令実行時間を初期化する(ステップS31)。その後、ステップS12に処理が移る。 After step S11, the controller emulator unit 13 initializes the cumulative instruction execution time (step S31). Then, the process proceeds to step S12.

ステップS15の後に、コントローラエミュレータ部13は、エミュレートした命令の置き換え前のプログラマブルコントローラにおける命令実行時間を見積もり、その時点における積算命令実行時間に加算する(ステップS32)。命令実行時間が加算された積算命令実行時間が新たな積算命令実行時間となる。その後、処理がステップS18に移る。 After step S15, the controller emulator unit 13 estimates the instruction execution time in the programmable controller before the replacement of the emulated instruction and adds it to the integrated instruction execution time at that time (step S32). The integrated instruction execution time obtained by adding the instruction execution time becomes a new integrated instruction execution time. After that, the process proceeds to step S18.

ステップS16でアクセス先アドレスがメモリマップドI/O領域14である場合(ステップS16でYesの場合)には、コントローラエミュレータ部13は、アクセス先アドレスが入出力リフレッシュ用のレジスタであるかを判定する(ステップS33)。アクセス先アドレスが入出力リフレッシュ用のレジスタではない場合(ステップS33でNoの場合)には、コントローラエミュレータ部13は、該当するレジスタにハードウェア模擬処理を実行する(ステップS34)。その後、処理がステップS32へと移る。 When the access destination address is the memory mapped I/O area 14 in step S16 (Yes in step S16), the controller emulator unit 13 determines whether the access destination address is a register for input/output refresh. Yes (step S33). When the access destination address is not the register for I/O refresh (No in step S33), the controller emulator unit 13 executes the hardware simulation process on the corresponding register (step S34). Then, the process proceeds to step S32.

また、アクセス先アドレスが入出力リフレッシュ用のレジスタである場合(ステップS33でYesの場合)には、コントローラエミュレータ部13は、その時点の積算命令実行時間を取得し、積算命令実行時間から模擬対象である実機のプログラマブルコントローラにおける入出力リフレッシュ処理の開始時刻を見積もる(ステップS35)。次いで、コントローラエミュレータ部13は、見積もった入出力リフレッシュ処理の開始時刻を入出力タイミング調整部431に出力する(ステップS36)。その後、コントローラエミュレータ部13は、入出力タイミング調整部431から入出力リフレッシュの実行完了の通知を受け取るまで、待機状態となる(ステップS37)。 If the access destination address is a register for I/O refresh (Yes in step S33), the controller emulator unit 13 acquires the cumulative instruction execution time at that time, and simulates it from the cumulative instruction execution time. The start time of the input/output refresh process in the actual programmable controller is estimated (step S35). Next, the controller emulator unit 13 outputs the estimated start time of the input/output refresh process to the input/output timing adjustment unit 431 (step S36). After that, the controller emulator unit 13 is in a standby state until receiving the notification of the completion of execution of the input/output refresh from the input/output timing adjustment unit 431 (step S37).

入出力タイミング調整部431は、入出力リフレッシュ処理の開始時刻を受け取ると、入出力リフレッシュ処理の開始時刻を設定する(ステップS38)。そして、入出力タイミング調整部431は、現在の時刻が入出力リフレッシュ処理の開始時刻になったかを判定し(ステップS39)、現在の時刻が入出力リフレッシュ処理の開始時刻になっていない場合(ステップS39でNoの場合)には、待機状態となる。 Upon receiving the start time of the input/output refresh processing, the input/output timing adjustment unit 431 sets the start time of the input/output refresh processing (step S38). Then, the input/output timing adjustment unit 431 determines whether or not the current time is the start time of the input/output refresh processing (step S39), and if the current time is not the start time of the input/output refresh processing (step S39). In the case of No in S39), the standby state is entered.

また、現在の時刻が入出力リフレッシュ処理の開始時刻になった場合(ステップS39でYesの場合)には、入出力タイミング調整部431は、入出力制御部43による入出力リフレッシュ処理の実行を許可する。すなわち、入出力制御部43は、入力情報の取り込みまたは出力情報の設定を行う入出力リフレッシュ処理を実行する(ステップS40)。その後、入出力タイミング調整部431は、入出力リフレッシュ処理の実行完了をコントローラエミュレータ部13に通知する(ステップS41)。 When the current time is the start time of the input/output refresh processing (Yes in step S39), the input/output timing adjustment unit 431 allows the input/output control unit 43 to execute the input/output refresh processing. To do. That is, the input/output control unit 43 executes an input/output refresh process for fetching input information or setting output information (step S40). After that, the input/output timing adjustment unit 431 notifies the controller emulator unit 13 of the completion of execution of the input/output refresh process (step S41).

コントローラエミュレータ部13は、入出力タイミング調整部431から入出力リフレッシュ処理の実行完了の通知を受けると(ステップS42)、ステップS31に処理が移る。 When the controller emulator section 13 receives the notification of the completion of execution of the input/output refresh processing from the input/output timing adjustment section 431 (step S42), the processing moves to step S31.

なお、ここでは、コントローラエミュレータ部13が、マイコンの命令実行を行う度に実機での同命令の命令実行時間を見積もり、その積算命令実行時間で実機でのスキャン時間を見積もる方式を説明したが、これ以外の時間見積もりの方法を用いてもよい。例えば、制御プログラム221の1命令単位で命令実行時間を見積もり、その積算命令実行時間で実機でのスキャン時間を見積もってもよい。 Here, a method has been described in which the controller emulator unit 13 estimates the instruction execution time of the same instruction in the actual machine every time the instruction of the microcomputer is executed, and estimates the scan time in the actual machine by the accumulated instruction execution time. Other time estimation methods may be used. For example, the instruction execution time may be estimated for each instruction of the control program 221, and the scan time in the actual machine may be estimated by the accumulated instruction execution time.

図9は、実施の形態2によるエミュレーションによる仮想出力をプログラマブルコントローラにおける実出力に変換する方法の一例を示す図である。ここでは、実施の形態1で説明した出力制御レジスタ341に対応する仮想レジスタ141に値を設定し、それを実出力に反映する場合における出力時の動作を説明する。 FIG. 9 is a diagram showing an example of a method for converting a virtual output by emulation according to the second embodiment into an actual output in a programmable controller. Here, an operation at the time of output when a value is set in the virtual register 141 corresponding to the output control register 341 described in the first embodiment and is reflected in the actual output will be described.

コントローラエミュレータ部13が実行するファームウェア211a上で出力制御レジスタ341へのアクセスが発生した場合には、置き換え前のプログラマブルコントローラにおける出力制御レジスタ341への出力と同じように、仮想レジスタ141に仮想出力が出力される。仮想出力は、置き換え前のプログラマブルコントローラにおける入出力機器の接続およびハードウェア構成を前提としたものである。そのため、実際のプログラマブルコントローラ1の入出力端子に対して入出力を行う場合には、プログラマブルコントローラ1における入出力機器の接続およびハードウェア構成に合わせて出力が変換される。すなわち、入出力マッピング情報241を参照して、仮想出力における出力番号が実際の出力番号に変換される。実施の形態2では、このときに、コントローラエミュレータ部13は、積算命令実行時間435を参照して入出力リフレッシュの開始時刻「A」を算出する。つまり、この場合には、実際の出力端子42からの出力情報の出力時刻が算出される。ここで得られた、実際の出力番号と入出力リフレッシュの開始時刻「A」とは、入出力タイミング調整部431に保持される。そして、入出力タイミング調整部431は、開始時刻「A」になると、入出力制御部43に入出力リフレッシュ処理の開始時刻になったことを通知し、入出力制御部43は、各出力情報の出力を行う。 When an access to the output control register 341 occurs on the firmware 211a executed by the controller emulator unit 13, a virtual output is output to the virtual register 141 in the same manner as the output to the output control register 341 in the programmable controller before replacement. Is output. The virtual output is based on the connection and hardware configuration of input/output devices in the programmable controller before replacement. Therefore, when inputting/outputting to/from the actual input/output terminal of the programmable controller 1, the output is converted according to the connection and hardware configuration of the input/output device in the programmable controller 1. That is, referring to the input/output mapping information 241, the output number in the virtual output is converted into the actual output number. In the second embodiment, at this time, the controller emulator unit 13 refers to the integrated instruction execution time 435 to calculate the input/output refresh start time “A”. That is, in this case, the actual output time of the output information from the output terminal 42 is calculated. The actual output number and the input/output refresh start time “A” obtained here are held in the input/output timing adjustment unit 431. Then, when the start time “A” is reached, the input/output timing adjustment unit 431 notifies the input/output control unit 43 that the start time of the input/output refresh processing has been reached, and the input/output control unit 43 notifies the output information of each output information. Output.

実施の形態2では、コントローラエミュレータ部13が、コントローラエミュレータ部13で実行する命令が実際の模擬対象のプログラマブルコントローラで実行されたときに要する命令実行時間を見積もり、さらに積算命令実行時間を見積もる。そして、実行対象の命令のアクセス先アドレスが入出力リフレッシュ用のレジスタである場合に、コントローラエミュレータ部13は、積算命令実行時間を用いて、実際の模擬対象のプログラマブルコントローラにおける入出力リフレッシュ処理の開始時刻を見積もる。入出力タイミング調整部431は、この入出力リフレッシュ処理の開始時刻を用いて、プログラマブルコントローラ1での入出力リフレッシュ処理を行うタイミングを調整する。これによって、プログラマブルコントローラ1における入出力リフレッシュを行うタイミングを、模擬対象の実際のプログラマブルコントローラと同等にすることができるという効果を有する。 In the second embodiment, the controller emulator unit 13 estimates the instruction execution time required when the instruction executed by the controller emulator unit 13 is actually executed by the programmable controller to be simulated, and further estimates the integrated instruction execution time. Then, when the access destination address of the instruction to be executed is the register for input/output refresh, the controller emulator unit 13 uses the accumulated instruction execution time to start the input/output refresh processing in the programmable controller to be actually simulated. Estimate the time. The input/output timing adjustment unit 431 adjusts the timing of performing the input/output refresh processing in the programmable controller 1 using the start time of the input/output refresh processing. Thereby, there is an effect that the timing of performing the input/output refresh in the programmable controller 1 can be made equal to that of the actual programmable controller to be simulated.

実施の形態3.
図10は、実施の形態3によるプログラマブルコントローラの構成の一例を模式的に示すブロック図である。以下では、実施の形態1と異なる部分について説明する。また、実施の形態1と同一の構成要素には、同一の符号を付して、その説明を省略する。
Embodiment 3.
FIG. 10 is a block diagram schematically showing an example of the configuration of the programmable controller according to the third embodiment. Below, a part different from the first embodiment will be described. Further, the same components as those of the first embodiment are designated by the same reference numerals and the description thereof will be omitted.

実施の形態3では、プログラマブルコントローラ1は、複数の演算部10A,10Bを有する。演算部10A,10Bのそれぞれは、実施の形態1で説明したものと同様に、仮想化部11A,11Bを有する。すなわち、プログラマブルコントローラ1には、複数の仮想化部11A,11Bが設けられる。仮想化部11Aは、実施の形態1の演算部10と同様に、管理部12A、コントローラエミュレータ部13A、メモリマップドI/O領域14Aおよびマッピング情報生成部15Aを有する。同様に、仮想化部11Bは、管理部12B、コントローラエミュレータ部13B、メモリマップドI/O領域14Bおよびマッピング情報生成部15Bを有する。これによって、プログラマブルコントローラ1は、複数の置き換え前のプログラマブルコントローラを模擬することができる。すなわち、仮想化部11A上でファームウェア211aが実行され、ファームウェア211a上で制御プログラム221aが実行される。仮想化部11B上でファームウェア212aが実行され、ファームウェア212a上で制御プログラム222aが実行される。なお、図10では、2つの演算部10A,10Bが設けられる場合を示しているが、3以上の演算部が設けられてもよい。 In the third embodiment, the programmable controller 1 has a plurality of arithmetic units 10A and 10B. Each of the arithmetic units 10A and 10B has virtualization units 11A and 11B, similar to those described in the first embodiment. That is, the programmable controller 1 is provided with a plurality of virtualization units 11A and 11B. The virtualization unit 11A has a management unit 12A, a controller emulator unit 13A, a memory-mapped I/O area 14A, and a mapping information generation unit 15A, similar to the arithmetic unit 10 of the first embodiment. Similarly, the virtualization unit 11B includes a management unit 12B, a controller emulator unit 13B, a memory mapped I/O area 14B, and a mapping information generation unit 15B. As a result, the programmable controller 1 can simulate a plurality of programmable controllers before replacement. That is, the firmware 211a is executed on the virtualization unit 11A, and the control program 221a is executed on the firmware 211a. The firmware 212a is executed on the virtualization unit 11B, and the control program 222a is executed on the firmware 212a. Although FIG. 10 shows the case where two arithmetic units 10A and 10B are provided, three or more arithmetic units may be provided.

このような構成によって、ハードウェア情報記憶部23は、仮想化部11A,11Bに設けられるコントローラエミュレータ部13A,13Bの数のハードウェア情報を記憶する。また、ファームウェア記憶部21は、仮想化部11A,11Bに設けられるコントローラエミュレータ部13A,13Bの数のファームウェア211a,212aを記憶し、制御プログラム記憶部22は、仮想化部11A,11Bに設けられるコントローラエミュレータ部13A,13Bの数の制御プログラム221a,222aを記憶する。入出力マッピング情報記憶部24は、複数のコントローラエミュレータ部13で共通の一つの入出力マッピング情報を記憶する。 With such a configuration, the hardware information storage unit 23 stores the hardware information of the number of the controller emulator units 13A and 13B provided in the virtualization units 11A and 11B. Further, the firmware storage unit 21 stores the firmware 211a, 212a as many as the controller emulator units 13A, 13B provided in the virtualization units 11A, 11B, and the control program storage unit 22 is provided in the virtualization units 11A, 11B. The control programs 221a and 222a corresponding to the number of controller emulator units 13A and 13B are stored. The input/output mapping information storage unit 24 stores one input/output mapping information common to the plurality of controller emulator units 13.

図10では、入力番号「60」の入力端子41にスイッチ82がさらに接続され、出力番号「60」の出力端子42にマグネットスイッチ92がさらに接続されている。 In FIG. 10, the switch 82 is further connected to the input terminal 41 of the input number “60”, and the magnet switch 92 is further connected to the output terminal 42 of the output number “60”.

図10に示されるプログラマブルコントローラ1では、演算部10Aで制御プログラム221aが実行され、演算部10Bで制御プログラム222aが実行されており、これらの制御プログラム221a,222aによって、外部の入力機器および出力機器が制御される。 In the programmable controller 1 shown in FIG. 10, the arithmetic unit 10A executes the control program 221a, and the arithmetic unit 10B executes the control program 222a. Is controlled.

図10の例では、入力番号「0」から「59」までの入力端子41と出力番号「0」から「59」までの出力端子42とが制御プログラム221aで制御される。また、入力番号「60」から「139」までの入力端子41と出力番号「60」から「139」までの出力端子42とが制御プログラム222aで制御される。 In the example of FIG. 10, the control program 221a controls the input terminals 41 having the input numbers “0” to “59” and the output terminals 42 having the output numbers “0” to “59”. The control program 222a controls the input terminals 41 with input numbers “60” to “139” and the output terminals 42 with output numbers “60” to “139”.

各コントローラエミュレータ部13A,13Bの動作は、実施の形態1の図4のフローチャートで説明したものと同様であり、それぞれのコントローラエミュレータ部13A,13Bが独立に動作する。ここでは、プログラマブルコントローラ1のハードウェアが複数の演算部10A,10Bを有しており、各演算部10A,10B上で異なるコントローラエミュレータ部13A,13Bが並列に実行される場合が示されている。しかし、プログラマブルコントローラ1のハードウェアが1つの演算部10を有する場合で、時分割で動作を切り替えることによって仮想化部11が複数のコントローラエミュレータ部13A,13Bを有するようにしてもよい。この場合には、時分割で動作を切り替えながら、それぞれのコントローラエミュレータ部13A,13Bでの処理が実行される。 The operation of each controller emulator unit 13A, 13B is similar to that described in the flowchart of FIG. 4 of the first embodiment, and each controller emulator unit 13A, 13B operates independently. Here, a case is shown in which the hardware of the programmable controller 1 has a plurality of arithmetic units 10A and 10B, and different controller emulator units 13A and 13B are executed in parallel on the arithmetic units 10A and 10B. .. However, when the hardware of the programmable controller 1 has one computing unit 10, the virtualization unit 11 may have a plurality of controller emulator units 13A and 13B by switching the operation in a time division manner. In this case, the processing in each of the controller emulator units 13A and 13B is executed while switching the operation in time division.

図11は、実施の形態3によるエミュレーションによる仮想出力をプログラマブルコントローラにおける実出力に変換する方法の一例を示す図である。コントローラエミュレータ部13Aが、入出力インタフェース部40にアクセスする場合、すなわち図4のステップS17での処理のように、入出力制御を行うハードウェアへのアクセスをファームウェアが行った場合には、入出力マッピング情報241を参照し、該当する実際の出力番号の出力端子42への出力を行う。 FIG. 11 is a diagram showing an example of a method for converting a virtual output by emulation according to the third embodiment into an actual output in a programmable controller. When the controller emulator unit 13A accesses the input/output interface unit 40, that is, when the firmware accesses the hardware for controlling the input/output as in the process in step S17 of FIG. With reference to the mapping information 241, the corresponding actual output number is output to the output terminal 42.

なお、図11では、図4とは入出力マッピング情報241の内容が異なっている。実施の形態1では、演算部10は1つの仮想コントローラを模擬していたが、実施の形態3では、演算部10A,10Bが2つの仮想コントローラを模擬している。そのため、入出力マッピング情報241の「仮想コントローラ割り付け」の欄には、演算部10Aで模擬される仮想コントローラAか、演算部10Bで模擬される仮想コントローラBかが入力される。 Note that the contents of the input/output mapping information 241 in FIG. 11 are different from those in FIG. In the first embodiment, the calculation unit 10 simulates one virtual controller, but in the third embodiment, the calculation units 10A and 10B simulate two virtual controllers. Therefore, the virtual controller A simulated by the arithmetic unit 10A or the virtual controller B simulated by the arithmetic unit 10B is input to the “virtual controller allocation” column of the input/output mapping information 241.

ここでは、コントローラエミュレータ部13A上で実行されるファームウェア211aが実際の入出力端子にアクセスした場合を例に挙げて説明する。出力制御レジスタ341は、実施の形態1で説明したものと同様であり、模擬対象の実際のプログラマブルコントローラが有する出力制御レジスタであり、各ビットがプログラマブルコントローラの各出力番号に対応する。 Here, a case where the firmware 211a executed on the controller emulator unit 13A accesses an actual input/output terminal will be described as an example. The output control register 341 is the same as that described in the first embodiment, is an output control register of the actual programmable controller to be simulated, and each bit corresponds to each output number of the programmable controller.

コントローラエミュレータ部13A上で、この出力制御レジスタ341の1ビット目、2ビット目への書込みが行われる場合には、該当するハードウェア模擬処理が実行される。すなわち、コントローラエミュレータ部13Aは、出力制御レジスタ341に対応するメモリマップドI/O領域14の仮想レジスタ141の1ビット目と2ビット目への書き込みを行う。そして、コントローラエミュレータ部13Aは、入出力マッピング情報241を参照して、実際の出力端子42への反映を行う。入出力マッピング情報241では、出力番号「0」から「59」までがコントローラエミュレータ部13Aで模擬される「仮想コントローラA」に割り付けられており、かつプログラマブルコントローラ1の出力番号「0」,「1」,「2」はそれぞれコントローラエミュレータ部13A上の仮想レジスタの出力番号「2」,「1」,「0」に対応付けられている。そのため、コントローラエミュレータ部13Aは、出力端子42の出力番号「0」,「1」,「2」の値をそれぞれ「1」,「1」,「0」に設定し、実際の入出力制御レジスタ441に出力する。なお、コントローラエミュレータ部13Bから実際の入出力端子にアクセスした場合も、同様に、入出力マッピング情報241の割付けに基づいて実際の入出力端子へのアクセスが行われる。 When the first and second bits of the output control register 341 are written on the controller emulator unit 13A, the corresponding hardware simulation process is executed. That is, the controller emulator unit 13A writes to the first bit and the second bit of the virtual register 141 of the memory-mapped I/O area 14 corresponding to the output control register 341. Then, the controller emulator unit 13A refers to the input/output mapping information 241, and reflects the actual output terminal 42. In the input/output mapping information 241, the output numbers “0” to “59” are assigned to the “virtual controller A” simulated by the controller emulator unit 13A, and the output numbers “0” and “1” of the programmable controller 1 are assigned. ," 2" are respectively associated with output numbers "2", "1", "0" of virtual registers on the controller emulator unit 13A. Therefore, the controller emulator unit 13A sets the values of the output numbers “0”, “1”, and “2” of the output terminal 42 to “1”, “1”, and “0”, respectively, and the actual input/output control register Output to 441. Even when the actual input/output terminal is accessed from the controller emulator unit 13B, the actual input/output terminal is similarly accessed based on the allocation of the input/output mapping information 241.

このように共通の入出力マッピング情報241を参照して、複数のコントローラエミュレータ部13A,13Bの入出力動作が模擬される。これによって、入力番号「0」から「59」までの入力端子41と出力番号「0」から「59」までの出力端子42とが制御プログラム221aで制御される。また、入力番号「60」から「139」までの入力端子41と出力番号「60」から「139」までの出力端子42とが制御プログラム222aで制御される動作が実現できる。そして、入出力マッピング情報241を変更することで、複数のコントローラエミュレータ部13A,13B間の実際の入力端子41および出力端子42への割り当て関係を変更することができる。 In this way, referring to the common input/output mapping information 241, the input/output operations of the plurality of controller emulator units 13A and 13B are simulated. As a result, the control program 221a controls the input terminals 41 with the input numbers “0” to “59” and the output terminals 42 with the output numbers “0” to “59”. Further, the operation of controlling the input terminals 41 with the input numbers “60” to “139” and the output terminals 42 with the output numbers “60” to “139” by the control program 222a can be realized. Then, by changing the input/output mapping information 241, it is possible to change the allocation relationship between the plurality of controller emulator units 13A and 13B to the actual input terminals 41 and output terminals 42.

なお、上記の説明では、各コントローラエミュレータ部13A,13Bの入出力が、プログラマブルコントローラ1のいずれかの実際の入力端子41および出力端子42に割り当てられていた。しかし、コントローラエミュレータ部13A,13B間での入出力の接続が必要な場合には、コントローラエミュレータ部13A,13B間の入出力が内部で接続されるように構成されてもよい。この場合、例えば、入出力マッピング情報241においてコントローラエミュレータ部13A,13B間の入出力関係を記述しておき、一方のコントローラエミュレータ部が他のコントローラエミュレータ部に接続された出力にアクセスした場合に、その出力結果をプロセス間通信でもう一方のコントローラエミュレータ部の入力に反映する方法を利用することができる。 In the above description, the input/output of each controller emulator unit 13A, 13B is assigned to any one of the actual input terminal 41 and output terminal 42 of the programmable controller 1. However, if the input/output connection between the controller emulator units 13A and 13B is required, the input/output between the controller emulator units 13A and 13B may be internally connected. In this case, for example, when the input/output mapping information 241 describes the input/output relationship between the controller emulator units 13A and 13B and one controller emulator unit accesses the output connected to another controller emulator unit, It is possible to use a method of reflecting the output result in the input of the other controller emulator unit by interprocess communication.

実施の形態3では、プログラマブルコントローラ1は、複数のコントローラエミュレータ部13A,13Bを有し、それぞれのコントローラエミュレータ部13A,13Bで異なる置き換え前のプログラマブルコントローラの動作を模擬するようにした。これによって、複数の既存の制御プログラム221a,222aを一つのプログラマブルコントローラ1のハードウェア上に統合し、同時に実行することが可能となる。 In the third embodiment, the programmable controller 1 has a plurality of controller emulator units 13A and 13B, and the respective controller emulator units 13A and 13B simulate different operations of the programmable controller before replacement. As a result, a plurality of existing control programs 221a and 222a can be integrated on the hardware of one programmable controller 1 and executed simultaneously.

実施の形態4.
図12は、実施の形態4によるプログラマブルコントローラの構成の一例を模式的に示すブロック図である。以下では、実施の形態1,3と異なる部分について説明する。また、実施の形態1,3と同一の構成要素には、同一の符号を付して、その説明を省略する。
Fourth Embodiment
FIG. 12 is a block diagram schematically showing an example of the configuration of the programmable controller according to the fourth embodiment. Below, parts different from the first and third embodiments will be described. Moreover, the same components as those in the first and third embodiments are designated by the same reference numerals, and the description thereof will be omitted.

実施の形態3の場合と同様に、プログラマブルコントローラ1は、複数のコントローラエミュレータ部13A,13Bを有する。ただし、実施の形態3では、プログラマブルコントローラ1は、物理的に異なる複数の演算部10A,10Bを有し、それぞれの演算部10A,10Bがコントローラエミュレータ部13A,13Bを有する構成であったが、実施の形態4では、プログラマブルコントローラ1は、1つの演算部10を有し、演算部10中の仮想化部11が複数のコントローラエミュレータ部13A,13Bを有する構成である。上記したように、このような場合には、演算部10は、複数のコントローラエミュレータ部13A,13Bを時分割で切り替えながら動作させる。 Similar to the case of the third embodiment, the programmable controller 1 has a plurality of controller emulator units 13A and 13B. However, in the third embodiment, the programmable controller 1 has a plurality of physically different arithmetic units 10A and 10B, and the arithmetic units 10A and 10B have controller emulator units 13A and 13B, respectively. In the fourth embodiment, the programmable controller 1 has one arithmetic unit 10, and the virtualization unit 11 in the arithmetic unit 10 has a plurality of controller emulator units 13A and 13B. As described above, in such a case, the arithmetic unit 10 operates while switching the plurality of controller emulator units 13A and 13B in a time division manner.

図12では、入力番号「0」の入力端子41にロータリエンコーダ83が接続され、入力番号「60」の入力端子41にスイッチ82が接続されている。また、出力番号「0」の出力端子42にランプ91が接続され、出力番号「60」の出力端子42にマグネットスイッチ92が接続されている。 In FIG. 12, the rotary encoder 83 is connected to the input terminal 41 of the input number “0”, and the switch 82 is connected to the input terminal 41 of the input number “60”. The lamp 91 is connected to the output terminal 42 of the output number “0”, and the magnet switch 92 is connected to the output terminal 42 of the output number “60”.

プログラマブルコントローラ1の入出力制御部43は、優先イベント検知部432をさらに有する。優先イベント検知部432は、複数のコントローラエミュレータ部13A,13Bで模擬動作処理中に、優先的に処理すべき割込みプログラムに対応付けられたイベントの発生を検知し、イベントが発生したことを示すイベント通知を演算部10に通知する機能を有する。以下では、優先的に処理すべき割込みプログラムに対応付けられたイベントは、優先イベントと称される。 The input/output control unit 43 of the programmable controller 1 further includes a priority event detection unit 432. The priority event detection unit 432 detects the occurrence of an event associated with the interrupt program to be preferentially processed during the simulated operation processing by the plurality of controller emulator units 13A and 13B, and indicates that the event has occurred. It has a function of notifying the arithmetic unit 10 of the notification. Hereinafter, the event associated with the interrupt program to be preferentially processed is referred to as a priority event.

演算部10の管理部12は、切替部121をさらに有する。切替部121は、優先イベント検知部432からイベント通知が通知されると、優先イベントの発生によって割込みプログラムを実行するコントローラエミュレータ部とは別のコントローラエミュレータ部が動作していても、割込みプログラムを実行するコントローラエミュレータ部に処理を切替える機能部である。 The management unit 12 of the arithmetic unit 10 further includes a switching unit 121. When the priority event detection unit 432 notifies the switching unit 121 of the event notification, the switching unit 121 executes the interrupt program even if a controller emulator unit different from the controller emulator unit that executes the interrupt program due to the occurrence of the priority event is operating. It is a functional unit that switches processing to the controller emulator unit.

プログラマブルコントローラ1は、一般的に、特定のイベントを契機に高速に動作する割込みプログラムの実行機能を有する。イベントは、入力信号の立上りまたは立下り、パルスカウンタの値の変動、内部タイマのカウントアップなどである。これらのイベントをトリガとして動作する割込みプログラムは、実行中の制御プログラムより高優先度で動作し、高速な応答性が求められる。 The programmable controller 1 generally has a function of executing an interrupt program that operates at high speed when a specific event occurs. The event is a rise or fall of the input signal, a change in the value of the pulse counter, a count-up of the internal timer, or the like. The interrupt program that operates using these events as a trigger operates at a higher priority than the control program that is being executed, and high-speed responsiveness is required.

2つのコントローラエミュレータ部13A,13Bが、同一の演算部10上で実行されている場合で、コントローラエミュレータ部13Aが実行中にコントローラエミュレータ部13Bが処理すべき優先イベントが発生する場合がある。この場合には、コントローラエミュレータ部13Aに割り当てられた時間が経過するまで、コントローラエミュレータ部13Bは優先イベントに対応する割込み処理を実行できないため、割込みプログラムの応答性が悪化してしまう。 When the two controller emulator units 13A and 13B are executed on the same arithmetic unit 10, a priority event to be processed by the controller emulator unit 13B may occur while the controller emulator unit 13A is executing. In this case, the controller emulator unit 13B cannot execute the interrupt processing corresponding to the priority event until the time allotted to the controller emulator unit 13A elapses, so that the responsiveness of the interrupt program deteriorates.

そこで、実施の形態4では、優先イベント発生時の応答性能を高めるために、入出力制御部43に優先イベント検知部432が設けられ、管理部12に切替部121が設けられる。 Therefore, in the fourth embodiment, in order to improve the response performance when a priority event occurs, the input/output control unit 43 is provided with the priority event detection unit 432, and the management unit 12 is provided with the switching unit 121.

ここで、割り込みが発生する例について説明する。ロータリエンコーダ83のパルスカウントが予め定められた設定値に達した場合に、コントローラエミュレータ部13Bが割込みプログラムを実行するものとして説明する。 Here, an example in which an interrupt occurs will be described. It is assumed that the controller emulator unit 13B executes the interrupt program when the pulse count of the rotary encoder 83 reaches a predetermined set value.

優先イベント検知部432には、優先イベントとして通知が必要な条件が設定される。優先イベントは、イベントが発生すると、優先的に割り込みプログラムを実行させなければならないイベントである。ここでは、「入力番号「0」の入力端子41に対するパルス数が予め定められた設定値となった場合」が条件に設定される。コントローラエミュレータ部13A,13B上で模擬されるファームウェア211a,212aがどのようにしてこの設定を行うかは、コントローラエミュレータ部13A,13Bの模擬対象となるプログラマブルコントローラのハードウェア仕様によって異なる。ここでは、パルスカウントを行う専用ハードウェアを搭載したプログラマブルコントローラを、コントローラエミュレータ部13Aが模擬するものと想定して説明する。専用ハードウェアを搭載しているプログラマブルコントローラ向けのファームウェアは、この専用ハードウェアのレジスタへアクセスする。このレジスタへのアクセスによって、コントローラエミュレータ部13Aによるハードウェア模擬処理が実行される。ハードウェア模擬処理において優先イベント検知部432に対してパルス監視が必要な入力番号「0」と、イベント条件となるパルス数と、が設定される。 In the priority event detection unit 432, conditions that require notification as a priority event are set. The priority event is an event for which the interrupt program must be executed preferentially when the event occurs. Here, “when the number of pulses to the input terminal 41 of the input number “0” becomes a predetermined set value” is set as the condition. How the firmware 211a, 212a simulated on the controller emulator sections 13A, 13B makes this setting depends on the hardware specifications of the programmable controller to be simulated by the controller emulator sections 13A, 13B. Here, it is assumed that the controller emulator unit 13A simulates a programmable controller equipped with dedicated hardware for pulse counting. The firmware for the programmable controller equipped with the dedicated hardware accesses the register of this dedicated hardware. By accessing this register, a hardware simulation process is executed by the controller emulator unit 13A. In the hardware simulation process, the input number “0” for which pulse monitoring is required for the priority event detection unit 432 and the number of pulses that are the event condition are set.

設定された優先イベントの条件が成立した場合には、優先イベント検知部432は、切替部121へイベント発生を通知する。切替部121は、優先イベントを処理すべきコントローラエミュレータ部13B上の仮想汎用レジスタ132に記憶されたハードウェアレジスタ情報をイベント発生時の状態とするとともに、優先イベントを処理すべきコントローラエミュレータ部13Bが実行されていなければ、演算部10上で実行されるコントローラエミュレータ部13A,13Bの切り替えを行う。 When the condition of the set priority event is satisfied, the priority event detection unit 432 notifies the switching unit 121 of the event occurrence. The switching unit 121 sets the hardware register information stored in the virtual general-purpose register 132 on the controller emulator unit 13B that should process the priority event to the state when the event occurred, and the controller emulator unit 13B that should process the priority event If not executed, the controller emulator units 13A and 13B executed on the arithmetic unit 10 are switched.

図13は、同一演算部上で実行される複数のコントローラエミュレータ部の切り替えタイミングの一例を示す図である。この図で、上段はコントローラエミュレータ部13Aの動作の状態を示し、下段は、コントローラエミュレータ部13Bの動作の状態を示す。また、横軸は、時間である。 FIG. 13 is a diagram showing an example of switching timings of a plurality of controller emulator units executed on the same arithmetic unit. In this figure, the upper part shows the operating state of the controller emulator unit 13A, and the lower part shows the operating state of the controller emulator unit 13B. The horizontal axis is time.

優先イベントが発生していない場合には、コントローラエミュレータ部13A,13Bは、特定の実行周期に基づいて時分割で切り替えられながら、処理を実行する。図13では、まず、実行周期551でコントローラエミュレータ部13Aが処理を実行し、その後の実行周期552でコントローラエミュレータ部13Bが処理を実行する。次の実行周期553では、コントローラエミュレータ部13Aが処理を実行するが、この実行周期553中の時刻t1に、優先イベント560が発生したものとする。ここでは、優先イベント560は、ロータリエンコーダ83によるパルスカウンタ数が設定値に達することである。優先イベント検知部432は、優先イベント560の発生を検知し、優先イベントの発生を示すイベント通知を切替部121に通知する。切替部121は、イベント通知を受けると、コントローラエミュレータ部13Aが動作している実行周期553の途中であっても、コントローラエミュレータ部13Aからコントローラエミュレータ部13Bへと処理を切り替え、コントローラエミュレータ部13Bが動作可能な状態とする。その後、コントローラエミュレータ部13Bは、優先イベントに対応する割込みプログラムを実行する。 When no priority event has occurred, the controller emulator units 13A and 13B execute processing while being switched in time division based on a specific execution cycle. In FIG. 13, first, the controller emulator unit 13A executes processing in the execution cycle 551, and the controller emulator unit 13B executes processing in the subsequent execution cycle 552. In the next execution cycle 553, the controller emulator unit 13A executes processing, but it is assumed that the priority event 560 occurs at time t1 in this execution cycle 553. Here, the priority event 560 is that the number of pulse counters by the rotary encoder 83 reaches the set value. The priority event detection unit 432 detects the occurrence of the priority event 560 and notifies the switching unit 121 of an event notification indicating the occurrence of the priority event. Upon receiving the event notification, the switching unit 121 switches the processing from the controller emulator unit 13A to the controller emulator unit 13B even during the execution cycle 553 in which the controller emulator unit 13A is operating. Ready for operation. After that, the controller emulator unit 13B executes the interrupt program corresponding to the priority event.

ここで、割込みプログラムを実行する時間である割込みプログラム実行用割り当て時間570は、特定のアルゴリズムに基づいて算出される。あるいは、割込みプログラム実行用割り当て時間570は、ファームウェア212aそのものを変更して、割込みプログラム完了時にフック処理を追加し、これにより割込みプログラムの実行完了を検出すようにしてもよい。フック処理を追加する方式の場合には、割込みプログラムの実行完了時刻を予想する必要がないため、割込みプログラム実行用割り当て時間570の計算は不要である。割込みプログラム実行用割り当て時間570が経過すると、切替部121は、コントローラエミュレータ部13Aへと処理を切替える。そして、実行周期554で、ハードウェアレジスタ情報が優先イベント560の発生時の状態に戻され、コントローラエミュレータ部13Aが処理を行う。 Here, the interrupt program execution allocation time 570, which is the time for executing the interrupt program, is calculated based on a specific algorithm. Alternatively, in the interrupt program execution allocation time 570, the firmware 212a itself may be changed to add a hook process when the interrupt program is completed, thereby detecting completion of execution of the interrupt program. In the case of the method of adding the hook process, it is not necessary to predict the execution completion time of the interrupt program, and therefore the calculation of the allocation time 570 for interrupt program execution is unnecessary. When the interrupt program execution allocation time 570 elapses, the switching unit 121 switches the processing to the controller emulator unit 13A. Then, in the execution cycle 554, the hardware register information is returned to the state at the time of occurrence of the priority event 560, and the controller emulator unit 13A performs processing.

なお、上記した説明では、優先イベント検知部432はパルスカウントの機能を有する機能ブロックであるものとして説明したが、実施の形態がこれに限定されるものではない。例えば、優先イベント検知部432は、入力信号の立上りまたは立下りなどの他のイベント検出機能を複数有するように構成されてもよい。 In the above description, the priority event detection unit 432 is described as a functional block having a pulse counting function, but the embodiment is not limited to this. For example, the priority event detection unit 432 may be configured to have a plurality of other event detection functions such as rising and falling of the input signal.

実施の形態4では、プログラマブルコントローラ1は、優先イベントを検知する優先イベント検知部432と、優先イベントが検知された場合に割込み処理を行うべきコントローラエミュレータ部13A,13Bに処理を切り替える切替部121と、を備える。これによって、優先イベント発生時に割込みプログラムを実行するコントローラエミュレータ部13A,13Bへと強制的に切り替えられ、同一の演算部10上で複数のコントローラエミュレータ部13A,13Bを実行する場合において、優先イベントに対する応答性を高めることができる。 In the fourth embodiment, the programmable controller 1 includes a priority event detection unit 432 that detects a priority event, a switching unit 121 that switches processing to the controller emulator units 13A and 13B that should perform interrupt processing when a priority event is detected. , Is provided. As a result, when the priority event occurs, the controller emulator units 13A and 13B that execute the interrupt program are forcibly switched to each other, and when a plurality of controller emulator units 13A and 13B are executed on the same computing unit 10, the priority event The responsiveness can be enhanced.

また、上記した実施の形態2を実施の形態3,4と組み合わせてもよい。これによって、プログラマブルコントローラ1における入出力リフレッシュを行うタイミングを、模擬対象の実際のプログラマブルコントローラと同等にすることができる。 Further, the second embodiment described above may be combined with the third and fourth embodiments. As a result, the timing of performing the input/output refresh in the programmable controller 1 can be made equal to that of the actual programmable controller to be simulated.

以上の実施の形態に示した構成は、本発明の内容の一例を示すものであり、別の公知の技術と組み合わせることも可能であるし、本発明の要旨を逸脱しない範囲で、構成の一部を省略、変更することも可能である。 The configurations described in the above embodiments are examples of the content of the present invention, and can be combined with other known techniques, 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 プログラマブルコントローラ、10,10A,10B 演算部、11,11A,11B 仮想化部、12,12A,12B 管理部、13,13A,13B コントローラエミュレータ部、14,14A,14B メモリマップドI/O領域、15,15A,15B マッピング情報生成部、20 記憶部、21 ファームウェア記憶部、22 制御プログラム記憶部、23 ハードウェア情報記憶部、24 入出力マッピング情報記憶部、30 通信インタフェース部、40 入出力インタフェース部、41 入力端子、42 出力端子、43 入出力制御部、50 バス、70 ヒューマンインタフェース、81,82 スイッチ、83 ロータリエンコーダ、91 ランプ、92 マグネットスイッチ、121 切替部、131 仮想プログラムカウンタ、132 仮想汎用レジスタ、211,211a,212a ファームウェア、221,221a,222a 制御プログラム、231 ハードウェア情報、241 入出力マッピング情報、431 入出力タイミング調整部、432 優先イベント検知部。 1 programmable controller, 10, 10A, 10B arithmetic unit, 11, 11A, 11B virtualization unit, 12, 12A, 12B management unit, 13, 13A, 13B controller emulator unit, 14, 14A, 14B memory mapped I/O area , 15, 15A, 15B mapping information generation unit, 20 storage unit, 21 firmware storage unit, 22 control program storage unit, 23 hardware information storage unit, 24 input/output mapping information storage unit, 30 communication interface unit, 40 input/output interface Section, 41 input terminal, 42 output terminal, 43 input/output control section, 50 bus, 70 human interface, 81, 82 switch, 83 rotary encoder, 91 lamp, 92 magnet switch, 121 switching section, 131 virtual program counter, 132 virtual General-purpose registers, 211, 211a, 212a firmware, 221, 221a, 222a control program, 231 hardware information, 241 input/output mapping information, 431 input/output timing adjustment unit, 432 priority event detection unit.

Claims (8)

模擬対象のプログラマブルコントローラで実行されるファームウェアおよび制御プログラムと、前記模擬対象のプログラマブルコントローラのハードウェアを模擬するのに必要なハードウェア情報と、を記憶する記憶部と、
前記模擬対象のプログラマブルコントローラにおける前記ハードウェアの動作を、前記ハードウェア情報に基づいて模擬するコントローラエミュレータ部と、
入力機器および出力機器と接続される入出力端子と、
前記入出力端子への情報の入出力を制御する入出力制御部と、
前記コントローラエミュレータ部で前記ファームウェアおよび前記制御プログラムを実行したときの前記入出力制御部による仮想的な入出力から前記入出力端子への実際の入出力のタイミングを調整する入出力タイミング調整部と、
を備え
記記憶部中の前記ファームウェアおよび前記ハードウェア情報は、前記模擬対象のプログラマブルコントローラに応じて変更可能であり、
前記記憶部は、前記入出力端子への入出力と、前記仮想的な入出力と、の間の対応関係を規定した入出力マッピング情報をさらに記憶し、
前記コントローラエミュレータ部は、模擬した前記ハードウェア上で、前記ファームウェアおよび前記制御プログラムを実行し、前記ファームウェアおよび前記制御プログラムを実行したときの前記仮想的な入出力を、前記入出力マッピング情報を参照して、前記入出力端子への入出力に変換し、
前記コントローラエミュレータ部は、前記模擬対象のプログラマブルコントローラを前記ファームウェアおよび前記制御プログラムにしたがって模擬するときに、実際の前記模擬対象のプログラマブルコントローラが前記制御プログラムを実行する際の実行時間を見積もり、前記実行時間に基づいて、実際の前記模擬対象のプログラマブルコントローラによる入出力の開始時刻を見積もり、
前記入出力タイミング調整部は、前記開始時刻になるまで、前記入出力制御部による制御を待機させ、前記開始時刻になると、前記入出力制御部による前記入出力端子への入出力の制御を許可することを特徴とするプログラマブルコントローラ。
A storage unit that stores firmware and a control program executed by the simulation target programmable controller, and hardware information necessary to simulate the hardware of the simulation target programmable controller,
A controller emulator unit that simulates the operation of the hardware in the programmable controller to be simulated based on the hardware information,
An input/output terminal connected to an input device and an output device,
An input/output control unit for controlling input/output of information to/from the input/output terminal,
An input/output timing adjustment unit that adjusts the timing of actual input/output from the virtual input/output by the input/output control unit when the firmware and the control program are executed in the controller emulator unit,
Equipped with
The firmware and the hardware information in front Symbol storage unit, Ri changeable der according to the programmable controller of the simulated target,
The storage unit further stores input/output mapping information defining a correspondence relationship between the input/output to the input/output terminal and the virtual input/output,
The controller emulator unit executes the firmware and the control program on the simulated hardware, and refers to the input/output mapping information regarding the virtual input/output when the firmware and the control program are executed. Then, convert to input/output to the input/output terminal,
When simulating the programmable controller to be simulated according to the firmware and the control program, the controller emulator unit estimates the execution time when the programmable controller to be simulated actually executes the control program, and executes the execution. Estimate the start time of input/output by the actual programmable controller based on the time,
The input/output timing adjustment unit waits for control by the input/output control unit until the start time, and at the start time, permits input/output control of the input/output terminal by the input/output control unit. programmable controller according to claim to Rukoto.
前記入出力マッピング情報の前記入出力端子への入出力と前記仮想的な入出力との間の関係を変更可能な外部機器と接続する通信インタフェース部をさらに備えることを特徴とする請求項1に記載のプログラマブルコントローラ。 Claim 1 further comprising Rukoto a communication interface unit which connects the changeable external devices the relationship between input and output and the virtual input and output of the the input and output terminals of the input and output mapping information The programmable controller described in. 複数の前記コントローラエミュレータ部を備え、
前記記憶部は、それぞれの前記コントローラエミュレータ部で実行される前記ファームウェア、前記制御プログラムおよび前記ハードウェア情報を有することを特徴とする請求項1または2に記載のプログラマブルコントローラ。
A plurality of controller emulator units,
The storage unit, the firmware, programmable controller according to claim 1 or 2, characterized in Rukoto to have a said control program and said hardware information to be executed by each of the controller emulator unit.
複数の前記コントローラエミュレータ部による前記模擬対象のプログラマブルコントローラにおける前記ハードウェアの模擬処理を切り替える切替部と、
割込み処理に対応付けられたイベントを検知する優先イベント検知部と、
をさらに備え、
前記優先イベント検知部は、前記割込み処理を優先的に実行するイベントである優先イベントの発生を検知すると、前記切替部に前記優先イベントの発生を通知し、
前記切替部は、前記優先イベントに対応付けられる前記割込み処理が実行されるように複数の前記コントローラエミュレータ部の切り替えを制御することを特徴とする請求項3に記載のプログラマブルコントローラ。
A switching unit that switches simulation processing of the hardware in the programmable controller that is the simulation target by a plurality of the controller emulator units;
A priority event detection unit that detects an event associated with interrupt processing,
Further equipped with,
When the priority event detection unit detects the occurrence of a priority event that is an event that preferentially executes the interrupt processing, it notifies the switching unit of the occurrence of the priority event,
The programmable controller according to claim 3 , wherein the switching unit controls switching of the plurality of controller emulator units so that the interrupt processing associated with the priority event is executed .
模擬対象のプログラマブルコントローラで実行されるファームウェアおよび制御プログラムと、前記模擬対象のプログラマブルコントローラのハードウェアを模擬するのに必要なハードウェア情報と、を記憶する記憶部と、
前記模擬対象のプログラマブルコントローラにおける前記ハードウェアの動作を、前記ハードウェア情報に基づいて模擬する複数のコントローラエミュレータ部と、
複数の前記コントローラエミュレータ部による前記模擬対象のプログラマブルコントローラにおける前記ハードウェアの模擬処理を切り替える切替部と、
割込み処理に対応付けられたイベントを検知する優先イベント検知部と、
を備え、
前記コントローラエミュレータ部は、模擬した前記ハードウェア上で、前記ファームウェアおよび前記制御プログラムを実行し、
前記記憶部中の前記ファームウェアおよび前記ハードウェア情報は、前記模擬対象のプログラマブルコントローラに応じて変更可能であり、
前記記憶部は、それぞれの前記コントローラエミュレータ部で実行される前記ファームウェア、前記制御プログラムおよび前記ハードウェア情報を有し、
前記優先イベント検知部は、前記割込み処理を優先的に実行するイベントである優先イベントの発生を検知すると、前記切替部に前記優先イベントの発生を通知し、
前記切替部は、前記優先イベントに対応付けられる前記割込み処理が実行されるように複数の前記コントローラエミュレータ部の切り替えを制御することを特徴とするプログラマブルコントローラ。
A storage unit that stores firmware and a control program executed by the simulation target programmable controller, and hardware information necessary to simulate the hardware of the simulation target programmable controller,
The operation of the hardware in the programmable controller of the simulated target, and a plurality of co cement roller emulator unit to simulate based on the hardware information,
A switching unit that switches simulation processing of the hardware in the programmable controller that is the simulation target by a plurality of the controller emulator units;
A priority event detection unit that detects an event associated with interrupt processing,
Equipped with
The controller emulator unit executes the firmware and the control program on the simulated hardware,
The firmware and the hardware information in the storage unit can be changed according to the programmable controller of the simulation target,
Wherein the storage unit, possess the firmware executed by each of the controller emulator unit, the control program and the hardware information,
When the priority event detection unit detects the occurrence of a priority event that is an event that preferentially executes the interrupt processing, it notifies the switching unit of the occurrence of the priority event,
The switching unit features and to pulp logs llama logic controllers to control the switching of a plurality of said controller emulator unit as the interrupt process associated with the priority event is executed.
入力機器および出力機器と接続される入出力端子と、
前記入出力端子への情報の入出力を制御する入出力制御部と、
をさらに備え、
前記記憶部は、前記入出力端子への入出力と、前記コントローラエミュレータ部で前記ファームウェアおよび前記制御プログラムを実行したときの仮想的な入出力と、の間の対応関係を規定した入出力マッピング情報をさらに記憶し、
前記コントローラエミュレータ部は、前記ファームウェアおよび前記制御プログラムを実行したときの前記仮想的な入出力を、前記入出力マッピング情報を参照して、前記入出力端子への入出力に変換することを特徴とする請求項に記載のプログラマブルコントローラ。
An input/output terminal connected to an input device and an output device,
An input/output control unit for controlling input/output of information to/from the input/output terminal,
Further equipped with,
The storage unit is input/output mapping information that defines a correspondence relationship between input/output to the input/output terminal and virtual input/output when the controller emulator unit executes the firmware and the control program. Remember more,
The controller emulator unit converts the virtual input/output when the firmware and the control program are executed into an input/output to the input/output terminal with reference to the input/output mapping information. The programmable controller according to claim 5 .
前記入出力マッピング情報の前記入出力端子への入出力と前記仮想的な入出力との間の関係を変更可能な外部機器と接続する通信インタフェース部をさらに備えることを特徴とする請求項6に記載のプログラマブルコントローラ。 The communication interface unit for connecting to an external device capable of changing the relationship between the input/output of the input/output mapping information to the input/output terminal and the virtual input/output is further provided. Programmable controller described. 前記入出力制御部による前記仮想的な入出力から前記入出力端子への実際の入出力のタイミングを調整する入出力タイミング調整部をさらに備え、 Further comprising an input/output timing adjustment unit that adjusts the actual input/output timing from the virtual input/output by the input/output control unit to the input/output terminal,
前記コントローラエミュレータ部は、前記模擬対象のプログラマブルコントローラを前記ファームウェアおよび前記制御プログラムにしたがって模擬するときに、実際の前記模擬対象のプログラマブルコントローラが前記制御プログラムを実行する際の実行時間を見積もり、前記実行時間に基づいて、実際の前記模擬対象のプログラマブルコントローラによる入出力の開始時刻を見積もり、 When simulating the programmable controller to be simulated according to the firmware and the control program, the controller emulator unit estimates the execution time when the programmable controller to be simulated actually executes the control program, and executes the execution. Estimate the start time of input/output by the actual programmable controller based on the time,
前記入出力タイミング調整部は、前記開始時刻になるまで、前記入出力制御部による制御を待機させ、前記開始時刻になると、前記入出力制御部による前記入出力端子への入出力の制御を許可することを特徴とする請求項6または7に記載のプログラマブルコントローラ。 The input/output timing adjustment unit waits for control by the input/output control unit until the start time, and at the start time, permits input/output control of the input/output terminal by the input/output control unit. The programmable controller according to claim 6, wherein:
JP2020519811A 2019-11-26 2019-11-26 Programmable controller Active JP6739689B1 (en)

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
PCT/JP2019/046114 WO2021106064A1 (en) 2019-11-26 2019-11-26 Programmable controller

Publications (2)

Publication Number Publication Date
JP6739689B1 true JP6739689B1 (en) 2020-08-12
JPWO2021106064A1 JPWO2021106064A1 (en) 2021-12-02

Family

ID=71949438

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2020519811A Active JP6739689B1 (en) 2019-11-26 2019-11-26 Programmable controller

Country Status (4)

Country Link
JP (1) JP6739689B1 (en)
CN (1) CN114730168B (en)
DE (1) DE112019007840T5 (en)
WO (1) WO2021106064A1 (en)

Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPS58200363A (en) * 1982-05-14 1983-11-21 Nec Corp Input and output control system of virtual system
JP2015026279A (en) * 2013-07-26 2015-02-05 株式会社東芝 Plant monitoring control device and program

Family Cites Families (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP4894961B1 (en) * 2011-03-15 2012-03-14 オムロン株式会社 PLC CPU unit, PLC system program, and recording medium storing PLC system program
WO2014112990A1 (en) * 2013-01-16 2014-07-24 Siemens Aktiengesellschaft Automated input simulation for simulated programmable logic controller
JP5713056B2 (en) 2013-06-24 2015-05-07 横河電機株式会社 Process control apparatus and system and update method thereof
JP2016031658A (en) * 2014-07-29 2016-03-07 株式会社東芝 Plant control device and plant control method
JP6915441B2 (en) * 2017-08-10 2021-08-04 オムロン株式会社 Information processing equipment, information processing methods, and information processing programs

Patent Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPS58200363A (en) * 1982-05-14 1983-11-21 Nec Corp Input and output control system of virtual system
JP2015026279A (en) * 2013-07-26 2015-02-05 株式会社東芝 Plant monitoring control device and program

Also Published As

Publication number Publication date
DE112019007840T5 (en) 2022-08-04
WO2021106064A1 (en) 2021-06-03
CN114730168A (en) 2022-07-08
JPWO2021106064A1 (en) 2021-12-02
CN114730168B (en) 2023-06-06

Similar Documents

Publication Publication Date Title
CN101714091B (en) Methods and systems to display platform graphics during operating system initialization
US9465610B2 (en) Thread scheduling in a system with multiple virtual machines
JP7465887B2 (en) Data Structure Processing
WO2003025721A2 (en) Microcontroller with configurable onboard boot-ram
JP2013536504A (en) Alignment control
JP2020525934A (en) Apparatus and method for controlling execution of instructions
KR20150004284A (en) Method for operating a control device and control device with a model calculation unit
CN105190551B (en) Dual boot system with memory region swap mechanism
KR20100081366A (en) Risc processor device and method of simulating floating-point stack operation thereof
JPH0517577B2 (en)
JP6739689B1 (en) Programmable controller
JP4665760B2 (en) Electronic computer, semiconductor integrated circuit, control method, program generation method, and program
JP6920286B2 (en) Exception handling
US8886512B2 (en) Simulation apparatus, computer-readable recording medium, and method
EP3329361B1 (en) Vector operand bitsize control
AU2017438670A1 (en) Simulation device, simulation method, and simulation program
JP2005353020A (en) Simulation system for computer program
JP6803957B2 (en) Memory control device and memory control method
JP6603100B2 (en) Memory control device and memory control method
JP6691884B2 (en) Computer and application management method
WO2019198235A1 (en) Simulation device and simulation program
JP3753572B2 (en) Simulation system and instruction simulation method
TW202144998A (en) Device and method for controlling command sequence
CN110858145A (en) Method and device for updating BIOS (basic input output System) in Linux operating system
JP2001209555A (en) Device for input/output emulation, method for emulating input/output device and storage medium which stores input/output emulation program

Legal Events

Date Code Title Description
A521 Request for written amendment filed

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20200406

A621 Written request for application examination

Free format text: JAPANESE INTERMEDIATE CODE: A621

Effective date: 20200406

A871 Explanation of circumstances concerning accelerated examination

Free format text: JAPANESE INTERMEDIATE CODE: A871

Effective date: 20200406

A975 Report on accelerated examination

Free format text: JAPANESE INTERMEDIATE CODE: A971005

Effective date: 20200619

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: 20200623

A61 First payment of annual fees (during grant procedure)

Free format text: JAPANESE INTERMEDIATE CODE: A61

Effective date: 20200721

R150 Certificate of patent or registration of utility model

Ref document number: 6739689

Country of ref document: JP

Free format text: JAPANESE INTERMEDIATE CODE: R150

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250