Intelligent rainfall monitoring station based on industrial internet unique identification and method

CN122568663BActive Publication Date: 2026-09-11JINAN DALU ELECTROMECHANICAL CO LTD
View PDF 3 Cites 0 Cited by

Patent Information

Application Number
CN202611040569.X
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2026-07-14
Publication Date
2026-09-11
Estimated Expiration
2046-07-14

AI Technical Summary

Technical Problem

[0004]具体而言,现有技术存在以下客观缺点:(1)设备身份缺乏全局唯一性:无国家工业互联网标识解析体系分配的唯一标识编码,仅依靠局部标识进行设备识别,数据上报过程中无法从源头验证设备真伪,易出现数据篡改、非法设备接入等安全问题,无法满足工业互联网场景下“来源可溯、去向可追”的数据可信要求,也难以实现设备全生命周期的可信管理

Benefits of technology

1.通过工业互联网唯一标识和硬件写保护,实现了设备全局唯一且不可篡改的数字身份,确保数据来源可信,支持跨平台互认和全生命周期追溯,有效防止非法接入和数据伪造。

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122568663B_ABST
    Figure CN122568663B_ABST
Patent Text Reader

Abstract

This invention discloses an intelligent rainfall monitoring station and method based on a unique identifier from the Industrial Internet, belonging to the interdisciplinary field of Industrial Internet and meteorological and hydrological monitoring. The monitoring station includes a main control module, a rainfall acquisition module, a GPS acquisition module, a user communication module, and an active identifier carrier communication module. The main control module has a unique identifier code embedded in a hardware write-protected FLASH memory and performs multi-task scheduling based on a real-time operating system. It achieves high-precision positioning and automatic time zone conversion via GPS; it has a local standardized instruction set and a remote JSON instruction system, supporting three data reporting modes; during reset, only the parameter area is erased, protecting the identifier's identity. This invention achieves globally unique and trusted identity authentication for the device, real-time and efficient task scheduling, flexible multi-mode reporting, local / remote dual control, and hardware protection of the identity, improving the intelligence level and data reliability of rainfall monitoring, and is suitable for unattended field environments.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of interdisciplinary technology of industrial internet and meteorological and hydrological monitoring, and in particular to an intelligent rainfall monitoring station based on a unique identifier of industrial internet and its management and control method, which is applicable to real-time rainfall monitoring, trusted device identity authentication, remote centralized management and control, and multi-scenario data reporting in unattended field environments. Background Technology

[0002] Existing industrial rainfall monitoring stations mostly adopt the traditional bare-metal program development model, using state machines and status flags to manage task scheduling. This results in high coupling between equipment functional modules and low task scheduling efficiency. Rainfall and GPS data acquisition and communication interaction functions lack standardized communication interface design. Data acquisition and reporting rely on local hardware triggers and fixed parameter configurations. Equipment identification still relies on local identifiers such as MAC addresses and device serial numbers, lacking a globally unified unique identifier for the industrial internet.

[0003] Existing rainfall monitoring stations cannot achieve proactive and reliable connections with industrial internet platforms. Data reporting is mostly forwarded via local serial ports or simple wireless modules, requiring edge gateways for protocol conversion and data uploading. Device configuration, parameter modification, and data querying all require on-site operation, lacking remote centralized management capabilities. Adjustments to core parameters such as reporting intervals require on-site technical personnel for debugging. Furthermore, there is no unified identification and binding mechanism for various data reports, making it impossible to accurately trace data sources. Data from different monitoring stations is difficult to achieve cross-platform and cross-enterprise interoperability, and there is a lack of a comprehensive local debugging command system, resulting in low on-site operation and maintenance efficiency. The system architecture is: upper-layer simple monitoring terminal / local computer → edge forwarding module → rainfall monitoring station → rainfall / GPS acquisition sensor. In this architecture, the rainfall monitoring station acts as a passive data acquisition node, lacking an independent global digital identity. Data reporting and device management heavily rely on local operation and edge forwarding nodes, lacking intelligent and remote control capabilities.

[0004] Specifically, the existing technology has the following objective disadvantages: (1) Lack of global uniqueness of device identity: There is no unique identifier code assigned by the national industrial internet identifier resolution system. Device identification is based solely on local identifiers. During the data reporting process, the authenticity of the device cannot be verified from the source. This can easily lead to security issues such as data tampering and illegal device access. It cannot meet the data trust requirements of "traceable source and traceable destination" in the industrial internet scenario, and it is also difficult to achieve trustworthy management of the entire life cycle of the device. (2) Low task scheduling efficiency and high module coupling: The task management is based on the state machine and state flag of the traditional bare-metal program. There is no task scheduling mechanism of the professional real-time operating system. The functional modules such as rainfall collection, GPS collection, and communication interaction do not have standardized communication interfaces. The coupling between modules is high, the program has poor scalability and maintainability, and it is easy to encounter problems such as data collection delay and reporting failure caused by task blocking. (3) Passive connection and data reporting mode: It is impossible to actively initiate a trusted connection to the industrial internet IoT platform. It must rely on the edge forwarding module for data transmission, which increases the system complexity and data transmission delay. The data reporting form is singular and lacks trigger-based, timed, and command-based multi-mode reporting mechanisms, which cannot adapt to the real-time requirements of different industrial monitoring scenarios. (4) Low efficiency in configuration and operation and maintenance: Equipment configuration, parameter modification (such as the above reporting interval), data query and other operations all need to be completed on-site. There is no remote configuration and debugging capability, and there is also a lack of a complete local standardized instruction system. Operation and maintenance personnel need to operate on-site one by one, which results in high labor costs and slow response speed, and it is impossible to achieve centralized management of large-scale monitoring stations. (5) Formation of information islands and limited data value: Due to the lack of a unified industrial Internet unique identification system, it is difficult for different manufacturers and different projects' rainfall monitoring stations and their collected data to be mutually recognized and communicated. Data can only circulate locally or within a single simple monitoring system, which cannot effectively support cross-platform and cross-enterprise industrial Internet collaborative applications. The sharing and mining value of data is severely limited. (6) Insufficient data collection and processing capabilities: The collection and parsing of rainfall and GPS data lack standardized task splitting and queue processing mechanisms, which easily leads to problems such as untimely data reception and parsing errors. GPS data has not achieved automatic time zone conversion and high-precision processing. Rainfall data does not distinguish between cumulative, today and other multi-dimensional statistics, and the level of refinement and standardization of data processing is low.

[0005] In existing technologies, such as Chinese patent CN201420361265.X, a wireless monitoring station for flood control and rainfall is disclosed, which features 4G communication and solar power supply, but does not address key features such as industrial internet identification, real-time operating system, GPS positioning, local / remote dual command sets, multi-mode reporting, and identity protection. Other similar solutions have also failed to solve the aforementioned comprehensive problems. Summary of the Invention

