Plant control device and plant control method

The plant control device manages task wake-up timing to prevent mixing of calculation results across control cycles, addressing unintended plant behavior and maintaining efficiency by ensuring timely completion of tasks with varying cycles.

WO2026141029A1PCT designated stage Publication Date: 2026-07-02MITSUBISHI HEAVY IND LTD +1

Patent Information

Authority / Receiving Office
WO · WO
Patent Type
Applications
Current Assignee / Owner
MITSUBISHI HEAVY IND LTD
Filing Date
2025-12-16
Publication Date
2026-07-02

AI Technical Summary

Technical Problem

Existing plant control systems face issues with unintended plant behavior and reduced efficiency due to mixing of calculation results from tasks with different control cycles, leading to incorrect control outputs.

Method used

A plant control device and method that manages the wake-up timing of calculation tasks with varying control cycles, ensuring that tasks with longer cycles and lower priority are not woken up until their previous processing is complete, using flags to control the timing and prevent mixing of results.

Benefits of technology

Prevents the mixing of calculation results across control cycles, thereby avoiding unintended plant behavior and maintaining production efficiency by ensuring timely completion of tasks.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure JP2025043834_02072026_PF_FP_ABST
    Figure JP2025043834_02072026_PF_FP_ABST
Patent Text Reader

Abstract

The present disclosure relates to a plant control device for controlling a plant on the basis of calculation results of a plurality of calculation tasks. This plant control device comprises: a control task execution unit for executing a control task that wakes up a plurality of computation tasks at prescribed control intervals; and a computation task execution unit for executing the plurality of computation tasks. The plurality of computation tasks include a first computation task having a first control period, and a second computation task having a second control period longer than the first control period and having a low priority. The second computation task can output a computation result to a communication counterpart device included in the plant via the first computation task. When a computation process immediately preceding the second computation task is incomplete at a first wake-up timing of the second computation task based on the second control period, the control task does not wake up the second computation task at the first wake-up timing.
Need to check novelty before this filing date? Find Prior Art

Description

Plant control device and plant control method

[0001] The present disclosure relates to a plant control device and a plant control method. This application claims priority based on Japanese Patent Application No. 2024-226005 filed with the Japan Patent Office on December 23, 2024, and incorporates its content herein by reference.

[0002] A plant control device that handles a plant as a control target is known. The plant control device is composed of an arithmetic processing device such as a CPU, and a field signal is input from a field device such as a sensor installed in the plant. In the arithmetic processing device, control logic consisting of a plurality of logic sheets described in, for example, a graphic processing language (POL: Problem Oriented Language) is installed in advance, arithmetic processing based on the control logic is performed, and the arithmetic processing result is output to an operation terminal such as an actuator or a switch, whereby the plant is controlled.

[0003] The plurality of logic sheets constituting the control logic are divided into logic sheet groups for each function and control target, and are executed as a plurality of arithmetic tasks corresponding to each logic sheet group. These plurality of arithmetic tasks are periodically executed based on the control period and priority set for each. Generally, the shorter the control period, the higher the priority is set.

[0004] For example, Patent Document 1 discloses an example of a plant control device that executes such arithmetic tasks. In this document, when performing reception processing of data used for control arithmetic from a communication port as communication interrupt processing, even when the reception amount of the data is large, a technique related to arithmetic processing for executing the arithmetic task without delay is disclosed.

[0005] Japanese Unexamined Patent Application Publication No. 2007-195131

[0006] In a plant control device that controls a plant based on control logic including multiple calculation tasks, multiple calculation tasks with different control cycles may be executed according to priority. Here, if the multiple calculation tasks include a first calculation task and a second calculation task with a longer control cycle and lower priority than the first calculation task, and the calculation results of both calculation tasks are output to a communication partner device such as a field device or operating terminal via the first calculation task, the first and second calculation tasks are designed so that the calculation processing is basically completed within their respective control cycles. However, if the second calculation task performs, for example, a convergence calculation, it may take longer than expected to complete the calculation processing of the second calculation task. In this case, the calculation processing of the second calculation task extends into the next control cycle, and depending on the wake-up timing of the second calculation task corresponding to the next control cycle, there is a risk that the calculation results of the second calculation task, which belongs to a different control cycle, may be mixed into the data output to the communication partner device synchronized with the control cycle of the first calculation task. Such a mixture of calculation results can lead to incorrect control outputs, causing unintended behavior in plant control and potentially reducing plant operating rates and production efficiency.

[0007] At least one embodiment of this disclosure has been made in view of the above circumstances, and aims to provide a plant control device and a plant control method that can prevent a decrease in plant operating rate and production efficiency due to unintended plant behavior caused by erroneous control output in plant control.

[0008] A plant control device according to at least one embodiment of the present disclosure is a plant control device for controlling a plant based on the calculation results of a plurality of calculation tasks in order to solve the above problems, comprising: a control task execution unit for executing a control task to wake up the plurality of calculation tasks at a predetermined control cycle; and a calculation task execution unit for executing the plurality of calculation tasks that have been woken up at the predetermined control cycle, wherein the plurality of calculation tasks include: a first calculation task for which a first control cycle is set as the control cycle; a second calculation task for which a second control cycle longer than the first control cycle is set as the control cycle and which has a lower priority than the first calculation task, wherein the second calculation task can output calculation results to a communication partner device provided by the plant via the first calculation task, and the control task does not wake up the second calculation task at the first wake-up timing of the second calculation task based on the second control cycle if the previous calculation processing of the second calculation task is not completed.

