Remote IO coupler based on xenomai operating system and control method thereof

CN122802562APending Publication Date: 2026-09-22BEIJING SIFANG JIBAO AUTOMATION +1
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202610611723.8
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2026-05-07
Publication Date
2026-09-22

AI Technical Summary

Technical Problem

[0004]为克服现有技术中工业耦合器实时性与开放性难以兼顾的缺陷,本发明提供一种基于Xenomai的远程IO新型耦合器,既能满足与PLC协同工作的实时控制需求,又能实现物联网对接、边缘计算等拓展功能

Benefits of technology

1)实时性与开放性兼顾:通过Xenomai的双内核架构,实时核保证与PLC协同的高确定性控制,非实时核利用Linux生态实现物联网、边缘计算等功能,解决传统设备的功能局限;

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122802562A_ABST
    Figure CN122802562A_ABST
Patent Text Reader

Abstract

The application provides a remote IO coupler based on a Xenomai operating system and a control method thereof, a coupler program of the remote IO coupler is compiled as a Xenomai integrated application, and a real-time part and a non-real-time part are divided in a program structure logic; the real-time part establishes a real-time communication link with a controller; the non-real-time part acquires non-real-time data from a real-time core of the Xenomai operating system through a data sharing mechanism, performs edge computing processing, and is uploaded to an Internet of Things platform through an Internet of Things interface after format conversion; the application considers real-time performance and openness, supports various industrial communication protocols and Internet of Things protocols, realizes local data processing and decision-making through edge computing function, reduces cloud transmission pressure, and improves response speed and intelligent level of an industrial system.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention belongs to the field of novel Internet of Things (IoT) industrial automation technology, and more specifically, relates to a method for implementing a remote I / O coupler based on the Xenomai operating system. Background Technology

[0002] Traditional couplers often employ dedicated RTOS (Real-Time Operating System), which, while ensuring real-time performance, suffers from limited functionality and poor scalability, making it difficult to adapt to emerging industrial demands such as the Internet of Things (IoT) and edge computing. On the other hand, devices based on general-purpose operating systems (such as, but not limited to, Linux), while offering rich expansion capabilities, lack sufficient real-time performance to meet the microsecond or millisecond-level response requirements of industrial control. Therefore, achieving both high real-time performance and strong scalability within a single device has become a significant technical challenge in the field of industrial automation.

[0003] In addition, there are generally two ways to collect field equipment data: 1) Remote IO data is uniformly aggregated to PLC (Programmable Logic Controller) and uploaded by PLC. This requires additional communication and data forwarding or calculation configuration of PLC, which has additional impact on the core main control design. Especially for the Internet of Things transformation of existing industrial automation systems, it inevitably introduces the risk of changes in the stability of the main control; 2) Deploy additional sensor acquisition system. Although this avoids affecting the control system, it increases the cost of sensors, Internet of Things gateways and deployment and maintenance. Summary of the Invention

[0004] To overcome the shortcomings of existing industrial couplers that struggle to balance real-time performance and openness, this invention provides a novel remote I / O coupler based on Xenomai. This coupler not only meets the real-time control requirements for collaborative work with PLCs but also enables extended functions such as IoT connectivity and edge computing. In practical applications, this coupler can satisfy the PLC's real-time control of field devices, for example, but not limited to, with a response latency consistently below 300μs. It also allows for remote monitoring via the Alibaba Cloud platform and early warning of device anomalies through edge computing, thus improving the system's intelligence and operational efficiency compared to traditional couplers.

[0005] The present invention adopts the following technical solution.

[0006] The first aspect of the present invention provides a remote I / O coupler based on the Xenomai operating system. The coupler program of the remote I / O coupler is compiled as an integrated Xenomai application and is logically divided into a real-time part and a non-real-time part in terms of program structure. The real-time part establishes a real-time communication link with the controller. The non-real-time part adds the acquisition of non-real-time data from the real-time kernel of the Xenomai operating system through a data sharing mechanism, performs edge computing processing and format conversion, and then uploads it to the Internet of Things platform through the Internet of Things interface.

[0007] Preferably, the real-time component establishes a real-time communication link with the controller, including: Receive control commands and collect real-time data from the IO interface module to ensure data transmission latency parameters; It parses the received control commands, drives the IO interface module to perform corresponding actions, and feeds back the execution results to the controller.

[0008] Preferably, the real-time task scheduling method is a priority preemption system, with the real-time data acquisition task having the highest priority, followed by the real-time high-speed bus communication task, and then the real-time data distribution task.

[0009] Preferably, the non-real-time portion adopts a time-slice rotation scheduling method, and its overall priority is lower than that of the real-time portion.

[0010] Preferably, the data exchanged between the real-time and non-real-time parts is I / O data, and the data exchange is performed using a globally allocated shared memory method.