[0006] To address the problems in existing technologies, this invention proposes an intelligent rainfall monitoring station and method based on a unique identifier from the Industrial Internet.

[0007] The technical solution adopted by this invention to solve its technical problem is as follows: In a first aspect, embodiments of the present invention provide an intelligent rainfall monitoring station based on a unique identifier from the Industrial Internet, comprising: The main control module has a built-in unique industrial internet identifier code, identifier resolution client, device security certificate and encryption key pair. The main control module runs on the FreeRTOS real-time operating system, manages multiple functional tasks through a task scheduler, and is equipped with message queues, semaphores and FreeRTOS software timers. The rainfall acquisition module is connected to the tipping bucket rain gauge via a pulse signal pin. It uses the rising edge to trigger an external interrupt, accumulates rainfall after debouncing by a software timer, and calculates today's rainfall based on the GPS date. The GPS acquisition module connects to the GPS sensor through the first serial communication interface, uses the serial port idle interrupt to receive raw data and store it in the communication queue, and the parsing task completes message verification, time zone conversion and latitude and longitude extraction. The user communication module provides a local standardized instruction set based on the second serial communication interface. The instruction set includes instructions for device configuration, information query, data reading, and reporting interval setting, and supports error code feedback. The active identification carrier communication module interacts with the active identification carrier based on the third serial communication interface, adopts the MQTT protocol and TLS encrypted tunnel to achieve a trusted connection with the industrial Internet of Things (IoT) platform, and forwards remote commands from the platform. The storage module has a FLASH memory that is at least divided into a program storage area, an identifier-specific storage area, and a parameter storage area. The identifier-specific storage area has hardware write protection and is used to store the unique identifier code and certificate. The parameter storage area is used to store runtime configuration and temporary data. The reset module, in response to a reset trigger signal, performs an erase operation only on the parameter storage area, while the data in the identifier-specific storage area remains unchanged due to hardware write protection; The power module provides a wide voltage input and independently powers the active identification carrier.

[0008] This intelligent rainfall monitoring station includes a main control module, a rainfall acquisition module, a GPS acquisition module, a user communication module, an active identifier carrier communication module, a storage module, a reset module, and a power supply module. The main control module incorporates a unique industrial internet identifier code conforming to GB / T 36377-2018, which is permanently stored in a hardware write-protected FLASH partition. Combined with an identifier resolution client, it enables device registration and authentication. The main control is based on the FreeRTOS real-time operating system and employs multi-priority task scheduling, message queues, semaphores, and independent software timers to improve task real-time performance and reliability. Rainfall acquisition achieves accurate measurement through interrupts and debouncing, while GPS acquisition achieves high-precision positioning and time zone conversion through serial port idle interrupts and queues. The user communication module provides the USART2 local standardized instruction set, and the active identifier carrier communication module implements MQTT+TLS encrypted communication through USART3, supporting both local and remote dual control. The storage module distinguishes between an identifier area (write-protected) and a parameter area; during reset, only the parameter area is cleared, protecting the identifier's identity. The power supply module provides wide voltage input and independent power supply.

[0009] Secondly, the present invention provides a management and control method for an intelligent rainfall monitoring station, comprising the following steps: Step S1: After the device is powered on, the main control module reads the unique industrial internet identifier code and device certificate from the identifier-dedicated storage area, initiates a registration request to the secondary node of the industrial internet through the active identifier carrier, obtains the session temporary key after verifying the legality of the certificate, and establishes a trusted connection with the IoT platform. Step S2: The rainfall acquisition module detects the rising edge of the tipping bucket rain gauge pulse, triggers an external interrupt, accumulates the rainfall value after debouncing by the software timer, and calculates today's rainfall based on the date information provided by the GPS acquisition module. In step S3, the GPS acquisition module receives raw NMEA data through the first serial communication interface, stores the data into a queue using an idle interrupt, and the parsing task performs message verification, UTC time extraction, and time zone conversion to generate high-precision latitude and longitude and local time. Step S4: The main control module determines the reporting trigger conditions. If the trigger-based reporting conditions are met, data reporting is executed immediately; if the timed reporting conditions are met, data is reported periodically; if a remote instruction is received from the platform, command-based reporting is executed; all reported data is bound to the unique identifier code. Step S5: The user communication module listens to the second serial communication interface, receives local standardized instructions, parses them, executes the corresponding operation, and returns a response or error code. Step S6: The active identification carrier communication module listens to the third serial communication interface, receives the remote command in JSON format sent by the platform, parses it, executes the corresponding action, and feeds back the execution result; In step S7, when the reset module detects a reset trigger signal, it performs a full erase only on the parameter storage area, and the exclusive storage area remains unchanged due to write protection. After the erase is completed, the device automatically restarts and repeats steps S1 to S6 without needing to re-register the device identity.

[0010] One of the above technical solutions has the following advantages or beneficial effects: 1. By using unique industrial internet identifiers and hardware write protection, a globally unique and tamper-proof digital identity for each device is achieved, ensuring the reliability of data sources, supporting cross-platform mutual recognition and full lifecycle traceability, and effectively preventing unauthorized access and data forgery.

[0011] 2. By adopting the FreeRTOS real-time operating system, the interrupt response time is reduced from 200ms in traditional bare metal to less than 10ms. Tasks are decoupled through queues and semaphores, and the failure of a single task does not affect the whole machine, significantly improving system stability and scalability.

[0012] 3. It integrates high-precision GPS positioning and automatic time zone conversion, outputting latitude and longitude to six decimal places and UTC+8 time, which improves the spatial and temporal accuracy of monitoring data and provides high-quality basic data for subsequent analysis.

[0013] 4. Design a USART2 local standardized instruction set and a USART3 remote JSON instruction system to achieve dual configuration and debugging on-site and remotely. Maintenance personnel can complete parameter modification and data query without being on-site, which is expected to save more than 80% of labor costs.

[0014] 5. It supports three reporting modes: triggered, scheduled, and command-based, which can be flexibly adapted to different scenarios such as rainstorm emergency response, daily statistics, and platform retrieval, thus significantly improving the real-time performance and flexibility of data reporting.

[0015] 6. The FLASH partition write protection mechanism ensures that the unique identifier and certificate are not erased during reset, avoiding repeated registration processes and greatly simplifying field deployment and fault recovery operations.

