A multi-protocol internet of things sensor access system and intercommunication method

By using a multi-protocol IoT platform to determine sensor types and set up data relay channels, and to unpack and repack data, the problem of interoperability between sensors with different protocols is solved, and data transmission between sensors is realized.

CN116846992BActive Publication Date: 2026-04-10HARBIN VEIC TECH
View PDF 2 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
HARBIN VEIC TECH
Filing Date
2023-07-12
Publication Date
2026-04-10

AI Technical Summary

Technical Problem

IoT sensors with different protocols cannot communicate with each other due to design or protocol reasons, resulting in the inability to exchange data.

Method used

The multi-protocol IoT platform determines whether a sensor is an instant messaging device or a non-instant messaging device, and sets up a data relay channel based on the communication characteristics of different devices. It then unpacks and repackages data and sends ACK or NACK to achieve data transmission.

Benefits of technology

It enables communication between sensors with different protocols, solving the data transmission barrier caused by protocol differences.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN116846992B_ABST
    Figure CN116846992B_ABST
Patent Text Reader

Abstract

The application relates to a multi-protocol Internet of Things sensor access system and an intercommunication method, and relates to the technical field of Internet of Things, and aims to solve the problem that different protocol sensors cannot communicate with each other due to different designs or protocols in the prior art. The application judges instant communication equipment and non-instant communication equipment, and sets a transfer channel, an unpacking mode and the sending of a corresponding ACK or NACK, etc. according to the communication between different equipment, so as to solve the problem that data cannot be interchanged due to different working modes and protocols of different sensors. The application can realize the mutual communication of Internet of Things sensor equipment of different protocols, such as sensors using MQTT, HTTP and TCP modes.
Need to check novelty before this filing date? Find Prior Art

Description

TECHNICAL FIELD

[0001] The present application relates to the technical field of Internet of Things, in particular to a multi-protocol Internet of Things sensor access system and intercommunication method. BACKGROUND

[0002] Common Internet transmission Internet of Things sensors generally use different network protocols for communication according to different functions, such as HTTP, MQTT, COAP, TCP, and other common network protocols. Different protocol Internet of Things sensors have different functions, and can only access the system within the protocol and communicate with sensors within the protocol according to the protocol. Different protocol sensors cannot communicate with each other due to design or protocol reasons. SUMMARY

[0003] The purpose of the present application is to solve the problem that different protocol sensors cannot communicate with each other due to different designs or protocols in the prior art. A multi-protocol Internet of Things sensor access system and intercommunication method are proposed.

[0004] The technical solution adopted by the present application to solve the above technical problems is:

[0005] A multi-protocol Internet of Things sensor access system and intercommunication method, comprising the following steps:

[0006] Based on the transmission sensor and the target sensor that need to communicate, respectively determine whether the transmission sensor and the target sensor are instant communication devices or non-instant communication devices;

[0007] When the determination result is instant communication device and instant communication device, or the determination result is non-instant communication device and instant communication device, the multi-protocol Internet of Things platform is used as a data transfer channel, the reporting protocol is unpacked, the corresponding data is taken out, and the taken-out data is packed and forwarded according to the protocol of the target sensor, and then whether the sending is successful is sent to the transmission sensor according to the corresponding ACK or NACK;

[0008] When the determination result is non-instant communication device and non-instant communication device, first unpack the reporting protocol to obtain and store the data, and directly send ACK to the transmission sensor, and then wait for the target sensor to communicate to establish, and according to the corresponding protocol, the obtained data is encoded and sent to the target sensor;

[0009] When the result of the judgment is that the instant communication device and the non-instant communication device, the default non-instant communication device is online, when receiving the data sent by the transmission sensor, the data is unpacked and stored, and ACK is returned, after the target sensor establishes connection in the next wake-up period, the command is sequentially issued according to the order, if the target sensor does not establish connection in the wake-up period, all subsequent commands are returned NACK, and the platform does not store the subsequent commands, until the target sensor re-establishes connection.

[0010] Further, the instant communication device includes a sensor using a TCP long connection or a sensor using an MQTT long connection.

[0011] Further, the sensor using a TCP long connection is a controlled device requiring instant response, and the sensor using an MQTT long connection is a collection device without power consumption limit.

[0012] Further, the non-instant communication device includes a sensor using HTTP protocol or a sensor in non-clean session mode of MQTT.

