JP2024088106A - Control system, processing method, and data relay program - Google Patents

Control system, processing method, and data relay program Download PDF

Info

Publication number
JP2024088106A
JP2024088106A JP2022203110A JP2022203110A JP2024088106A JP 2024088106 A JP2024088106 A JP 2024088106A JP 2022203110 A JP2022203110 A JP 2022203110A JP 2022203110 A JP2022203110 A JP 2022203110A JP 2024088106 A JP2024088106 A JP 2024088106A
Authority
JP
Japan
Prior art keywords
data
data relay
relay unit
unit
execution unit
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
JP2022203110A
Other languages
Japanese (ja)
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.)
Omron Corp
Original Assignee
Omron Corp
Filing date
Publication date
Application filed by Omron Corp filed Critical Omron Corp
Publication of JP2024088106A publication Critical patent/JP2024088106A/en
Pending legal-status Critical Current

Links

Images

Abstract

Figure 2024088106000001

【課題】予め定められた周期毎に実行されるプログラムと、予め定められた条件が成立する毎に実行されるプログラムとが混在する場合であっても、互いのプログラムの実行が制限されない仕組みを提供する。
【解決手段】制御システムは、第1プログラムを予め定められた周期毎に実行する第1処理実行部と、第2プログラムを予め定められた条件が成立する毎に実行する第2処理実行部と、データ通信に用いられる通信路と、第1処理実行部と通信路との間に配置された第1データ中継部と、第2処理実行部と通信路との間に配置された第2データ中継部とを含む。第2データ中継部は、第2処理実行部が出力するデータを受け取り、当該受け取ったデータを第1データ中継部に送信する。第1データ中継部は、第1処理実行部が第2データ中継部からのデータにアクセスできるように、第2データ中継部からのデータを格納する。
【選択図】図6

Figure 2024088106000001

To provide a mechanism that does not restrict the execution of a program, even when a program that is executed at a predetermined cycle and a program that is executed whenever a predetermined condition is met are mixed.
[Solution] The control system includes a first process execution unit that executes a first program at predetermined intervals, a second process execution unit that executes a second program whenever a predetermined condition is satisfied, a communication path used for data communication, a first data relay unit arranged between the first process execution unit and the communication path, and a second data relay unit arranged between the second process execution unit and the communication path. The second data relay unit receives data output by the second process execution unit and transmits the received data to the first data relay unit. The first data relay unit stores the data from the second data relay unit so that the first process execution unit can access the data from the second data relay unit.
[Selected Figure] Figure 6

Description

本発明は、制御システム、処理方法およびデータ中継プログラムに関する。 The present invention relates to a control system, a processing method, and a data relay program.

産業オートメーションの分野において、産業システムの制御を担当するOT(Operational Technology)と、情報システムを担当するIT(Information Technology)とを連携させる取組が活発化している。例えば、制御装置が収集したデータをAI(Artificial Intelligence)などを用いて解析するようなことが想定されている。 In the field of industrial automation, efforts to link operational technology (OT), which controls industrial systems, with information technology (IT), which controls information systems, are gaining momentum. For example, it is anticipated that data collected by control devices will be analyzed using artificial intelligence (AI).

特開2019-159882号公報(特許文献1)は、PLC(Programmable Logic Controller)と、HMIとしてのプログラマブル表示器とを備えて、機械や設備等の制御対象の動作を制御するIPC(産業用PC)システムを開示する。 JP 2019-159882 A (Patent Document 1) discloses an IPC (industrial PC) system that includes a PLC (Programmable Logic Controller) and a programmable display as an HMI, and controls the operation of controlled objects such as machines and equipment.

特表2021-523494号公報(特許文献2)は、パーソナルコンピュータ(PC)デバイスを産業用PC(IPC)として用いる構成を開示する。 JP2021-523494A (Patent Document 2) discloses a configuration in which a personal computer (PC) device is used as an industrial PC (IPC).

特開2019-159882号公報JP 2019-159882 A 特表2021-523494号公報Specific Publication No. 2021-523494

OTによる産業システムの制御は、予め定められた周期毎に処理が実行される時間駆動の方式が採用される傾向にある(例えば、一定周期で実行されるシーケンス制御など)。これに対して、ITによる情報処理は、特定のイベントが発生することで処理が実行されるイベント駆動の方式が採用される傾向にある。 Control of industrial systems using OT tends to adopt a time-driven method in which processing is executed at predetermined intervals (for example, sequence control executed at fixed intervals). In contrast, information processing using IT tends to adopt an event-driven method in which processing is executed when a specific event occurs.

時間駆動プログラムとイベント駆動プログラムとが混在している場合には、プログラム間でやり取りされるデータに不整合が生じる可能性があり、いずれかのプログラムが意図通りに動作しない可能性もある。そのため、時間駆動プログラムとイベント駆動プログラムとを互いに連携して実行させる必要がある。 When time-driven and event-driven programs are mixed, there is a possibility that inconsistencies will occur in the data exchanged between the programs, and one of the programs may not work as intended. For this reason, it is necessary to run time-driven and event-driven programs in conjunction with each other.

また、データを整合させるためのプログラムを追加する、あるいは、データのやり取りに関連するプログラムを改修するといった対策をとることもできる。但し、このような対策をとった場合には、保守性および移植性などが低下し得る。 It is also possible to take measures such as adding a program to align the data or modifying the programs related to data exchange. However, taking such measures may reduce maintainability and portability.

本発明は、予め定められた周期毎に実行されるプログラムと、予め定められた条件が成立する毎に実行されるプログラムとが混在する場合であっても、互いのプログラムの実行が制限されない仕組みを提供することを一つの目的とする。 One objective of the present invention is to provide a mechanism that does not restrict the execution of a program, even when a program that is executed at a predetermined interval and a program that is executed whenever a predetermined condition is met are mixed.

本発明のある局面に従う制御システムは、第1プログラムを予め定められた周期毎に実行する第1処理実行部と、第2プログラムを予め定められた条件が成立する毎に実行する第2処理実行部と、データ通信に用いられる通信路と、第1処理実行部と通信路との間に配置された第1データ中継部と、第2処理実行部と通信路との間に配置された第2データ中継部とを含む。第2データ中継部は、第2処理実行部が出力するデータを受け取り、当該受け取ったデータを第1データ中継部に送信する。第1データ中継部は、第1処理実行部が第2データ中継部からのデータにアクセスできるように、第2データ中継部からのデータを格納する。 A control system according to an aspect of the present invention includes a first process execution unit that executes a first program at predetermined intervals, a second process execution unit that executes a second program whenever a predetermined condition is satisfied, a communication path used for data communication, a first data relay unit disposed between the first process execution unit and the communication path, and a second data relay unit disposed between the second process execution unit and the communication path. The second data relay unit receives data output by the second process execution unit and transmits the received data to the first data relay unit. The first data relay unit stores data from the second data relay unit so that the first process execution unit can access the data from the second data relay unit.

この構成によれば、第2処理実行部は、処理の実行結果を反映したデータを第2データ中継部に出力すれば、次の処理を開始できる。そのため、第1処理実行部による周期毎の実行に律速されることなく、第2処理実行部が第2プログラムを実行できる。 According to this configuration, the second process execution unit can start the next process by outputting data reflecting the execution result of the process to the second data relay unit. Therefore, the second process execution unit can execute the second program without being limited by the periodic execution by the first process execution unit.

第1データ中継部は、第1処理実行部が出力するデータを受け取り、当該受け取ったデータを第2データ中継部に送信してもよい。第2データ中継部は、第2処理実行部が第1データ中継部からのデータにアクセスできるように、第1データ中継部からのデータを格納してもよい。この構成によれば、第1処理実行部は、処理の実行結果を反映したデータを第1データ中継部に出力すれば、処理を完了できる。そのため、第1処理実行部と第2処理実行部との間の律速を低減できる。 The first data relay unit may receive data output by the first processing execution unit and transmit the received data to the second data relay unit. The second data relay unit may store the data from the first data relay unit so that the second processing execution unit can access the data from the first data relay unit. According to this configuration, the first processing execution unit can complete the processing by outputting data reflecting the execution result of the processing to the first data relay unit. Therefore, the rate constraint between the first processing execution unit and the second processing execution unit can be reduced.

第1データ中継部および第2データ中継部の各々は、第1処理実行部が出力するデータを格納するための第1メッセージキューと、第2処理実行部が出力するデータを格納するための第2メッセージキューとを含んでもよい。この構成によれば、第1処理実行部が出力するデータおよび第2処理実行部が出力するデータをそれぞれ独立に取り扱うことができる。 Each of the first data relay unit and the second data relay unit may include a first message queue for storing data output by the first processing execution unit, and a second message queue for storing data output by the second processing execution unit. With this configuration, the data output by the first processing execution unit and the data output by the second processing execution unit can be handled independently.