[0016] 7. The aforementioned technical methods, through systematic integration, have generated a synergistic effect: the binding of identifiers to hardware ensures identity trustworthiness, RTOS ensures real-time response, GPS provides spatiotemporal attributes, dual commands enable full-scenario control, multi-mode reporting covers differentiated needs, and reset protection enhances on-site reliability. These features work together to upgrade traditional passive data acquisition nodes into industrial internet intelligent terminals with proactive sensing, secure communication, and intelligent control, achieving unexpected technical results. Attached Figure Description

[0017] Figure 1This is a schematic diagram illustrating the structure of an intelligent rainfall monitoring station based on a unique identifier of the Industrial Internet, according to an exemplary embodiment. Figure 2 This is a flowchart illustrating a management and control method based on a unique identifier in the Industrial Internet, according to an exemplary embodiment. Detailed Implementation

[0018] To more clearly illustrate the technical features of the present invention, the present invention will be described in detail below through specific embodiments and in conjunction with the accompanying drawings.

[0019] Example 1 like Figure 1 As shown in the figure, an embodiment of the present invention provides an intelligent rainfall monitoring station based on a unique identifier of the Industrial Internet, comprising: The main control module has a built-in industrial internet unique identifier code, identifier resolution client, device security certificate and encryption key pair. The main control module runs on the FreeRTOS real-time operating system, manages multiple functional tasks through a task scheduler, and is equipped with message queues, semaphores and FreeRTOS software timers. The main control module is connected to the GPS acquisition module through a first serial communication interface, to the user communication module through a second serial communication interface, and to the active identifier carrier communication module through a third serial communication interface. The rainfall acquisition module is connected to the tipping bucket rain gauge via a pulse signal pin. It uses the rising edge to trigger an external interrupt, accumulates rainfall after debouncing by a software timer, and calculates today's rainfall based on the GPS date. The GPS acquisition module connects to the GPS sensor through the first serial communication interface, uses the serial port idle interrupt to receive raw data and store it in the communication queue, and the parsing task completes message verification, time zone conversion and latitude and longitude extraction. The user communication module provides a local standardized instruction set based on the second serial communication interface. The instruction set includes instructions for device configuration, information query, data reading, and reporting interval setting, and supports error code feedback. The active identification carrier communication module interacts with the active identification carrier based on the third serial communication interface, adopts the MQTT protocol and TLS encrypted tunnel to achieve a trusted connection with the industrial Internet of Things (IoT) platform, and forwards remote commands from the platform. The storage module has a FLASH memory that is at least divided into a program storage area, an identifier-specific storage area, and a parameter storage area. The identifier-specific storage area has hardware write protection and is used to store the unique identifier code and certificate. The parameter storage area is used to store runtime configuration and temporary data. The reset module, in response to a reset trigger signal, performs an erase operation only on the parameter storage area, while the data in the identifier-specific storage area remains unchanged due to hardware write protection; The power module provides a wide voltage input and independently powers the active identification carrier.

[0020] Preferably, the FreeRTOS task scheduler of the main control module divides tasks into three priority levels: high, medium, and low. Among them, the rainfall external interrupt service task and the serial port idle interrupt reception task have the highest priority, the GPS parsing task, the MQTT reporting task, and the remote command parsing task have the medium priority, and the local command interaction task, the log printing task, and the status self-check task have the low priority. High-priority tasks can preempt low-priority tasks.

[0021] Preferably, the de-jitter time of the rainfall acquisition module is set to 10 milliseconds, and the FreeRTOS software timer is also used to periodically trigger rainfall data acquisition tasks, with an acquisition cycle of 30 seconds.

[0022] Preferably, the time zone conversion of the GPS acquisition module includes adding 8 hours to the UTC time and automatically handling cases of crossing days, months, and years, and outputting the date and time in the UTC+8 time zone; the latitude and longitude extraction outputs the data with six decimal places.

[0023] Preferably, the local standardized instruction set of the user communication module adopts a unified frame format, which includes a start symbol, instruction code, data length, data field, checksum, and end symbol; the error code feedback includes at least format error code, parameter range error code, and runtime resource error code.

[0024] Preferably, the active identifier carrier communication module uses MQTT 3.1.1 protocol as the main protocol and is compatible with CoAP backup protocol; the TLS encrypted tunnel is TLS 1.3 version and uses two-way certificate authentication; the service data uses AES-128-CBC symmetric encryption and the message integrity is verified using SHA256.

[0025] Preferably, the hardware write protection of the dedicated storage area is implemented through the Flash option byte or register configuration of the microcontroller, and can only be unlocked by a dedicated programming tool after verifying a specific key.

[0026] Preferably, the reset module automatically performs a checksum and detection after erasing the parameter storage area. If the checksum fails, it automatically triggers a second erasure until the parameter area is clean.

[0027] Preferably, the power module has a wide voltage input range of 5V to 12V, a ripple of less than 50mV, and is equipped with a DIP switch to control the power supply to the main controller and the active identification carrier.

[0028] Example 2 like Figure 2As shown in the figure, an embodiment of the present invention provides a management and control method for an intelligent rainfall monitoring station, comprising the following steps: Step S1: After the device is powered on, the main control module reads the unique industrial internet identifier code and device certificate from the identifier-dedicated storage area, initiates a registration request to the secondary node of the industrial internet through the active identifier carrier, obtains the session temporary key after verifying the legality of the certificate, and establishes a trusted connection with the IoT platform.

[0029] The registration request includes: the active identifier carrier encapsulates the device certificate and unique identifier into a registration message and sends it to the registration interface of the secondary node through a TLS encrypted tunnel.

[0030] The verification of certificate legitimacy includes: whether the secondary node verification device certificate was issued by its root certificate, whether it is within the validity period, and whether the unique identifier code is consistent with the subject information in the certificate.

[0031] The session temporary key is dynamically generated by the secondary node and sent to the active identifier carrier through the TLS encrypted tunnel. This key is used for AES encryption of subsequent business data.

[0032] After the trusted connection is established, the active identification carrier periodically sends heartbeat messages to the secondary node to maintain the validity of the session; when the heartbeat times out, step S1 is automatically re-executed.

[0033] In step S2, the rainfall acquisition module detects the rising edge of the tipping bucket rain gauge pulse, triggers an external interrupt, accumulates the rainfall value after debouncing by the software timer, and calculates today's rainfall based on the date information provided by the GPS acquisition module.

[0034] The external interrupt has a higher priority than all tasks, ensuring that the tipping pulse is captured within 10 microseconds; the software timer debouncing delay is 10 milliseconds.

[0035] The cumulative rainfall value is the total number of bucket tippings since the last reset of the device multiplied by the rainfall value corresponding to each tipping (0.5 mm); the today's rainfall is based on the UTC+8 date provided by GPS, and is automatically reset and recalculated at 0:00 every day.

