Queue blocks for flexible automation engineering programs

By introducing queue blocks in the automation system, dynamic data exchange and multi-platform compatibility between PLCs are achieved, and the problem of redesigning PLC programs in the prior art when hardware or software changes are solved, which improves the efficiency of engineering work and adaptability.

CN114503037BActive Publication Date: 2024-12-27SIEMENS AG
View PDF 10 Cites 0 Cited by

Patent Information

Application Number
CN201980100523.4
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2019-09-19
Publication Date
2024-12-27
Estimated Expiration
2039-09-19

AI Technical Summary

Technical Problem

Existing automation engineering programs need to be redesigned when software or hardware changes, resulting in time-consuming and expensive engineering work and difficult to achieve interoperability between PLCs and data exchange flexibility.

Method used

The introduction of queue blocks (QBs) as data type in programmable logic controllers (PLCs), allowing dynamic exchange of data between PLCs or between PLCs and other computer systems, achieving multi-platform compatibility and distributed processing through message queues.

Benefits of technology

It realizes efficient data exchange and flexible adaptability of PLC programs, so that the program is no longer bound to specific hardware configurations, supports multi-platform implementation and parallel processing, reducing the time and cost of engineering work.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN114503037B_ABST
    Figure CN114503037B_ABST
Patent Text Reader

Abstract

A system for exchanging data in an automation environment is provided. The system comprises at least one programmable logic controller (PLC A) and a queue block (50), the programmable logic controller containing program instructions executable by the at least one programmable logic controller, the queue block being configured to dynamically exchange data between the program instructions of the PLC and data consumers (PLC C, PLC D).
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] Aspects of the present disclosure generally relate to programmable logic controllers (PLCs) for automating industrial processes. More specifically, a system for exchanging data in an automated environment is presented. The system includes a new block type for PLC programming, a queue block, which is configured to dynamically exchange data between two PLCs or between a PLC and other applications hosted in other computer systems. Background Art

[0002] Currently, automation engineering programs are tied to a specific PLC. For example, function blocks (FB), functions (FC), and data blocks (DB) are associated with a specific PLC. In the PLC programming environment, function blocks utilize internal data blocks for data storage, while functions (FC) utilize only temporary storage. Each PLC vendor has its own engineering environment and supports its own version of IEC 61131-3 (International Electrotechnical Commission PLC standard) programming languages, such as ladder diagram (LAD), sequential function chart (SFC), and structured control language (SCL). FB / FC developed for one PLC cannot be migrated or interoperated with other FB / FC in other PLCs without very large integration work. When two PLCs communicate values ​​to each other, the automation program uses special FB / FC to call the communication through industrial communication protocols such as Profinet. This engineering paradigm is inflexible because it prescribes a specific hardware configuration for the automation program. Any change in the hardware triggers a redesign of the software. Similarly, any change in the software triggers a validation of the hardware. As a result, this leads to additional engineering work, which is time-consuming and expensive.

[0003] Some efforts have been made to make PLC programs interoperable. These efforts include adapting PLC programs to PLCs that support standards such as OPC UA (Open Platform Communications Unified Architecture). The data model of a PLC designed to store known data structures must first be mapped to a standard data model and then to the data model of other PLCs. In addition, the integration work is project-specific and difficult to reuse in different projects. If the PLC does not support common standards, a larger integration effort must be performed based on the open interfaces provided by each PLC, such as the Software Development Kit (SDK) and the Open Development Kit (ODK).

[0004] Flexibility in automation engineering programs has traditionally been achieved through best practices in software architecture. The goal is to use automation software design patterns to make software redesign and maintenance easy. However, this does not solve the problem mentioned above, that any changes to the software or hardware still trigger a redesign. Therefore, a flexible automation engineering program that can exchange data in a more efficient way is needed. Summary of the invention

[0005] Briefly described, aspects of the present disclosure relate to a system for exchanging data in an automation environment, and a computer-implemented method for exchanging data between a programmable logic controller and a data consumer in an automation system.

[0006] A first aspect provides a system for exchanging data in an automation environment. The system includes at least one programmable logic controller and a queue block, the programmable logic controller containing program instructions executable by the at least one programmable logic controller, and the queue block is configured to dynamically exchange data between the program instructions of the PLC and a data consumer.

[0007] A second aspect provides a computer-implemented method for exchanging data between a programmable logic controller and a data consumer in an automation system. The method comprises the following steps: providing a queue block for dynamically exchanging data between a function block and the data consumer, the function block containing program instructions executable by the programmable logic controller; assigning the function block to the programmable logic controller via the queue block at runtime; and exchanging data from the programmable logic controller to the data consumer. BRIEF DESCRIPTION OF THE DRAWINGS

