Process control system, process control device, and program update method

By acquiring and restoring the inherited data of the current device in the update device, and determining the switching time at the switching time, the problem of online system update in the prior art is solved, and the function expansion of the process control system and the continuity of the system functions are realized.

CN115145228BActive Publication Date: 2025-07-22YOKOGAWA ELECTRIC CORP
View PDF 3 Cites 0 Cited by

Patent Information

Application Number
CN202210318987.6
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Priority Date
2021-03-30
Filing Date
2022-03-29
Publication Date
2025-07-22
Estimated Expiration
2042-03-29

AI Technical Summary

Technical Problem

The prior art cannot embed the online update function in the current device in the operating state, resulting in the process control system being unable to expand the function without stopping.

Method used

By acquiring inherited data of the current device in the update device and restoring it during switching, the timing decision unit determines the switching timing to realize online system update.

Benefits of technology

It realizes the function expansion of online system updates without stopping the process control system, ensuring the continuity and stability of system functions.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN115145228B_ABST
    Figure CN115145228B_ABST
Patent Text Reader

Abstract

A process control system according to one aspect of the present invention includes a first process control device and a second process control device. The second process control device includes: a data inheritance unit that acquires inheritance data, which is data that needs to be inherited in order to continue system functions when switching from the first process control device to the second process control device, from the first process control device and restores it in the second process control device; and a timing determination unit that determines the timing of the switching.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to a process control system, a process control device, and a program update method. Background Art

[0002] Currently, in workshops, factories, etc. (hereinafter, when collectively referring to them, simply referred to as "workshops"), a process control system that controls various state quantities (such as pressure, temperature, flow rate, etc.) of an industrial process is constructed, and a high level of automatic operation is achieved.

[0003] In such a process control system, sometimes it is necessary to replace hardware or improve software. As an improvement of software, for example, functional expansion of an operating system (OS), correction of defects and weaknesses in the operating system, etc. can be cited.

[0004] Japanese Patent Application Laid-Open No. 2020-52668 (hereinafter, referred to as "Patent Document 1") discloses the following invention: in a process control system having dualized process control devices (a current device and an update device), it is possible to update an update target program simply and in a short time while the process control system continues to execute operations. Specifically, in the current device, a non-update target program that is not an update target is temporarily stopped, and only the context of the non-update target program is transmitted from the current device to the update device. In the update device, the context of the non-update target program is restored using the transmitted context, the context of the update target program is initialized, and the non-update target program and the update target program are restarted for execution using the update device.

[0005] In order to update a system program using the invention disclosed in Patent Document 1, it is necessary to embed functions required to implement online system update (hereinafter, referred to as "online update functions") in both the current device and the update device. "Online system update" means updating a system program while continuously processing functions (system functions) implemented by the system program.

[0006] However, the above-mentioned online update functions can be easily embedded in the update device in a waiting state, but cannot be embedded in the current device in an operating state. Therefore, there is a problem that in order to embed the above-mentioned online update functions in the current device, it is necessary to temporarily stop the current device. Summary of the Invention

[0007] An object of one aspect of the present invention is to provide a process control system, a process control device, and a program update method that can expand the function of online system update without stopping the process control system.

[0008] In order to solve the above problems, a process control system according to one aspect of the present invention is a process control system (1) having a first process control device (10) and a second process control device (20). The second process control device includes: a data inheritance unit (24b) that acquires inheritance data (DT), which is data that needs to be inherited in order to continue system functions when switching from the first process control device to the second process control device, from the first process control device and restores it in the second process control device; and a timing determination unit (24c, 24f) that determines the timing of the switching.

[0009] In the process control system according to one aspect of the present invention, it can be configured such that the data inheritance unit acquires the inheritance data from the first process control device with reference to a symbol table (TB1) of the system functions of the first process control device.

[0010] In the process control system according to one aspect of the present invention, it can be configured such that the timing determination unit determines the timing in such a manner that the switching is performed after confirming a completed state in which all the system functions of the first process control device have ended processing.

[0011] In the process control system according to one aspect of the present invention, it can be configured such that the timing determination unit aborts the switching when the completed state cannot be confirmed.

[0012] The process control system according to one aspect of the present invention can be configured to further include an address conversion unit (24e). When the inheritance data is an address value of a variable stored in an address variable region where the address may change, the address conversion unit (24e) uses an address conversion table (TB2) that associates the address of the variable stored in the address variable region before the switching and the address of the variable stored in the address variable region after the switching to convert the address value as the inheritance data.

[0013] In the process control system according to one aspect of the present invention, it can be configured such that the address conversion table is pre-generated using the symbol table of the system functions of the first process control device and the symbol table of the system functions of the second process control device.

[0014] In the process control system according to one aspect of the present invention, it can be configured such that the first process control device has a buffer operation unit (14a), and the buffer operation unit (14a) operates on a buffer that is temporarily held in a state where data used internally cannot be referenced from the second process control device. When determining the timing, the timing determination unit performs an operation on the buffer operation unit so that the data held in the buffer can be referenced from the second process control device.

[0015] In the process control system according to one aspect of the present invention, the timing determination unit can perform an operation on the first process control device to make the buffer valid or invalid.

[0016] In the process control system according to one aspect of the present invention, it can be configured such that the symbol table (TB1) is a table generated by compiling and linking a system program that implements the system functions of the first process control device.

[0017] In the process control system according to one aspect of the present invention, it can be configured such that the data inheritance unit (24b) refers to the symbol table (TB1) to obtain the address where the inheritance data (DT) is stored in the first process control device.