[0036] When the number of times the rain gauge tipper is triggered exceeds a preset threshold (e.g., 5 times) within 1 minute, the trigger-based reporting in step S4 is automatically triggered, and this trigger-based reporting takes precedence over the timed reporting.

[0037] In step S3, the GPS acquisition module receives raw NMEA data through the first serial communication interface, stores the data in a queue using an idle interrupt, and performs message verification, UTC time extraction, and time zone conversion by the parsing task to generate high-precision latitude and longitude and local time.

[0038] The original NMEA data includes at least GGA and RMC statements; the message verification includes calculating the intra-frame checksum and comparing it with the frame tail checksum, and verifying the statement header identifier.

[0039] The time zone conversion is as follows: the extracted UTC time (hours, minutes, seconds) is increased by 8 hours. If the result exceeds 24 hours, the date is increased by 1 day, and the month and year are automatically adjusted. If the result is less than 0, the date is decreased by 1 day.

[0040] The high-precision latitude and longitude are retained to six decimal places and stored in the RAM of the main control module for use in step S4 when reporting; at the same time, when the positioning status is invalid, GPS data is not reported and a positioning failure log is recorded.

[0041] In step S4, the main control module determines the reporting trigger conditions. If the trigger-based reporting conditions are met (rain pulse trigger or GPS parsing completion), the data is immediately reported. If the timed reporting conditions are met (reaching the preset interval), the data is reported periodically. If a remote instruction is received from the platform, the data is reported in a command-based manner. All reported data is bound to the unique identifier code.

[0042] The trigger-based reporting conditions also include: when GPS parsing is completed and positioning is valid, an immediate report containing latitude, longitude, time and current rainfall is triggered; this report shares the same reporting queue as the tipping bucket trigger report, but the tipping bucket trigger report has a higher priority.

[0043] The preset interval for the timed reporting is dynamically configured by step S5 or step S6, with a default value of 300 seconds and an allowable range of 10 seconds to 86400 seconds; the timer is implemented using FreeRTOS software timer and does not occupy hardware timer resources.

[0044] The command-based reporting is triggered by the "rainfall report" command issued by the platform. Upon receiving the command, the main control module immediately collects the current rainfall value and GPS data and reports it, without being affected by the timed period.

[0045] All reported data is encapsulated in a uniform format, including at least: a unique identifier code, a timestamp, cumulative rainfall, today's rainfall, latitude and longitude, and location status; data packets are encrypted with AES-128-CBC and an SHA256 checksum is attached before being sent.

[0046] In step S5, the user communication module listens to the second serial communication interface, receives local standardized instructions, parses them, executes the corresponding operations (configuration, query, setting), and returns a response or error code.

[0047] The format of the local standardized instruction is as follows: start character (0xAA), instruction code (2 bytes), data length (1 byte), data field (N bytes), checksum (1 byte, XOR check), and end character (0x55); the instruction code includes at least: device configuration (0x01), information query (0x02), identifier query (0x03), rainfall query (0x04), GPS query (0x05), interval query (0x06), interval setting (0x07), and help (0x08).

[0048] The error codes include: format error (ERR_FORMAT, returns a correct format example), parameter range error (ERR_PARAM, returns the allowed range), and runtime resource error (ERR_RUN, returns the specific faulty module).

[0049] When performing the corresponding operation, if it is a configuration command (such as setting the reporting interval), the corresponding variable in the parameter storage area is updated immediately and an "OK" response is returned; if it is a query command, data is read from the current memory or parameter area and returned.

[0050] In step S6, the active identification carrier communication module listens to the third serial communication interface, receives remote instructions in JSON format from the platform, parses them, executes the corresponding actions (such as modifying the reporting interval or immediately reporting rainfall), and provides feedback on the execution results.

[0051] The JSON-formatted remote command includes at least the "method" and "params" fields; the "method" value includes "setValue" (modify the reporting interval) and "rainfall" (report rainfall immediately); the "params" value is the corresponding parameter value.

[0052] After the corresponding action is performed, the active identification carrier encapsulates the execution result (success / failure and reason) into a JSON response and feeds it back to the IoT platform via MQTT; if the execution fails, the error information is recorded in the log area of ​​the parameter storage area.

[0053] In step S7, when the reset module detects a reset trigger signal, it performs a full erase only on the parameter storage area, and the exclusive storage area remains unchanged due to write protection. After the erase is completed, the device automatically restarts and repeats steps S1 to S6 without needing to re-register the device identity.

[0054] Specifically, the step of performing a full erase on the parameter storage area only includes: the main control module sending a Flash sector erase command, the erase address range being from the start address to the end address of the parameter storage area, and verifying whether the area is write-protected before erasing (the identifier area is skipped).

[0055] After erasure is completed, the device automatically performs a hardware reset. After the reset, if the main control module detects that the parameter area is empty, it will automatically enter the configuration state and wait for new configuration parameters to be issued in step S1 or step S5. If a checksum error is detected in the parameter area, the erase will be repeated automatically.

[0056] The phrase "no need to re-register device identity" means that, since the unique identifier code and certificate in the identifier-dedicated storage area have not been erased, when the device restarts and executes step S1, the secondary node directly identifies the existing registration record and only needs to re-obtain the session temporary key, without having to re-perform the device authentication and binding process.

[0057] Example 3 This invention provides an industrial internet rainfall monitoring station based on a unique industrial internet identifier, aiming to address the aforementioned shortcomings of existing technologies. The core of this invention lies in upgrading the traditional passive rainfall monitoring station into an industrial internet intelligent monitoring terminal with a globally unique digital identity, standardized interfaces for multiple modules, dual local and remote configuration and debugging, and multi-mode data reporting. It utilizes the FreeRTOS real-time operating system for task scheduling. The system structure includes a main control module, a rainfall acquisition module, a GPS acquisition module, a user communication module, an active identifier carrier communication module, a code burning module, a power supply module, and a reset module. Each module is designed with standardized communication interfaces to achieve module decoupling and efficient collaboration.

[0058] Main control module: Based on the FreeRTOS real-time operating system, it replaces the traditional state machine with a task scheduler to realize task management and coordination of all modules; it has built-in industrial internet unique identifier code, identifier resolution client, device security certificate, encryption key pair and device configuration information (customer ID, username, password, etc.); it receives local user instructions and platform remote instructions, parses and executes corresponding configuration, query and data reporting operations; it completes the integration, processing and identifier binding of rainfall and GPS data; it has built-in encryption and decryption tasks, responsible for the encryption verification of data exchanged with active identifier carriers.

[0059] Rainfall acquisition module: The communication interface is based on the PA0 pin, configured as a pull-down input and an external interrupt triggered by the rising edge. The input signal is debouncing through a software timer. It can collect and count cumulative rainfall and today's rainfall. Today's rainfall is automatically calibrated based on GPS date information. It supports three rainfall data reporting modes: triggered, timed, and command-based. It can independently create 30-second rainfall acquisition tasks to implement dedicated reporting logic.