[0009] A plant control method according to at least one embodiment of the present disclosure is a plant control method for controlling a plant based on the calculation results of a plurality of calculation tasks in order to solve the above problems, comprising: a step of executing a control task to wake up the plurality of calculation tasks at a predetermined control cycle; and a step of executing the plurality of calculation tasks that have been woken up at the predetermined control cycle, wherein the plurality of calculation tasks include: a first calculation task for which a first control cycle is set as the control cycle; a second calculation task for which a second control cycle longer than the first control cycle is set as the control cycle and which has a lower priority than the first calculation task, wherein the second calculation task can output calculation results to a communication partner device provided by the plant via the first calculation task, and the control task does not wake up the second calculation task at the first wake-up timing of the second calculation task based on the second control cycle if the previous calculation processing of the second calculation task is not completed.

[0010] According to at least one embodiment of this disclosure, it is possible to provide a plant control device and a plant control method that can prevent a decrease in plant operating rate and production efficiency due to unintended plant behavior caused by erroneous control outputs in plant control.

[0011] This is a schematic diagram showing the overall configuration of a plant control device according to one embodiment. This is a block diagram showing the functional configuration of the arithmetic processing unit in Figure 1. This is a timing chart showing an example of control of the first and second arithmetic tasks by a control task. This is a timing chart showing the case in the control example of Figure 3 where the arithmetic processing of the second arithmetic task takes more time than the second control cycle. This is a flowchart showing the control flow by a control task periodically activated by the control task execution unit in Figure 2. This is a timing chart showing the activation timing of the control task by the control task execution unit in Figure 2 and the execution timing of the arithmetic processing by the first and second arithmetic tasks activated by the control task. This is a flowchart showing the arithmetic processing executed by the first arithmetic task activated in step S101 of Figure 5. This is a flowchart showing the control processing performed by the second arithmetic task Tsk2 activated in step S104 of Figure 5.

[0012] Hereinafter, several embodiments of the present invention will be described with reference to the attached drawings. However, the dimensions, materials, shapes, relative arrangements, etc., of the configurations described or shown in the drawings as embodiments are not intended to limit the scope of the present invention, but are merely illustrative examples.

[0013] Figure 1 is a schematic diagram showing the overall configuration of a plant control device 100 according to one embodiment. The plant control device 100 is a control device that controls a plant 1, such as a power plant. The plant 1 is equipped with numerous field devices, such as an oscillator 2, a switch 3, a control valve 4, and an ON / OFF switching valve 5. The plant control device 100 is composed of an input / output module 15 for inputting and outputting data to and from these field devices, a arithmetic processing unit 20 (DCS: Distributed Control System) that performs calculation processing using the data input and output to and from the field devices, and a communication network 30 for data communication between the input / output module 15 and the arithmetic processing unit 20.

[0014] Figure 2 is a block diagram showing the functional configuration of the arithmetic processing unit 20 in Figure 1. The arithmetic processing unit 20 implements various functions by executing a pre-installed plant control program. The plant control program consists of multiple logic sheets, for example, written in a graphical processing language. These logic sheets are classified into multiple tasks according to the processing content implemented during execution. Figure 2 shows the functional configuration corresponding to each task implemented by the multiple logic sheets.

[0015] Note that the configuration shown in Figure 2 is merely an example; some component blocks may be integrated, some may be subdivided, and other component blocks may be included.

[0016] The arithmetic processing unit 20 includes a control task execution unit 110 for executing a control task Tsk0 and an arithmetic task execution unit 120 for executing an arithmetic task.

[0017] The control task execution unit 110 is configured to execute the control task Tsk0. The control task Tsk0 is a task for controlling the wake-up timing of each calculation task executed by the calculation task execution unit 120, and is a task for controlling the wake-up timing of each calculation task in synchronization with the reference control period T0.

[0018] In this embodiment, the calculation tasks executed by the calculation task execution unit 120 include a first calculation task Tsk1 and a second calculation task Tsk2. The first calculation task Tsk1 is a calculation task having a first control period T1. The second calculation task Tsk2 has a second control period T2 that is longer than the first control period T1, and is a calculation task set to have a lower priority than the first calculation task Tsk1.

[0019] The calculation task execution unit 120 is configured to execute multiple calculation tasks. The multiple calculation tasks include a first calculation task Tsk1 having a first control period T1, and a second calculation task Tsk2 having a second control period T2. The second control period T2 of the second calculation task Tsk2 is set to be longer than the first control period T1 of the first calculation task Tsk1. Also, the second calculation task Tsk2 is set to have a lower priority than the first calculation task Tsk1. In addition, the multiple calculation tasks executed by the calculation task execution unit 120 may include other calculation tasks.

[0020] Figure 2 shows the configuration realized when the first calculation task Tsk1 is executed by the calculation task execution unit 120, which includes an input / output processing unit 122, a data conversion processing unit 124, a data storage area 126 for the first calculation task, a data storage area 128 for the second calculation task, and a first calculation processing unit 130.

[0021] The input / output processing unit 122 is configured to perform various data input and output processing with the communication partner device 10. The input / output processing includes input processing to acquire data input from the communication partner device 10 to the first calculation task Tsk1, and output processing to output data from the first calculation task Tsk1 to the communication partner device 10.

[0022] The data conversion processing unit 124 is configured to perform data conversion processing between the data format handled by the input / output processing unit 122 and the data format handled by each calculation task. This data conversion processing includes data conversion processing between data input / output between the input / output processing unit 122 and the communication partner device 10 (input / output data) and data having a data format handled by the first calculation task Tsk1 (data for the first calculation task), and data conversion processing between data input / output between the input / output processing unit 122 and the communication partner device 10 (input / output data) and data having a data format handled by the second calculation task Tsk2 (data for the second calculation task).