[0018] In the process control system according to one aspect of the present invention, it can be configured such that the timing is a timing that is a predetermined time earlier than the timing of the start of the next control cycle during the period from the end of the processing that should be executed in a certain control cycle of the first process control device until the start of the next control cycle.

[0019] In the process control system according to one aspect of the present invention, it can be configured such that the predetermined time is the sum of the time required for the timing determination unit (24c, 24f) to confirm the completion state of the first process control device and the time required for the data inheritance unit to acquire the inheritance data from the first process control device and restore it in the second process control device.

[0020] In the process control system according to one aspect of the present invention, it can be configured such that the address change area is composed of one or more consecutive address areas, and each area is managed according to the head address and size.

[0021] A process control device according to one aspect of the present invention is a process control device (20) that performs a switch from another device to this device, and includes: a data inheritance unit (24b) that acquires, from the other device, inheritance data which is data required to continue system functions during the switch and restores it in this device; and a timing determination unit (24c, 24f) that determines the timing of performing the switch.

[0022] A program update method according to one aspect of the present invention is a program update method for a process control system (1) having a first process control device (10) and a second process control device (20), and includes the following steps: a data inheritance step (S14) in which the second process control device acquires, from the first process control device, inheritance data (DT) which is data required to continue system functions during a switch from the first process control device to the second process control device and restores it in the second process control device; and a timing determination step (S13) in which the second process control device determines the timing of performing the switch.

[0023] Effects of the Invention

[0024] According to the present invention, it is possible to expand the function of online system update without stopping the process control system. BRIEF DESCRIPTION OF THE DRAWINGS

[0025] Figure 1 It is a functional block diagram showing a schematic functional configuration of a process control system according to a first embodiment of the present invention.

[0026] Figure 2 It is a functional block diagram showing a functional configuration for implementing online system update in the first embodiment of the present invention.

[0027] Figure 3 It is a flowchart showing a program update method according to a first embodiment of the present invention.

[0028] Figure 4 It shows Figure 3 Details of the processing of step S13 in.

[0029] Figure 5 It shows Figure 3 Details of the processing of step S14 in.

[0030] Figure 6 It is a functional block diagram showing a functional configuration for implementing online system update in the second embodiment of the present invention.

[0031] Figure 7AThis is a diagram showing an example of the address translation table in the second embodiment of the present invention.

[0032] Figure 7B This is a diagram showing an example of external variables.

[0033] Figure 8 This is a flowchart showing the address translation process executed in the second embodiment of the present invention.

[0034] Figure 9A This is a diagram showing an example of the corrected address translation table in the second embodiment of the present invention.

[0035] Figure 9B This is a diagram showing an example of external variables.

[0036] Figure 10 This is a functional block diagram showing the functional structure for implementing online system update in the third embodiment of the present invention. Detailed Embodiment

[0037] Hereinafter, the process control system, process control device, and program update method according to the embodiments of the present invention will be described in detail with reference to the accompanying drawings. First, the outline of the embodiments of the present invention will be described, and then each embodiment will be described in detail.

[0038] [Outline]

[0039] The embodiments of the present invention expand the function of online system update without stopping the process control system. Regarding the process control system, since most of them require long-term continuous operation in units of months to years even for slightly improving production efficiency, it is impossible to freely stop the process control system in the operating state. For example, except for the stops related to regular maintenance or shutdowns for ensuring the safety of the workshop, it is basically not allowed to stop the process control system. The reason is as follows. Taking a chemical process as an example, if an unexpected interruption occurs during the ongoing chemical reaction process, sometimes the semi-finished products produced midway cannot be used, resulting in a large loss.

[0040] On the other hand, for the process control system, from the aspect of safety, it is required not to produce malfunction or action defects. Therefore, when a cause (such as an operating system defect or vulnerability) that may cause a malfunction is found, it is necessary to immediately take measures (update of the operating system) to eliminate the cause. However, as described above, it is impossible to freely stop the process control system. Therefore, even when a cause that may cause a malfunction is found, sometimes it is impossible to immediately take such measures.

[0041] If the invention disclosed in the above-mentioned Patent Document 1 is utilized, it is also possible to update the system program (online system update) while continuously processing the functions (system functions) implemented by the system program. However, in order to update the system program using the invention disclosed in the above-mentioned Patent Document 1, it is necessary to embed the online update function required for implementing the online system update into both the current device and the update device.

[0042] However, regarding the above-mentioned online update function, it is possible to easily embed the extended function into the update device in a waiting state, but it cannot be embedded into the current device in an operating state. That is, it means that even if the extended function of the online update is implemented for the current device, the extended function cannot be used in the next online update. For example, regarding a specific system function, there are restrictions on the processing stop during the current online update, but sometimes the processing can be continued through the extended function of the online update. In this case, it is necessary to temporarily use the current online update to embed the extended function into the current online update function of the current device. Therefore, when using the current online update, it is necessary to stop the specific system function.

[0043] In an embodiment of the present invention, for the data (inheritance data) that needs to be inherited in order to continuously execute the system function when switching from the current device (first process control device) to the update device (second process control device), the update device acquires the data from the current device and restores it in the update device. The update device determines the timing for switching from the current device to the update device. In this embodiment, it is only necessary to embed the online update function required for implementing the online system update into the update device, and there is no need to embed it into the current device. Therefore, the function expansion of the online system update can be achieved without stopping the process control system.

[0044] [First Embodiment]

[0045] <Process Control System>