[0060] GPS acquisition module: The communication interface is based on USART1, configured with serial port idle interrupt to receive data and buffered through communication queue; an independent USART1 read task is created to complete the parsing and processing of GPS raw data; GPS message feature verification and positioning status judgment are implemented, and the raw data is converted into UTC+8 time zone date and time, high-precision latitude and longitude to six decimal places, and hemispherical position information; GPS data reporting is completed through trigger mode.

[0061] User communication module: The communication interface is based on USART2 (PA2, PA3 pin headers) to realize local configuration and debugging; it supports receiving device configuration, device information query, identification code query, rainfall / GPS data query, reporting interval configuration / query, help and other local standardized command sets; it completes command verification, parsing and response, and outputs device operation log, platform commands and active identification carrier return information.

[0062] Active Identifier Carrier Communication Module: The communication interface is based on USART3 (PB10 and PB11 pin headers are built-in) to realize interaction with the self-developed active identifier carrier module; it sends device configuration information (for 4G module to connect to the IoT platform) and rainfall / GPS collected data (for platform reporting) to the active identifier carrier; it receives platform remote instructions forwarded by the active identifier carrier, performs interrupt verification, forwards them to USART2 output, and executes the corresponding platform instruction logic; it realizes active and trusted connection and data interaction with the industrial Internet platform.

[0063] Communication protocol specifications: The active identification carrier adopts MQTT 3.1.1 as the main communication protocol with the industrial Internet IoT platform, and is compatible with the CoAP backup protocol in low-bandwidth field network outage scenarios; MQTT adopts QoS level 1 to ensure that data is delivered at least once and to avoid loss of rainfall and location monitoring data.

[0064] End-to-end encryption and transmission security mechanisms: Link encryption: MQTT communication uses a TLS 1.3 encrypted tunnel with two-way certificate authentication; Business data encryption: Reported rainfall, GPS, and device identification data are encrypted using AES-128-CBC symmetric encryption, with the key being uniformly distributed by the secondary identification node; instruction messages use SHA256 hash checksums appended to the end of the message, and tampered messages are discarded without execution.

[0065] Certificate and key lifecycle management process: (1) Equipment delivery stage: The main control FLASH identifier partition is fixed with the unique identifier code of the device, the device public key certificate, and the device private key; the root certificate issued by the secondary node is written to the identifier exclusive storage area; (2) Platform registration stage: The active identification carrier carries the device certificate and the unique industrial internet identifier to initiate registration with the secondary node. After the node verifies the certificate, it issues a session temporary key.

[0066] Code burning module: The Micro USB interface is used to write programs. The interface is only used for burning and does not provide power to the device.

[0067] Power supply module: It provides a wide voltage input of 5V-12V (ripple less than 50mV) through VCC and GND terminals; it supplies power to the active identification carrier module through VCC-out and GND-out terminals; and it is equipped with a DIP switch to realize the overall power supply control of the rain gauge main control module and the active identification carrier module.

[0068] Reset Module: After pressing the reset button, all configuration information saved by each module of the device will be cleared except for the industrial internet identification information and identification code. The configuration process needs to be triggered again to complete the device initialization.

[0069] 1. FLASH partition hardware division (main controller built-in 2MB Flash): Partition 1: Program Storage Area (1MB): Stores the FreeRTOS system and various business task code; read-only. Partition 2: Dedicated storage area for identification (256KB, hardware write protection enabled): Permanently stores the unique industrial internet identifier code, root certificate, device public and private keys, and identifier resolution node address; hardware write protection means it cannot be rewritten by ordinary erase commands, and can only be unlocked by the manufacturer's dedicated programming tool; Partition 3: Parameter storage area (768KB, no write protection): Stores reporting intervals, local debugging logs, temporary session keys, GPS time zone cache, temporary rainfall statistics data, and platform connection parameters.

[0070] 2. Reset the complete execution logic: Pressing the reset button triggers a hardware interrupt, and the main controller executes the layered erase process: (1) Perform a full wipe only on the partition 3 parameter storage area, clearing all temporary configurations, session keys, and statistical caches; (2) The partition 2 identifier exclusive storage area is locked due to hardware write protection, so the erase command is invalid, but the unique identifier, certificate and key are completely preserved; (3) After the erasure is completed, the device will automatically restart and enter the initialization process. The DEVICECONFIGURATION command needs to be sent again to complete the platform reconnection. There is no need to re-register the device identity.

[0071] Fault fallback logic: If the parameter partition erasure process is interrupted by a power outage, the partition checksum will be automatically detected after power is restored. If the checksum fails, a second erasure will be automatically performed to ensure that the parameter area is clean and the identifier area is not affected by the power outage.

[0072] Task scheduling based on the FreeRTOS real-time operating system: Comparison of existing bare-metal state machine defects: Traditional bare metal systems rely solely on global status flags for polling and scheduling, executing all data acquisition and communication services sequentially in a single loop. The task has no priority, and conflicts such as rainfall interruption, GPS serial port, and platform communication preemption can easily lead to task blocking. Without message queues or semaphore mechanisms, data is passed between modules through global variables, resulting in extremely high coupling. Without critical zone protection, simultaneous triggering of multiple events can cause rainfall, GPS data overlay, and parsing errors. Without an independent software timer, rainfall de-shaking and timed reporting occupy the main loop, lengthening the data collection cycle.

[0073] The improvements to FreeRTOS in this embodiment: Multi-priority task preemptive scheduling divides tasks into three priority levels: high, medium, and low. Highest priority: Rainfall external interrupt service task, serial port idle interrupt reception task (ensure real-time data collection, complete rainfall counting within 10ms of bucket tipping trigger). Medium priority: GPS parsing, MQTT reporting, and remote command parsing tasks; Low priority tasks include local command interaction, log printing, and status self-checking. High priority tasks can preempt low priority tasks to prevent data collection delays and reporting failures.

[0074] Standardized communication decoupling mechanism: FreeRTOS queues and binary semaphores are used to complete data interaction between modules, replacing global variables: GPS raw data is stored in the serial port queue and rainfall counts are stored in the acquisition queue. Each task reads and writes independently, and critical section mutex locks are used for protection, which completely reduces module coupling. New tasks only need to be connected to the standard queue interface without modifying other module code, which greatly improves scalability.

[0075] Independent software timer component: Utilizes FreeRTOS software timer to achieve rain data de-jittering, 30-second periodic data acquisition, and timed reporting without occupying the main loop. In bare-metal mode, the 200ms polling latency is reduced to less than 10ms.