[0023] The data storage area 126 for the first calculation task is configured to store data for the first calculation task. For example, the input data acquired from the communication partner device 10 by the input / output processing unit 122 and converted by the data conversion processing unit 124 to become data for the first calculation task is stored in the data storage area 126 for the first calculation task, making it readable from the first calculation processing unit 130. In addition, the calculation results from the first calculation processing unit 130 are stored in the data storage area 126 for the first calculation task as data for the first calculation task, making them output to the communication partner device 10 from the input / output processing unit 122.

[0024] The data storage area 128 for the second calculation task is configured to store data for the second calculation task that can be input / output to and from the second calculation task Tsk2. The data for the second calculation task stored in the data storage area 128 can be input / output to and from the awakened second calculation task Tsk2. That is, the second calculation task Tsk2 can perform calculation processing using the data for the second calculation task stored in the data storage area 128 and store the calculation result in the data storage area 128 as data for the second calculation task (i.e., the second calculation task Tsk2 does not directly transmit or receive data with the communication partner device 10, but indirectly transmits and receives data with the communication partner device 10 via the first calculation task Tsk1).

[0025] In this embodiment, the data storage area 126 for the first calculation task and the data storage area 128 for the second calculation task are shown as separate areas. However, the data storage area 126 for the first calculation task and the data storage area 128 for the second calculation task may be configured as the same area, provided that the output locations from the first calculation processing unit 130 and the output locations from the second calculation processing unit 132 are separated.

[0026] The first arithmetic processing unit 130 is configured to perform arithmetic processing using multiple logic sheets corresponding to the first arithmetic task Tsk1. Specifically, the first arithmetic processing unit 130 accesses the data storage area 126 for the first arithmetic task to acquire input data from the communication partner device 10 stored as data for the first arithmetic task (more precisely, input data that has been converted by the data conversion processing unit 124), and performs arithmetic processing by inputting this input data into multiple logic sheets corresponding to the first arithmetic task Tsk1. The calculation results from this arithmetic processing are stored in the data storage area 126 for the first arithmetic task as data for the first arithmetic task and can be output to the communication partner device 10 from the input / output processing unit 122.

[0027] Figure 2 also shows a second arithmetic processing unit 132, which is implemented when the second arithmetic task Tsk2 is executed by the arithmetic task execution unit 120. The second arithmetic processing unit 132 is configured to perform arithmetic processing using multiple logic sheets possessed by the second arithmetic task Tsk2. Specifically, the second arithmetic processing unit 132 accesses the data storage area 128 for the second arithmetic task to acquire input data from the communication partner device 10 stored as data for the second arithmetic task (more precisely, input data that has been data-converted by the data conversion processing unit 124), and performs arithmetic processing by inputting this input data into the multiple logic sheets possessed by the second arithmetic task Tsk2. The calculation results from this arithmetic processing are stored in the data storage area 128 for the second arithmetic task as data for the second arithmetic task, making them available for output to the communication partner device 10 from the input / output processing unit 122.

[0028] Next, we will explain a specific example of controlling the wake-up timing of the first calculation task Tsk1 and the second calculation task Tsk2 by the control task Tsk0. Figure 3 is a timing chart showing an example of controlling the first calculation task Tsk1 and the second calculation task Tsk2 by the control task Tsk0. In Figure 3, the first calculation task Tsk1 and the second calculation task Tsk2 are woken up in accordance with their priority, at the first control period T1 and the second control period T2, respectively, in synchronization with the control pulse signal Sp generated by the control task Tsk0 in accordance with the reference control period T0.

[0029] In Figure 3, as an example, the case where the reference control period T0 is 10 msec, the first control period T1 is equal to the reference control period T0 (10 msec), and the second control period T2 is 100 msec is shown, but this is merely an example and is not limited to this case.

[0030] The control task Tsk0 performs wake-up processing for each task at each reference control cycle T0, based on the initial time t. For example, at the initial time t, the first calculation task Tsk1, which has a higher priority, is woken up first, and calculation processing is performed by the first calculation task Tsk1. Since the time required for calculation processing by the first calculation task Tsk1 is shorter than the first control cycle T1, the calculation processing by the first calculation task Tsk1 is completed before time t+10, which corresponds to the next first control cycle T1, is reached. Therefore, once the calculation processing of the first calculation task Tsk1 is completed, the second calculation task Tsk2, which has a lower priority, is executed before time t+10. Here, the calculation processing of the second calculation task Tsk2 takes longer than the remaining time until time t+10, so when time t+10, which corresponds to the next reference control cycle T0, is reached, the calculation processing of the second calculation task Tsk2 is temporarily interrupted, and the first calculation task Tsk1, which has a higher priority, is executed again. Once the calculation process of the first calculation task Tsk1 is completed, the calculation process of the second calculation task Tsk2, which had been interrupted, is resumed.

[0031] Thus, in each reference control cycle T0, the second calculation task Tsk2 proceeds with its calculations during the remaining period after the first calculation task Tsk1, which has a higher priority, has completed, and is basically completed before reaching the time t+100 corresponding to the next second control cycle T2. In this case, at the next wake-up timing of the second calculation task Tsk2 (time t+100), the previous calculation processing of the second calculation task Tsk2 has already been completed, so the data output from the first calculation task Tsk1 to the communication partner device 10 includes the calculation results of the second calculation task Tsk2 within a single second control cycle T2, and therefore there is no problem.

[0032] Thus, the calculations performed by the second calculation task Tsk2 are basically designed to be completed within the second control cycle T2 of the second calculation task Tsk2. However, if calculations such as convergence calculations are performed in the second calculation task Tsk2, depending on the convergence state of the calculation results, the calculations may take longer than expected, and it may not be possible to complete them within the second control cycle T2.