第1データ中継部は、第1メッセージキューにデータが格納されると、当該格納されたデータを第2データ中継部の第1メッセージキューに反映してもよい。第2データ中継部は、第2メッセージキューにデータが格納されると、当該格納されたデータを第1データ中継部の第2メッセージキューに反映してもよい。この構成によれば、第1データ中継部と第2データ中継部との間で、第1メッセージキューおよび第2メッセージキューに格納されるデータを同期させることができる。 When data is stored in the first message queue, the first data relay unit may reflect the stored data in the first message queue of the second data relay unit. When data is stored in the second message queue, the second data relay unit may reflect the stored data in the second message queue of the first data relay unit. With this configuration, data stored in the first message queue and the second message queue can be synchronized between the first data relay unit and the second data relay unit.

第1データ中継部および第2データ中継部の各々は、通信ミドルウェアであってもよい。この構成によれば、第1処理実行部および第2処理実行部から見ると、通常のデータ通信の手続きに見えるので、特別な処理を追加する必要がない。 Each of the first data relay unit and the second data relay unit may be communication middleware. With this configuration, the first processing execution unit and the second processing execution unit see the procedure as a normal data communication procedure, so there is no need to add special processing.

第1データ中継部および第2データ中継部の各々は、通信路を介したデータ通信を担当するドライバを利用してもよい。この構成によれば、第1データ中継部および第2データ中継部は、通信路に特有の処理はドライバに任せることができるので、汎用性を高めることができる。 The first data relay unit and the second data relay unit may each use a driver that handles data communication via the communication path. With this configuration, the first data relay unit and the second data relay unit can leave processing specific to the communication path to the driver, thereby improving versatility.

第1処理実行部および第2処理実行部は、単一の制御装置に含まれてもよい。この構成によれば、第1処理実行部および第2処理実行部の両方を含む制御装置においても、第1処理実行部による周期毎の実行に律速されることなく、第2処理実行部が第2プログラムを実行できる。 The first processing execution unit and the second processing execution unit may be included in a single control device. With this configuration, even in a control device that includes both the first processing execution unit and the second processing execution unit, the second processing execution unit can execute the second program without being limited by the execution by the first processing execution unit every period.

第1処理実行部は、第1制御装置に含まれてもよい。第2処理実行部は、第2制御装置に含まれてもよい。この構成によれば、複数の制御装置で構成される場合であっても、第1処理実行部による周期毎の実行に律速されることなく、第2処理実行部が第2プログラムを実行できる。 The first processing execution unit may be included in the first control device. The second processing execution unit may be included in the second control device. With this configuration, even if multiple control devices are used, the second processing execution unit can execute the second program without being limited by the execution by the first processing execution unit every period.

本発明の別の局面に従う処理方法は、第1処理実行部が、第1プログラムを予め定められた周期毎に実行するステップと、第2処理実行部が、第2プログラムを予め定められた条件が成立する毎に実行するステップと、第2処理実行部と通信路との間に配置された第2データ中継部が、第2処理実行部が出力するデータを受け取り、当該受け取ったデータを第1処理実行部と通信路との間に配置された第1データ中継部に送信するステップと、第1データ中継部が、第1処理実行部が第2データ中継部からのデータにアクセスできるように、第2データ中継部からのデータを格納するステップとを含む。 A processing method according to another aspect of the present invention includes a step in which a first processing execution unit executes a first program at predetermined intervals, a step in which a second processing execution unit executes a second program whenever a predetermined condition is satisfied, a step in which a second data relay unit disposed between the second processing execution unit and the communication path receives data output by the second processing execution unit and transmits the received data to a first data relay unit disposed between the first processing execution unit and the communication path, and a step in which the first data relay unit stores the data from the second data relay unit so that the first processing execution unit can access the data from the second data relay unit.

本発明のさらに別の局面に従うデータ中継プログラムは、コンピュータに、第1プログラムを予め定められた周期毎に実行する第1処理実行部と第2プログラムを予め定められた条件が成立する毎に実行する第2処理実行部との間のデータ通信に用いられる通信路、に接続されたデータ中継部を構成するステップと、第1処理実行部が出力するデータを受け取り、当該受け取ったデータを他のデータ中継部に送信するステップと、第2処理実行部が出力するデータを受け取り、当該受け取ったデータを他のデータ中継部に送信するステップとを実行させる。 A data relay program according to yet another aspect of the present invention causes a computer to execute the steps of: configuring a data relay unit connected to a communication path used for data communication between a first processing execution unit that executes a first program at a predetermined cycle and a second processing execution unit that executes a second program whenever a predetermined condition is satisfied; receiving data output by the first processing execution unit and transmitting the received data to another data relay unit; and receiving data output by the second processing execution unit and transmitting the received data to another data relay unit.

本発明によれば、予め定められた周期毎に実行されるプログラムと、予め定められた条件が成立する毎に実行されるプログラムとが混在する場合であっても、互いのプログラムの実行が制限されない仕組みを実現できる。 According to the present invention, even when a program that is executed at a predetermined interval and a program that is executed whenever a predetermined condition is met are mixed, a mechanism can be realized in which the execution of each program is not restricted.

本実施の形態に従う産業システムの全体構成例を示す模式図である。1 is a schematic diagram showing an example of an overall configuration of an industrial system according to an embodiment of the present invention; 本実施の形態に従う制御装置のハードウェア構成例を示す模式図である。FIG. 2 is a schematic diagram showing an example of a hardware configuration of a control device according to the present embodiment. 本実施の形態に従う制御装置の機能構成例を示す模式図である。FIG. 2 is a schematic diagram showing an example of a functional configuration of a control device according to the present embodiment. 時間駆動タスクとイベント駆動タスクとを並列的に実行する場合の処理例を示す。13 shows an example of processing when a time-driven task and an event-driven task are executed in parallel. 図4に示す処理例において生じ得る課題を示す図である。FIG. 5 is a diagram illustrating a problem that may occur in the processing example shown in FIG. 4 . 本実施の形態に従う制御装置におけるタスク実行の処理例を示す。13 shows an example of a process for executing a task in the control device according to the present embodiment. 本実施の形態に従う制御装置を含む産業システムの一例を示す模式図である。1 is a schematic diagram showing an example of an industrial system including a control device according to an embodiment of the present invention. 本実施の形態に従う制御システムの別の構成例を示す模式図である。FIG. 4 is a schematic diagram showing another configuration example of the control system according to the present embodiment.

本発明の実施の形態について、図面を参照しながら詳細に説明する。なお、図中の同一または相当部分については、同一符号を付してその説明は繰り返さない。 The embodiment of the present invention will be described in detail with reference to the drawings. Note that the same or equivalent parts in the drawings will be given the same reference numerals and their description will not be repeated.

<A.適用例>
まず、本発明が適用される場面の一例について説明する。
<A. Application Examples>
First, an example of a situation in which the present invention is applied will be described.

図1は、本実施の形態に従う産業システム1の全体構成例を示す模式図である。図1を参照して、産業システム1は、1または複数の時間駆動プログラムおよび1または複数のイベント駆動プログラムを実行する制御装置100を含む。以下の説明においては、時間駆動プログラムを実行する処理を「時間駆動タスク150」と称し、イベント駆動プログラムを実行する処理を「イベント駆動タスク160」とも称す。 FIG. 1 is a schematic diagram showing an example of the overall configuration of an industrial system 1 according to the present embodiment. Referring to FIG. 1, the industrial system 1 includes a control device 100 that executes one or more time-driven programs and one or more event-driven programs. In the following description, the process of executing the time-driven programs is also referred to as a "time-driven task 150," and the process of executing the event-driven programs is also referred to as an "event-driven task 160."

時間駆動タスク150は、1または複数の時間駆動プログラムを予め定められた周期毎に実行される処理を包含する。時間駆動タスク150が複数存在することもあり、複数の時間駆動タスク150の実行周期は、互いに異なっていてもよい。また、「タスク」との名称にかかわらず、時間駆動タスク150において実行されるプログラムの内容は限定されない。 A time-driven task 150 includes processing in which one or more time-driven programs are executed at a predetermined cycle. There may be multiple time-driven tasks 150, and the execution cycles of the multiple time-driven tasks 150 may be different from each other. Furthermore, despite being called a "task," the content of the program executed in the time-driven task 150 is not limited.

イベント駆動タスク160は、1または複数のイベント駆動プログラムを予め定められた条件が成立する毎に実行される処理を包含する。イベント駆動タスク160が複数存在することもあり、複数のイベント駆動タスク160を実行するための条件は、互いに異なっていてもよい。予め定められた条件は、例えば、予め定められたイベントの発生を含む。また、「タスク」との名称にかかわらず、イベント駆動タスク160において実行されるプログラムの内容は限定されない。 An event-driven task 160 includes processing that executes one or more event-driven programs each time a predetermined condition is met. There may be multiple event-driven tasks 160, and the conditions for executing the multiple event-driven tasks 160 may be different from each other. The predetermined conditions include, for example, the occurrence of a predetermined event. Furthermore, despite the name "task," the content of the program executed in the event-driven task 160 is not limited.