[0076] Task resource isolation: Each functional task is allocated an independent stack space, and the crash of a single task will not cause the entire machine to stop. It has an automatic restart mechanism with a task watchdog; a single logical error in the bare metal state machine will directly freeze the entire machine.

[0077] The core workflow of the rainfall monitoring station of this invention revolves around active identification empowerment, multi-module collaborative data collection, local + remote dual-end control, and multi-mode data reporting. The overall process is as follows: powering on the device → module initialization → active identification carrier connection → device registration and platform authentication → data collection (rainfall / GPS) → local / remote command processing → multi-mode data reporting (binding a unique identifier).

[0078] The specific core process is as follows: 1. Active identification carrier activation and platform connection: The rain gauge's main control chip has a built-in unique industrial internet identifier (e.g., 88.163.11 / 302001142004226446020202508000002) and complete device configuration information (including custId, username, password, requestId, deviceType, etc.). After sending a local DEVICE CONFIGURATION activation command, the main control module sends the above configuration information to the active identification carrier module via USART3. After receiving the configuration information, the active identification carrier module automatically connects to the industrial internet device monitoring and control center, completes the registration and platform authentication of the rain gauge monitoring station, and establishes a trusted communication link with the IoT platform.

[0079] 2. Standardized data acquisition across multiple modules: (1) Rainfall data collection: The PA0 pin detects the rising edge signal of the rain gauge tipping bucket → triggers an external interrupt → software timer debouncing is processed → after debouncing passes, the rain data collection service is executed: the cumulative rainfall is incremented by 0.5 (rainfall from a single tipping bucket), and today's rainfall is automatically calculated based on the UTC+8 date information collected by GPS (reset to zero and re-accumulated at 0:00 every day); the independent 30-second rain data collection task is executed and reported at a fixed cycle, and is not coupled with the main collection logic.

[0080] (2) GPS data acquisition: USART1 receives raw GPS sensor data → triggers serial port idle interrupt → data is stored in USART1 communication queue → USART1 reads data from the queue and parses it: ① Verifies GPS message characteristics (the 1st, 5th, and 6th characters are '$', 'M', and 'C'); ② Parses longitude, latitude, UTC date, and UTC time to determine if positioning is successful; ③ Processes the raw data into UTC+8 time zone date and time, high-precision latitude and longitude (six decimal places), and hemispherical location information; ④ Pushes the processed GPS data to the active identification carrier module via USART3.

[0081] 3. Local configuration and debugging (based on the USART2 standardized instruction set): Users send local standardized command sets to the rainfall monitoring station via USART2. The main control module verifies and parses the commands before executing the corresponding logic. The command processing flow is as follows: USART2 receives commands → command format verification → command type identification → calling the corresponding processing function → executing configuration / query logic → USART2 outputs response results.

[0082] Core local instructions and processing logic: DEVICE CONFIGURATION: Calls the ProcessDeviceConfig function to send device configuration information via USART3 and activates the active identification carrier; DEVICE INFO: Calls the ProcessDeviceInfoQuery function, and USART2 outputs complete device configuration information; CODE: Call the ProcessIdentificationCodeQuery function to output the unique industrial internet identifier code from USART2; RAINFALL: Calls the ProcessRainfallQuery function, copies the rainfall data after critical zone protection, and outputs cumulative, today's, and 30-second rainfall data to USART2. GPS ALL: Calls the ProcessGPSQuery function to update and critical section protect GPS data. USART2 outputs latitude, longitude, time, positioning status and other data. REPORT INTERVAL: Calls the ProcessReportIntervalQuery function, and USART2 outputs the current reporting interval parameter; REPORT SET <seconds>The ProcessReportIntervalConfig function is called to verify the parameter range (10-86400 seconds), update the reporting interval, and output the setting result to USART2. HELP: Constructs help information; USART2 outputs descriptions of all available instructions.

[0083] (1) Error handling mechanism of local USART2 standardized instruction set: Format validation error: Instruction length mismatch, missing keyword, parameter exceeds character limit, returns ERR_FORMAT: Instruction format error + correct instruction example; Incorrect parameter range: For example, REPORT SET 5 (interval less than 10s) returns ERR_PARAM: reporting interval range 10~86400s; Runtime resource error: FLASH read / write failed, GPS data not found, returned ERR_RUN: Code burning module has no valid data.

[0084] (2) Remote platform JSON command error handling: JSON parsing failed (fields missing, formatting errors): The carrier returned error code: 400, msg: message parsing failed; Command not supported: The platform issued an undefined command, returning code:405, msg: command not adapted; Device offline / location failure: Requests GPS to report immediately but no location data is available, returns code:503, msg: GPS has no valid location.

[0085] 4. Remote configuration and debugging (based on platform-issued commands): The industrial internet IoT platform sends remote commands to the rainfall monitoring station through the active identification carrier module. The main control module receives and processes the commands through USART3. The process is as follows: platform sends commands → active identification carrier forwards commands → USART3 receives and triggers an interrupt → data verification → forwards to USART2 output → parses command type → executes corresponding logic.

[0086] Core platform instructions and processing logic: Reporting interval modification command: Receive JSON format command {"method":"setValue","params":value}, parse params and update the reporting interval variable interval, USART2 outputs "interval set value"; Immediate Rainfall Reporting Instruction: Upon receiving the JSON format instruction {"method":"rainfall","params":"report"}, immediately send the rainfall data to the active identifier carrier via USART3 to complete the platform reporting.

[0087] 5. Multi-mode data reporting (bound to a unique identifier): After rainfall and GPS data are collected and processed, they are bound to a unique industrial internet identifier and sent to the active identifier carrier module via USART3. The module then reports the data to the industrial internet IoT platform, supporting three reporting modes to meet the needs of different monitoring scenarios. Triggered reporting: Each time the rain gauge tipping bucket is triggered (PA0 rising edge), the cumulative and today's rainfall is immediately reported; after the GPS data is parsed, high-precision GPS information is immediately reported. Scheduled reporting: Automatically reports cumulative and today's rainfall at a fixed interval of 300 seconds by default (can be modified locally / remotely, range 10-86400 seconds). The reporting interval variable interval is globally effective. Command-based reporting: Upon receiving the "Report Rainfall Immediately" command from the platform, immediately execute the reporting of rainfall data and respond to the platform's remote call requests.

[0088] 6. Device Reset and Data Protection: Reset Module: The main control module's FLASH memory is divided into an independent identification-dedicated storage area (write-protected) and a parameter storage area. The identification-dedicated storage area is used to store industrial internet identification information and identification codes, while the parameter storage area is used to store configuration information such as reporting intervals and operating parameters. After pressing the reset button, the main control module only erases all data in the parameter storage area, while the identification-dedicated storage area remains unchanged due to write protection. All configuration information saved by each module of the device is cleared, and the configuration process needs to be triggered again to complete the device initialization.

