Gateway system of Internet of Things and data transmission method
By designing the IoT gateway system, including northbound components, southbound components, cache components and management components, the problem of poor compatibility of existing IoT gateway products has been solved, and support for multiple cloud services and IoT device protocols has been achieved, improving the support for various cloud services and IoT device protocols has been improved. System stability and compatibility.
Patent Information
- Application Number
- CN202411561162.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-11-04
- Publication Date
- 2025-02-11
AI Technical Summary
Existing IoT gateway products are poorly compatible and difficult to manage, and cannot meet the growing multi-protocol compatibility needs.
An IoT gateway system was designed, including northbound components, southbound components, cache components and management components. The northbound component is used to connect to external cloud service platforms, the southbound component connects external IoT devices through different communication protocols, the cache component is used to temporarily store device data, and the management component is used to manage the entire system and realize data transmission.
It improves the compatibility of the Internet of Things protocol, realizes support for a variety of cloud services and IoT device protocols, facilitates users to monitor and manage IoT systems, and improves the stability of the system.
Smart Images

Figure CN119420821A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of Internet of Things, and in particular to an Internet of Things gateway system and a data transmission method. Background Art
[0002] With the development of IoT technology, various smart devices are widely used in many fields such as industrial automation and smart home. However, since different devices usually use different communication protocols (such as Modbus, EtherCAT, Profinet, etc.), the interoperability between devices is poor and it is difficult to manage and control them uniformly. In addition, the communication protocols used by many old devices cannot be directly connected to modern cloud computing platforms, which limits the value of their data.
[0003] Although the gateway products currently on the market can support some protocol conversions, they are often limited to specific application scenarios or only support a limited number of protocol types, and cannot meet the growing demand for multi-protocol compatibility. Therefore, it is particularly important to develop a universal IoT gateway that can support multiple protocols and has flexible expansion capabilities. Summary of the invention
[0004] The present invention aims to solve the technical problems of poor compatibility and difficult management of existing Internet of Things gateway products.
[0005] In order to solve the above technical problems, in a first aspect, the present invention provides an Internet of Things gateway system, wherein the Internet of Things gateway system comprises a northbound component, a southbound component cache component and a southbound component;
[0006] The northbound component is used to connect to the external cloud service platform and realize data communication with the external cloud service platform;
[0007] The southbound component is used to connect different external IoT devices through different communication protocols, and manage each of the connected external IoT devices through a separate task program;
[0008] The cache component is used to temporarily store the data of the external IoT device collected by the task program;
[0009] The management component is used to manage the northbound component, the southbound component and the cache component, and to implement data transmission among the northbound component, the southbound component and the cache component.
[0010] Furthermore, the management component includes a control service module, an Internet of Things service module, a database module and an operating system module;
[0011] The control service module is used to provide control and management of the Internet of Things gateway system to users through web services;
[0012] The Internet of Things service module is used to provide the external Internet of Things device with Internet of Things internal services of different communication protocols;
[0013] The database module is used to provide data storage services to the external IoT device connected through the southbound component, and store service parameters for the task program operation;
[0014] The operating system module is used to implement the operation, performance monitoring and network connection of the Internet of Things gateway system, and to implement data transmission between the internal northbound component, the southbound component and the cache component.
[0015] Furthermore, the southbound component includes a connection module, a connection management module and a task management module;
[0016] The connection module is used to connect different external IoT devices in the form of instantiated programs through different communication protocols;
[0017] The connection management module is used to manage the connection, disconnection, data reading and writing of the external IoT device by the connection module;
[0018] The task management module is used to manage the data communication of each connected external IoT device through a separate task program.
[0019] Furthermore, the cache component is specifically used to allocate a separate cache space to each of the task programs, and read and write the data of the external IoT device acquired by the task program in the database module of the management component.
[0020] Furthermore, the northbound component includes a cloud service management module and a scheduling module;
[0021] The cloud service management module is used to store the configuration information of the external cloud service platform;
[0022] The scheduling module is used to realize data transmission between the external Internet of Things device connected through the southbound component and the external cloud service platform.
[0023] Furthermore, the internal IoT service includes at least one of an MQTT service and an OPC UA service.
[0024] In a second aspect, the present invention further provides a data transmission method, which is implemented based on the Internet of Things gateway system as described above, and the data transmission method comprises the following steps:
[0025] Initialize the management component, call the control service module to provide control management services to users, and call the Internet of Things service module to enable the internal services of the Internet of Things;
[0026] Initialize the southbound component and connect to the database module in the management component to read the service parameters of the task program;
[0027] Connecting an external IoT device through the connection module, and executing the task program corresponding to the external IoT device through the task management module;
[0028] Based on the task program, using the cache component and the management component to read and write data to the external IoT device;
[0029] Initialize the northbound component, read the configuration information of the external cloud service platform from the cloud service management module, and connect to the external cloud service platform;
[0030] Based on the scheduling module, the request instruction issued by the external cloud service platform is forwarded to the southbound component, or the data of the external IoT device acquired by the task program is read from the cache component and forwarded to the external cloud service platform.
[0031] Furthermore, the data transmission method further comprises the following steps:
[0032] In the steps of monitoring user control operations based on the control management service provided by the control service module to the user, connecting an external IoT device through the connection module, and executing the task program corresponding to the external IoT device through the task management module:
[0033] If the control service module monitors the user's startup operation, data communication is achieved with the external IoT device through the instantiation program of the connection module, and data reading and writing of the external IoT device are executed through the task program;
[0034] If the control service module detects a pause operation by the user, the executed task program is closed, and the instantiated program and data communication between the connection module and the external IoT device are disconnected;
[0035] If the control service module monitors the user's deletion operation, the instantiation program connecting the connection module and the external IoT device is deleted;
[0036] If the control service module monitors the user's adding operation, it establishes an instantiation program for connecting the connection module with the external IoT device according to the preset service parameters, and stores the preset service parameters in the database module in the management component;
[0037] If the control service module monitors the user's modification operation, the modification content is verified according to the service parameters of the instantiated program connected by the connection module and the external Internet of Things device, and the modified service parameters are stored in the database module in the management component.
[0038] The beneficial effect achieved by the present invention is that an Internet of Things gateway system that is compatible with multiple cloud services and Internet of Things device protocols is proposed. The system integrates internal Internet of Things services in the system in a software-compatible manner, and realizes the connection of external Internet of Things devices with different communication protocols through instantiation programs and independent task programs. The data communication between cloud services and Internet of Things devices is realized by modules within the system, thereby improving the compatibility of Internet of Things protocols. At the same time, based on controllable management components, it is convenient for users to monitor and manage the Internet of Things system and external Internet of Things devices, thereby improving the stability of the system. BRIEF DESCRIPTION OF THE DRAWINGS
[0039] Figure 1 Schematic diagram of the gateway architecture of the Internet of Things gateway system provided by an embodiment of the present invention;
[0040] Figure 2 is a schematic diagram of the steps of a data transmission method provided by an embodiment of the present invention;
[0041] Figure 3 It is a startup sequence diagram of the Internet of Things gateway system provided by an embodiment of the present invention. DETAILED DESCRIPTION
[0042] In order to make the purpose, technical solution and advantages of the present invention more clearly understood, the present invention is further described in detail below in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain the present invention and are not intended to limit the present invention.
[0043] Please refer to Figure 1 , Figure 1 1 is a schematic diagram of a gateway architecture of an Internet of Things gateway system provided by an embodiment of the present invention, wherein the Internet of Things gateway system includes a northbound component, a southbound component cache component and a southbound component;
[0044] The northbound component is used to connect to the external cloud service platform and realize data communication with the external cloud service platform;
[0045] The southbound component is used to connect different external IoT devices through different communication protocols, and manage each of the connected external IoT devices through a separate task program;
[0046] The cache component is used to temporarily store the data of the external IoT device collected by the task program;
[0047] The management component is used to manage the northbound component, the southbound component and the cache component, and to implement data transmission among the northbound component, the southbound component and the cache component.
[0048] The management component includes a control service module, an Internet of Things service module, a database module and an operating system module;
[0049] The control service module is used to provide control and management of the Internet of Things gateway system to users through web services;
[0050] The Internet of Things service module is used to provide the external Internet of Things device with Internet of Things internal services of different communication protocols;
[0051] The database module is used to provide data storage services to the external IoT device connected through the southbound component, and store service parameters for the task program operation;
[0052] The operating system module is used to implement the operation, performance monitoring and network connection of the Internet of Things gateway system, and to implement data transmission between the internal northbound component, the southbound component and the cache component.
[0053] The southbound component includes a connection module, a connection management module and a task management module;
[0054] The connection module is used to connect different external IoT devices in the form of instantiated programs through different communication protocols;
[0055] The connection management module is used to manage the connection, disconnection, data reading and writing of the external IoT device by the connection module;
[0056] The task management module is used to manage the data communication of each connected external IoT device through a separate task program.
[0057] The cache component is specifically used to allocate a separate cache space to each of the task programs, and read and write the data of the external IoT device acquired by the task program in the database module of the management component.
[0058] The northbound components include a cloud service management module and a scheduling module;
[0059] The cloud service management module is used to store the configuration information of the external cloud service platform;
[0060] The scheduling module is used to realize data transmission between the external Internet of Things device connected through the southbound component and the external cloud service platform.
[0061] The internal IoT service includes at least one of an MQTT service and an OPC UA service.
[0062] During implementation, the connection module can realize the connection of external IoT devices of various communication protocols based on the instantiated program, including but not limited to Modbus, Dit645, MQTT, OPC UA, Siemens, Mitsubishi, Omron, etc.
[0063] The embodiment of the present invention also provides a data transmission method, which is implemented based on the Internet of Things gateway system described in the above embodiment. Figure 2 , Figure 2 1 is a schematic diagram of a step flow chart of a data transmission method provided by an embodiment of the present invention, wherein the data transmission method comprises the following steps:
[0064] S1. Initialize the management component, call the control service module to provide control management services to users, and call the Internet of Things service module to enable the internal services of the Internet of Things;
[0065] In the embodiment of the present invention, by initializing the service module of the Internet of Things gateway system (in the form of Web backend service), port 80 is opened to allow users to log in using the web page to use the management service; at the same time, the MQTT Service and OPC UA services in the internal services of the Internet of Things are initialized. For these two services, the system also needs to monitor the communication connections on ports 1883 (MQTT), 4880 (OPC UA non-SSL), and 4881 (OPC UA SSL);
[0066] S2, initializing the southbound component, and connecting to the database module in the management component to read the service parameters of the task program running;
[0067] S3, connecting an external IoT device through the connection module, and executing the task program corresponding to the external IoT device through the task management module;
[0068] S4. Based on the task program, use the cache component and the management component to read and write data to the external IoT device;
[0069] S5. Initialize the northbound component, read the configuration information of the external cloud service platform from the cloud service management module, and connect to the external cloud service platform;
[0070] S6. Based on the scheduling module, the request instruction issued by the external cloud service platform is forwarded to the southbound component, or the data of the external IoT device obtained by the task program is read from the cache component and forwarded to the external cloud service platform.
[0071] For the southbound component, when the connection module completes data collection, the latest data will be written into the cache component. At this time, the northbound component quickly extracts the data from the cache component and directly reports it to the cloud service platform.
[0072] For the northbound component, when receiving the request sent by the cloud service platform, it will immediately forward it to the southbound component for processing, and regardless of whether the data write operation is successful or not, the southbound component will feed back the execution result to the northbound component for further response or error handling.
[0073] Based on the data transmission method described above, the startup sequence diagram of the Internet of Things gateway system provided by the embodiment of the present invention is as follows: Figure 3 shown.
[0074] In order to achieve user control management, the data transmission method further includes the following steps:
[0075] In the steps of monitoring user control operations based on the control management service provided by the control service module to the user, connecting an external IoT device through the connection module, and executing the task program corresponding to the external IoT device through the task management module:
[0076] If the control service module monitors the user's startup operation, data communication is achieved with the external IoT device through the instantiation program of the connection module, and data reading and writing of the external IoT device are executed through the task program;
[0077] If the control service module detects a pause operation by the user, the executed task program is closed, and the instantiated program and data communication between the connection module and the external IoT device are disconnected;
[0078] If the control service module monitors the user's deletion operation, the instantiation program connecting the connection module and the external IoT device is deleted;
[0079] If the control service module monitors the user's adding operation, it will establish an instantiation program for connecting the connection module with the external IoT device according to the preset service parameters, and store the preset service parameters in the database module in the management component; in this process, verification is performed according to the preset service parameters filled in by the user, and the implementation process may include verification of the naming and parameters, such as whether the IP, subnet mask, and register are beyond the normal range. If legal, they will be written into the database module;
[0080] If the control service module monitors the user's modification operation, the modification content is verified according to the service parameters of the instantiated program connected by the connection module and the external Internet of Things device, and the modified service parameters are stored in the database module in the management component.
[0081] The beneficial effect achieved by the present invention is that an Internet of Things gateway system that is compatible with multiple cloud services and Internet of Things device protocols is proposed. The system integrates internal Internet of Things services in the system in a software-compatible manner, and realizes the connection of external Internet of Things devices with different communication protocols through instantiation programs and independent task programs. The data communication between cloud services and Internet of Things devices is realized by modules within the system, thereby improving the compatibility of Internet of Things protocols. At the same time, based on controllable management components, it is convenient for users to monitor and manage the Internet of Things system and external Internet of Things devices, thereby improving the stability of the system.
[0082] Those skilled in the art can understand that all or part of the processes in the above-mentioned embodiments can be implemented by instructing the relevant hardware through a computer program, and the program can be stored in a computer-readable storage medium, and when the program is executed, it can include the processes of the embodiments of the above-mentioned methods. The storage medium can be a disk, an optical disk, a read-only memory (ROM) or a random access memory (RAM).
[0083] It should be noted that, in this article, the terms "include", "comprises" or any other variations thereof are intended to cover non-exclusive inclusion, so that a process, method, article or device including a series of elements includes not only those elements, but also other elements not explicitly listed, or also includes elements inherent to such process, method, article or device. In the absence of further restrictions, an element defined by the sentence "comprises a ..." does not exclude the existence of other identical elements in the process, method, article or device including the element.
[0084] Through the description of the above implementation methods, those skilled in the art can clearly understand that the above-mentioned embodiment methods can be implemented by means of software plus a necessary general hardware platform, and of course by hardware, but in many cases the former is a better implementation method. Based on such an understanding, the technical solution of the present invention, or the part that contributes to the prior art, can be embodied in the form of a software product, which is stored in a storage medium (such as ROM / RAM, a magnetic disk, or an optical disk), and includes a number of instructions for enabling a terminal (which can be a mobile phone, a computer, a server, an air conditioner, or a network device, etc.) to execute the methods described in each embodiment of the present invention.
[0085] The embodiments of the present invention are described above in conjunction with the accompanying drawings. What is disclosed is only the preferred embodiment of the present invention. However, the present invention is not limited to the above-mentioned specific implementation manner. The above-mentioned specific implementation manner is only illustrative rather than restrictive. Under the enlightenment of the present invention, ordinary technicians in this field can also make many forms and equivalent changes without departing from the scope of protection of the purpose of the present invention and the claims, all of which are within the protection of the present invention.
Claims
1. An Internet of Things gateway system, characterized in that: The Internet of Things gateway system includes a northbound component, a southbound component cache component and a southbound component; The northbound component is used to connect to the external cloud service platform and realize data communication with the external cloud service platform; The southbound component is used to connect different external IoT devices through different communication protocols, and manage each of the connected external IoT devices through a separate task program; The cache component is used to temporarily store the data of the external IoT device collected by the task program; The management component is used to manage the northbound component, the southbound component and the cache component, and to implement data transmission among the northbound component, the southbound component and the cache component.
2. The Internet of Things gateway system according to claim 1, characterized in that: The management component includes a control service module, an Internet of Things service module, a database module and an operating system module; The control service module is used to provide control and management of the Internet of Things gateway system to users through web services; The Internet of Things service module is used to provide the external Internet of Things device with Internet of Things internal services of different communication protocols; The database module is used to provide data storage services to the external IoT device connected through the southbound component, and store service parameters for the task program operation; The operating system module is used to implement the operation, performance monitoring and network connection of the Internet of Things gateway system, and to implement data transmission between the internal northbound component, the southbound component and the cache component.
3. The Internet of Things gateway system according to claim 2, characterized in that: The southbound component includes a connection module, a connection management module and a task management module; The connection module is used to connect different external IoT devices in the form of instantiated programs through different communication protocols; The connection management module is used to manage the connection, disconnection, data reading and writing of the external IoT device by the connection module; The task management module is used to manage the data communication of each connected external IoT device through a separate task program.
4. The Internet of Things gateway system according to claim 2, characterized in that: The cache component is specifically used to allocate a separate cache space to each of the task programs, and read and write the data of the external IoT device acquired by the task program in the database module of the management component.
5. The Internet of Things gateway system according to claim 1, characterized in that: The northbound components include a cloud service management module and a scheduling module; The cloud service management module is used to store the configuration information of the external cloud service platform; The scheduling module is used to realize data transmission between the external Internet of Things device connected through the southbound component and the external cloud service platform.
6. The Internet of Things gateway system according to claim 2, characterized in that: The internal IoT service includes at least one of an MQTT service and an OPC UA service.
7. A data transmission method, characterized in that: The data transmission method is implemented based on the Internet of Things gateway system according to claims 1-6, and the data transmission method comprises the following steps: Initialize the management component, call the control service module to provide control management services to users, and call the Internet of Things service module to enable the internal services of the Internet of Things; Initialize the southbound component and connect to the database module in the management component to read the service parameters of the task program; Connecting an external IoT device through the connection module, and executing the task program corresponding to the external IoT device through the task management module; Based on the task program, using the cache component and the management component to read and write data to the external IoT device; Initialize the northbound component, read the configuration information of the external cloud service platform from the cloud service management module, and connect to the external cloud service platform; Based on the scheduling module, the request instruction issued by the external cloud service platform is forwarded to the southbound component, or the data of the external IoT device acquired by the task program is read from the cache component and forwarded to the external cloud service platform.
8. The data transmission method according to claim 7, characterized in that: The data transmission method further comprises the following steps: In the steps of monitoring user control operations based on the control management service provided by the control service module to the user, connecting an external IoT device through the connection module, and executing the task program corresponding to the external IoT device through the task management module: If the control service module monitors the user's startup operation, data communication is achieved with the external IoT device through the instantiation program of the connection module, and data reading and writing of the external IoT device are executed through the task program; If the control service module detects a pause operation by the user, the executed task program is closed, and the instantiated program and data communication between the connection module and the external IoT device are disconnected; If the control service module monitors the user's deletion operation, the instantiation program connecting the connection module and the external IoT device is deleted; If the control service module monitors the user's adding operation, it establishes an instantiation program for connecting the connection module with the external IoT device according to the preset service parameters, and stores the preset service parameters in the database module in the management component; If the control service module monitors the user's modification operation, the modification content is verified according to the service parameters of the instantiated program connected by the connection module and the external Internet of Things device, and the modified service parameters are stored in the database module in the management component.