[0033] Figure 4 is a timing chart showing the case in the control example of Figure 3 where the calculation processing of the second calculation task Tsk2 takes more time than the second control cycle T2. In this control example, the calculation processing of the second calculation task Tsk2 cannot be completed within the second control cycle T2 up to time t+100, and extends into the next second control cycle T2 after time t+100. Then, in the next second control cycle T2 after time t+100, the second calculation task Tsk2 corresponding to the next second control cycle T2 is started immediately after the previous calculation processing is completed. Therefore, focusing on the period from time t+100 to t+110, within a single second control cycle T2, the calculation result corresponding to the previous second control cycle T2 and the calculation result corresponding to the next second control cycle T2 are mixed. If such mixed data is output to the communication partner device 10, it may lead to unintended plant behavior in plant control. This problem can be suitably resolved by the embodiment shown below.

[0034] In this embodiment, in the control task Tsk0 executed by the control task execution unit 110, the previous calculation processing incomplete flag F1 and the task delay wake-up flag F2 can be set in order to suitably control the wake-up timing of the first calculation task Tsk1 and the second calculation task Tsk2.

[0035] The previous calculation incomplete flag F1 indicates whether the calculation process corresponding to the previous second control cycle T2 (previous calculation process) of the second calculation task Tsk2 is incomplete at the wake-up timing corresponding to the second control cycle T2. Specifically, if the previous calculation process of the second calculation task Tsk2 is incomplete at that timing, the previous calculation incomplete flag F1 is set to the ON state, and if the previous calculation process of the second calculation task Tsk2 is completed at that timing, the previous calculation incomplete flag F1 is set to the OFF state.

[0036] The task delay wake-up flag F2 indicates whether the wake-up timing of the second calculation task Tsk2 is delayed compared to the wake-up timing corresponding to the second control cycle T2. Specifically, if the wake-up timing of the second calculation task Tsk2 is delayed, the task delay wake-up flag F2 is set to ON, and if the wake-up timing of the second calculation task Tsk2 is not delayed (i.e., it coincides with the second control cycle T2), the task delay wake-up flag F2 is set to OFF.

[0037] Figure 5 is a flowchart showing the control flow by the control task Tsk0 which is periodically awakened by the control task execution unit 110 in Figure 2, and Figure 6 is a timing chart showing the awakening timing of the control task Tsk0 by the control task execution unit 110 in Figure 2, and the timing of the execution of calculation processing by the first calculation task Tsk1 and the second calculation task Tsk2 which are awakened by the control task Tsk0. Hereafter, we will explain assuming that the initial state of the previous calculation processing incomplete flag F1 and the task delay awakening flag F2 are both in the OFF state.

[0038] First, when the control task execution unit 110 wakes up the control task Tsk0 (step S100), if it is time for the first calculation task Tsk1 to wake up (step S101: YES), the control task Tsk0 wakes up the first calculation task Tsk1 (step S102). After the processing by the control task Tsk0, which has the highest priority (a series of processes shown in Figure 5), is completed, the first calculation task Tsk1 performs the calculation processing corresponding to the first calculation task Tsk1. The specific details of the calculation processing in the first calculation task Tsk1 will be described later with reference to Figure 7.

[0039] Next, once the wake-up process for the first calculation task Tsk1 in step S102 is complete, the control task Tsk0 determines whether it is time for the wake-up of the second calculation task Tsk2, which has a lower priority than the first calculation task Tsk1 (step S103). If it is time for the wake-up of the second calculation task Tsk2 (step S103: YES), the control task Tsk0 further determines whether the previous calculation process of the second calculation task Tsk2 has been completed (step S104). As mentioned above, the second calculation task Tsk2 performs, for example, a convergence calculation process, but if it takes longer than expected for the calculation result to converge, the previous calculation process may not be completed by the next wake-up time for the second calculation task Tsk2 (hereinafter referred to as the "first wake-up time" as appropriate). At the first wake-up timing of the second calculation task Tsk2, if the previous calculation process of the second calculation task Tsk2 has been completed (step S104: YES), the control task Tsk0 wakes up the second calculation task Tsk2 as usual (step S105) and puts the control task Tsk0 into sleep mode (step S106).

[0040] On the other hand, if the previous calculation process of the second calculation task Tsk2 has not been completed at the first wake-up timing of the second calculation task Tsk2 (step S104: NO), the control task Tsk0 sets the task delay wake-up flag F2, which was initially OFF, to ON (step S107), and puts the control task Tsk0 into sleep mode (step S106), thereby not waking up the second calculation task Tsk2. In this way, if the previous calculation process of the second calculation task Tsk2 has not been completed at the first wake-up timing, the second calculation task Tsk2 corresponding to the next second control cycle T2 will not be woken up, but will be held in abeyance (i.e., its wake-up will be delayed).

[0041] In the control example shown in Figure 6, the calculation process of the second calculation task Tsk2 corresponding to the previous second control cycle T2 up to time t+100 extends beyond time t+100 and is not completed at the first wake-up timing of time t+100. Therefore, at time t+100, which is the first wake-up timing of the second calculation task Tsk2 corresponding to the next second control cycle T2, the next second calculation task Tsk2 is not woken up.