制御装置100は、時間駆動タスク150とイベント駆動タスク160との間のデータ通信を仲介するデータ中継部170を含む。データ中継部170は、時間駆動タスク150とイベント駆動タスク160との間で、処理の実行タイミングが異なっていることに起因する影響を低減する。データ中継部170の詳細については後述する。 The control device 100 includes a data relay unit 170 that mediates data communication between the time-driven task 150 and the event-driven task 160. The data relay unit 170 reduces the effects caused by differences in the execution timing of processes between the time-driven task 150 and the event-driven task 160. Details of the data relay unit 170 will be described later.

制御装置100は、例えば、産業用PC(Industrial Personal Computer)などのコンピュータである。制御装置100は、PLC(Programmable Logic Controller)であってもよい。 The control device 100 is, for example, a computer such as an industrial PC (Industrial Personal Computer). The control device 100 may also be a programmable logic controller (PLC).

制御装置100は、産業用ネットワーク2を介して、産業システムを構成するデバイス群10と接続される。産業用ネットワーク2は、EtherCAT(登録商標)、EtherNet/IP(登録商標)、DeviceNet(登録商標)、CompoNet(登録商標)などの産業用の通信プロトコルが採用されてもよい。 The control device 100 is connected to a group of devices 10 that constitute an industrial system via an industrial network 2. The industrial network 2 may employ an industrial communication protocol such as EtherCAT (registered trademark), EtherNet/IP (registered trademark), DeviceNet (registered trademark), or CompoNet (registered trademark).

デバイス群10は、各種情報を収集して制御装置100に送信するデバイスと、制御装置100からの指令に従って動作するデバイスとを含む。 The device group 10 includes devices that collect various information and transmit it to the control device 100, and devices that operate according to commands from the control device 100.

デバイス群10は、例えば、リモートI/O(Input/Output)装置12と、リレー群14と、サーボドライバ16およびサーボモータ18と、ロボット20と、カメラ22とを含む。 The device group 10 includes, for example, a remote I/O (Input/Output) device 12, a relay group 14, a servo driver 16 and a servo motor 18, a robot 20, and a camera 22.

リモートI/O装置12およびリレー群14は、産業システムに含まれるセンサなどからの信号を収集して制御装置100に送信し、制御装置100からの指令に従って、産業システムに含まれるアクチュエータなどに信号を与える。 The remote I/O device 12 and the relay group 14 collect signals from sensors and other devices included in the industrial system, transmit them to the control device 100, and provide signals to actuators and other devices included in the industrial system according to instructions from the control device 100.

サーボドライバ16は、制御装置100からの指令に従って、サーボモータ18を駆動する。サーボドライバ16は、サーボモータ18の駆動状態などを示す情報を制御装置100に送信する。 The servo driver 16 drives the servo motor 18 according to instructions from the control device 100. The servo driver 16 transmits information indicating the driving state of the servo motor 18 to the control device 100.

ロボット20は、制御装置100からの指令に従って動作する。ロボット20は、例えば、多関節ロボット、スカラーロボット、モバイルロボットなどである。 The robot 20 operates according to commands from the control device 100. The robot 20 is, for example, an articulated robot, a scalar robot, a mobile robot, etc.

カメラ22は、制御装置100からの指令に従って、または、予め定められた条件が成立すると、撮像した画像を制御装置100などに送信する。 The camera 22 transmits the captured image to the control device 100 or the like in response to a command from the control device 100 or when a predetermined condition is met.

<B.ハードウェア構成例>
次に、本実施の形態に従う制御装置100のハードウェア構成例について説明する。
<B. Hardware Configuration Example>
Next, an example of a hardware configuration of control device 100 according to the present embodiment will be described.

図2は、本実施の形態に従う制御装置100のハードウェア構成例を示す模式図である。図2を参照して、制御装置100は、1または複数のプロセッサ102と、主記憶装置104と、入力部106と、出力部108と、ネットワークコントローラ110,112と、ストレージ120とを含む。 FIG. 2 is a schematic diagram showing an example of the hardware configuration of a control device 100 according to the present embodiment. Referring to FIG. 2, the control device 100 includes one or more processors 102, a main memory device 104, an input unit 106, an output unit 108, network controllers 110 and 112, and storage 120.

プロセッサ102は、時間駆動タスク150およびイベント駆動タスク160を含む各種処理を実行する演算処理部に相当する。プロセッサ102は、ストレージ120に格納されたプログラムを読み出して、主記憶装置104に展開して実行することで、後述するような処理を実現する。プロセッサ102は、CPU(Central Processing Unit)、GPU(Graphics Processing Unit)、MPU(Micro Processing Unit)などで構成される。 The processor 102 corresponds to an arithmetic processing unit that executes various processes including the time-driven task 150 and the event-driven task 160. The processor 102 reads out a program stored in the storage 120, deploys it in the main memory device 104, and executes it to realize the processes described below. The processor 102 is composed of a CPU (Central Processing Unit), a GPU (Graphics Processing Unit), an MPU (Micro Processing Unit), etc.

主記憶装置104は、例えば、DRAM(Dynamic Random Access Memory)、SRAM(Static Random Access Memory)などの揮発性記憶装置で構成される。 The main memory device 104 is composed of a volatile memory device such as a dynamic random access memory (DRAM) or a static random access memory (SRAM).

入力部106は、マウス、キーボード、タッチパネルなどで構成され、ユーザからの指示を受け付ける。出力部108は、ディスプレイインターフェイス、ディスプレイ、スピーカなどで構成され、プロセッサ102からの処理結果などを出力する。 The input unit 106 is composed of a mouse, keyboard, touch panel, etc., and accepts instructions from a user. The output unit 108 is composed of a display interface, display, speaker, etc., and outputs processing results from the processor 102, etc.

ネットワークコントローラ110は、図示しない上位ネットワークを介したデータ送受信を担当する。ネットワークコントローラ112は、産業用ネットワーク2を介したデバイス群10とのデータ送受信を担当する。 The network controller 110 is responsible for sending and receiving data via a higher-level network (not shown). The network controller 112 is responsible for sending and receiving data with the device group 10 via the industrial network 2.

ストレージ120は、例えば、SSD(Solid State Drive)、HDD(Hard Disk Drive)などの不揮発性記憶装置で構成される。ストレージ120には、例えば、1または複数のOS(Operating System)121と、ハイパーバイザプログラム122と、デプロイマネジャプログラム123と、時間駆動プログラム125と、イベント駆動プログラム126と、データ中継プログラム127とが格納される。 The storage 120 is configured with a non-volatile storage device such as a solid state drive (SSD) or a hard disk drive (HDD). The storage 120 stores, for example, one or more operating systems (OS) 121, a hypervisor program 122, a deployment manager program 123, a time-driven program 125, an event-driven program 126, and a data relay program 127.

ハイパーバイザプログラム122は、ハイパーバイザを構成するための命令を含む。ハイパーバイザは、複数のOS121が並行して実行できる仮想環境を提供する。 The hypervisor program 122 contains instructions for configuring the hypervisor. The hypervisor provides a virtual environment in which multiple OSs 121 can run in parallel.

デプロイマネジャプログラム123は、プログラムを仮想環境上に展開する。
時間駆動プログラム125は、時間駆動タスク150に対応するプログラムである。
The deployment manager program 123 deploys the program on the virtual environment.
The time-driven program 125 is a program that corresponds to the time-driven task 150 .

イベント駆動プログラム126は、イベント駆動タスク160に対応するプログラムである。 The event-driven program 126 is a program that corresponds to the event-driven task 160.

データ中継プログラム127は、データ中継部170を構成するための命令を含む。すなわち、データ中継プログラム127は、データ中継部170を構成するための命令を含む。 The data relay program 127 includes instructions for configuring the data relay unit 170. In other words, the data relay program 127 includes instructions for configuring the data relay unit 170.

図2には、プロセッサ102がプログラムを実行することで必要な機能を提供する構成例を示したが、これらの提供される機能の一部または全部を、専用のハードウェア回路(例えば、ASIC(Application Specific Integrated Circuit)、FPGA(Field-Programmable Gate Array)など)を用いて実装してもよい。 Figure 2 shows an example of a configuration in which the processor 102 executes a program to provide the necessary functions, but some or all of the provided functions may be implemented using dedicated hardware circuits (e.g., ASICs (Application Specific Integrated Circuits), FPGAs (Field-Programmable Gate Arrays), etc.).

<C.機能構成例>
次に、本実施の形態に従う制御装置100の機能構成例について説明する。
<C. Functional configuration example>
Next, an example of a functional configuration of control device 100 according to the present embodiment will be described.