[0008] Figure 1 A conventional PLC automation program using function blocks and data blocks is shown.

[0009] Figure 2 A first embodiment of a PLC automation program using queue blocks is shown.

[0010] Figure 3 A second embodiment of a PLC automation program using a queue block is shown.

[0011] Figure 4 A third embodiment of a PLC automation program using a queue block is shown.

[0012] Figure 5 A fourth embodiment of a PLC automation program using queue blocks is shown.

[0013] Figure 6 A fifth embodiment of a PLC automation program using queue blocks is shown. DETAILED DESCRIPTION

[0014] To facilitate understanding of the embodiments, principles and features of the present disclosure, they are explained below with reference to implementation in illustrative embodiments. However, the embodiments of the present disclosure are not limited to use in the described systems or methods.

[0015] The components and materials that make up the various embodiments described below are intended to be illustrative rather than limiting. Many suitable components and materials that will perform the same or similar functions as the materials described herein are intended to be included within the scope of the embodiments of the present disclosure.

[0016] Typically, a PLC program includes blocks containing user programs for processing specific automation tasks. Once programmed, these user programs can be loaded onto the controller of the PLC, where they are executed cyclically. Traditionally, program blocks are divided into different block types, including organization blocks, function blocks (FBs), functions (FCs), and data blocks (DBs). The present disclosure focuses on FB / FC and DB types. Functions are similar to FBs, except that they cannot access cyclic data storage. FBs include programming instructions, and DBs provide data as input parameters to FBs and provide storage for output parameters. Therefore, DBs can be described as interfaces between different FBs / FCs.

[0017] Broadly speaking, a system for exchanging data between programmed logic controllers and / or other data consumers using queue blocks (QBs) is presented. Queue blocks are interchangeable data types in PLCs to replace the traditional DB types. A specific QB can be implemented for each PLC. Once a QB is instantiated in the program, no changes are required to the rest of the PLC program (e.g., OBs, FBs, FCs, SFCs (library system functions)) except for the configuration of the FBs / FCs to use queue blocks instead of DBs. In programming terms, all references to DBs can be replaced with references to QBs. The replacement can be done manually or automatically by an engineering tool.

[0018] Reference now Figure 1 , shows a conventional PLC automation program 10 including FB 40 and DB 30. As shown, DB1 30 is an interface between FB1 40 and FB2 40 so as to exchange data between FB1 40 and FB2 40 through DB1 30. This conventional approach forces the automation program 10 consisting of FB1->DB1->FB2 to be assigned to a specific hardware configuration (e.g., PLC A20). The term programmable logic controller (PLC) as used herein refers to an industrial computer control system that monitors the status of input devices and makes decisions based on custom program instructions, typically located in functions / function blocks, to control the status of output devices. A PCL may include an operating system, firmware, and a processor.

[0019] Reference now Figure 2, shows an embodiment of a flexible automation program 100 using a queue block 50. QB 50 is an explicit communication primitive (queue) that the automation program can handle like a DB. Figure 2 In the example shown, QB1 50 replaces DB1 30 of the automation program 10. However, unlike a DB, a QB can separate execution from communication. Thus, for example, with the introduction of a QB 50, the same program FB1->QB1->FB2 100 can be dynamically assigned to various hardware configurations during runtime, e.g. Figure 1 A single PLC in the original program shown, such as PLC A 20 or Figure 2 Multiple PLCs are shown, such as PLC C 20 and PLC D 20. QB exists in the runtime of the PLC. In one embodiment, QB 50 can be implemented in the firmware of the PLC. Alternatively, QB 50 can be implemented in the operating system of the PLC.

[0020] In a further embodiment, QB 50 implements Figure 3 Here, QB50 can dynamically distribute the automation program FB1->QB1->FB2 100 to multiple programmable logic controllers PLC C 20, PLC D 20 and PLC E 20 during operation.

[0021] In one embodiment, QB 50 may be implemented using a message queue or a messaging library such as ZeroMQ or rabbitmq. For example, depending on the source of the data to be exchanged, the configuration of the PLC, or the platform used by the PLC, QB 50 may utilize different communication modes. While monitoring the state of the system, a programmer who understands the specific application or runtime system being implemented may select the communication mode used. Furthermore, depending on this state of the system / network, different communication modes may be selected to achieve faster execution times, lower cycle times, etc. For example, QB 50 may provide the following different communication modes:

[0022] Peer-to-peer - single producer and single consumer.