[0042] Such a control task Tsk0 is repeatedly executed by being periodically woken up by the control task execution unit 110. The previous calculation processing of the second calculation task Tsk2, which was incomplete at the first wake-up timing, will eventually be completed as time passes, and the flag indicating that the previous calculation processing was incomplete will be switched from the ON state to the OFF state. When the flag indicating that the previous calculation processing was incomplete is switched to the OFF state (step S108: YES), and it is also the wake-up timing for the first calculation task Tsk1 (step S109: YES), the second calculation task Tsk2 is woken up (step S105). The wake-up timing for the second calculation task Tsk2 is controlled to be after the completion of the previous calculation processing of the second calculation task Tsk2, and before the second wake-up timing following the first wake-up timing based on the second control cycle T2 (i.e., time t+200). Preferably, the wake-up timing of the second calculation task Tsk2 is after the completion of the previous calculation process of the second calculation task Tsk2, and is controlled to the earliest timing corresponding to the first control cycle T1. In the control example in Figure 6, since the previous calculation process of the second calculation task Tsk2 is completed between time t+100 and time t+110, the second calculation task Tsk2 corresponding to the next second control cycle T2 is woken up in synchronization with the wake-up timing of the next first calculation task Tsk1 at the time of completion (time t+110).

[0043] Thus, in this embodiment, if the previous calculation process of the second calculation task Tsk2 is not completed at the first wake-up timing (time t+100), the wake-up timing is delayed until time t+110, rather than waking up the next second calculation task Tsk2 immediately after the previous calculation process, as shown in the control example in Figure 4. This prevents the mixing of calculation results of second calculation tasks Tsk2 corresponding to different second control periods T2 within a single first control period T1 (times t+100 to t+110). As a result, it is possible to effectively prevent the communication partner device 10 from causing unintended plant behavior by performing plant control based on mixed data.

[0044] Next, the specific content of the arithmetic processing executed by the first arithmetic task Tsk1 that is woken up in step S101 described above will be described. FIG. 7 is a flowchart showing the arithmetic processing executed by the first arithmetic task Tsk1 that is woken up in step S101 of FIG. 5.

[0045] When the first arithmetic task Tsk1 is woken up by the control task Tsk0 (step S200), in the first arithmetic task Tsk1, first, input processing is performed by the input / output processing unit 122, and input data from the communication partner device 10 is acquired (step S201).

[0046] Subsequently, the data conversion processing unit 124 converts the input data from the communication partner device 10 acquired in the input processing of step S201 into data for the first arithmetic task (step S202). That is, input data having an arbitrary data format is converted into data for the first arithmetic task having a data format suitable for the arithmetic processing in the first arithmetic task Tsk1. The data for the first arithmetic task converted in step S201 is stored in a readable manner in the data storage area 126 for the first arithmetic task.

[0047] Subsequently, when it is the wake-up timing of the second arithmetic task Tsk2 (step S203: YES), and when the previous arithmetic processing of the second arithmetic task Tsk2 has been completed (step S204: YES), the data conversion processing unit 124 converts the input data from the communication partner device 1 ten acquired in the input processing of step S200 into data for the second arithmetic task (step S205). That is, input data having a specified data format is converted into data for the second arithmetic task having a data format suitable for the arithmetic processing in the second arithmetic task Tsk2. The data for the second arithmetic task converted in step S205 is stored in a readable manner in the data storage area 128 for the second arithmetic task. Thereby, when the previous arithmetic processing of the second arithmetic task Tsk2 has been completed at the wake-up timing of the second arithmetic task Tsk2, as usual, new input data from the communication partner device 10 in step S200 is reflected in the data for the second arithmetic task, and the second arithmetic task Tsk2 performs arithmetic processing corresponding to the next second control cycle T2.

[0048] On the other hand, even if it is the wake-up timing of the second arithmetic task Tsk2 (step S203: YES), if the previous arithmetic processing of the second arithmetic task Tsk2 has not been completed (step S204: NO), step S205 is not executed. In this case, the data for the second arithmetic task stored in the data storage area 128 for the second arithmetic task is not updated and remains in the state corresponding to the previous second control cycle T2. As a result, when the previous arithmetic processing of the second arithmetic task Tsk2 is not completed at the wake-up timing of the second arithmetic task Tsk2, by not reflecting the new input data from the communication partner device 10 in the data for the second arithmetic task in step S201, it is possible to prevent the mixing of the previous arithmetic processing result and the next arithmetic processing result in the second arithmetic task Tsk2.

[0049] Also, when it is not the wake-up timing of the second arithmetic task Tsk2 (step S203: NO), if the previous arithmetic processing incomplete flag F1 is in the OFF state and the task delayed wake-up flag F2 is in the ON state (step S206: YES), step S205 is executed. As described above, when the previous arithmetic processing of the second arithmetic task Tsk2 has not been completed at the wake-up timing of the second arithmetic task Tsk2, the second arithmetic task Tsk2 is not woken up at the wake-up timing of the second arithmetic task Tsk2, the previous arithmetic processing incomplete flag F1 is set to the ON state, and the task delayed wake-up flag F2 is set to the ON state. After that, when the previous arithmetic processing of the second arithmetic task Tsk2 is completed, the previous arithmetic processing incomplete flag F1 is in the OFF state and the task delayed wake-up flag F2 is in the ON state. In this case, by executing step S205, by performing data conversion processing on the input data from the communication partner device 10 in step S201 to the data for the second arithmetic task, the data storage area 128 for the second arithmetic task is updated, and the arithmetic processing of the second arithmetic task Tsk2 corresponding to the next second control cycle T2 is made possible (that is, the wake-up of the second arithmetic task Tsk2 corresponding to the next second control cycle T2 for which the wake-up has been postponed is permitted).