[0011] Preferably, the size of the shared memory is set according to the real-time write speed and the non-real-time read speed to ensure that data is not overwritten under normal circumstances; The shared memory adopts a real-time partial unidirectional write design to ensure that the IoT part does not affect the original collected data.

[0012] Preferably, the communication interface module used by the high-speed bus communication task of the real-time part includes: an industrial Ethernet interface supporting PROFINET and EtherCAT protocols, connected to the controller; The non-real-time communication task uses an IoT communication interface that supports 4G / 5G, Wi-Fi, and LoRa, preferably but not limited to supporting 4G / 5G, Wi-Fi, and LoRa, and connects to an IoT platform.

[0013] Preferably, multiple novel remote I / O couplers are physically connected in a daisy-chain manner via a high-speed real-time control bus and are uniformly controlled by a PLC.

[0014] Preferably, the edge computing processing includes: Lightweight data processing includes extracting the maximum, minimum, average, cumulative, or multi-channel data using simple arithmetic operations as feature data, avoiding the uploading of the full original collected data; Deploy a local model, perform local model inference and lightweight learning, perform anomaly detection, predictive maintenance and / or trend prediction calculations on the raw collected data, and only upload the calculation results; Data compression: The data is first compressed locally before being uploaded. Data caching: If network conditions are abnormal, slow operations such as local caching are performed first, and the data is uploaded after the network is restored.

[0015] A second aspect of the present invention provides a control method for a remote I / O coupler, used to control a remote I / O coupler based on the Xenomai operating system according to the first aspect, comprising the following steps: the remote I / O coupler establishes a real-time communication link with the controller, receives control commands and collects real-time data from the I / O interface module, ensures data transmission delay parameters, parses the received control commands, drives the I / O interface module to perform corresponding actions, and feeds back the execution results to the controller; the non-real-time part obtains non-real-time data from the real-time kernel of the Xenomai operating system through a data sharing mechanism, performs edge computing processing and format conversion, and uploads it to the Internet of Things platform through the Internet of Things interface.

[0016] Compared with the prior art, the beneficial effects of the present invention include at least the following: 1) Balancing real-time performance and openness: Through Xenomai's dual-kernel architecture, the real-time kernel ensures highly deterministic control in collaboration with the PLC, while the non-real-time kernel utilizes the Linux ecosystem to realize functions such as IoT and edge computing, thus solving the functional limitations of traditional devices; 2) High flexibility: Supports multiple industrial communication protocols and IoT protocols, and can be adapted to different brands of PLCs and cloud platforms, reducing system integration costs; 3) Intelligent upgrade: Edge computing enables local data processing and decision-making, reducing cloud transmission pressure and improving the response speed and intelligence level of industrial systems. Attached Figure Description

[0017] Figure 1 This is a schematic diagram of the connection relationship of a novel remote I / O coupler provided according to an embodiment of the present invention; Figure 2 This is a structural block diagram of a novel remote I / O coupler based on the Xenomai operating system provided in accordance with an embodiment of the present invention. Detailed Implementation

[0018] To make the objectives, technical solutions, and advantages of this invention clearer, the technical solutions of this invention will be clearly and completely described below with reference to the accompanying drawings of the embodiments of this invention. The described embodiments are merely some embodiments of this invention, and not all embodiments. Based on the spirit of this invention, all other embodiments obtained by those skilled in the art without creative effort are within the protection scope of this invention.

[0019] like Figure 1 , 2 As shown, Embodiment 1 of the present invention provides a novel remote I / O coupler based on the Xenomai operating system. It is backward compatible with conventional remote I / O coupler I / O modules and forward compatible with controller communication protocols. It adds IoT docking and edge computing capabilities. The novel coupler design is divided into real-time and non-real-time parts and performs reasonable communication.

[0020] It is worth noting that, as one of the outstanding substantive features of this invention, Xenomai is used as a strong real-time extension framework that can be deeply integrated with the Linux kernel. This solves the problem of insufficient real-time performance of remote I / O couplers based on traditional Linux systems in the prior art. It can provide coupler programs with predictable response times. Based on the core concept of this invention, coupler programs can be more widely used in the fields of embedded and industrial real-time systems.

[0021] Specifically, in this invention, the Xenomai operating system employs a dual-kernel mechanism, relying on Adeos (Adaptive Domain Environment for Operating System) to achieve collaboration between the real-time kernel and the Linux kernel. The real-time domain corresponding to Xenomai has a higher priority than the Linux domain. When a system interrupt occurs, Adeos will prioritize scheduling Xenomai to handle the interrupt and the corresponding real-time task; only when there are no real-time tasks or interrupts to handle will Linux be scheduled to run non-real-time tasks, thereby ensuring low latency and deterministic execution of real-time tasks.