図3は、本実施の形態に従う制御装置100の機能構成例を示す模式図である。図3には、1つのハードウェアに仮想環境を構成し、構成された仮想環境上で複数の独立したプログラムを実行する構成例を示す。 Figure 3 is a schematic diagram showing an example of the functional configuration of a control device 100 according to this embodiment. Figure 3 shows an example of a configuration in which a virtual environment is configured in a single piece of hardware, and multiple independent programs are executed on the configured virtual environment.

図3を参照して、制御装置100は、ハイパーバイザ180と、第1制御部130と、第2制御部140とを含む。 Referring to FIG. 3, the control device 100 includes a hypervisor 180, a first control unit 130, and a second control unit 140.

ハイパーバイザ180は、制御装置100において利用可能なハードウェアリソースを第1制御部130および第2制御部140に提供する。ハイパーバイザ180は、第1制御部130と第2制御部140との間のデータ通信に用いられる仮想内部バス182を有している。仮想内部バス182は、データ通信を担当する通信路の一例である。 The hypervisor 180 provides the hardware resources available in the control device 100 to the first control unit 130 and the second control unit 140. The hypervisor 180 has a virtual internal bus 182 used for data communication between the first control unit 130 and the second control unit 140. The virtual internal bus 182 is an example of a communication path responsible for data communication.

第1制御部130は、第1処理実行部132と、OS121と、時間駆動プログラム125と、データ中継部170-1と、インターフェイス173,174とを含む。 The first control unit 130 includes a first processing execution unit 132, an OS 121, a time-driven program 125, a data relay unit 170-1, and interfaces 173 and 174.

第1処理実行部132は、1または複数の時間駆動プログラム125を予め定められた周期毎に実行する。 The first process execution unit 132 executes one or more time-driven programs 125 at predetermined intervals.

OS121は、第1処理実行部132が時間駆動プログラム125を実行するための環境を提供する。OS121は、仮想内部バス182を介したデータ通信を行うためのドライバ124を有している。 The OS 121 provides an environment for the first process execution unit 132 to execute the time-driven program 125. The OS 121 has a driver 124 for performing data communication via the virtual internal bus 182.

データ中継部170-1は、第1処理実行部132と仮想内部バス182との間に配置されている。データ中継部170-1は、通信ミドルウェアであってもよい。データ中継部170-1は、仮想内部バス182を介したデータ通信を担当するドライバ124を利用するように構成されてもよい。 The data relay unit 170-1 is disposed between the first process execution unit 132 and the virtual internal bus 182. The data relay unit 170-1 may be communication middleware. The data relay unit 170-1 may be configured to use the driver 124 that is responsible for data communication via the virtual internal bus 182.

データ中継部170-1は、時間駆動用のメッセージキュー171と、イベント駆動用のメッセージキュー172とを含む。メッセージキュー171,172は、一種のバッファメモリである。 The data relay unit 170-1 includes a time-driven message queue 171 and an event-driven message queue 172. The message queues 171 and 172 are a type of buffer memory.

インターフェイス173,174は、データ中継部170-1によるドライバ124へのアクセスを仲介する。インターフェイス173は、時間駆動用のメッセージキュー171に格納されるデータを担当し、インターフェイス174は、イベント駆動用のメッセージキュー172に関連するデータを担当する。 Interfaces 173 and 174 mediate access to driver 124 by data relay unit 170-1. Interface 173 is responsible for data stored in time-driven message queue 171, and interface 174 is responsible for data related to event-driven message queue 172.

第2制御部140は、第2処理実行部142と、OS121と、データ中継部170-2と、インターフェイス173,174と、イベント駆動プログラム126とを含む。 The second control unit 140 includes a second processing execution unit 142, an OS 121, a data relay unit 170-2, interfaces 173 and 174, and an event-driven program 126.

第2処理実行部142は、1または複数のイベント駆動プログラム126を予め定められた条件が成立する毎に実行する。 The second process execution unit 142 executes one or more event-driven programs 126 each time a predetermined condition is met.

OS121は、第2処理実行部142がイベント駆動プログラム126を実行するための環境を提供する。OS121は、仮想内部バス182を介したデータ通信を行うためのドライバ124を有している。 The OS 121 provides an environment for the second process execution unit 142 to execute the event-driven program 126. The OS 121 has a driver 124 for performing data communication via the virtual internal bus 182.

データ中継部170-2は、第2処理実行部142と仮想内部バス182との間に配置されている。データ中継部170-2は、通信ミドルウェアであってもよい。データ中継部170-2は、仮想内部バス182を介したデータ通信を担当するドライバ124を利用するように構成されてもよい。 The data relay unit 170-2 is disposed between the second process execution unit 142 and the virtual internal bus 182. The data relay unit 170-2 may be communication middleware. The data relay unit 170-2 may be configured to use the driver 124 that is responsible for data communication via the virtual internal bus 182.

データ中継部170-2は、時間駆動用のメッセージキュー171と、イベント駆動用のメッセージキュー172とを含む。メッセージキュー171,172は、一種のバッファメモリである。 The data relay unit 170-2 includes a time-driven message queue 171 and an event-driven message queue 172. The message queues 171 and 172 are a type of buffer memory.

インターフェイス173,174は、データ中継部170-2によるドライバ124へのアクセスを仲介する。インターフェイス173は、時間駆動用のメッセージキュー171に格納されるデータを担当し、インターフェイス174は、イベント駆動用のメッセージキュー172に関連するデータを担当する。 Interfaces 173 and 174 mediate access to driver 124 by data relay unit 170-2. Interface 173 is responsible for data stored in time-driven message queue 171, and interface 174 is responsible for data related to event-driven message queue 172.

図3に示す構成例においては、第1処理実行部132および第2処理実行部142が単一の制御装置100に含まれている。 In the example configuration shown in FIG. 3, the first processing execution unit 132 and the second processing execution unit 142 are included in a single control device 100.

<D.課題および解決手段>
次に、本実施の形態に従う制御装置100が解決する課題および解決手段について説明する。
D. Problems and Solutions
Next, problems to be solved by control device 100 according to the present embodiment and means for solving the problems will be described.

図4は、時間駆動タスク150とイベント駆動タスク160とを並列的に実行する場合の処理例を示す。図4に示す例では、時間駆動タスク150およびイベント駆動タスク160は、共通のハードウェアリソースを利用して実行される。時間駆動タスク150は、最も高い優先度で実行される。イベント駆動タスク160は、時間駆動タスク150が発生するイベントに応じて、時間駆動タスク150が実行されていない時間に実行されるとする。 Figure 4 shows an example of processing when the time-driven task 150 and the event-driven task 160 are executed in parallel. In the example shown in Figure 4, the time-driven task 150 and the event-driven task 160 are executed using common hardware resources. The time-driven task 150 is executed with the highest priority. The event-driven task 160 is executed during a time when the time-driven task 150 is not being executed, in response to an event generated by the time-driven task 150.

図4を参照して、時間駆動タスク150は、周期T毎に繰り返し実行される。時間駆動タスク150は、演算処理151と、出力処理152と、入力処理153とを含む。 Referring to FIG. 4, the time-driven task 150 is repeatedly executed at each period T. The time-driven task 150 includes a calculation process 151, an output process 152, and an input process 153.

出力処理152は、直前の演算処理151において算出された結果(値)を出力する処理である。入力処理153は、演算処理151に必要な入力値を取り込む処理である。 The output process 152 is a process that outputs the result (value) calculated in the immediately preceding calculation process 151. The input process 153 is a process that takes in the input values required for the calculation process 151.

演算処理151は、予め定められた命令の実行、命令の実行により得られた結果(V1,V2,・・・)の算出、イベントの発生などを含む。 Calculation processing 151 includes the execution of predetermined commands, the calculation of results (V1, V2, ...) obtained by executing the commands, the occurrence of events, etc.

イベント駆動タスク160は、時間駆動タスク150が発生したイベントに応じて、処理を開始する。イベント駆動タスク160の実行後に算出または生成される結果は、時間駆動タスク150に出力される。なお、時間駆動タスク150が発生イベントに応じて、イベント駆動タスク160が処理を開始した後、次の周期で時間駆動タスク150の実行が開始されると、イベント駆動タスク160の実行は一旦休止となる。このように、処理は優先度に応じて実行される。そのため、イベント駆動タスク160を任意のタイミングで開始することが難しい。 The event-driven task 160 starts processing in response to an event that occurs in the time-driven task 150. The result calculated or generated after the execution of the event-driven task 160 is output to the time-driven task 150. Note that after the event-driven task 160 starts processing in response to an event that occurs in the time-driven task 150, when the execution of the time-driven task 150 starts in the next cycle, the execution of the event-driven task 160 is temporarily paused. In this way, the processing is executed according to the priority. For this reason, it is difficult to start the event-driven task 160 at any timing.