[0013] Further, the non-instant communication device is a low-power collection device, including a smart thermometer, a wireless alarm, and a water immersion sensor.

[0014] Further, the judgment of whether the transmission sensor and the target sensor are instant communication devices or non-instant communication devices is determined by judging whether the connection state is a long connection, if it is a long connection, it is an instant communication device, otherwise it is a non-instant communication device.

[0015] Further, there is ACK between the transmission sensor and the target sensor, and the message distribution mode is:

[0016] Between long connection devices: the uplink device sends the command after unpacking, repackages and sends according to the protocol of the downlink device, and returns ACK according to whether the command arrives;

[0017] Long connection device to periodic device: the uplink device sends the command after unpacking, stores it in the server, and after the downlink device is online, it is packaged and sent according to the protocol of the downlink device, and returns ACK when the uplink device sends the command after unpacking and stores it in the server;

[0018] The uplink device sends multiple commands and the downlink device does not reach the communication period, only the first data is retained and ACK is returned, and the rest of the data is discarded and no ACK is returned;

[0019] Between periodic devices: the uplink device sends the command after unpacking, returns ACK, and waits for the downlink device to be online to send data;

[0020] ACK, namely NACK, between the transmission sensor and the target sensor, the message distribution mode is:

[0021] Between long connection devices: the uplink device sends a command after unpacking and repackages according to the protocol of the downlink device for sending;

[0022] Long connection device sent to periodic device: the uplink device sends a command after unpacking and stores it in the server, and after the downlink device is online, it is packaged according to the protocol of the downlink device and sent, the uplink device sends multiple commands and the downlink device is not in the communication period, only the first data is retained, and the rest of the data is discarded;

[0023] Between periodic devices: the uplink device sends a command after unpacking, and waits for the downlink device to be online before sending data.

[0024] The beneficial effects of the present application are:

[0025] The present application can solve the problem that different sensors cannot transmit data to each other due to different working modes and protocols by judging instant communication devices and non-instant communication devices, and setting up a transfer channel, unpacking mode, and sending corresponding ACK or NACK according to the communication between different devices.

[0026] The present application can realize the mutual communication of Internet of Things sensor devices between different protocols, such as sensors using MQTT, HTTP, and TCP methods. BRIEF DESCRIPTION OF DRAWINGS

[0027] Figure 1 The overall flowchart of the present application. DETAILED DESCRIPTION

[0028] It should be particularly noted that the various embodiments disclosed in the present application can be combined with each other without conflict.

[0029] Specific embodiment one: refer to Figure 1 Specifically, the present embodiment is a multi-protocol Internet of Things sensor access system and intercommunication method, comprising the following steps:

[0030] Obtain the transmission sensor and the target sensor that need to communicate, and judge whether the transmission sensor and the target sensor are instant communication devices or non-instant communication devices;

[0031] When the judgment result is instant communication device and instant communication device, the multi-protocol Internet of Things platform is taken as a data transfer channel, the reporting protocol is unpacked, the corresponding data is taken out, and the taken data is packaged and forwarded according to the protocol of the target sensor, and then whether the transmission sensor is sent successfully to send the corresponding ACK or NACK, the ACK is a positive feedback, the receiver replies after receiving the data, and the NACK is a negative feedback, the receiver only notifies the sender when no data is received;

[0032] When the judgment result is non-instant communication device and non-instant communication device, the reporting protocol is first unpacked, the data is obtained and stored, and the ACK is directly sent to the transmission sensor, and then the obtained data is encoded and sent to the target sensor according to the corresponding protocol after the target sensor communication is established;

[0033] When the judgment result is non-instant communication device and instant communication device, the multi-protocol Internet of Things platform is taken as a data transfer channel, the reporting protocol is unpacked, the corresponding data is taken out, and the taken data is packaged and forwarded, and then whether the transmission sensor is sent successfully to send the corresponding ACK or NACK;

[0034] When the judgment result is instant communication device and non-instant communication device, the non-instant communication device is online by default, when the data sent by the transmission sensor is received, the data is unpacked and stored, and the ACK is returned, and then the target sensor is connected after the next wake-up period, the commands are sequentially issued according to the order of the commands, if the target sensor is not connected at the wake-up period, all subsequent commands are returned NACK, and the platform no longer stores subsequent commands until the target sensor is reconnected.

[0035] The application realizes mutual communication between different protocol sensors.