[0089] Unique Identifier Application Mechanism: a Identifier Code: The unique industrial internet identifier for the rainfall monitoring station of this invention is 88.163.11 / 302001142004226446020202508000002. This identifier conforms to the Industrial Internet Identifier Resolution System Specification and "GB / T 36377-2018 Identification Code for Measuring Instruments," and consists of a prefix code and a suffix code. Prefix code (88.163.11): contains the national top-level node identifier, industry second-level node identifier, and enterprise node identifier, used to locate the industry, enterprise, and node to which the device belongs; The suffix code (302001142004226446020202508000002) contains the device type code, device serial number, and production batch information, used to globally and uniquely identify a single rainfall monitoring station. The main control module has a built-in identifier resolution client that can interact with the national top-level node / secondary node of the Industrial Internet Identifier Resolution System to complete identifier registration, resolution, and global uniqueness verification. The code is bound to the device configuration information (custId, deviceType, etc.) and is built into the main control module's independent FLASH storage area. It is not lost when the device is reset and serves as the device's globally unique digital identity.

[0090] Unique identifier registration, resolution, and national standard compliance: 1) Compliance with GB / T 36377-2018 "Identification Code of Measuring Instruments": The unique identification code of the equipment in the Industrial Internet fully complies with the national standard: the code prefix 88.163.11 is the prefix of the secondary node of the measuring instrument in the Industrial Internet, and the suffix segments correspond to: measuring instrument type code (rainfall monitoring station) + equipment serial number + production batch + verification code, which meets the coding standard of the entire life cycle of measuring instruments and can be directly connected to the measuring supervision platform.

[0091] 2) Complete registration process for identifiers to national / secondary nodes: (1) Equipment delivery: The manufacturer submits equipment batch information at the secondary node of the industrial internet, generates unique identification codes in batches, and writes them into the equipment FLASH identification protection area; (2) On-site deployment and power-on: The main control active identification carrier carries the identification code and equipment certificate to initiate a registration application to the secondary node; (3) The secondary node verifies the compliance of the coding (matching GB / T36377), completes the registration, and synchronizes to the national top-level node; (4) After successful registration, the node returns the identifier resolution address and session key, and the device establishes a trusted access link.

[0092] 3) Local Identifier Resolution Client Workflow The main control has a built-in lightweight identifier resolution client: (1) When the platform needs traceability data, the client sends a resolution request to the secondary node with the identifier code; (2) The node returns the equipment manufacturer, production time, deployment address, calibration record and full life cycle information; (3) The resolution result is reported to the platform along with the rainfall / GPS data, so as to realize one-click traceability of the full information of the equipment.

[0093] b identifier and data binding: All rainfall data (cumulative, today's, 30-second) and GPS data (latitude, longitude, time, hemisphere location) reported to the industrial internet platform are forcibly bound to a unique identifier code. The data is reported with the identifier information to achieve accurate traceability of the data source.

[0094] C-label enables device certification: Rainfall monitoring stations complete registration and authentication with the Industrial Internet Equipment Monitoring and Control Center through a unique identification code. The active identification carrier module achieves a two-way trusted connection with the IoT platform based on this identification, preventing unauthorized device access and data forgery.

[0095] This invention achieves globally unique and trusted identity authentication for devices, real-time and efficient task scheduling, flexible multi-mode reporting, local / remote dual control, and identity hardware protection, thereby improving the intelligence level and data reliability of rainfall monitoring and making it suitable for unattended environments in the field.

[0096] Compared with the prior art, the present invention has the following characteristics: 1) Achieve globally unique identity authentication for equipment and improve data credibility: Introduce a unique industrial internet identifier code as the global digital identity of the rainfall monitoring station, enabling the equipment to be uniquely identified in the industrial internet identifier resolution system; all reported data are bound to the identifier code, realizing the data "traceable source and destination", effectively preventing equipment forgery, data tampering and illegal access, meeting the high credibility data requirements of the industrial internet, and realizing trusted management of the entire life cycle of the equipment.

[0097] 2) Improve task scheduling efficiency and reduce module coupling: Task scheduling is implemented based on the FreeRTOS real-time operating system, replacing the traditional state machine mode, which greatly improves the real-time performance and stability of task scheduling; standardized communication interfaces are designed for each functional module to achieve module decoupling, significantly improving the program's scalability and maintainability, and avoiding problems such as data acquisition delays and reporting failures caused by task blocking.

[0098] 3) Achieve proactive and trusted connectivity, reducing system complexity: Through a self-developed proactive identification carrier module, proactive connectivity between the rainfall monitoring station and the industrial Internet of Things (IoT) platform is achieved without relying on edge forwarding modules for data transmission, reducing intermediate nodes in the system, lowering system complexity and data transmission latency; bidirectional authentication between the device and the platform is achieved based on a unique identifier, improving connection security.

[0099] 4) Enables dual local and remote configuration and debugging, significantly improving operation and maintenance efficiency: The well-designed local standardized command set (USART2) and platform remote command system enable dual local and remote operations for functions such as device configuration, parameter modification, data query, and log viewing; administrators can complete batch parameter configuration and data query for monitoring stations across the country or even the world from their office without on-site operation, greatly reducing labor costs and improving operation and maintenance response speed; local standardized commands also make on-site debugging more efficient and standardized.

[0100] It enables multi-mode data reporting and adapts to diverse industrial monitoring scenarios: It supports three data reporting modes: trigger-based, timed, and command-based. Rainfall data can be flexibly reported based on hardware triggers, fixed intervals, and platform instructions. GPS data is automatically triggered for reporting after parsing, meeting the diverse needs of different industrial monitoring scenarios for real-time and periodic data, and improving the scenario adaptability of the monitoring station.

[0101] 5) Achieve synergistic effects of technical features: Deeply integrate high-precision GPS resolution, automatic time zone conversion and unique identifier binding, and modular standardized interface, so that known GPS processing technologies can produce a synergistic effect of "precise positioning + identity traceability + secure transmission" in this system; standard hardware interfaces (USART / GPIO) serve the identifier resolution and modular architecture, and the overall system has the ability to actively join the network, trusted authentication and dual-end control that existing technologies do not have.

[0102] 6) Break down information silos and achieve cross-platform data interoperability: Based on the unique identification system of the industrial internet, data interoperability between rain gauge monitoring stations from different manufacturers and projects is achieved. Data can flow and be shared freely within the industrial internet platform, effectively supporting cross-platform and cross-enterprise industrial internet collaborative applications and fully exploring the shared and commercial value of rain gauge monitoring data.