図5は、図4に示す処理例において生じ得る課題を示す図である。図5を参照して、イベント駆動タスク160の開始は、時間駆動タスク150がイベントを発生するタイミングに依存するが、処理内容によっては、イベント駆動タスク160を任意のタイミングで開始したいというニーズが存在する(符号50)。 Figure 5 is a diagram showing problems that may arise in the processing example shown in Figure 4. Referring to Figure 5, the start of the event-driven task 160 depends on the timing at which the time-driven task 150 generates an event, but depending on the processing content, there is a need to start the event-driven task 160 at any timing (reference numeral 50).

また、イベント駆動タスク160から出力される結果は、入力処理153により時間駆動タスク150に取り込まれることになる。そのため、イベント駆動タスク160は、新たな結果を出力する場合には、時間駆動タスク150が少なくとも1回実行されるまで待たなければならない。例えば、時間駆動タスク150の周期が125μsであるとすると、イベント駆動タスク160の開始は最大で125μs遅延する可能性がある。 In addition, the results output from the event-driven task 160 are taken into the time-driven task 150 by the input process 153. Therefore, before the event-driven task 160 outputs a new result, it must wait until the time-driven task 150 has been executed at least once. For example, if the period of the time-driven task 150 is 125 μs, the start of the event-driven task 160 may be delayed by up to 125 μs.

処理内容によっては、時間駆動タスク150が実行される前に、次のイベント駆動タスク160を開始したいというニーズが存在する(符号52)。すなわち、イベント駆動タスク160をより高速および/またはより高頻度に実行したいというニーズが存在する(符号54)。 Depending on the processing content, there is a need to start the next event-driven task 160 before the time-driven task 150 is executed (symbol 52). In other words, there is a need to execute the event-driven task 160 faster and/or more frequently (symbol 54).

この場合、イベント駆動タスク160の実行毎に出力される結果が時間駆動タスク150に取り込まれないという課題が生じ得る(符号56)。すなわち、イベント駆動タスク160の実行頻度は、時間駆動タスク150の1周期の長さに律速されることになる。 In this case, a problem may occur in which the results output each time the event-driven task 160 is executed are not imported into the time-driven task 150 (reference numeral 56). In other words, the execution frequency of the event-driven task 160 is limited by the length of one cycle of the time-driven task 150.

本実施の形態に従う制御装置100は、イベント駆動タスク160を任意のタイミングで開始できる。この結果、主として産業システムの制御を担当する時間駆動タスク150と非同期で、イベント駆動タスク160を実行できる。すなわち、時間駆動タスク150に律速されることなく、イベント駆動タスク160を開始できる。 The control device 100 according to this embodiment can start the event-driven task 160 at any timing. As a result, the event-driven task 160 can be executed asynchronously with the time-driven task 150, which is mainly responsible for controlling the industrial system. In other words, the event-driven task 160 can be started without being limited by the time-driven task 150.

このような構成を採用することで、時間駆動タスク150の周期とイベント駆動タスク160の開始タイミングとを疎結合にできる。これによって、時間駆動タスク150の周期に依存せず、イベント駆動タスク160の開始タイミングを自由に設定できる。 By adopting such a configuration, the period of the time-driven task 150 and the start timing of the event-driven task 160 can be loosely coupled. This allows the start timing of the event-driven task 160 to be freely set without depending on the period of the time-driven task 150.

図6は、本実施の形態に従う制御装置100におけるタスク実行の処理例を示す。図6を参照して、制御装置100は、時間駆動タスク150に関連付けられたデータ中継部170-1と、イベント駆動タスク160に関連付けられたデータ中継部170-2とを含む。データ中継部170-1およびデータ中継部170-2は、インターフェイス173,174と、ドライバ124と、仮想内部バス182とを介して(いずれも図3参照)、データ通信できるようになっている。 Figure 6 shows an example of task execution processing in the control device 100 according to this embodiment. With reference to Figure 6, the control device 100 includes a data relay unit 170-1 associated with a time-driven task 150, and a data relay unit 170-2 associated with an event-driven task 160. The data relay units 170-1 and 170-2 are capable of data communication via interfaces 173, 174, a driver 124, and a virtual internal bus 182 (all see Figure 3).

例えば、時間駆動タスク150の出力処理152により何らかの結果(値)が出力されると、出力された結果は、データ中継部170-1の時間駆動用のメッセージキュー171に格納される(符号72)。そして、データ中継部170-1とデータ中継部170-2との間のデータ通信により、データ中継部170-1のメッセージキュー171に格納された結果がデータ中継部170-2のメッセージキュー171にも格納される(符号74)。イベント駆動タスク160は、データ中継部170-2のメッセージキュー171にアクセスすることで、時間駆動タスク150が出力した結果を利用できる(符号76)。 For example, when a result (value) is output by the output process 152 of the time-driven task 150, the output result is stored in the time-driven message queue 171 of the data relay unit 170-1 (symbol 72). Then, through data communication between the data relay unit 170-1 and the data relay unit 170-2, the result stored in the message queue 171 of the data relay unit 170-1 is also stored in the message queue 171 of the data relay unit 170-2 (symbol 74). The event-driven task 160 can use the result output by the time-driven task 150 by accessing the message queue 171 of the data relay unit 170-2 (symbol 76).

すなわち、データ中継部170-1は、時間駆動プログラム125を実行する第1処理実行部132が出力するデータを受け取り(符号72)、当該受け取ったデータをデータ中継部170-2に送信する(符号74)。データ中継部170-2は、イベント駆動プログラム126を実行する第2処理実行部142がデータ中継部170-1からのデータにアクセスできるように、データ中継部170-1からのデータをメッセージキュー171に格納する。 That is, the data relay unit 170-1 receives data output by the first process execution unit 132 executing the time-driven program 125 (reference number 72), and transmits the received data to the data relay unit 170-2 (reference number 74). The data relay unit 170-2 stores the data from the data relay unit 170-1 in the message queue 171 so that the second process execution unit 142 executing the event-driven program 126 can access the data from the data relay unit 170-1.

一方、イベント駆動タスク160は、時間駆動タスク150が発生するイベントではなく、任意の方法で発生するイベント60に応じて開始する。イベント60は、時間駆動タスク150から独立したイベントトリガであり、任意のディスパッチャが発生してもよい。そのため、イベント駆動タスク160を任意のタイミングで開始できる。 On the other hand, the event-driven task 160 is started in response to an event 60 that occurs in any manner, not in response to an event generated by the time-driven task 150. The event 60 is an event trigger independent of the time-driven task 150, and may be generated by any dispatcher. Therefore, the event-driven task 160 can be started at any timing.

イベント駆動タスク160の実行後に出力された結果は、データ中継部170-1のイベント駆動用のメッセージキュー172に格納される(符号82)。そして、データ中継部170-2とデータ中継部170-1とのデータ通信により、データ中継部170-2のメッセージキュー172に格納された結果がデータ中継部170-2のメッセージキュー172にも格納される(符号84)。時間駆動タスク150は、データ中継部170-1のメッセージキュー172にアクセスすることで、イベント駆動タスク160が出力した結果を利用できる(符号86)。 The results output after execution of the event-driven task 160 are stored in the event-driven message queue 172 of the data relay unit 170-1 (symbol 82). Then, through data communication between the data relay unit 170-2 and the data relay unit 170-1, the results stored in the message queue 172 of the data relay unit 170-2 are also stored in the message queue 172 of the data relay unit 170-2 (symbol 84). The time-driven task 150 can use the results output by the event-driven task 160 by accessing the message queue 172 of the data relay unit 170-1 (symbol 86).

すなわち、データ中継部170-2は、イベント駆動プログラム126を実行する第2処理実行部142が出力するデータを受け取り(符号82)、当該受け取ったデータをデータ中継部170-1に送信する(符号84)。データ中継部170-1は、時間駆動プログラム125を実行する第1処理実行部132がデータ中継部170-2からのデータにアクセスできるように(符号86)、データ中継部170-2からのデータをメッセージキュー172に格納する。 That is, the data relay unit 170-2 receives data output by the second process execution unit 142 executing the event-driven program 126 (reference number 82), and transmits the received data to the data relay unit 170-1 (reference number 84). The data relay unit 170-1 stores the data from the data relay unit 170-2 in the message queue 172 so that the first process execution unit 132 executing the time-driven program 125 can access the data from the data relay unit 170-2 (reference number 86).

イベント駆動タスク160は、時間駆動タスク150が結果を取り込むまで待つ必要はなく、任意のタイミングで処理を完了できる。また、時間駆動タスク150は、イベント駆動タスク160が出力した結果を任意のタイミングで取り込むことができる。 The event-driven task 160 does not need to wait until the time-driven task 150 retrieves the results, and can complete processing at any time. In addition, the time-driven task 150 can retrieve the results output by the event-driven task 160 at any time.