[0046] Figure 1 It is a functional structure diagram showing the schematic functional structure of the process control system according to the first embodiment of the present invention. As Figure 1 shown, the process control system 1 of this embodiment includes a process control device 10 (first process control device), a process control device 20 (second process control device), and an engineering device 30. The process control device 10 and the process control device 20 are implemented using computers of the same or similar scale. In this embodiment, the process control device 10 may sometimes be referred to as the "current device", and the process control device 20 may be referred to as the "update device". The "current device" represents the currently operating device, and the "update device" represents the device that is not currently operating but is waiting for program update.

[0047] In the present embodiment, for the update of the program, the functions operating in the process control device 10 are switched to the process control device 20. That is, initially, the process control device 10, which is the active device, operates to control the process, and the process control device 20, which is the update device, stands by. Then, based on the command signal from the engineering device 30, the functions of the process control device 10 (active device) are temporarily stopped, and the functions are restarted in the process control device 20 (update device). As will be described in detail later, the process control device 20 has a function of updating the program while keeping the state of the system operation unchanged.

[0048] The process control device 10 has the functions of the hardware 11, the system function providing unit 12, and the control application program 13. The hardware 11 has a CPU (Central Processing Unit), a memory, an input / output device, a communication device, etc., and executes various programs used in the process control device 10 (system programs for implementing the system functions provided by the system function providing unit 12, application programs for implementing the control application program 13, etc.). The functions of the process control device 10 are realized by the hardware 11 executing the programs for realizing these functions. That is, the functions of the process control device 10 are realized by the collaborative operation of software and hardware resources.

[0049] The system function providing unit 12 is located between the hardware 11 and the control application program 13, manages the hardware 11, and provides various system functions according to the calls from the control application program 13. The system function providing unit 12 provides, for example, system functions such as a PID control function 12a, a sequence control function 12b, an interpreter function 12c, an I / O function 12d, and a communication function 12e. The system function providing unit 12 also includes an operating system (OS) and drivers. Among the system programs for realizing the various system functions provided by the system function providing unit 12, there are update object programs that can be update targets and non-update object programs that are not update targets.

[0050] The control application program 13 performs process control at a preset control cycle (for example, a cycle of about several seconds). The control application program 13 includes, for example, one or more control logics created by the user using the engineering device 30. The control application program 13 calls the system functions provided by the system function providing unit 12 and performs process control. The switching from the process control device 10 to the process control device 20 is performed in such a way that the processing of the control application program 13 and the processing of the system functions called from the control application program 13 continue.

[0051] The process control device 20 has the functions of hardware 21, a system function providing unit 22, a control application program 23, and an online update control unit 24. The hardware 21 is the same as the above-mentioned hardware 11 and executes various programs used in the process control device 20 (system programs that implement the system functions provided by the system function providing unit 22, application programs that implement the control application program 23, etc.). The functions of the process control device 20 are also realized through the coordinated operation of software and hardware resources.

[0052] The system function providing unit 22 provides the same system functions as the above-mentioned system function providing unit 12. Specifically, the system function providing unit 22 provides system functions such as a PID control function 22a, a sequence control function 22b, an interpreter function 22c, an I / O function 22d, and a communication function 22e. The system functions provided by the system function providing unit 22 may include the same system functions as those provided by the system function providing unit 12, or may include different system functions (such as extended functions).

[0053] The online update control unit 24 controls the online system update process of updating the system program while keeping the processing of the system functions implemented by the system program continuous. Specifically, when switching from the process control device 10 to the process control device 20, the online update control unit 24 acquires the data (inheritance data DT) required to keep the system functions continuous from the process control device 10 and restores it in the process control device 20. The online update control unit 24 determines the timing for switching from the process control device 10 to the process control device 20. The details of the processing executed in the online update control unit 24 are described later.

[0054] The engineering device 30 performs various engineering tasks of the process control system 1 using the design information of the workshop including the design information of the process control system 1. The engineering device 30 executes an instruction to start the process control device 20 when switching from the process control device 10 to the process control device 20. The engineering device 30 is implemented by a computer such as a personal computer or a workstation, for example.