[0103] 7) Improve the precision and standardization of data collection and processing: Enable multi-dimensional statistics of rainfall data, including cumulative, today's, and 30-second data, with today's rainfall automatically calibrated based on GPS date; perform message feature verification, high-precision parsing, and automatic time zone conversion on GPS data, outputting six decimal places of latitude and longitude and UTC+8 time zone time. The precision and standardization of data collection and processing are greatly improved, providing high-quality monitoring data for industrial applications.

[0104] 8) Implement hierarchical protection of equipment data to improve safety: Design a dedicated reset module that only clears configuration parameters when resetting the equipment, while retaining industrial internet identification information and identification codes to avoid loss of the equipment's unique identity due to misoperation; Wide voltage power input (5V-12V) and low ripple design, as well as an independent power supply control switch, improve the equipment's power supply stability and safety.

[0105] 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.< / seconds>

Claims

1. An intelligent rainfall monitoring station based on industrial internet unique identification, characterized in that, include: The main control module has a built-in unique industrial internet identifier code, identifier resolution client, device security certificate and encryption key pair. The main control module runs on the FreeRTOS real-time operating system, manages multiple functional tasks through a task scheduler, and is equipped with message queues, semaphores and FreeRTOS software timers. The rainfall acquisition module is connected to the tipping bucket rain gauge via a pulse signal pin. It uses the rising edge to trigger an external interrupt, accumulates rainfall after debouncing by a software timer, and calculates today's rainfall based on the GPS date. The GPS acquisition module connects to the GPS sensor through the first serial communication interface, uses the serial port idle interrupt to receive raw data and store it in the communication queue, and the parsing task completes message verification, time zone conversion and latitude and longitude extraction. The user communication module provides a local standardized instruction set based on the second serial communication interface. The instruction set includes instructions for device configuration, information query, data reading, and reporting interval setting, and supports error code feedback. The active identification carrier communication module interacts with the active identification carrier based on the third serial communication interface, adopts the MQTT protocol and TLS encrypted tunnel to achieve a trusted connection with the industrial Internet of Things (IoT) platform, and forwards remote commands from the platform. The storage module has a FLASH memory that is at least divided into a program storage area, an identifier-specific storage area, and a parameter storage area. The identifier-specific storage area has hardware write protection and is used to store the unique identifier code and certificate. The parameter storage area is used to store runtime configuration and temporary data; The reset module, in response to a reset trigger signal, performs an erase operation only on the parameter storage area, while the data in the identifier-specific storage area remains unchanged due to hardware write protection; The power module provides a wide voltage input and independently powers the active identification carrier; The FreeRTOS task scheduler of the main control module divides tasks into three priority levels: high, medium, and low. Among them, the rainfall external interrupt service task and the serial port idle interrupt reception task have the highest priority, the GPS parsing task, the MQTT reporting task, and the remote command parsing task have medium priority, and the local command interaction task, the log printing task, and the status self-check task have low priority. High-priority tasks can preempt low-priority tasks.

2. A management method of an intelligent rainfall monitoring station, the intelligent rainfall monitoring station being the intelligent rainfall monitoring station based on the unique identification of the industrial internet according to claim 1, characterized in that, Includes the following steps: Step S1: After the device is powered on, the main control module reads the unique industrial internet identifier code and device certificate from the identifier-dedicated storage area, initiates a registration request to the secondary node of the industrial internet through the active identifier carrier, obtains the session temporary key after verifying the legality of the certificate, and establishes a trusted connection with the IoT platform. Step S2: The rainfall acquisition module detects the rising edge of the tipping bucket rain gauge pulse, triggers an external interrupt, accumulates the rainfall value after debouncing by the software timer, and calculates today's rainfall based on the date information provided by the GPS acquisition module. In step S3, the GPS acquisition module receives raw NMEA data through the first serial communication interface, stores the data into a queue using an idle interrupt, and the parsing task performs message verification, UTC time extraction, and time zone conversion to generate high-precision latitude and longitude and local time. Step S4: The main control module determines the reporting trigger conditions. If the trigger-based reporting conditions are met, data reporting is executed immediately; if the timed reporting conditions are met, data is reported periodically; if a remote instruction is received from the platform, command-based reporting is executed; all reported data is bound to the unique identifier code. Step S5: The user communication module listens to the second serial communication interface, receives local standardized instructions, parses them, executes the corresponding operation, and returns a response or error code. Step S6: The active identification carrier communication module listens to the third serial communication interface, receives the remote command in JSON format sent by the platform, parses it, executes the corresponding action, and feeds back the execution result; In step S7, when the reset module detects a reset trigger signal, it performs a full erase only on the parameter storage area, and the exclusive storage area remains unchanged due to write protection. After the erase is completed, the device automatically restarts and repeats steps S1 to S6 without needing to re-register the device identity.

3. The method of claim 2, wherein, The registration request includes: the active identifier carrier encapsulates the device certificate and unique identifier into a registration message and sends it to the registration interface of the secondary node through a TLS encrypted tunnel.

4. The method of claim 2, wherein, The cumulative rainfall value is the total number of bucket flips since the last reset of the device multiplied by the rainfall value corresponding to each bucket flip; the today's rainfall is based on the UTC+8 date provided by GPS, and is automatically reset and recalculated at 0:00 every day.

5. The method of claim 2, wherein, The time zone conversion is as follows: the extracted UTC time is increased by 8 hours; if the result exceeds 24 hours, the date is increased by 1 day and the month and year are automatically adjusted; if the result is less than 0, the date is decreased by 1 day.

6. The method of claim 2, wherein, The trigger-based reporting conditions also include: when GPS parsing is completed and positioning is valid, an immediate report containing latitude, longitude, time and current rainfall is triggered; this report shares the same reporting queue as the tipping bucket trigger report, but the tipping bucket trigger report has a higher priority.

7. The method of claim 2, wherein, The format of the local standardized instructions is as follows: start character, instruction code, data length, data field, checksum, and end character; the instruction code includes at least: device configuration, information query, identification query, rainfall query, GPS query, interval query, interval setting, and help.

8. The control method according to any one of claims 2 to 7, characterized in that, The step of performing a full erase on the parameter storage area only includes: the main control module sending a Flash sector erase command, the erase address range being from the start address to the end address of the parameter storage area, and verifying whether the area is write-protected before erasing.

Citation Information

Patent Citations

  • Flood prevention rainwater condition wireless monitoring station

    CN204131632U

  • Equipment remote operation and maintenance method and system based on industrial internet active identification

    CN117176790A

  • Industrial Internet of Things service information processing method and system based on identification analysis

    CN121985006A