この結果、イベント駆動タスク160をより高速および/またはより高頻度に実行できる(符号54)。この場合、イベント駆動タスク160の実行毎に出力される結果は、データ中継部170-2のメッセージキュー172に順次格納され、続いて、データ中継部170-1のメッセージキュー172にも順次格納される。 As a result, the event-driven task 160 can be executed faster and/or more frequently (symbol 54). In this case, the results output each time the event-driven task 160 is executed are stored sequentially in the message queue 172 of the data relay unit 170-2, and then sequentially in the message queue 172 of the data relay unit 170-1.

イベント駆動タスク160の実行頻度に応じて、メッセージキュー172のデータサイズ(バッファ容量)を設計することで、時間駆動タスク150は、イベント駆動タスク160が出力した結果の全部または一部を任意に取り込むことができる(符号56および符号86)。 By designing the data size (buffer capacity) of the message queue 172 according to the execution frequency of the event-driven task 160, the time-driven task 150 can optionally incorporate all or part of the results output by the event-driven task 160 (symbols 56 and 86).

上述したように、データ中継部170-1,170-2の各々が有しているメッセージキュー171には、第1処理実行部132が出力するデータが格納される。一方、データ中継部170-1,170-2の各々が有しているメッセージキュー172には、第2処理実行部142が出力するデータが格納される。そして、データ中継部170-1は、メッセージキュー171にデータが格納されると、当該格納されたデータをデータ中継部170-2のメッセージキュー171に反映する(符号74)。同様に、データ中継部170-2は、メッセージキュー172にデータが格納されると、当該格納されたデータをデータ中継部170-1のメッセージキュー172に反映する(符号84)。 As described above, the message queue 171 owned by each of the data relay units 170-1 and 170-2 stores data output by the first process execution unit 132. Meanwhile, the message queue 172 owned by each of the data relay units 170-1 and 170-2 stores data output by the second process execution unit 142. Then, when data is stored in the message queue 171, the data relay unit 170-1 reflects the stored data in the message queue 171 of the data relay unit 170-2 (reference number 74). Similarly, when data is stored in the message queue 172 of the data relay unit 170-2, the data relay unit 170-2 reflects the stored data in the message queue 172 of the data relay unit 170-1 (reference number 84).

図6に示すように、制御装置100によれば、時間駆動タスク150とイベント駆動タスク160との間のデータ通信を疎結合にできる。これによって、イベント駆動タスク160は、時間駆動タスク150の実行タイミングなどに律速されることなく実行できる。 As shown in FIG. 6, the control device 100 allows data communication between the time-driven task 150 and the event-driven task 160 to be loosely coupled. This allows the event-driven task 160 to execute without being limited by the execution timing of the time-driven task 150.

また、制御装置100によれば、時間駆動プログラム125(主として、産業システムの制御)とイベント駆動プログラム126(主として、情報システム)とを共存および連係できる。 In addition, the control device 100 allows the time-driven program 125 (mainly for control of industrial systems) and the event-driven program 126 (mainly for control of information systems) to coexist and work together.

<E.産業システムの一例>
次に、本実施の形態に従う制御装置100を含む産業システム1の一例について説明する。
<E. An example of an industrial system>
Next, an example of the industrial system 1 including the control device 100 according to the present embodiment will be described.

図7は、本実施の形態に従う制御装置100を含む産業システム1の一例を示す模式図である。図7を参照して、産業システム1は、ワーク6を搬送するコンベア4を含む。カメラ22が搬送されるワーク6を撮像し、撮像した画像に基づいてワーク6の座標(位置)が算出される。なお、撮像時には、フラッシュ24によりワーク6が照明される。ロボット20は、算出された座標に基づいて、ワーク6をピックする。 Figure 7 is a schematic diagram showing an example of an industrial system 1 including a control device 100 according to the present embodiment. Referring to Figure 7, the industrial system 1 includes a conveyor 4 that transports a workpiece 6. A camera 22 captures an image of the transported workpiece 6, and the coordinates (position) of the workpiece 6 are calculated based on the captured image. During the image capture, the workpiece 6 is illuminated by a flash 24. A robot 20 picks up the workpiece 6 based on the calculated coordinates.

図7に示す構成例においては、第1制御部130が実行する時間駆動タスク150がロボット20の制御を担当し、第2制御部140が実行するイベント駆動タスク160がカメラ22およびフラッシュ24の制御を担当する。 In the example configuration shown in FIG. 7, a time-driven task 150 executed by the first control unit 130 is responsible for controlling the robot 20, and an event-driven task 160 executed by the second control unit 140 is responsible for controlling the camera 22 and the flash 24.

例えば、イベント駆動タスク160は、フラッシュ24の点灯、点灯から所定時間後にカメラ22による撮像、撮像した画像の画像処理(ワーク6の座標を算出)などの処理を含む。時間駆動タスク150は、ロボット20のハンド位置の制御、ロボット20が移動するパスの算出、ロボット20のアーム位置の制御といった処理を含む。 For example, the event-driven task 160 includes processes such as turning on the flash 24, capturing an image with the camera 22 a predetermined time after the flash is turned on, and processing the captured image (calculating the coordinates of the workpiece 6). The time-driven task 150 includes processes such as controlling the hand position of the robot 20, calculating the path along which the robot 20 will move, and controlling the arm position of the robot 20.

本実施の形態に従う制御装置100は、時間駆動タスク150の実行周期に律速されることなく、イベント駆動タスク160を実行できる。その結果、時間駆動タスク150の実行周期より短い時間でワーク6を撮像することが可能となる。ワーク6をより頻繁に撮像することで、ワーク6の座標をより正確に算出でき、制御精度を高めることができる。 The control device 100 according to this embodiment can execute the event-driven task 160 without being limited by the execution period of the time-driven task 150. As a result, it becomes possible to image the workpiece 6 in a time shorter than the execution period of the time-driven task 150. By imaging the workpiece 6 more frequently, the coordinates of the workpiece 6 can be calculated more accurately, and control precision can be improved.

このとき、イベント駆動タスク160が算出するワーク6の座標は、データ中継部170に出力される。時間駆動タスク150は、データ中継部170が保持する座標を任意のタイミングで取り込む。 At this time, the coordinates of the work 6 calculated by the event-driven task 160 are output to the data relay unit 170. The time-driven task 150 retrieves the coordinates held by the data relay unit 170 at any timing.

<F.変形例>
上述の説明においては、単一の制御装置100が時間駆動タスク150およびイベント駆動タスク160を実行する構成例を説明した(図3参照)。時間駆動タスク150およびイベント駆動タスク160をそれぞれ別の制御装置100が実行するようにしてもよい。
F. Modifications
In the above description, a configuration example has been described in which a single control device 100 executes the time-driven task 150 and the event-driven task 160 (see FIG. 3). The time-driven task 150 and the event-driven task 160 may be executed by different control devices 100, respectively.

図8は、本実施の形態に従う制御システムの別の構成例を示す模式図である。図8を参照して、制御システムは、時間駆動タスク150を実行する制御装置100-1と、イベント駆動タスク160を実行する制御装置100-2とを含む。制御装置100-1と制御装置100-2とは、産業用ネットワーク2を介して接続されている。 FIG. 8 is a schematic diagram showing another example of the configuration of a control system according to the present embodiment. Referring to FIG. 8, the control system includes a control device 100-1 that executes a time-driven task 150, and a control device 100-2 that executes an event-driven task 160. The control devices 100-1 and 100-2 are connected via an industrial network 2.

制御装置100-1の機能構成は、図3に示す第1制御部130と同様であり、制御装置100-2の機能構成は、図3に示す第2制御部140と同様である。図8に示す構成例においては、第1処理実行部132は、制御装置100-1に含まれ、第2処理実行部142は、制御装置100-2に含まれる。 The functional configuration of the control device 100-1 is similar to that of the first control unit 130 shown in FIG. 3, and the functional configuration of the control device 100-2 is similar to that of the second control unit 140 shown in FIG. 3. In the configuration example shown in FIG. 8, the first process execution unit 132 is included in the control device 100-1, and the second process execution unit 142 is included in the control device 100-2.

さらに、図3および図8に示す構成例に限らず、時間駆動タスク150を実行する制御部および/または制御装置が複数存在していてもよいし、イベント駆動タスク160を実行する制御部および/または制御装置が複数存在していてもよい。 Furthermore, without being limited to the configuration examples shown in Figures 3 and 8, there may be multiple control units and/or control devices that execute the time-driven task 150, and there may be multiple control units and/or control devices that execute the event-driven task 160.

その結果、3つ以上の制御部および/または制御装置の間でデータ通信を行う場合においても、上述したようなデータ中継部170を採用することで、同様の処理を実現できる。 As a result, even when data communication is performed between three or more control units and/or control devices, similar processing can be achieved by employing the data relay unit 170 described above.