[0055] Figure 2 is a functional block diagram showing the functional structure for realizing the online system update in the first embodiment of the present invention. In Figure 2 the redundancy function 15 is a function provided on the side of the active device ( Figure 1 the process control device 10 in Figure 1 ), and the redundancy function 25 is a function provided on the side of the update device ( Figure 1 the process control device 20 in

[0056] The redundancy functions 15 and 25 are functions for controlling the control system and the process control device of the standby system that adopt a redundant structure. However, in addition to the purpose of redundancy, they can also be used for a part of the online system update function. In either case, the function is realized by the exchange between the process control devices 10 and 20, and the two devices perform actions in coordination with each other. The redundancy function 15 has a memory access unit 15a and a control right switching unit 15b, and the redundancy function 25 has a memory access unit 25a and a control right switching unit 25b.

[0057] For the memory access unit 15a and the memory access unit 25a, in the redundancy function, in order to copy all the memories of the control system device to the memory of the standby system device, an exchange is performed. On the other hand, in the online system update function, when switching from the process control device 10 to the process control device 20, an exchange is performed to copy the inheritance data DT (refer to Figure 1 ) that needs to be inherited to keep the system function continuous. For the control right switching unit 15b and the control right switching unit 25b, in the redundancy function, in order to switch the control right from the control system device to the standby system device, a control signal (control right) is exchanged. On the other hand, in the online system update function, in order to switch from the current control device 10 to the update device 20, a control signal (control right) is exchanged. The functions of the redundancy functions 15 and 25 are realized by the coordinated actions of software and hardware resources.

[0058] As Figure 2 shown, the online update control unit 24 has a communication management unit 24a, a data inheritance unit 24b, a timing determination unit 24c, and a program restart unit 24d. The process control device 20 is connected to the engineering device 30 via a network. The communication management unit 24a of the process control device 20 can communicate with the engineering device 30 via the network.

[0059] The communication management unit 24a receives an instruction (start instruction) sent from the engineering device 30 via the network. When the communication management unit 24a receives the start instruction from the engineering device 30, it gives an indication to the timing determination unit 24c for determining the timing (switching timing) of switching from the process control device 10 to the process control device 20.

[0060] When the switching timing is determined by the timing determination unit 24c, the data inheritance unit 24b acquires the inheritance data DT that needs to be inherited to keep the system function continuous from the process control device 10 and restores it in the process control device 20. The data inheritance unit 24b has a symbol table TB1 of the system function of the process control device 10, and acquires the inheritance data DT from the process control device 10 with reference to the symbol table TB1.

[0061] The above symbol table TB1 is a table generated by compiling and linking a system program (source program) that implements the system functions of the process control device 10. By referring to this symbol table TB1, the address where the inherited data DT is stored in the process control device 10 can be obtained. The data inheritance unit 24b accesses the address obtained by referring to the symbol table TB1 to obtain the inherited data DT.

[0062] The data inheritance unit 24b obtains the address where the inherited data DT should be stored in the process control device 20, and sets the obtained inherited data DT to this address, thereby restoring the inherited data DT in the process control device 20. That is, when the data inheritance unit 24b switches from the process control device 10 to the process control device 20, it restores the context of the system function that continuously executes the process in the process control device 20.

[0063] The timing determination unit 24c determines the switching timing from the process control device 10 to the process control device 20 based on an instruction from the communication management unit 24a. Specifically, the timing determination unit 24c determines the switching timing in the following manner: after confirming the state in which all system functions of the process control device 10 have completed processing (hereinafter, also referred to as the "completed state of the process control device 10"), the switching from the process control device 10 to the process control device 20 is performed.

[0064] This is to reliably perform the switching from the process control device 10 to the process control device 20. For example, when the system function is a function of outputting a control signal, if the switching from the process control device 10 to the process control device 20 is performed before the output processing of the control signal is completed, a part of the output will be lost. To avoid this situation, the timing determination unit 24c determines the switching timing in the following manner: after confirming the completed state of the process control device 10, the switching from the process control device 10 to the process control device 20 is performed.

[0065] The timing at which the timing determination unit 24c confirms the completed state of the process control device 10 is the timing that is a specified time earlier than the timing of the start of the next control cycle during the period from the end of the processing that should be executed in a certain control cycle of the process control device 10 until the start of the next control cycle.

[0066] The above specified time is the sum of the time required for the timing determination unit 24c to confirm the completed state of the process control device 10 and the time required for the data inheritance unit 24b to obtain the inherited data DT from the process control device 10 and restore it in the process control device 20.

[0067] That is, the timing determination unit 24c reserves the timing for the minimum time required for the switch from the process control device 10 to the process control device 20 until the start of the next control cycle, and confirms the completion state of the process control device 10. Confirming the completion state of the process control device 10 at this timing is to determine whether the time required to end the system function of the process control device 10 is reserved after the processing that should be executed in a certain control cycle of the process control device 10 is completed within this process control cycle.

[0068] When the timing determination unit 24c can confirm the completion state of the process control device 10, it notifies the process control device 10 of the switch timing. When the timing determination unit 24c cannot confirm the completion state of the process control device 10, it aborts the online system update. This is to prevent the online system update from being performed in a state where there are system functions with uncompleted processing.

[0069] After the timing determination unit 24c notifies the process control device 10 of the switch timing, the program restart unit 24d waits for a control signal (control right) to be sent from the process control device 10 via the redundancy functions 15 and 25. When a control signal (control right) is sent from the process control device 10, the program restart unit 24d restarts the program that implements the system function, and causes the process control device 20 to operate as the active device.

[0070] <Program Update Method>

[0071] Figure 3 It is a flowchart showing the program update method according to the first embodiment of the present invention. As a prerequisite for executing Figure 3 the processing of the flowchart shown, the process control device 10 (active device) operates using the system program before the update. The process control device 20 (update device) stands by in a state where the updated system program is installed. The updated system program is downloaded and installed from the engineering device 30, for example, when the process control device 20 (update device) is temporarily started based on the designation of the engineering device 30.

[0072] For the system program of the process control device 20 (update device), all of it can be updated, or only a part of it can be updated. The communication management unit 24a of the process control device 20 (update device) receives a start instruction output from the engineering device 30 to start Figure 3 the operation of the flowchart shown.

[0073] If it starts Figure 3For the processing shown, first, the standby process control device 20 (update device) is started (step S11). Next, the data inheritance unit 24b of the process control device 20 (update device) performs the following processing, that is, selects the data (context) required for the system function being executed in the process control device 10 (current device) to continue the processing (step S12). The data inheritance unit 24b selects the above data by referring to, for example, the symbol table TB1 of the system function of the process control device 10.

[0074] Next, the timing determination unit 24c of the process control device 20 (update device) performs the following processing, that is, determines the timing for switching from the process control device 10 (current device) to the process control device 20 (update device) (step S13: timing determination step). Figure 4 It represents Figure 3 The detailed flowchart of the processing in step S13 in

[0075] If the processing of step S13 is started, first, the timing determination unit 24c performs the following processing, that is, determines whether it is the waiting time between control cycles (that is, whether it is the period from the end of the processing that should be executed in a certain control cycle of the process control device 10 until the start of the next control cycle) (step S21). When the determination result in step S21 is "NO", the determination in step S21 is repeated. That is, during the process of the process control device 10 (current device) executing a certain control cycle, waiting processing is performed until the end of the control cycle.

[0076] In contrast, when the determination result in step S21 is "YES", the timing determination unit 24c performs the following processing, that is, determines whether it is a timing that is a specified time earlier than the start timing of the next control cycle (step S22). The above specified time is the sum of the time required for the timing determination unit 24c to confirm the completion state of the process control device 10 and the time required for the data inheritance unit 24b to obtain the inheritance data DT from the process control device 10 and restore it in the process control device 20.

[0077] When the determination result in step S22 is "NO", the processing returns to step S21. In contrast, when the determination result in step S22 is "YES", the timing determination unit 24c performs the following processing, that is, determines whether the process control device 10 (current device) is in a completed state (step S23). When the determination result in step S23 is "NO", the timing determination unit 24c performs the processing to abort the online system update. If this processing is performed, the process ends Figure 3The series of processes shown. In contrast, when the determination result in step S23 is "YES", it is determined that the switching timing has been reached and the process ends. Figure 3 The process of step S13 shown.

[0078] If Figure 3 the process of step S13 shown ends, the data inheritance unit 24b is called from the timing determination unit 24c. The data inheritance unit 24b performs the following process, that is, the inheritance data DT is acquired from the process control device 10 (current device) and restored in the process control device 20 (update device) (step S14: data inheritance step). Figure 5 represents Figure 3 the details of the process of step S14 in

[0079] If the process of step S14 starts, first, the symbol table TB1 is referred to and the data inheritance unit 24b performs the following process, that is, the address where the inheritance data DT is stored in the process control device 10 (current device) is acquired (step S31). For example, the process of acquiring all the addresses where the inheritance data DT is stored at once is performed. Next, the data inheritance unit 24b performs the following process, that is, the inheritance data DT stored in the address acquired in step S31 by the memory access units 15a and 25a is acquired from the process control device 10 (current device) (step S32).

[0080] Next, the data inheritance unit 24b performs the following process, that is, the address where the inheritance data DT should be stored in the process control device 20 (update device) is acquired (step S33). Specifically, the process of acquiring the address of the variable used in the updated system program installed in the process control device 20 (update device) is performed. Then, the data inheritance unit 24b performs the following process, that is, the inheritance data DT acquired from the process control device 10 (current device) in step S32 is set for the address of the process control device 20 (update device) acquired in step S33. By performing the above process, the inheritance data DT is restored in the process control device 20 (update device).

[0081] If the above process ends, the timing determination unit 24c performs the process of notifying the process control device 10 (current device) of the switching timing (step S15). If this notification is made, the program restart unit 24d is in a waiting state for waiting for a control signal (right of control) sent from the process control device 10 via the redundancy functions 15 and 25.

[0082] If the process control device 10 (the current device) receives the above switching timing notified by the timing determination unit 24c, it sends a control signal (control right) to the process control device 20 (the update device) via the redundancy functions 15 and 25, and then stops the operation. If it receives a control signal (control right) sent from the process control device 10, it restarts the program that implements the system function, and the program restart unit 24d performs processing to cause the process control device 20 to execute operations as the current device (step S16).

[0083] As described above, in the present embodiment, the process control device 20 as the update device acquires the inheritance data DT that needs to be inherited to keep the system function continuous when switching from the process control device 10 as the current device to the process control device 20 from the process control device 10, restores it in the process control device 20, and determines the timing for switching from the process control device 10 to the process control device 20. In this way, in the present embodiment, it is only necessary to embed the extended function for expanding the online update function required for expanding the online system update into the process control device 20 as the update device, and there is no need to embed it into the process control device 10 as the current device. Therefore, it is possible to expand the function of online system update without stopping the process control system 1.

[0084] [Second Embodiment]

[0085] <Process Control System>

[0086] Figure 6 It is a functional block diagram showing the functional structure for implementing the online system update in the second embodiment of the present invention. In Figure 6 it, the same reference numerals are assigned to the structures corresponding to the structures shown in Figure 2 . The functional structure of the entire process control system according to the present embodiment is the same as the functional structure described using Figure 1 . Hereinafter, the description will be centered on the differences from the foregoing first embodiment.

[0087] In the present embodiment, even if the value of the inheritance data DT is the address value of a variable stored in the address change area, the inheritance of the inheritance data DT can be accurately performed. The address change area refers to an area (storage area) where the address may change when switching from the process control device 10 (the current device) to the process control device 20 (the update device). The address change area is composed of one or more areas with consecutive addresses, and each area is managed according to the start address and size (dimension).

[0088] Even if the address value of the variable stored in the address variable area is inherited, if the head address of the address variable area changes, the inherited address value becomes meaningless. In this embodiment, even if the head address of the address variable area changes, the inheritance data DT can be accurately inherited.

[0089] like Figure 6 As shown, the online update control unit 24A of this embodiment is configured to Figure 2 The online update control unit 24 shown in FIG. 1 is supplemented with an address conversion unit 24e. Figure 2 The functions shown are the same. When the value of the inherited data DT is the address value of the variable stored in the address change area, the address conversion unit 24e is called from the data inheritance unit 24b to convert the address value using the address conversion table TB2. When the value of the inherited data DT is not the address value of the variable stored in the address change area, the address conversion unit 24e does not convert using the address conversion table TB2.

[0090] The address conversion table TB2 is a table that associates the storage address before switching with the storage address after switching for all variables stored in the address change area. The address conversion table TB2 is prepared for each area with consecutive addresses in the address change area (that is, each area managed according to the head address and size).

[0091] The address conversion table TB2 utilizes the property that, unless the program related to the address change area is modified, the offset of the storage address of each variable (the offset relative to the head address of the address change area) does not change before and after the switching. For example, the address conversion table TB2 is prepared in advance using a symbol table generated by compiling and linking a system program (source program) that realizes the system function of the process control device 10, 20.

[0092] Figure 7A , Figure 7B It is a diagram showing an example of an address conversion table according to the second embodiment of the present invention. Figure 7A The address conversion table TB2 shown is declared in the system program (source program) that realizes the system function of the process control device 10. Figure 7B In the present embodiment, for easy understanding, the source program is described as a program written in C language, but the source program may be written in any language other than C language.

[0093] exist Figure 7BIn the example shown, an integer variable a is declared as an external variable, a structure variable b with integer variables b1 and b2 as members, an array variable c with six integer elements, a pointer *p_a pointing to variable a, a pointer *p_b pointing to member b2 of structure variable b, and a pointer *p_c pointing to the second element (c[2]) of array variable c. In the case of such declarations, as Figure 7A shown, variable a, structure variable b, member b1 of structure variable b, member b2 of structure variable b, array variable c, the 0th to 5th elements c[0] to c[5] of the array variable, pointer variable p_a, pointer variable p_b, and pointer variable p_c are stored consecutively in the address change area in this order. The size of each variable is 32 bits (4 bytes).

[0094] If the start address of the address change area before switching where the above external variables are stored is represented in hexadecimal as "0xa000", the addresses for storing each external variable are represented as Figure 7A the "address before switching" in. If the start address of the address change area after switching where the above external variables are stored is represented in hexadecimal as 0xc000, the addresses for storing each external variable are represented as Figure 7A the "address after switching" in. The size of the address change area where the external variables are stored is 48 bytes and remains unchanged before and after switching.

[0095] <Program Update Method>

[0096] The program update method of this embodiment is the same as the program update method of the first embodiment and basically updates the system program by executing Figures 3 - 5 the steps shown. However, in this embodiment, when using the data inheritance unit 24b to obtain and restore the inheritance data DT from the existing device (the process of Figure 3 step S14 shown), the address transformation unit 24e performs the transformation process using the address transformation table TB2.

[0097] Figure 8 is a flowchart showing the address transformation process executed in the second embodiment of the present invention. Figure 8 The process of the flowchart shown can be executed, for example, in step S32 or step S34 of Figure 3 which details the process of Figure 5 step S14 shown. If the process starts, first, the data inheritance unit 24b determines whether the inherited variable value is an address value within the address change area (step S41).

[0098] When the determination result in step S41 is "YES", the data inheritance unit 24b is used to perform the process of extracting the address value before switching stored in the inherited variable (step S42). Next, the data inheritance unit 24b calls the address conversion unit 24e, refers to the address conversion table TB2, and uses the address conversion unit 24e to perform the process of obtaining the address after switching corresponding to the address value before switching (step S43). Then, the address conversion unit 24e is used to perform the process of setting the obtained address value for the inherited variable (step S44).

[0099] When the process in step S44 ends, or when the determination result in step S41 is "NO", the data inheritance unit 24b determines whether the above process has ended for all inherited data DT (step S45). When the determination result in step S45 is "NO", the process returns to step S41, and the same process is performed for the remaining variables. In contrast, when the determination result in step S45 is "YES", the series of processes shown Figure 8 ends.

[0100] When an external variable as shown Figure 7B is declared, if the above process is performed, the address values stored in the pointer variable p_a, pointer variable p_b, and pointer variable p_c exemplified in Figure 7B are transformed. Specifically, the address value "0xa000" stored in the pointer variable p_a is transformed into the address value "0xc000", the address value "0xa008" stored in the pointer variable p_b is transformed into the address value "0xc008", and the address value "0xa014" stored in the pointer variable p_c is transformed into the address value "0xc014". In contrast, for the remaining variables (variable a, structure variable b, member b1 of structure variable b, member b2 of structure variable b, array variable c, elements c[0] to c[5] of the array variable), their values are inherited as they are.

[0101] As described above, in the present embodiment, when the inherited data DT is the address value of a variable stored in an address change area where the address may change before and after switching, the address value is transformed using the address conversion table TB2. Therefore, even if the head address of the address change area changes before and after switching, the inheritance of the inherited data DT (the address value of the variable stored in the address change area) can be accurately performed.

[0102] In the present embodiment, when correcting a variable allocated to the address change area, it is possible to easily cope with only by correcting the address conversion table TB2. Specifically, when adding or deleting a variable in the address change area, it is only necessary to correct the offset of the variable accordingly.

[0103] Figure 9A , Figure 9B is a diagram showing an example of the corrected address translation table in the second embodiment of the present invention. Currently, it is assumed that as shown in Figure 9B shown, the external variable (the variable assigned to the address change area) shown in Figure 7B is corrected. Specifically, the structure variable b having integer variables b1 and b2 as members is corrected to a structure variable b having integer variables b1, b2, b3, and b4 as members, and the array variable c having six integer elements is corrected to an array variable c having four integer elements.

[0104] In the case of making such corrections, as long as the address translation table TB2 shown in Figure 7A is corrected to the address translation table TB2 shown in Figure 9A That is, as long as the members b3 and b4 of the added structure variable b are corrected to have no pre-switching address, and the elements (the fourth and fifth elements) of the deleted array variable c are corrected to have no post-switching address.

[0105] In the above embodiment, the address translation unit 24e uses the address translation table TB2 to perform the translation of the address value to be inherited (the address value of the variable stored in the address change area). However, if the offset address value of the storage address of each variable assigned to the address change area with respect to the head of the area does not change before and after the switch, that is, in the case where no addition or deletion correction is made to the variable assigned to the address change area, the address translation unit 24e may use the address translation formula shown in the following (1) instead of the address translation table TB2 to perform the translation of the address value to be inherited.

[0106] D = C+(B - A)…(1)

[0107] A: The head address of the address change area before the switch

[0108] B: The head address of the address change area after the switch

[0109] C: The address value before the switch

[0110] D: The address value after the switch

[0111] [Third Embodiment]

[0112] <Process Control System>

[0113] Figure 10 is a functional block diagram showing the functional structure for implementing the online system update in the third embodiment of the present invention. In Figure 10 , for Figure 2 ,Figure 6 Structures shown are equivalent structures, labeled with the same reference numerals. The functional structure of the entire process control system involved in this embodiment is the same as the functional structure described using Figure 1 the description. Below, the description will be centered on the differences from the aforementioned first and second embodiments.

[0114] In this embodiment, even when the cache in the process control device 10 (current device) is valid, the inheritance of the inheritance data DT can be accurately performed. The cache of the process control device 10 (current device) refers to a temporary storage area for data provided between the CPU and the memory of the process control device 10 (current device). Since the cache cannot be referred to from the process control device 20 (updating device), it can be temporarily maintained in a state where data cannot be referred to from the process control device 20 (updating device).

[0115] In the case where such a cache is provided, sometimes the content of the data stored in the cache is different from the content of the data stored in the memory. The process control device 20 (updating device) accesses the memory of the process control device 10 (current device) to obtain the inheritance data DT. Therefore, when the data stored in the memory is different from the data stored in the cache, the inheritance of the inheritance data DT cannot be accurately performed. In this embodiment, the inheritance of the inheritance data DT can be accurately performed by operating the cache of the process control device 10 (current device) from the process control device 20 (updating device).

[0116] As Figure 10 shown, in this embodiment, an online update control unit 14 is provided on the current device side ( Figure 1 the process control device 10 therein). An online update control unit 24B is provided on the updating device side ( Figure 1 the process control device 20 therein). The redundancy functions 15 and 25 are the same as the Figure 2 , Figure 6 functions shown.

[0117] The online update control unit 14 and the online update control unit 24B together control the following online system update process, that is, while continuously processing the system functions implemented by the system program, the system program is updated. The online update control unit 14 has a cache operation unit 14a that operates on the cache of the process control device 10 (current device). In this embodiment, it is necessary to pre-embed the online update control unit 14 having the cache operation unit 14a into the process control device 10 (current device).

[0118] Specifically, the cache operation unit 14a operates on the cache according to the following three cache operation flags.

[0119] · Flash memory flag: A flag that controls whether the content in the cache is reflected in the memory. If the value is "1", the cache operation unit 14a causes the content in the cache to be reflected in the memory. If the content in the cache is reflected in the memory, the cache operation unit 14a sets the value to "0".

[0120] · Invalidation flag: A flag that invalidates the cache. If the value is "1", the cache operation unit 14a invalidates the cache.

[0121] · Validation flag: A flag that validates the cache. If the value is "1", the cache operation unit 14a validates the cache.

[0122] The online update control unit 24B has a structure in which the timing determination unit 24c of the online update control unit 24A shown in Figure 6 is replaced by a timing determination unit 24f. The timing determination unit 24f changes the value of the cache operation flag used in the cache operation unit 14a of the process control device 10 (the current device) to operate on the cache of the process control device 10 (the current device).

[0123] The timing determination unit 24f sets the value of the flash memory flag to "1" before, for example, the processing that should be executed in a certain control cycle ends and the switching timing is determined. The timing determination unit 24f sets the value of the flash memory flag to "1" immediately after the processing of each system function executed in the process control device 10 (the current device) is completed. Alternatively, the timing determination unit 24f sets the value of the invalidation flag to "1" during an arbitrary period (for example, during the online system update).

[0124] <Program update method>

[0125] The program update method of this embodiment is the same as the program update method of the second embodiment, and basically updates the system program by executing Figures 3 - 5 、 Figure 8 shown steps. However, in this embodiment, between the steps S22 and S23 shown in Figure 4 , the timing determination unit 24f of the process control device 20 (the update device) performs an operation of setting the value of the flash memory flag to "1".

[0126] If the value of the flash memory flag is set to "1", the cache operation unit 14a of the process control device 10 (the current device) performs an operation of reflecting the content in the cache in the memory. Reflecting the content in the cache enables the process control device 20 (the update device) to refer to the content. Therefore, the operation of reflecting the content in the cache by the cache operation unit 14a can be referred to as an operation that enables the process control device 20 (the update device) to refer to the data held in the cache.

[0127] As described above, in the present embodiment, the timing determination unit 24f of the process control device 20 (update device) operates on the value of the cache operation flag, and the cache operation unit 14a of the process control device 10 (current device) performs an operation to reflect the content of the cache in the memory. Therefore, even when the cache is valid in the process control device 10 (current device), the inheritance of the inheritance data DT can be accurately performed.

[0128] As described above, by using any of the foregoing embodiments, it is possible to implement online system update without stopping the process control system (update the system program while continuing the processing of the functions (system functions) implemented by the system program).

[0129] At least a part of the functions of the process control devices 10 and 20 and the engineering equipment 30 of each embodiment can be implemented by a computer. In this case, a program for implementing this function can be recorded in a computer-readable recording medium, and the program recorded in the recording medium can be read into a computer system and executed to implement the function.

[0130] The above-mentioned "computer system" is assumed to include hardware such as an OS and peripheral devices. The "computer-readable recording medium" refers to a storage device such as a floppy disk, an optical disk, a ROM, a CD-ROM, a DVD-ROM, a USB memory, etc., and a hard disk built in a computer system. In addition, the "computer-readable recording medium" may include a medium that temporarily and dynamically holds a program, such as a communication line when the program is transmitted via a network such as the Internet or a communication line such as a telephone line, and a medium that holds the program for a certain period of time, such as a volatile memory inside a computer system such as a server or a client terminal in this case. The above program can implement a part of the foregoing functions, and can also implement the foregoing functions by combining with a program already recorded in the computer system.

[0131] The process control system, the process control device, and the program update method according to the embodiments of the present invention have been described above. The present invention is not limited to the above embodiments, and can be arbitrarily changed within the scope of the present invention. For example, the first embodiment and the third embodiment can be combined. In the above embodiments, the structures of the process control system and the process control device are described. However, the structures of the above embodiments can also be applied to any other system. In the above embodiments, the operating system can be an embedded OS for controlling an embedded system, or a general-purpose OS for controlling a general-purpose computer.

Claims

1. A process control system having a first process control device and a second process control device, wherein the first process control device does not have an online update control unit, and the second process control device has the online update control unit, where the online update control unit of the second process control device has: a data inheritance unit that acquires inheritance data, which is data required to continue system functions when switching from the first process control device to the second process control device, from the first process control device and restores the inheritance data in the second process control device; and a timing determination unit that determines the timing of performing the switching, When the function of the online update function of the process control system is expanded, an extended function is embedded in the online update control unit of the second process control device, and the extended function is not embedded in the first process control device.

2. The process control system according to claim 1, wherein the data inheritance unit acquires the inheritance data from the first process control device with reference to the symbol table of the system function of the first process control device.

3. The process control system according to claim 1 or 2, wherein the timing determination unit determines the timing in such a manner that the switching is performed after confirming that all the system functions of the first process control device have ended processing in a completed state.

4. The process control system according to claim 3, wherein the timing determination unit aborts the switching when the completed state cannot be confirmed.

5. The process control system according to claim 1, wherein the process control system further has an address conversion unit, and when the inheritance data is an address value of a variable stored in an address variable area where the address may change, the address conversion unit uses an address conversion table that associates the address of the variable stored in the address variable area before the switching and the address of the variable stored in the address variable area after the switching to convert the address value as the inheritance data.

6. The process control system according to claim 5, wherein the address conversion table is pre-generated using the symbol table of the system function of the first process control device and the symbol table of the system function of the second process control device.

7. The process control system according to claim 1, wherein the first process control device has a cache operation unit that operates on a cache that is temporarily kept in a state where data used internally cannot be referenced from the second process control device, when determining the timing, the timing determination unit performs an operation on the cache operation unit so that data held by the cache can be referenced from the second process control device.

8. The process control system according to claim 7, wherein the timing determination unit can perform an operation on the first process control device to make the cache valid or invalid.

9. The process control system according to claim 2, wherein The symbol table is a table generated by compiling and linking a system program that implements the system functions of the first process control device.

10. The process control system according to claim 2, wherein the data inheritance unit refers to the symbol table to obtain the address where the inheritance data is stored in the first process control device.

11. The process control system according to claim 1, wherein the timing is the timing during the period from the end of the processing that should be executed in a certain control cycle of the first process control device until the start of the next control cycle, and is a timing that is a specified time earlier than the timing of the start of the next control cycle.

12. The process control system according to claim 11, wherein the specified time is the time obtained by adding the time required for the timing determination unit to confirm the completion state of the first process control device and the time required for the data inheritance unit to obtain the inheritance data from the first process control device and restore it in the second process control device.

13. The process control system according to claim 5, wherein the address change area is composed of one or more areas with consecutive addresses, and each area is managed according to the start address and size.

14. A process control device that performs a switch from another process control device to the present process control device, the other process control device not having an online update control unit, and the present process control device having the online update control unit, wherein the online update control unit has: a data inheritance unit that obtains inheritance data, which is data that needs to be inherited to maintain system functions when performing the switch, from another process control device and restores the inheritance data in the present process control device; and a timing determination unit that determines the timing of performing the switch, in the case where the function of the online update function of the process control device is extended, an extended function is embedded in the online update control unit of the present process control device, and the extended function is not embedded in the other process control device.

15. A program update method, which is a program update method for a process control system having a first process control device and a second process control device, the first process control device not having an online update control unit, and the second process control device having the online update control unit, wherein the program update method has the following steps: the online update control unit of the second process control device obtains inheritance data, which is data that needs to be inherited to maintain system functions when performing the switch from the first process control device to the second process control device, from the first process control device and restores the inheritance data in the second process control device; and the online update control unit of the second process control device determines the timing of performing the switch, in the case where the function of the online update function of the process control system is extended, an extended function is embedded in the online update control unit of the second process control device, and the extended function is not embedded in the first process control device.

Citation Information

Patent Citations

  • Process control system, process controller, and program update method

    JP2020052668A

  • Method And Apparatus For Providing Redundancy In An Industrial Control System

    US20090125122A1

  • Process control system, process control apparatus and program update method

    US20200097282A1