Data reporting method based on NB-IOT network communication
By combining the answer and response messages into a comprehensive message, the NB-IOT network communication process is optimized, and the inefficiency problem caused by repeated registration of frames by smart devices is solved, achieving more efficient and reliable data transmission and battery life extension.
Patent Information
- Application Number
- CN202510715442.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-05-30
- Publication Date
- 2025-07-25
AI Technical Summary
In the communication interaction between the existing NB-IOT smart devices and cloud server platforms, there are problems such as low communication efficiency, high latency and large power consumption caused by repeated registration of frames, which affects the timeliness of data transmission and the stability of management system.
By combining the answer and response messages into a comprehensive message, the communication steps are reduced, the message type is identified using function codes, and the data reporting process is optimized in NB-IOT network communication, ensuring that the message length is within the maximum transmission unit, and the data amount is compressed to meet MTU restrictions.
2 steps are reduced in each communication interaction, reducing communication overhead and latency, improving communication efficiency, extending battery life, and enhancing communication reliability and accuracy.
Smart Images

Figure CN120378056A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of Internet of Things communication, and specifically relates to a data reporting method based on NB-IOT network communication. Background Art
[0002] In the interaction application between NB-IOT intelligent devices and cloud server platforms, the unique identifier IMEI (International Mobile Equipment Identity) of the intelligent device is used for intelligent device identity recognition and network management, and needs to be registered and bound on the platform. A registration frame is designed at the application layer. Every time there is an interaction, the registration frame needs to be sent first, which wastes bandwidth and increases communication latency when reported frequently; the instruction interaction efficiency in the protocol is low. When the platform issues a query instruction, the intelligent device first replies with an answer and then sends a data report message. The communication interaction is based on a one-way linear process: the MCU of the intelligent device sends an uplink periodic message - parses the downlink answer - the platform issues a cached query instruction - the MCU of the intelligent device reports the answer, and then the MCU of the intelligent device organizes a response message and reports it again - the platform answers the response message. The low communication rate leads to problems such as untimely data transmission and packet loss, affecting the accurate collection and analysis of intelligent device data by the management department, and further affecting the stability and reliability of the entire intelligent transaction management system, which urgently needs to be improved. Summary of the Invention
[0003] One technical problem to be solved by this application is to overcome the defects of the above related technologies, and provide a data reporting method based on NB-IOT network communication, which avoids duplicate registration messages, integrates messages to reduce the number of communications, and improves communication efficiency.
[0004] The technical solution adopted by the present invention to solve the technical problem is: a data reporting method based on NB-IOT network communication, for the communication interaction between an intelligent device with an NB module and an IOT platform, specifically including the following steps:
[0005] Step 1, the MCU of the intelligent device sends an uplink periodic message;
[0006] Step 2, parse the downlink answer;
[0007] Step 3, the IOT platform issues a cached query instruction;
[0008] Step 4, the MCU reports a comprehensive message containing an answer and a response.
[0009] Compared with the related technologies, the present invention has the following advantages: The comprehensive message combines the answer message and the data message, reducing 2 communication steps in each communication interaction, reducing communication overhead and latency, and avoiding duplicate registration messages, improving communication efficiency, thereby reducing power consumption and extending battery life.
[0010] Preferably, the integrated message contains a function code. The function code is used as an identifier to facilitate the identification of the message type.
[0011] Preferably, the intelligent device is an intelligent water meter or an intelligent electricity meter with an NB module.
[0012] Preferably, the function code of the integrated message is 0x4F. It is used to identify the integrated message to improve the reliability and accuracy of communication.
[0013] Preferably, step 4 further includes determining that the length of the integrated message is less than the maximum transmission unit of NB-IoT network communication. Description of the Drawings
[0014] Figure 1 is a flowchart of the present invention. Detailed Embodiments
[0015] First of all, those skilled in the art should understand that these embodiments are only used to explain the technical principles of the embodiments of the present application, and are not intended to limit the protection scope of the embodiments of the present application. Those skilled in the art can adjust it according to needs to adapt to specific application scenarios.
[0016] The present invention will be further described in detail below with reference to the drawings and specific embodiments.
[0017] In this embodiment, taking the communication interaction scenario between an intelligent water meter with an NB module based on NB-IoT network communication and an IOT platform server as an example, the MCU of the intelligent water meter freezes the cycle flow and intelligent water meter status data within a day in the format of the application protocol (COAP protocol) at zero o'clock every day and waits to be reported. The preset cycle reporting time is obtained according to the discrete rule, and waits for the reporting moment to arrive.
[0018] After the intelligent water meter is powered on for the first time, it activates reporting or reports automatically at a fixed time. On the basis of detecting the correctness of the head and tail fields and CRC check of the message, it adds the verification and correction of key configuration information (parameters such as imei). After the verification passes, the NB module (also called the NB communication module) in the intelligent water meter searches for the network, and the MCU in the intelligent water meter sends an AT registration instruction and an AT attach network instruction to the NB module, and waits for the network attachment to succeed and the network registration to be completed.
[0019] After the network layer registration is successful, the network access and resource subscription allocation of the NB module are completed. After the one-time application layer registration is successful, the intelligent device does not need to send an application registration message before each report. By virtue of the network information cached after the application layer registration is successful, the network connection time is reduced, and only the periodic message needs to be sent regularly.
[0020] To avoid duplicate application layer registration messages, the present invention changes the response message for querying data and proposes a comprehensive message. This comprehensive message merges the response message into the response frame and adds necessary frame sequence numbers and the communication status of intelligent devices. It extracts key information such as the real-time network status and the current attributes of the intelligent water meter in the registration message, creates a registration class data structure, and adds it to the data field of the reporting frame. The data length of the reporting frame is updated, and a custom function code is added. The checksum is recalculated based on the new content, and a new reporting frame is generated according to the protocol format. It is ensured that the length of the merged comprehensive message is within the maximum transmission unit (MTU) range. According to the communication protocol, the MTU for NB-IoT network communication is 512 bytes. Thus, after the protocol interaction is optimized, the data reporting method based on NB-IOT network communication of the present invention has a communication process as follows Figure 1 shown, specifically including the following steps:
[0021] Step 1, the MCU sends an uplink periodic message;
[0022] The MCU of the intelligent water meter pushes periodic data reports to its NB module, and the NB module sends a COAP CON message to the platform. The payload in the COAP CON message is the periodic data report; the platform issues a COAP ACK message to confirm the periodic data report, and the payload in the COAP ACK message is the periodic report response + setting parameter command;
[0023] Step 2, parse the downstream response;
[0024] After the MCU of the intelligent water meter parses the downstream response, the MCU of the intelligent water meter pushes a setting parameter response to its NB module, and the NB module sends a COAP CON message to the platform. The payload in the COAP CON message is the setting parameter response;
[0025] Step 3, the platform issues a cached query instruction;
[0026] The platform issues a COAP ACK message, and the payload in the COAP ACK message is the query data;
[0027] Step 4, the MCU reports a comprehensive message containing a response and a reply;
[0028] The MCU of the intelligent water meter pushes a comprehensive message to its NB module, and the NB module sends a COAP CON message to the platform. The payload in this COAP CON message is a comprehensive message containing a response and a reply, and it is ensured that the length of the comprehensive message is less than the maximum transmission unit of NB-IoT network communication; the platform issues a CON ACK message.
[0029] Each such interaction reduces 2 communication steps compared to the existing communication process.
[0030] In addition, if the platform does not receive the comprehensive message, after waiting for the network connection to succeed, repeat the communication process.
[0031] Among them, the response frame includes a frame header - frame length - data field - checksum - frame tail. The data field of the response frame mainly contains the processing result status. The response frame includes a frame header - frame length - data field - checksum - frame tail. The data field of the response frame contains the data to be reported.
[0032] Among them, the comprehensive message is identified by the specific content in the extended data field. For example, in the smart water meter of this embodiment, the function code of the response frame is 0x40, and the function code of the response frame is 0x41. Then the function code of the comprehensive message is set to 0x4F. The first 2 bytes in the data field of the comprehensive message reserve the frame sequence number field for the platform to confirm receiving the response message; the 1-byte result status in the response frame is placed after the sequence number, and the remaining fields are filled with the data packet of the response frame. Update the data length of the comprehensive message, calculate the checksum according to the new content, and generate a new reporting frame according to the protocol format.
[0033] If the length of the comprehensive message exceeds the MTU, data compression needs to be performed on the data packet of the response frame. The MCU of the smart water meter performs compression processing on the data packet of the response frame in the comprehensive message to reduce the amount of data. For example, the compression processing uses an efficient compression algorithm to compress a large amount of raw data collected by the sensor and then send it through the NB module.
[0034] This method is also applicable to the communication scenario between smart metering devices such as smart electricity meters and the platform server based on NB-IOT network communication.
[0035] The above is only the specific implementation manner of the present application, but the protection scope of the present application is not limited thereto. Any changes or substitutions that can be easily thought of by those skilled in the art within the technical scope disclosed in the present application should be covered within the protection scope of the present application. Therefore, the protection scope of the present application should be subject to the protection scope of the claims.
Claims
1. A data reporting method based on NB-IOT network communication, for the communication interaction between an intelligent device with an NB module and an IOT platform, characterized in that, Specifically, it includes the following steps: Step 1: The MCU of the intelligent device sends an uplink periodic message; Step 2: Parse the downlink response; Step 3: The platform issues a query instruction for caching; Step 4: The MCU reports a comprehensive message of a packet of response and response.
2. The data reporting method based on NB-IOT network communication according to claim 1, wherein The comprehensive message contains a function code.
3. A data reporting method based on NB-IOT network communication according to claim 2, characterized in that, The intelligent device is an intelligent water meter or an intelligent electricity meter.
4. A data reporting method based on NB-IOT network communication according to claim 3, characterized in that, The function code of the comprehensive message is 0x4F.
5. A data reporting method based on NB-IOT network communication according to claim 1, characterized in that, Step 4 also includes determining that the length of the comprehensive message is less than the maximum transmission unit of NB-IoT network communication.