[0023] Request-Reply - connects consumers to producers via a communication broker.

[0024] Publish-Subscribe - connects a set of publishers to a set of subscribers.

[0025] Map-Reduce - dataflow execution, where consumers initiate their computations upon receiving input from producers.

[0026] Broadcast - The producer broadcasts information to the network.

[0027] Although the QB 50 may utilize any of the communication modes described above to exchange data between the FBs 40 of different PLCs 20, the QB may also utilize other communication modes not listed herein.

[0028] In one embodiment, the message queuing capability of QB utilizes a communication pattern such as a publish-subscribe communication pattern to implement Figure 4 The publish-subscribe communication pattern is a messaging pattern in which the sender of messages (called the publisher) does not program messages to be sent directly to specific receivers (called subscribers), but instead categorizes published messages into classes without knowing what, if any, subscribers there may be. Similarly, subscribers express interest in one or more classes and receive only messages of interest without knowing what, if any, publishers there may be. Now refer to Figure 4 In an exemplary embodiment of the present invention, sensor values ​​from sensors 60 in an automation environment can be published by FB1 40 using QB1 50 to data consumers, i.e., subscribers authorized to read the values ​​from the Internet 70. The data consumers in this example can be non-PLC applications 80, which are written in different languages ​​such as C, C++, Python, Java, etc. Therefore, using QB 50, multi-platform compatibility can be achieved. Although sensor values ​​are used in the exemplary embodiment, other values ​​from other IoT devices can also be exchanged in the described manner.

[0029] In other embodiments, QB allows for parallel and distributed computing models in automation networks. This will greatly benefit new applications that require higher processing at the edge, as close to the sensor 60 as possible. For example, refer to Figure 5 , function block FB1 40 assigned to PLC C 20 needs to perform calculations on sensor values ​​from sensor 60, but FB1 40 does not have the computational power to obtain the results before the deadline. In one embodiment, QB1 50 utilizes the request-reply communication mode of its message queue to allow more powerful PLCs 20 to perform calculations on FB2 40. In the embodiment shown, QB1 50 sends a request to the pool of PLCs 90, PLC C, PLCE, and PLC F. Because these PLCs may be performing other tasks, the first PLC that reads the sent message and is able to perform the calculation responds to the request and sends the result back to FB1 40 before the deadline is missed.

[0030] Figure 6Another example of the distributed and parallel processing capabilities of an automation system utilizing QB 50 is shown. In this example, a complex calculation is split into two PLCs, PLC D 20 and PLC E 20. A map-reduce communication pattern from a message queue is used. The map-reduce communication pattern includes a map function that performs filtering and / or sorting of input data into tasks. The reduce function then performs summary operations. In the example shown, a complex calculation on a sensor value from a sensor 60 can be split into two PLCs, PLC D 20 and PLC E 20. After FB2 40 of PLC D 20 and PLC E 20 completes their portion of the calculation, the results can be collected into FB3 40 for final processing.

[0031] The queue block has many advantages over the traditional inflexible data blocks. For example, QB supports multi-platform implementations of automation networks, where PLCs can communicate freely with each other and with other non-PLC applications. Programs from one PLC can be easily migrated to other PLCs because they are no longer bound to specific hardware. In addition, the queue block allows parallel and distributed processing by utilizing QB's message queues. As computing needs increase, new nodes can be added or removed. Automation engineering programs, by utilizing queue blocks, now exchange data dynamically, with the result that they are no longer fixed to a specific configuration, but can adapt to different runtime conditions. In summary, the queue block provides flexibility in the automation system, making it easy to exchange data between PLCs and non-PLC applications.

[0032] While the embodiments of the present disclosure have been disclosed in exemplary forms, it will be apparent to those skilled in the art that various modifications, additions and deletions are possible, without departing from the spirit and scope of the invention and its equivalents as set forth in the accompanying claims.

Claims

1. A system for exchanging data in an automated environment (10), comprising: A first programmable logic controller (20), comprising program instructions, the program instructions being executable by the first programmable logic controller (20), wherein the program instructions are implemented in a function block (40) within the first programmable logic controller (20); and A queue block (50) is implemented for use in the first programmable logic controller, wherein the queue block is used as an interchangeable data type in the first programmable logic controller to replace a data block type, wherein the function block (40) is configured to use the queue block (50) instead of the data block, wherein the queue block (50) dynamically allocates the first function block to the first programmable logic controller (20) during operation, and the queue block is configured to dynamically exchange data between the first function block and a data consumer during operation; and The data consumer is a second programmable logic controller having a second function block containing program instructions executable by the second programmable logic controller, and the queue block is configured to dynamically exchange data between the first programmable logic controller and the second programmable logic controller by exchanging data between the first function block and the second function block.