本明細書において、「制御システム」との用語は、1または複数の制御装置からなる構成を包含する。すなわち、図3に示すように、単一の制御装置100が時間駆動タスク150およびイベント駆動タスク160を実行する構成例においては、単一の制御装置100が制御システムに相当する。また、図8に示すように、複数の制御装置100からなる構成例においては、複数の制御装置100が制御システムに相当する。 In this specification, the term "control system" includes a configuration consisting of one or more control devices. That is, as shown in FIG. 3, in an example configuration in which a single control device 100 executes a time-driven task 150 and an event-driven task 160, the single control device 100 corresponds to a control system. Also, as shown in FIG. 8, in an example configuration in which multiple control devices 100 are included, the multiple control devices 100 correspond to a control system.

<G.付記>
上述したような本実施の形態は、以下のような技術思想を含む。
<G. Notes>
The present embodiment as described above includes the following technical idea.

[構成1]
第1プログラム(125)を予め定められた周期毎に実行する第1処理実行部(132)と、
第2プログラム(126)を予め定められた条件が成立する毎に実行する第2処理実行部(142)と、
データ通信に用いられる通信路(182;2)と、
前記第1処理実行部と前記通信路との間に配置された第1データ中継部(170-1)と、
前記第2処理実行部と前記通信路との間に配置された第2データ中継部(170-2)とを備え、
前記第2データ中継部は、前記第2処理実行部が出力するデータを受け取り、当該受け取ったデータを前記第1データ中継部に送信し(82,84)、
前記第1データ中継部は、前記第1処理実行部が前記第2データ中継部からのデータにアクセスできるように、前記第2データ中継部からのデータを格納する(84,86)、制御システム。
[Configuration 1]
a first processing execution unit (132) that executes a first program (125) at predetermined intervals;
a second processing execution unit (142) that executes the second program (126) every time a predetermined condition is satisfied;
A communication path (182; 2) used for data communication;
a first data relay unit (170-1) disposed between the first process execution unit and the communication path;
a second data relay unit (170-2) disposed between the second processing execution unit and the communication path;
The second data relay unit receives the data output by the second process execution unit and transmits the received data to the first data relay unit (82, 84);
The first data relay unit stores (84, 86) data from the second data relay unit such that the first process execution unit can access the data from the second data relay unit.

[構成2]
前記第1データ中継部は、前記第1処理実行部が出力するデータを受け取り、当該受け取ったデータを前記第2データ中継部に送信し(72,74)、
前記第2データ中継部は、前記第2処理実行部が前記第1データ中継部からのデータにアクセスできるように、前記第1データ中継部からのデータを格納する(74,76)、構成1に記載の制御システム。
[Configuration 2]
The first data relay unit receives data output by the first process execution unit and transmits the received data to the second data relay unit (72, 74);
2. The control system of claim 1, wherein the second data relay unit stores (74, 76) data from the first data relay unit so that the second process execution unit can access the data from the first data relay unit.

[構成3]
前記第1データ中継部および前記第2データ中継部の各々は、前記第1処理実行部が出力するデータを格納するための第1メッセージキュー(171)と、前記第2処理実行部が出力するデータを格納するための第2メッセージキュー(172)とを含む、構成2に記載の制御システム。
[Configuration 3]
The control system of configuration 2, wherein each of the first data relay unit and the second data relay unit includes a first message queue (171) for storing data output by the first processing execution unit, and a second message queue (172) for storing data output by the second processing execution unit.

[構成4]
前記第1データ中継部は、前記第1メッセージキューにデータが格納されると、当該格納されたデータを前記第2データ中継部の前記第1メッセージキューに反映し(74)、
前記第2データ中継部は、前記第2メッセージキューにデータが格納されると、当該格納されたデータを前記第1データ中継部の前記第2メッセージキューに反映する(84)、構成3に記載の制御システム。
[Configuration 4]
When data is stored in the first message queue, the first data relay unit reflects the stored data in the first message queue of the second data relay unit (74);
The control system according to configuration 3, wherein when data is stored in the second message queue, the second data relay unit reflects the stored data in the second message queue of the first data relay unit (84).

[構成5]
前記第1データ中継部および前記第2データ中継部の各々は、通信ミドルウェアである、構成1~4のいずれか1項に記載の制御システム。
[Configuration 5]
The control system according to any one of configurations 1 to 4, wherein each of the first data relay unit and the second data relay unit is communication middleware.

[構成6]
前記第1データ中継部および前記第2データ中継部の各々は、前記通信路を介したデータ通信を担当するドライバ(124)を利用する、構成5に記載の制御システム。
[Configuration 6]
6. The control system of configuration 5, wherein each of the first data relay unit and the second data relay unit utilizes a driver (124) that is responsible for data communication over the communication path.

[構成7]
前記第1処理実行部および前記第2処理実行部は、単一の制御装置(100)に含まれる、構成1~4のいずれか1項に記載の制御システム。
[Configuration 7]
The control system according to any one of configurations 1 to 4, wherein the first processing execution unit and the second processing execution unit are included in a single control device (100).

[構成8]
前記第1処理実行部は、第1制御装置(100-1)に含まれ、
前記第2処理実行部は、第2制御装置(100-2)に含まれる、構成1~4のいずれか1項に記載の制御システム。
[Configuration 8]
The first processing execution unit is included in a first control device (100-1),
The control system according to any one of configurations 1 to 4, wherein the second processing execution unit is included in a second control device (100-2).

[構成9]
第1処理実行部(132)が、第1プログラム(125)を予め定められた周期毎に実行するステップと、
第2処理実行部(142)が、第2プログラム(126)を予め定められた条件が成立する毎に実行するステップと、
前記第2処理実行部と通信路(182;2)との間に配置された第2データ中継部(170-2)が、前記第2処理実行部が出力するデータを受け取り、当該受け取ったデータを前記第1処理実行部と通信路との間に配置された第1データ中継部(170-1)に送信するステップ(82,84)と、
前記第1データ中継部が、前記第1処理実行部が前記第2データ中継部からのデータにアクセスできるように、前記第2データ中継部からのデータを格納するステップ(84,86)とを備える、処理方法。
[Configuration 9]
A step in which a first processing execution unit (132) executes a first program (125) at predetermined intervals;
A step in which a second processing execution unit (142) executes a second program (126) every time a predetermined condition is satisfied;
a step (82, 84) in which a second data relay unit (170-2) arranged between the second processing execution unit and a communication path (182; 2) receives data output by the second processing execution unit, and transmits the received data to a first data relay unit (170-1) arranged between the first processing execution unit and the communication path;
and a step (84, 86) of the first data relay unit storing data from the second data relay unit such that the first processing execution unit can access the data from the second data relay unit.

[構成10]
コンピュータ(100)に、
第1プログラム(125)を予め定められた周期毎に実行する第1処理実行部(132)と第2プログラム(126)を予め定められた条件が成立する毎に実行する第2処理実行部(142)との間のデータ通信に用いられる通信路(182;2)、に接続されたデータ中継部(182)を構成するステップと、
前記第1処理実行部が出力するデータを受け取り、当該受け取ったデータを他のデータ中継部に送信するステップ(72,74;82,84)と、
前記第2処理実行部が出力するデータを受け取り、当該受け取ったデータを前記他のデータ中継部に送信するステップ(74;84)とを実行させる、データ中継プログラム。
[Configuration 10]
A computer (100)
A step of configuring a data relay unit (182) connected to a communication path (182; 2) used for data communication between a first processing execution unit (132) that executes a first program (125) at predetermined intervals and a second processing execution unit (142) that executes a second program (126) at predetermined intervals;
receiving data output by the first processing execution unit and transmitting the received data to another data relay unit (72, 74; 82, 84);
receiving data output by the second process execution unit and transmitting the received data to the other data relay unit (74; 84).

今回開示された実施の形態はすべての点で例示であって制限的なものではないと考えられるべきである。本発明の範囲は、上記した説明ではなく、特許請求の範囲によって示され、特許請求の範囲と均等の意味および範囲内でのすべての変更が含まれることが意図される。 The embodiments disclosed herein should be considered to be illustrative and not restrictive in all respects. The scope of the present invention is indicated by the claims, not by the above description, and is intended to include all modifications within the meaning and scope of the claims.