[0050] Next, the first arithmetic processing unit 130 performs arithmetic processing based on the multiple logic sheets of the first arithmetic task Tsk1 (step S207). Specifically, the first arithmetic processing unit 130 accesses the data storage area 126 for the first arithmetic task to obtain the data for the first arithmetic task converted in step S201, and performs arithmetic processing by inputting the data for the first arithmetic task into each logic sheet.

[0051] The calculation result in step S207 is output to the communication partner device 10 by output processing by the input / output processing unit 122 (step S208). In this embodiment, the calculation result by the first calculation processing unit 130 is temporarily stored in the first calculation task data storage area 126, converted into a data format suitable for the communication partner device 10 by the data conversion processing unit 124, and then output to the communication partner device 10 from the input / output processing unit 122.

[0052] Once this series of processes is complete, the first arithmetic task Tsk1 is returned to a dormant state (step S209) and becomes ready to be woken up again by the control task Tsk0.

[0053] Next, we will explain the specific details of the control processing performed by the second calculation task Tsk2, which was activated in step S104 as described above. Figure 8 is a flowchart showing the control processing performed by the second calculation task Tsk2, which was activated in step S104 of Figure 5.

[0054] First, when the second calculation task Tsk2 is woken up (step S300), it is determined whether the task delay wake-up flag F2 was ON at the previous wake-up timing of the second calculation task Tsk2 (step S301). If the task delay wake-up flag was ON at the previous wake-up timing of the second calculation task Tsk2 (step S301: YES), the task delay wake-up flag F2 is set to OFF (step S302). In other words, if the wake-up of the second calculation task Tsk2 was delayed at the previous wake-up timing of the second calculation task Tsk2, the delay is resolved by the current wake-up of the second calculation task Tsk2, and the task delay wake-up flag is switched to OFF.

[0055] Furthermore, if the task delay wake-up flag F2 was OFF at the previous wake-up timing of the second calculation task Tsk2 (step S301: NO), step S302 is omitted.

[0056] Next, the second calculation task Tsk2 determines whether the task delay wake-up flag F2 is in the ON state (step S303). If the task delay wake-up flag F2 is in the ON state (step S303: YES), that is, if the wake-up of the second calculation task Tsk2 is delayed, the second calculation task immediately goes into sleep mode (step S308). On the other hand, if the task delay wake-up flag is in the OFF state (step S303: NO), the second calculation task Tsk2 sets the previously incomplete calculation flag to the ON state (step S304). Subsequently, the second calculation processing unit 132 performs calculation processing based on the multiple logic sheets possessed by the second calculation task Tsk2 (step S305). Specifically, the second calculation processing unit 132 accesses the data storage area 128 for the second calculation task to obtain the data for the second calculation task stored in the data storage area 128 for the second calculation task, and performs calculation processing by inputting the data for the second calculation task into each logic sheet. Once the calculation process is complete, the flag indicating that the previous calculation process was incomplete is set to the OFF state (step S306).

[0057] Furthermore, the calculation result in step S305 is stored in the second calculation task data storage area 128 as data for the second calculation task, and can be output to the communication partner device 10 by output processing by the input / output processing unit 122. In other words, the calculation result of the second calculation task Tsk2 is output to the communication partner device 10 via the first calculation task Tsk1.

[0058] Once this series of processes is complete, the task delay wake-up flag from the previous wake-up is updated (step S307), the second calculation task Tsk2 is returned to a sleep state (step S308), and becomes ready to be woken up again by the control task Tsk0.

[0059] As described above, according to the above embodiment, if the previous calculation processing of the second calculation task Tsk2 has not been completed at the first wake-up timing of the second calculation task Tsk2 based on the second control cycle T2, the second calculation task Tsk2 corresponding to the next second control cycle T2 will not be woken up at that first wake-up timing. This effectively prevents the calculation processing results output to the communication partner device 10 for each first control cycle T1 from being mixed with the calculation processing results of the second calculation task Tsk2 corresponding to the previous second control cycle T2 and the calculation processing results of the second calculation task Tsk2 corresponding to the next second control cycle T2.

[0060] This disclosure is not limited to the embodiments described above, but also includes modified forms of the embodiments described above, as well as forms that combine these forms as appropriate.

[0061] The contents described in each of the above embodiments can be understood, for example, as follows:

[0062] (1) A plant control device according to one embodiment is a plant control device for controlling a plant based on the calculation results of a plurality of calculation tasks, comprising: a control task execution unit for executing a control task to wake up the plurality of calculation tasks at a predetermined control cycle; and a calculation task execution unit for executing the plurality of calculation tasks that have been woken up at the predetermined control cycle, wherein the plurality of calculation tasks include: a first calculation task for which a first control cycle is set as the control cycle; a second calculation task for which a second control cycle longer than the first control cycle is set as the control cycle and which has a lower priority than the first calculation task, wherein the second calculation task can output calculation results to a communication partner device provided by the plant via the first calculation task, and the control task does not wake up the second calculation task at the first wake-up timing of the second calculation task based on the second control cycle if the previous calculation processing of the second calculation task is not completed.

[0063] According to the embodiment of (1) above, if the previous calculation processing of the second calculation task has not been completed at the first wake-up timing of the second calculation task based on the second control cycle, the second calculation task corresponding to the next second control cycle will not be woken up at that first wake-up timing. This effectively prevents the calculation processing results output to the communication partner device for each first control cycle from being mixed with the calculation processing results of the second calculation task corresponding to the previous second control cycle and the calculation processing results of the second calculation task corresponding to the next second control cycle.

[0064] (2) In another embodiment, in the embodiment of (1) above, if the previous calculation process is not completed at the first wake-up timing, the control task wakes up the second calculation task after the previous calculation process of the second calculation task is completed and before the second wake-up timing following the first wake-up timing based on the second control cycle.