[0022] The Xenomai operating system's real-time kernel provides a wealth of features, including real-time thread scheduling, user-space real-time task support, thread synchronization, clock services, and interrupt services. With its strong real-time performance and Linux compatibility, the core concept of this invention can be applied to scenarios with stringent task response time requirements, such as industrial automation control, robotics, aerospace equipment, and embedded measurement and control, becoming an important bridge connecting traditional proprietary real-time systems with the Linux open-source environment.

[0023] The coupler program is compiled as an integrated Xenomai application, simplifying the deployment structure and logically dividing the program structure into real-time and non-real-time parts.

[0024] The non-real-time portion can arbitrarily access Xenomai's non-real-time core infrastructure, preferably but not limited to slow storage devices, low-bandwidth communication devices, NPU computing units, etc., for resuming data transmission after disconnection. The real-time component strictly guarantees that the Xenomai real-time core infrastructure is invoked, and data processing only involves memory and high-speed communication devices.

[0025] The real-time component retains the original functionality of the conventional remote I / O coupler, achieving backward compatibility with conventional remote I / O coupler I / O modules. It can establish a real-time communication link with the controller, receive control commands, and collect real-time data from the I / O interface module, ensuring data transmission latency parameters.

[0026] The real-time component parses the received control commands, drives the IO interface module to perform corresponding actions, and feeds back the execution results to the controller; the controller is preferably, but not limited to, a PLC.

[0027] The non-real-time portion adds the ability to obtain non-real-time data from the real-time kernel of the Xenomai operating system through a data sharing mechanism, perform edge computing processing and format conversion, and then upload it to the IoT platform through the IoT interface.

[0028] Further preferably, but not limitingly, the edge computing processing function for implementing local data processing and decision-making includes: Lightweight data processing, including but not limited to, extracting feature data such as maximum, minimum, average, cumulative, or simple arithmetic operations on multi-channel data, thereby avoiding uploading the full amount of raw collected data; Deploy a local model, perform local model inference and lightweight learning, perform anomaly detection, predictive maintenance, trend prediction and other calculations on the raw collected data, and only upload the calculation results; Data compression: The data is first compressed locally before being uploaded. Data caching: In cases of poor network conditions, slow operations such as local caching are performed first, and uploading and other processing are carried out after the network is restored.

[0029] It is worth noting that, as one of the prominent substantive features of this invention, edge computing processing can realize the Internet of Things transformation and intelligent upgrade of existing industrial automation systems. By realizing local data processing and decision-making through edge computing functions, the pressure of cloud transmission is reduced, and the response speed and intelligence level of industrial systems are improved.

[0030] Preferably, but not limitingly, the real-time task scheduling method is a priority preemption system, with the real-time data acquisition task having the highest priority, followed by the real-time high-speed bus communication task, and then the real-time data distribution task. The non-real-time portion adopts a time-slice rotation scheduling method, and its overall priority is lower than that of the real-time portion.

[0031] Preferably, but not limitingly, the real-time and non-real-time parts mainly exchange IO data, which is characterized by being fast and intensive. Since the real-time and non-real-time functions adopt the compilation method of Xenomai integrated application, the data exchange adopts a globally allocated shared memory method. The size of the shared memory is set according to the write speed of the real-time part and the read speed of the non-real-time part to ensure that the data is not overwritten under normal circumstances. The shared memory adopts a unidirectional write design for the real-time part to ensure that the Internet of Things part does not affect the original acquired data, thereby ensuring the safety of the control process.

[0032] Preferably, but not limited to, the communication interface modules commonly used for the real-time high-speed bus communication tasks include: an industrial Ethernet interface, preferably but not limited to, supporting PROFINET and EtherCAT protocols; and an IoT communication interface commonly used for non-real-time communication tasks, preferably but not limited to, supporting 4G / 5G, Wi-Fi, and LoRa, respectively connecting the controller and the IoT platform.

[0033] Preferably, but not restrictively, multiple novel remote I / O couplers are physically connected in a daisy chain via a high-speed real-time control bus and are uniformly controlled by a PLC.

[0034] Embodiment 2 of the present invention provides a control method for a remote I / O coupler, used to control a remote I / O coupler based on the Xenomai operating system according to Embodiment 1, comprising the following steps: The remote I / O coupler establishes a real-time communication link with the controller, receives control commands and collects real-time data from the I / O interface module, ensures data transmission delay parameters, parses the received control commands, drives the I / O interface module to perform corresponding actions, and feeds back the execution results to the controller. The non-real-time portion obtains non-real-time data from the real-time kernel of the Xenomai operating system through a data sharing mechanism, performs edge computing processing and format conversion, and then uploads it to the IoT platform through the IoT interface.