2. The system according to claim 1, wherein: The queue block (50) is implemented in the firmware or operating system of the first programmable logic controller (20).

3. The system according to claim 1, wherein: The queue block (50) also includes a message queue for communicating between the first programmable logic controller (20) and the data consumer.

4. The system according to claim 3, wherein: The message queue supports a plurality of communication modes selected from the group consisting of point-to-point, request-reply, publish-subscribe, map-reduce, broadcast, and combinations thereof.

5. The system according to claim 4, wherein: Utilizing a publish-subscribe communication mode of the message queue on the Internet (70), data values ​​are exchanged between the program instructions of the first programmable logic controller and the data consumer (80), so that the data values ​​are published by the message queue to subscribing clients authorized to read the data values ​​from the Internet (70).

6. The system according to claim 5, wherein: The data value is a value from the IoT device (60).

7. The system according to claim 6, wherein: The IoT device (60) is a sensor within the automation environment (10).

8. The system according to claim 3, wherein: The queue block (50) enables parallel and distributed computing in the first programmable logic controller (20) via the message queue.

9. A computer-implemented method for exchanging data between a first programmable logic controller (20) and a data consumer in an automation system (10), comprising: providing a queue block (50) for dynamic data exchange between a first function block (40) and the data consumer, the first function block (40) comprising program instructions executable by the programmable logic controller (20), wherein the queue block serves as an interchangeable data type in the first programmable logic controller for replacing a data block type; wherein the first functional block (40) is configured to use the queue block (50) instead of the data block, allocating the first function block (40) to the first programmable logic controller (20) via the queue block (50) at runtime; and exchanging data between the first programmable logic controller (20) and the data consumer; The data consumer is a second programmable logic controller, the second programmable logic controller has a second function block, the second function block contains program instructions executable by the second programmable logic controller, and the queue block is configured to dynamically exchange data between the first programmable logic controller and the second programmable logic controller by exchanging data between the first function block and the second function block.

10. The method according to claim 9, further comprising: receiving, via the first functional block (40), a data value corresponding to an IoT device in the automation system (10), publishing the data value to the data consumer (80) via the message queue of the queue block (50); and The data value is read by the data consumer (80) via the Internet.

11. The method according to claim 9, further comprising: The computation is distributed to a plurality of other functional blocks via the message queue of the queue block (50).

12. The method according to claim 11, further comprising: receiving, via the first functional block (40), a data value corresponding to an IoT device in the automation system (10), requesting, via the message queue of the queue block (50) from a pool of function blocks (90) comprising the plurality of other function blocks, a calculation to be performed on the data value, each function block of the pool (90) being assigned to the second programmable logic controller and containing program instructions executable by the second programmable logic controller, and The calculations performed on the data values ​​are responded to by the function blocks of the function block pool (90).

13. The method of claim 11, further comprising receiving, via the first function block (40), a data value corresponding to an IoT device in the automation system (10), mapping, via the message queue of the queue block (50), calculations to be performed on the data values ​​to the plurality of other function blocks, each other function block being assigned to a respective second programmable logic controller and containing instructions executable by the second programmable logic controller, and The computation of the function block of the plurality of other function blocks is reduced via a queue block (50).

14. A system for exchanging data in an automated environment, comprising: at least one programmable logic controller (20); A function block (40) comprising program instructions, wherein the program instructions are executable by the at least one programmable logic controller (20); as well as A queue block (50) is configured to dynamically exchange data between the function block (40) of at least one programmable logic controller and a data consumer during operation, wherein the queue block (50) dynamically assigns a first function block to a first programmable logic controller (20) during operation, wherein the queue block is used as an interchangeable data type in the first programmable logic controller to replace a data block type, wherein the first function block is configured to use the queue block (50) instead of a data block, and the data consumer is a second programmable logic controller, the second programmable logic controller having a second function block containing program instructions executable by the second programmable logic controller, and the queue block is configured to dynamically exchange data between the first programmable logic controller and the second programmable logic controller by exchanging data between the first function block and the second function block.

Citation Information

Patent Citations

  • Method and device for automatically generating application programs of programmable logic controllers

    CN103235549A

  • Method for realizing programmable real-time logic in programmable logic controller and system thereof

    CN103901808A

  • Method for processing data and terminal

    CN106502817A

  • Distributed embedded data and knowledge management system integrated with PLC historian

    CN108369404A

  • Method, system, and program for managing parity RAID data reconstruction

    CN1965298A