[0065] According to the embodiment of (2) above, if the previous calculation processing of the second calculation task has not been completed at the first wake-up timing of the second calculation task based on the second control cycle, the second calculation task corresponding to the next second control cycle that was not woken up at the first wake-up timing will wake up after the completion of the previous calculation processing of the second calculation task and before the second wake-up timing following the first wake-up timing.

[0066] (3) In another embodiment, in the embodiment of (2) above, the second calculation task is woken up at the earliest timing corresponding to the first control cycle, after the completion of the previous calculation process of the second calculation task.

[0067] According to the embodiment of (3) above, if the previous calculation processing of the second calculation task has not been completed at the first wake-up timing of the second calculation task based on the second control cycle, the second calculation task corresponding to the next second control cycle that was not woken up at the first wake-up timing will wake up at the earliest timing corresponding to the first control cycle, after the previous calculation processing of the second calculation task has been completed. This prevents the mixing of calculation processing results of second calculation tasks corresponding to different calculation cycles as described above, while suppressing the delay amount of the second calculation task that was not woken up at the first wake-up timing.

[0068] (4) In other embodiments, in any one embodiment of (1) to (3) above, the control task controls the wake-up timing of the second calculation task based on a previous calculation incomplete flag set based on the completion status of the previous calculation process, and a task delayed wake-up flag set based on the delay state of the wake-up timing of the second calculation task relative to the first wake-up timing.

[0069] According to the embodiment of (4) above, the control task determines the completion status of the previous calculation process of the second calculation task at the first wake-up timing, and the delay status of the second calculation task relative to the first wake-up timing, based on the settings of the previous calculation process incomplete flag and the task delay wake-up flag. Then, by controlling the wake-up timing of the second calculation task based on the determination result, it is possible to effectively prevent the calculation processing result of the second calculation task corresponding to the previous second control cycle and the calculation processing result of the second calculation task corresponding to the next second control cycle from being mixed in the calculation processing result output to the communication partner device for each first control cycle.

[0070] (5) In another embodiment, in the embodiment of (4) above, if the previous calculation processing incomplete flag and the task delay wake-up flag are both set to the ON state, the control task does not wake up the second calculation task at the first wake-up timing, and thereafter, if the previous calculation processing incomplete flag is set to the OFF state, the control task wakes up the second calculation task.

[0071] According to the embodiment of (5) above, when both the "previous calculation incomplete flag" and the "task delayed wake-up flag" are set to the ON state, it is determined that the second calculation task is not woken up at the first wake-up timing, and the wake-up timing of the second calculation task is delayed relative to the first wake-up timing. From this state, when the "previous calculation incomplete flag" is set to the OFF state, it is determined that the previous calculation processing of the second calculation task, which was incomplete, has been completed, and the second calculation task can be suitably woken up at the aforementioned timing.

[0072] (6) In other embodiments, in any one embodiment of (1) to (5) above, the first arithmetic task comprises: an input / output processing unit for performing data input / output processing with the communication partner device; a data conversion processing unit for performing data conversion processing between the data input / output by the input / output processing unit and first arithmetic task data suitable for the first arithmetic task and second arithmetic task data suitable for the second arithmetic task; a first arithmetic task data storage area for storing the first arithmetic task data; a second arithmetic task data storage area for storing the second arithmetic task data; and a first arithmetic processing unit for performing arithmetic processing using the first arithmetic task data stored in the first arithmetic task data storage area. The second arithmetic task comprises a second arithmetic processing unit for performing arithmetic processing using the second arithmetic task data stored in the second arithmetic task data storage area.

[0073] According to the embodiment of (6) above, the data input and output to and from the communication partner device is converted into data for the first calculation task and data for the second calculation task, each having a data format suitable for the first calculation task and the second calculation task, respectively, and stored in the memory area. The first calculation task and the second calculation task perform calculation processing using the data for the first calculation task and the data for the second calculation task by accessing these memory areas.

[0074] (7) In another embodiment, in the embodiment of (6) above, if the previous calculation process is not completed at the first wake-up timing, the first calculation task does not update the data for the second calculation task stored in the data storage unit for the second calculation task at the first wake-up timing.

[0075] According to the embodiment of (7) above, if the previous calculation processing of the second calculation task is not completed at the first wake-up timing, the data for the second calculation task stored in the data storage area for the second calculation task is not updated, thereby effectively preventing the mixing of the calculation processing result of the second calculation task corresponding to the previous second control cycle and the calculation processing result of the second calculation task corresponding to the next second control cycle.

[0076] (8) In other embodiments, in any one embodiment of (1) to (7) above, the second arithmetic task performs a convergence arithmetic process.

[0077] According to the embodiment of (8) above, in the second calculation task in which convergence calculation processing is performed, if the previous calculation processing is not completed due to factors such as the calculation result performed by the second calculation task not converging at the first wake-up timing, the second calculation task will not wake up at the first wake-up timing. This effectively prevents the calculation processing result output to the communication partner device for each first control cycle from being mixed with the calculation processing result of the second calculation task corresponding to the previous second control cycle and the calculation processing result of the second calculation task corresponding to the next second control cycle.

[0078] (9) In other embodiments, in any one embodiment of (1) to (8) above, the plurality of calculation tasks include a plurality of logic sheets written in a graphic processing language.

[0079] According to the embodiment of (9) above, in a plant control device that controls a plant based on the calculation results of multiple calculation tasks including multiple logic sheets written in a graphic processing language, it is possible to suitably prevent the calculation processing results output to the communication partner device for each first control cycle from being mixed with the calculation processing results of the second calculation task corresponding to the previous second control cycle and the calculation processing results of the second calculation task corresponding to the next second control cycle.