[0035] As one of the significant advancements brought by this invention to the prior art, in the new IoT industrial automation system, the novel remote I / O coupler provided by this invention serves as a key component for acquiring data from field devices. It is not only responsible for transmitting real-time data to the PLC for control, but also needs to perform edge processing on the acquired data and forward it to the IoT platform.

[0036] Compared to the current conventional architecture where data aggregation and unified submission to the IoT platform are handled by the controller, this method reduces data transmission paths, distributes data processing load, and lowers the workload of the core process controller. While rationalizing the structure of the automation system, it also expands the application scope of traditional remote I / O in new IoT industrial systems. Replacing the register coupler with a new type of coupler offers significant advantages in cost control and maintaining system stability.

[0037] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention and not to limit it. Although the present invention has been described in detail with reference to the above embodiments, those skilled in the art should understand that modifications or equivalent substitutions can still be made to the specific implementation of the present invention. Any modifications or equivalent substitutions that do not depart from the spirit and scope of the present invention should be covered within the protection scope of the claims of the present invention.

Claims

1. A remote I / O coupler based on the Xenomai operating system, characterized in that: The coupler program of the remote I / O coupler is compiled as an integrated Xenomai application, and the program structure is logically divided into real-time and non-real-time parts. The real-time component establishes a real-time communication link with the controller; The non-real-time portion adds the ability to obtain non-real-time data from the real-time kernel of the Xenomai operating system through a data sharing mechanism, perform edge computing processing and format conversion, and then upload it to the IoT platform through the IoT interface.

2. The remote I / O coupler based on the Xenomai operating system according to claim 1, characterized in that: The real-time component establishes a real-time communication link with the controller, including: Receive control commands and collect real-time data from the IO interface module to ensure data transmission latency parameters; It parses the received control commands, drives the IO interface module to perform corresponding actions, and feeds back the execution results to the controller.

3. A remote I / O coupler based on the Xenomai operating system according to claim 1 or 2, characterized in that: The real-time task scheduling method is a priority preemption system, with the real-time data acquisition task having the highest priority, followed by the real-time high-speed bus communication task, and then the real-time data distribution task.

4. A remote I / O coupler based on the Xenomai operating system according to claim 3, characterized in that: The non-real-time portion adopts a time-slice rotation scheduling method, and its overall priority is lower than that of the real-time portion.

5. A remote I / O coupler based on the Xenomai operating system according to claim 1 or 4, characterized in that: The real-time and non-real-time parts exchange data as I / O data, and the data exchange is performed using globally allocated shared memory.

6. A remote I / O coupler based on the Xenomai operating system according to claim 5, characterized in that: The size of the shared memory is set according to the real-time write speed and the non-real-time read speed to ensure that data is not overwritten under normal circumstances. The shared memory adopts a real-time partial unidirectional write design to ensure that the IoT part does not affect the original collected data.

7. A remote I / O coupler based on the Xenomai operating system according to claim 1 or 6, characterized in that: The communication interface module used for the high-speed bus communication task in the real-time section includes: an industrial Ethernet interface supporting PROFINET and EtherCAT protocols, which is connected to the controller; The non-real-time communication task uses an IoT communication interface that supports 4G / 5G, Wi-Fi, and LoRa, preferably but not limited to supporting 4G / 5G, Wi-Fi, and LoRa, and connects to an IoT platform.

8. A remote I / O coupler based on the Xenomai operating system according to claim 1 or 6, characterized in that: Multiple new remote I / O couplers are physically connected in a daisy chain via a high-speed real-time control bus and are uniformly controlled by a PLC.

9. A remote I / O coupler based on the Xenomai operating system according to claim 1 or 6, characterized in that: The edge computing processing includes: Lightweight data processing includes extracting the maximum, minimum, average, cumulative, or multi-channel data using simple arithmetic operations as feature data, avoiding the uploading of the full original collected data; Deploy a local model, perform local model inference and lightweight learning, perform anomaly detection, predictive maintenance and / or trend prediction calculations on the raw collected data, and only upload the calculation results; Data compression: The data is first compressed locally before being uploaded. Data caching: If network conditions are abnormal, slow operations such as local caching are performed first, and the data is uploaded after the network is restored.

10. A control method for a remote I / O coupler, used to control a remote I / O coupler based on the Xenomai operating system as described in claims 1 to 9, characterized in that, Includes the following steps: The remote I / O coupler establishes a real-time communication link with the controller, receives control commands and collects real-time data from the I / O interface module, ensures data transmission delay parameters, parses the received control commands, drives the I / O interface module to perform corresponding actions, and feeds back the execution results to the controller. The non-real-time portion obtains non-real-time data from the real-time kernel of the Xenomai operating system through a data sharing mechanism, performs edge computing processing and format conversion, and then uploads it to the IoT platform through the IoT interface.