[0036] The Internet of Things sensors are generally divided into the following three types according to the protocol function:

[0037] Non-instant communication, the communication link is generally linked when needed and closed when idle. The uplink communication is established periodically or when the sensor acts, generally without downlink command or allowing long downlink command delay, and the downlink command sending time occurs after the uplink command connection is established. It is commonly used in sensors using HTTP protocol or MQTT non-CleanSession mode. This kind of sensor is generally a low-power acquisition device, such as a smart thermometer, a wireless alarm, a water immersion sensor, etc.

[0038] Instant messaging, long connection, communication link is always linked, sensor device can report data and receive downlink command at any time. Commonly used in sensors using TCP long connection or using MQTT long connection. Such sensors are generally controlled devices that need instant response or acquisition devices without power consumption limit.

[0039] Limited instant messaging, communication link is generally established by protocol according to certain rules, which is not aware of business logic and has delay at hardware level. For example, sensors using MQTT protocol, which specifies a set of CleanSession fields in the protocol, allowing devices to use different communication methods as needed. After the device sleeps and the communication link is disconnected, the platform still allows some commands to be issued or displays as broken line according to the configuration platform function. For example, some metering instruments, such as electricity meters or gas meters.

[0040] The platform has a variety of different protocols for different sensors to access.

[0041] Due to the Internet NAT mechanism or firewall restrictions, messages between sensors are communicated based on server transit.

[0042] Message transmission is divided into sensor and platform communication or sensor and sensor communication.

[0043] Sensor and platform communication only needs to communicate according to the requirements of the protocol used.

[0044] Sensor and sensor communication needs to consider different factors such as sensor design and protocol, and is transmitted by unpacking and packaging by the server.

[0045] The multi-protocol Internet of Things platform needs to consider the above situations and make corresponding processing. For the above three categories of sensors, the system platform can be essentially classified into two categories, namely instant communication and non-instant communication.

[0046] For instant communication and instant communication sensors, the platform acts as a data transit channel, unpacks the reporting protocol to get the corresponding data, and packs according to the target sensor protocol and forwards it. According to whether the sending is successful, send the corresponding ACK or NACK to the sender. This function is relatively easy to implement.

[0047] For non-instant communication and non-instant communication devices, the data will be obtained by unpacking the reporting protocol and stored, and the ACK will be returned to the sender directly, while waiting for the target sensor communication to be established and the data to be sent according to the corresponding protocol.

[0048] For instant messaging equipment sent to non-instant messaging equipment, the platform needs to maintain a certain state, and by default, the non-instant messaging equipment is online. When receiving the data sent by the sending end, the data is unpacked and stored, and an ACK is returned. After the next wake-up period, the receiving end device establishes a connection, and according to the command sequence, the instructions are sequentially issued. If the device does not wake up due to failure at this time, all subsequent commands return NACK, and the platform does not store subsequent commands until the receiving end device re-establishes the connection.

[0049] The third variable sensor is summarized according to the protocol indication at this time in the above centralized case when it is first connected or reconnected after interruption.

[0050] Different protocol sensors will have different communication behaviors due to design reasons, such as maintaining a long connection between the device and the server, and periodic communication between the device and the server.

[0051] Generally, the downlink channel of the long connection device is in a state of being reachable at any time, and commands can be directly issued.

[0052] Generally, the downlink of the periodic communication device cannot be reached at any time, and it needs to wait for the device to connect before it can be reached.

[0053] Some devices require ACK (command response packet) to ensure that the data is delivered.

[0054] Some devices do not require ACK, and the command is ignored after being sent.

[0055] The technical solution mainly includes the following types

[0056] ACK communication between devices

[0057] Long connection device between: the uplink device sends the command, unpacks it, and then repackages it according to the protocol of the downlink device, and returns an ACK according to whether the command is reached.

[0058] Long connection device sent to periodic device: the uplink device sends the command, unpacks it, and stores it in the server. After the downlink device is online, it is packaged and sent according to the protocol of the downlink device. ACK occurs in the step of storing in the server to satisfy the command of the uplink device without being re-sent due to timeout. If the downlink device does not reach the communication period, only the first data is retained and an ACK is returned, and the remaining data is discarded and no ACK is returned.

[0059] Periodic device between: the uplink device sends the command, unpacks it and returns an ACK, and waits for the downlink device to be online before sending data.