1 産業システム、2 産業用ネットワーク、4 コンベア、6 ワーク、10 デバイス群、12 リモートI/O装置、14 リレー群、16 サーボドライバ、18 サーボモータ、20 ロボット、22 カメラ、24 フラッシュ、60 イベント、100 制御装置、102 プロセッサ、104 主記憶装置、106 入力部、108 出力部、110,112 ネットワークコントローラ、120 ストレージ、121 OS、122 ハイパーバイザプログラム、123 デプロイマネジャプログラム、124 ドライバ、125 時間駆動プログラム、126 イベント駆動プログラム、127 データ中継プログラム、130 第1制御部、132 第1処理実行部、140 第2制御部、142 第2処理実行部、150 時間駆動タスク、151 演算処理、152 出力処理、153 入力処理、160 イベント駆動タスク、170 データ中継部、171,172 メッセージキュー、173,174 インターフェイス、180 ハイパーバイザ、182 仮想内部バス。 1 Industrial system, 2 Industrial network, 4 Conveyor, 6 Work, 10 Device group, 12 Remote I/O device, 14 Relay group, 16 Servo driver, 18 Servo motor, 20 Robot, 22 Camera, 24 Flash, 60 Event, 100 Control device, 102 Processor, 104 Main memory device, 106 Input unit, 108 Output unit, 110, 112 Network controller, 120 Storage, 121 OS, 122 Hypervisor program, 123 Deployment manager program, 124 Driver, 125 Time-driven program, 126 Event-driven program, 127 Data relay program, 130 First control unit, 132 First processing execution unit, 140 Second control unit, 142 Second processing execution unit, 150 Time-driven task, 151 Calculation processing, 152 Output processing, 153 Input processing, 160 Event-driven task, 170 Data relay unit, 171, 172 message queue, 173, 174 interface, 180 hypervisor, 182 virtual internal bus.

Claims (10)

第1プログラムを予め定められた周期毎に実行する第1処理実行部と、
第2プログラムを予め定められた条件が成立する毎に実行する第2処理実行部と、
データ通信に用いられる通信路と、
前記第1処理実行部と前記通信路との間に配置された第1データ中継部と、
前記第2処理実行部と前記通信路との間に配置された第2データ中継部とを備え、
前記第2データ中継部は、前記第2処理実行部が出力するデータを受け取り、当該受け取ったデータを前記第1データ中継部に送信し、
前記第1データ中継部は、前記第1処理実行部が前記第2データ中継部からのデータにアクセスできるように、前記第2データ中継部からのデータを格納する、制御システム。
a first process execution unit that executes a first program at predetermined intervals;
a second process execution unit that executes the second program every time a predetermined condition is satisfied;
A communication path used for data communication;
a first data relay unit disposed between the first process execution unit and the communication path;
a second data relay unit disposed between the second process execution unit and the communication path;
The second data relay unit receives data output by the second processing execution unit and transmits the received data to the first data relay unit;
The first data relay unit stores the data from the second data relay unit so that the first process execution unit can access the data from the second data relay unit.
前記第1データ中継部は、前記第1処理実行部が出力するデータを受け取り、当該受け取ったデータを前記第2データ中継部に送信し、
前記第2データ中継部は、前記第2処理実行部が前記第1データ中継部からのデータにアクセスできるように、前記第1データ中継部からのデータを格納する、請求項1に記載の制御システム。
The first data relay unit receives data output by the first process execution unit and transmits the received data to the second data relay unit;
The control system according to claim 1 , wherein the second data relay unit stores the data from the first data relay unit so that the second process execution unit can access the data from the first data relay unit.
前記第1データ中継部および前記第2データ中継部の各々は、前記第1処理実行部が出力するデータを格納するための第1メッセージキューと、前記第2処理実行部が出力するデータを格納するための第2メッセージキューとを含む、請求項2に記載の制御システム。 The control system according to claim 2, wherein each of the first data relay unit and the second data relay unit includes a first message queue for storing data output by the first process execution unit and a second message queue for storing data output by the second process execution unit. 前記第1データ中継部は、前記第1メッセージキューにデータが格納されると、当該格納されたデータを前記第2データ中継部の前記第1メッセージキューに反映し、
前記第2データ中継部は、前記第2メッセージキューにデータが格納されると、当該格納されたデータを前記第1データ中継部の前記第2メッセージキューに反映する、請求項3に記載の制御システム。
when data is stored in the first message queue, the first data relay unit reflects the stored data in the first message queue of the second data relay unit;
The control system according to claim 3 , wherein when data is stored in the second message queue, the second data relay unit reflects the stored data in the second message queue of the first data relay unit.
前記第1データ中継部および前記第2データ中継部の各々は、通信ミドルウェアである、請求項1~4のいずれか1項に記載の制御システム。 The control system according to any one of claims 1 to 4, wherein each of the first data relay unit and the second data relay unit is a communication middleware. 前記第1データ中継部および前記第2データ中継部の各々は、前記通信路を介したデータ通信を担当するドライバを利用する、請求項5に記載の制御システム。 The control system according to claim 5, wherein each of the first data relay unit and the second data relay unit uses a driver that is responsible for data communication via the communication path. 前記第1処理実行部および前記第2処理実行部は、単一の制御装置に含まれる、請求項1~4のいずれか1項に記載の制御システム。 The control system according to any one of claims 1 to 4, wherein the first process execution unit and the second process execution unit are included in a single control device. 前記第1処理実行部は、第1制御装置に含まれ、
前記第2処理実行部は、第2制御装置に含まれる、請求項1~4のいずれか1項に記載の制御システム。
The first process execution unit is included in a first control device,
The control system according to any one of claims 1 to 4, wherein the second process execution unit is included in a second control device.
第1処理実行部が、第1プログラムを予め定められた周期毎に実行するステップと、
第2処理実行部が、第2プログラムを予め定められた条件が成立する毎に実行するステップと、
前記第2処理実行部と通信路との間に配置された第2データ中継部が、前記第2処理実行部が出力するデータを受け取り、当該受け取ったデータを前記第1処理実行部と通信路との間に配置された第1データ中継部に送信するステップと、
前記第1データ中継部が、前記第1処理実行部が前記第2データ中継部からのデータにアクセスできるように、前記第2データ中継部からのデータを格納するステップとを備える、処理方法。
A step in which a first process execution unit executes a first program at predetermined intervals;
a step of a second process execution unit executing the second program every time a predetermined condition is satisfied;
a second data relay unit disposed between the second processing execution unit and a communication path receiving data output by the second processing execution unit, and transmitting the received data to a first data relay unit disposed between the first processing execution unit and a communication path;
the first data relay unit storing the data from the second data relay unit so that the first processing execution unit can access the data from the second data relay unit.
コンピュータに、
第1プログラムを予め定められた周期毎に実行する第1処理実行部と第2プログラムを予め定められた条件が成立する毎に実行する第2処理実行部との間のデータ通信に用いられる通信路、に接続されたデータ中継部を構成するステップと、
前記第1処理実行部が出力するデータを受け取り、当該受け取ったデータを他のデータ中継部に送信するステップと、
前記第2処理実行部が出力するデータを受け取り、当該受け取ったデータを前記他のデータ中継部に送信するステップとを実行させる、データ中継プログラム。
On the computer,
configuring a data relay unit connected to a communication path used for data communication between a first processing execution unit that executes a first program at predetermined intervals and a second processing execution unit that executes a second program at predetermined intervals;
receiving data output by the first process execution unit and transmitting the received data to another data relay unit;
receiving data output by the second process execution unit and transmitting the received data to the other data relay unit.
JP2022203110A 2022-12-20 Control system, processing method, and data relay program Pending JP2024088106A (en)

Publications (1)

Publication Number Publication Date
JP2024088106A true JP2024088106A (en) 2024-07-02

Family

ID=

Similar Documents

Publication Publication Date Title
JP5149258B2 (en) Robot component management device
US10908577B2 (en) Control device
JP6488830B2 (en) Control device
KR20120099222A (en) Multi-processor based programmable logic controller and method for operating the same
EP3582036B9 (en) Control device
CN114463163A (en) Heterogeneous multi-core image processing method and device
JP2024503168A (en) Multi-threaded controller for parallel robots
Bruzzone et al. Standard Linux for embedded real-time robotics and manufacturing control systems
CN111052012B (en) Control device and control system
JP2024088106A (en) Control system, processing method, and data relay program
Bruno et al. CAB: An environment for developing concurrent application
Finkemeyer et al. A middleware for high-speed distributed real-time robotic applications
Hace et al. Control system for the waterjet cutting machine
US11498211B2 (en) Composability framework for robotic control system
KR102259503B1 (en) Method and system for controlling simulation based on event driven scheme
JP2007241744A (en) Motion controller and its command method
JP7231073B2 (en) Controllers and control systems
CN114690702B (en) Robot control system combining soft PLC and motion control
JP2001331346A (en) Simulator and its method
Steiner et al. Self-Management within a Software Architecture for Parallel Kinematic Machines
US20230401090A1 (en) Control device, control method, and non-transitory computer readable medium
EP4296856A1 (en) Computer system and method for executing an automotive customer function
Hace et al. The open CNC controller for a cutting machine
EP4254098A1 (en) Controlling an automation system comprising a plurality of machines
Bruzzone et al. Standard Linux for embedded real-time manufacturing control systems