[0080] (10) A plant control method according to one embodiment is a plant control method for controlling a plant based on the calculation results of a plurality of calculation tasks, comprising: a step of executing a control task to wake up the plurality of calculation tasks at a predetermined control cycle; and a step of executing the plurality of calculation tasks that have been woken up at the predetermined control cycle, wherein the plurality of calculation tasks include: a first calculation task for which a first control cycle is set as the control cycle; a second calculation task for which a second control cycle longer than the first control cycle is set as the control cycle and which has a lower priority than the first calculation task, wherein the second calculation task can output calculation results to a communication partner device provided by the plant via the first calculation task, and the control task does not wake up the second calculation task at the first wake-up timing of the second calculation task based on the second control cycle if the previous calculation processing of the second calculation task is not completed.

[0081] According to the embodiment of (10) above, if the previous calculation processing of the second calculation task has not been completed at the first wake-up timing of the second calculation task based on the second control cycle, the second calculation task corresponding to the next second control cycle will not be woken up at that first wake-up timing. This effectively prevents the calculation processing results output to the communication partner device for each first control cycle from being mixed with the calculation processing results of the second calculation task corresponding to the previous second control cycle and the calculation processing results of the second calculation task corresponding to the next second control cycle.

[0082] 1 Plant 2 Oscillator 3 Switch 4 Control valve 10 Communication partner equipment 15 Input / output module 20 Arithmetic processing unit 30 Communication network 100 Plant control device 110 Control task execution unit 120 Arithmetic task execution unit 122 Input / output processing unit 124 Data conversion processing unit 126 Data storage area for first arithmetic task 128 Data storage area for second arithmetic task 130 First arithmetic processing unit 132 Second arithmetic processing unit F1 Flag indicating previous arithmetic processing was not completed F2 Flag indicating task delay wake-up T0 Reference control cycle T1 First control cycle T2 Second control cycle Tsk0 Control task Tsk1 First arithmetic task Tsk2 Second arithmetic task

Claims

1. A plant control device for controlling a plant based on the calculation results of a plurality of calculation tasks, comprising: a control task execution unit for executing a control task to wake up the plurality of calculation tasks at a predetermined control cycle; and a calculation task execution unit for executing the plurality of calculation tasks that have been woken up at the predetermined control cycle, wherein the plurality of calculation tasks include: a first calculation task for which a first control cycle is set as the control cycle; a second calculation task for which a second control cycle longer than the first control cycle is set as the control cycle and which has a lower priority than the first calculation task, wherein the second calculation task can output calculation results to a communication partner device provided by the plant via the first calculation task, and the control task does not wake up the second calculation task at the first wake-up timing if the previous calculation processing of the second calculation task is incomplete at the first wake-up timing based on the second control cycle.

2. The plant control device according to claim 1, wherein if the previous calculation process is not completed at the first wake-up timing, the control task wakes up the second calculation task after the previous calculation process of the second calculation task is completed and before the second wake-up timing following the first wake-up timing based on the second control cycle.

3. The plant control device according to claim 2, wherein the second calculation task is activated after the completion of the previous calculation process of the second calculation task and at the earliest timing corresponding to the first control cycle.

4. The plant control device according to claim 1 or 2, wherein the control task controls the wake-up timing of the second calculation task based on a previous calculation processing incomplete flag set based on the completion status of the previous calculation processing, and a task delay wake-up flag set based on the delay state of the wake-up timing of the second calculation task relative to the first wake-up timing.

5. The plant control device according to claim 4, wherein if the previous calculation processing incomplete flag and the task delay wake-up flag are both set to the ON state, the control task does not wake up the second calculation task at the first wake-up timing, and thereafter, if the previous calculation processing incomplete flag is set to the OFF state, the control task wakes up the second calculation task.

6. The plant control device according to claim 1 or 2, wherein the first calculation task comprises an input / output processing unit for performing data input / output processing with the communication partner device; a data conversion processing unit for performing data conversion processing between the data input / output by the input / output processing unit and first calculation task data suitable for the first calculation task and second calculation task data suitable for the second calculation task; a first calculation task data storage area for storing the first calculation task data; a second calculation task data storage area for storing the second calculation task data; and a first calculation processing unit for performing calculation processing using the first calculation task data stored in the first calculation task data storage area, and the second calculation task comprises a second calculation processing unit for performing calculation processing using the second calculation task data stored in the second calculation task data storage area.

7. If the previous calculation process is not completed at the first wake-up timing, the first calculation task does not update the data for the second calculation task stored in the data storage unit for the second calculation task at the first wake-up timing, as described in claim 6.

8. The plant control device according to claim 1 or 2, wherein a convergence calculation process is performed in the second calculation task.

9. The plant control device according to claim 1 or 2, wherein the plurality of calculation tasks include a plurality of logic sheets written in a graphic processing language.

10. A plant control method for controlling a plant based on the calculation results of a plurality of calculation tasks, comprising: a step of executing a control task to wake up the plurality of calculation tasks at a predetermined control cycle; and a step of executing the plurality of calculation tasks that have been woken up at the predetermined control cycle, wherein the plurality of calculation tasks include: a first calculation task for which a first control cycle is set as the control cycle; a second calculation task for which a second control cycle longer than the first control cycle is set as the control cycle and which has a lower priority than the first calculation task, wherein the second calculation task can output calculation results to a communication partner device provided by the plant via the first calculation task, and the control task does not wake up the second calculation task at the first wake-up timing if the previous calculation processing of the second calculation task is incomplete at the first wake-up timing based on the second control cycle.