[0060] No ACK communication

[0061] No ACK packet needs to be sent on the basis of the above.

[0062] In this way, the data exchange requirement between different sensors using different protocols due to different working modes is realized.

[0063] It should be noted that the specific embodiments are only an explanation and illustration of the technical solutions of the present application, and cannot be used to limit the protection scope. Any minor change made according to the claims and description of the present application shall still fall within the protection scope of the present application.

Claims

1. A multi-protocol Internet of Things sensor access system and interworking method, characterized in that The method comprises the following steps: Based on the transmission sensor and the target sensor needing communication, it is determined whether the transmission sensor and the target sensor are instant communication devices or non-instant communication devices; When the determination result is instant communication device and instant communication device, or the determination result is non-instant communication device and instant communication device, the multi-protocol Internet of Things platform is used as a data transfer channel, the reporting protocol is unpacked, the corresponding data is taken out, and the taken-out data is packed and forwarded according to the protocol of the target sensor, and then an ACK or NACK is sent to the transmission sensor according to whether the sending is successful; When the determination result is non-instant communication device and non-instant communication device, the reporting protocol is first unpacked to obtain data and store the data, and an ACK is directly sent to the transmission sensor, and then the obtained data is encoded and sent to the target sensor according to the corresponding protocol after the target sensor establishes communication; When the determination result is instant communication device and non-instant communication device, the non-instant communication device is online by default, when the data sent by the transmission sensor is received, the data is unpacked and stored, and an ACK is returned, and when the target sensor establishes a connection in the next wake-up period, the instructions are sequentially issued according to the order of the commands, if the target sensor does not establish a connection in the wake-up period, all subsequent commands are returned as NACK, and the platform no longer stores subsequent commands until the target sensor re-establishes a connection; The determination of whether the transmission sensor and the target sensor are instant communication devices or non-instant communication devices is determined by whether the connection state is a long connection, if it is a long connection, it is an instant communication device, otherwise it is a non-instant communication device. 2.The multi-protocol IoT sensor access system and intercommunication method of claim 1, wherein The instant communication device includes a sensor using a TCP long connection or a sensor using an MQTT long connection. 3.The multi-protocol IoT sensor access system and intercommunication method of claim 2, wherein The sensor using a TCP long connection is a controlled device that needs instant response, and the sensor using an MQTT long connection is a collection device without power consumption limitation.

4. The multi-protocol IoT sensor access system and intercommunication method of claim 3, wherein The non-instant communication device includes a sensor using an HTTP protocol or a sensor in a non-CleanSession mode of MQTT.

5. The multi-protocol IoT sensor access system and intercommunication method of claim 4, wherein The non-instant communication device is a low-power collection device, including a smart thermometer, a wireless alarm, and a water immersion sensor.

6. The multi-protocol IoT sensor access system and intercommunication method of claim 5, wherein If there is an ACK between the transmission sensor and the target sensor, the message distribution method is: Between long connection devices: the uplink device sends a command, unpacks it, repackages it according to the protocol of the downlink device, and returns an ACK according to whether the command is received; Long connection device to periodic device: the uplink device sends a command, unpacks it, stores it in the server, and then sends it according to the protocol of the downlink device after the downlink device is online, and returns an ACK when the uplink device sends a command, unpacks it, and stores it in the server; If the uplink device sends multiple commands and the downlink device is not in the communication period, only the first data is retained and an ACK is returned, and the remaining data is discarded and no ACK is returned; Between periodic devices: the uplink device sends a command, unpacks it, returns an ACK, and waits for the downlink device to be online before sending data; If there is no ACK between the transmission sensor and the target sensor, i.e. NACK, the message distribution method is: Long connection between devices: the uplink device sends the command after unpacking and repackages according to the protocol of the downlink device; Long connection device to periodic device: the uplink device sends the command after unpacking and stores it in the server, and then sends it after packing according to the protocol of the downlink device when the downlink device is online. If the uplink device sends multiple commands and the downlink device is not in the communication period, only the first data is retained, and the rest is discarded; Periodic device to device: the uplink device sends the command after unpacking, and waits for the downlink device to be online before sending data.

Citation Information

Patent Citations

  • Parallel processing system and method for massive real-time traffic data

    CN103237045A

  • Method and system for accessing multiple different types of Internet of Things devices to Internet of Things

    CN110417629A