Agricultural irrigation method and system based on Internet of Things
By employing a self-organizing mesh network architecture, virtual sensor coverage, heterogeneous protocol interoperability, and collaborative sensing verification, the problems of water waste and equipment interoperability in traditional agricultural irrigation systems have been solved, achieving highly reliable, low-cost, and precise irrigation control.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- JIANGMEN QUANSHUN TECHNOLOGY CO LTD
- Filing Date
- 2026-03-18
- Publication Date
- 2026-05-19
AI Technical Summary
Traditional agricultural irrigation systems suffer from serious water waste, uneven irrigation, and an inability to provide precise irrigation based on the actual water needs of crops. IoT irrigation systems, on the other hand, suffer from problems such as centralized architecture prone to failure, high sensor deployment costs, poor interoperability of heterogeneous devices, and a lack of collaborative verification between nodes.
The system adopts a self-organizing mesh network architecture, establishes a soil moisture mapping model through multi-hop signal attenuation sensing to achieve virtual sensor coverage, dynamically adjusts the sampling frequency using a compressed sensing sampling strategy, achieves interoperability of heterogeneous protocols, and constructs a self-organizing network of node profiles, uses a collaborative sensing verification mechanism to identify abnormal data, and ensures fault-tolerant operation of the system through a fault self-diagnosis and switching mechanism.
It achieves decentralized and highly reliable operation, low-cost full-domain monitoring, seamless integration of heterogeneous devices, and collaborative verification to improve accuracy and credibility of irrigation decisions, ensuring the continuity and availability of irrigation services.
Smart Images

Figure CN122069285A_ABST
Abstract
Description
Technical Field
[0001] This invention belongs to the field of agricultural automated irrigation technology, specifically relating to an agricultural irrigation method and system based on the Internet of Things. Background Technology
[0002] Traditional agricultural irrigation systems mainly rely on timed irrigation or manual control, which leads to serious water waste, uneven irrigation, and an inability to provide precise irrigation based on the actual water needs of crops.
[0003] While existing IoT irrigation systems have introduced sensor monitoring and remote control functions, they still have the following technical shortcomings: First, they adopt a centralized architecture, and a failure of the central server can paralyze the entire system; second, there is a contradiction between sensor deployment density and monitoring accuracy, with dense deployment being costly and sparse deployment being insufficient in accuracy; third, there is a lack of effective protocol interoperability mechanisms between heterogeneous devices, resulting in poor system scalability; and fourth, there is a lack of collaborative verification mechanisms between nodes, making it difficult to identify single-point sensor failures or data anomalies.
[0004] Therefore, there is an urgent need for an IoT irrigation technology solution that can self-organize, support interoperability of heterogeneous protocols, and has collaborative sensing and verification capabilities. Summary of the Invention
[0005] To achieve the above objectives, the present invention adopts the following technical solution: On the one hand, the present invention provides an agricultural irrigation method based on the Internet of Things, comprising the following steps: S1: Multi-hop signal attenuation sensing: Obtain wireless signal strength indication values during multi-hop communication between IoT nodes, analyze the correlation between signal attenuation in each hop segment and soil medium characteristics of that path segment, establish a mapping model between hop count, soil moisture, and signal attenuation, and inversely calculate the soil moisture value of each segment on the multi-hop path based on real-time collected multi-hop signal attenuation data; This step obtains wireless signal strength indication values for multi-hop communication between IoT nodes, utilizes the correlation between signal attenuation characteristics in soil propagation and soil moisture, establishes a radial basis function neural network mapping model with path loss, hop count, etc. as input and soil moisture as output, and inversely calculates the soil moisture value of each segment on the multi-hop path based on real-time collected multi-hop signal attenuation data; S2: Compressed sensing sampling: Receives the soil moisture data obtained from step S1, performs time series analysis on historical soil moisture data, identifies its sparsity characteristics and change patterns, calculates the rate of change of soil moisture at the current moment, and dynamically adjusts the sampling frequency of the sensor according to the magnitude of the rate of change. The sampling frequency is reduced when the humidity changes slowly and increased when the humidity changes rapidly, thereby achieving optimized allocation of sampling resources. S3: Heterogeneous protocol interoperability, identifies the communication protocol type used by the connected IoT devices, parses the data frame structure of different protocols, extracts the frame header, payload and check field, establishes a unified intermediate data representation format, converts the source protocol data into the intermediate format, and then converts the intermediate format into the target protocol format, so as to realize data exchange and command transmission between IoT protocol devices. S4: Device profiling self-organizing network, collects the operating status parameters of each IoT node, including remaining power, communication link quality, processor load and storage space, constructs a multi-dimensional profile vector reflecting the comprehensive capabilities of the nodes, calculates the comprehensive capability score of each node based on the profile vector, selects the node with the highest score as the current cluster head node, and other nodes automatically join the corresponding cluster according to the connection quality with the cluster head, forming a self-organizing mesh network topology, and periodically re-evaluates and adjusts the network topology; S5: Collaborative sensing verification identifies groups of nodes that are spatially adjacent or have overlapping sensing ranges within the monitoring area. Correlation analysis is performed on the soil moisture data collected by each node in the same group. A data credibility assessment model based on Bayesian inference is constructed. The reliability of the node's historical data is used as the prior probability. The posterior probability is updated by combining the verification results of the current adjacent nodes. The credibility score of each node's data is calculated. Data with credibility below the threshold is marked as abnormal and filtered or corrected. S6: Fault self-diagnosis and switching. Establish a mutual supervision relationship chain between nodes. Each node periodically sends a heartbeat signal and listens to the heartbeat of neighboring nodes. When a node heartbeat loss or abnormal data transmission is detected, the fault diagnosis process is started. The faulty node is confirmed through multi-path detection, the routing table is updated to remove the faulty node, and an alternative communication path is automatically selected to re-establish the data transmission link. At the same time, the fault information is reported to the system.
[0006] Furthermore, the method for establishing the mapping model in S1 is as follows: during the system initialization phase, the signal attenuation data of multi-hop communication is measured and recorded under different soil moisture conditions, and a radial basis function neural network is used to train the relationship model between the number of hops, moisture and attenuation; during the system operation phase, the real-time signal attenuation data is input into the trained model, and the corresponding soil moisture estimate is output.
[0007] Furthermore, the method for dynamically adjusting the sampling frequency in S2 is as follows: calculate the difference value of multiple consecutive sampled data; when the difference value is less than a preset stable threshold, it is determined to be a stable period, and the sampling interval is extended; when the difference value is greater than a preset change threshold, it is determined to be a change period, and the sampling interval is shortened; the adjustment range of the sampling interval is adaptively determined according to the magnitude of the difference value.
[0008] Furthermore, the unified intermediate data representation format in S3 includes a device identifier field, a timestamp field, a data type field, a numerical field, and a control instruction field; semantic consistency is maintained during protocol conversion, and fields that exist in the source protocol but are missing in the target protocol are transmitted through extended fields or metadata.
[0009] Furthermore, the comprehensive capability score in S4 adopts a multi-factor weighting method, dynamically adjusting the weight coefficients of each factor according to the application scenario and network status; when the network is in a low-power mode, the weight of the remaining power is increased, and when the data transmission volume is large, the weight of the link quality is increased.
[0010] Furthermore, the Bayesian inference process in S5 includes: calculating the data accuracy of each node based on historical data as the prior probability; when new data arrives, calculating the consistency between the data and the data of neighboring nodes; updating the posterior probability of the node using the Bayesian formula based on the degree of consistency and the credibility of neighboring nodes; the posterior probability is the credibility score of the current data.
[0011] Furthermore, the multipath detection method in S6 is as follows: send multiple detection messages of different paths to the suspected faulty node, and determine whether it is a node fault or a link fault based on the detection response; if there is no response on all paths, it is determined to be a node fault, and if there is a response on some paths, it is determined to be a link fault.
[0012] On the other hand, the present invention provides an agricultural irrigation system based on the Internet of Things, comprising: The perception estimation module is used to collect signal strength data of multi-hop communication between IoT nodes, analyze the signal attenuation law in soils with different moisture levels, establish and maintain a mapping model between signal attenuation and soil moisture, and invert the soil moisture distribution based on the real-time signal attenuation. The sampling optimization module is used to monitor the temporal variation trend of soil moisture, calculate the rate of change of moisture and data sparsity, and dynamically adjust the sensor sampling frequency and sampling interval according to the data change characteristics to achieve adaptive optimization of data acquisition. The protocol interoperability module is used to identify the communication protocol types of different IoT devices, parse the data frame format of various protocols, establish a unified intermediate data representation structure, perform bidirectional format conversion between protocols, and support transparent communication between heterogeneous devices. The self-organizing network module is used to collect multi-dimensional capability parameters of IoT nodes, construct node capability profile vectors, execute cluster head election algorithms based on capability scores, dynamically generate and maintain mesh network topology, and realize network self-organizing management. The collaborative verification module is used to divide spatially adjacent node verification groups, analyze the correlation and consistency of node data within the group, use Bayesian inference to calculate data credibility, identify and process abnormal perception data, and ensure data quality. The fault switching module is used to maintain the node heartbeat monitoring mechanism, execute fault diagnosis and location algorithms, calculate backup communication paths, implement route reconstruction and link switching, and ensure the fault-tolerant operation of the system.
[0013] Furthermore, the perception estimation module establishes a nonlinear mapping relationship between signal attenuation and soil moisture through a radial basis function neural network, and dynamically updates the model parameters according to environmental changes.
[0014] Furthermore, the sampling optimization module uses an autoregressive moving average model to predict humidity change trends and updates model parameters online using a recursive least squares algorithm.
[0015] Furthermore, the protocol interoperability module supports mutual conversion between four mainstream IoT protocols: LoRa, NB-IoT, ZigBee, and WiFi, achieving plug-and-play functionality through protocol adaptation.
[0016] Furthermore, the self-organizing network module employs a distributed election algorithm to ensure that each partition can still operate independently in the event of network segmentation.
[0017] Furthermore, the collaborative verification module uses the historical data accuracy of nodes through a sliding time window as prior knowledge for Bayesian inference.
[0018] Furthermore, the fault switching module maintains information on multiple backup paths, enabling rapid switching when the primary path fails.
[0019] Beneficial effects
[0020] 1. Decentralized and highly reliable operation: Adopting a self-organizing mesh network architecture, it eliminates the risk of single point of failure. The failure of any node does not affect the overall system operation, significantly improving the system's robustness. 2. Low-cost virtual sensing coverage: The innovative approach transforms the communication link into a soil moisture sensing channel, enabling full-area monitoring without the need for dense deployment of physical sensors, significantly reducing deployment and maintenance costs; 3. Seamless integration of heterogeneous protocols: Interconnection and interoperability of multiple IoT standards are achieved through protocol conversion middleware, supporting smooth access of existing devices and improving the openness and scalability of the system; 4. Collaborative verification improves accuracy: The multi-node cross-validation mechanism effectively identifies and filters abnormal data, improves data reliability through collective wisdom, and provides a reliable basis for precise irrigation decisions; 5. Adaptive sampling saves energy: Based on the dynamic sampling strategy of data change characteristics, unnecessary data collection and transmission are reduced without losing key information, thus extending the service life of the equipment; 6. Intelligent fault-tolerant continuous service: Fault self-diagnosis and automatic path switching mechanisms ensure the continuity of irrigation services, improving system availability and user experience. Attached Figure Description
[0021] Figure 1 A flowchart illustrating the steps of the method described in this invention is shown. Figure 2 A schematic diagram of the system architecture described in this invention is shown. Detailed Implementation
[0022] Exemplary embodiments of the present invention will now be described in detail with reference to the accompanying drawings.
[0023] On the one hand, combined with Figure 1 This invention provides an agricultural irrigation method based on the Internet of Things (IoT). This method achieves self-organizing and highly reliable irrigation control in an IoT environment through the organic coordination of six core steps.
[0024] Step S1: Multi-hop signal attenuation sensing This step transforms the IoT communication link into a virtual sensor for soil moisture. In the mesh network of agricultural IoT, data transmission needs to be relayed through multiple nodes. Wireless signals attenuate as they propagate through the soil medium, and the degree of attenuation is related to the soil moisture content.
[0025] When electromagnetic waves pass through soil, their propagation characteristics are affected by the soil's dielectric constant. The path loss model is expressed as:
[0026] in: Total path loss, in dB; For reference distance The path loss at the location, in dB; The path loss exponent is dimensionless. The propagation distance is expressed in meters (m). This is a reference distance, in meters, usually taken as 1 meter; The shadow fading is expressed in dB and follows a mean of 0 and a standard deviation of [missing value]. The log-normal distribution; It represents a logarithm with base 10.
[0027] According to the Topp empirical model, the relative permittivity of soil is expressed as: in: ρ is the relative permittivity of the soil, which is dimensionless; The soil volumetric water content is dimensionless and ranges from 0 to 1.
[0028] Considering the differences between different soil types, this invention adopts a hybrid dielectric model: in: ρ is the relative permittivity of the soil, which is dimensionless; is the relative permittivity of dry soil, dimensionless, 2.5 for sand, 3.0 for loam, and 3.5 for clay; Let be the relative permittivity of water, which is dimensionless and taken as 80 at room temperature; Soil volumetric water content, dimensionless; This is an empirical coefficient, dimensionless, with a value range of 0.5 to 1.0.
[0029] The relationship between the path loss exponent and the dielectric constant was obtained through experimental fitting: in: The path loss exponent is dimensionless. is the dielectric constant coefficient, dimensionless, with a value ranging from 0.1 to 0.3; is the relative permittivity of soil, which is dimensionless; This is the frequency coefficient, in MHz^(-0.5), with a value range of 0.001 to 0.005. This refers to the communication frequency, measured in MHz.
[0030] The coefficients α, β, and γ can be obtained through pre-calibration experiments in the target soil environment; for example, by measuring the dielectric constant and signal attenuation of soils with different known moisture levels, the specific values of the above coefficients can be obtained through curve fitting or least squares regression.
[0031] In a mesh network, each node is equipped with a wireless transceiver module to measure the strength of the received signal. The signal attenuation at the i-th hop is calculated as follows:
[0032] in: The path loss for the i-th hop is expressed in dB. Transmit power, in dBm; This refers to the transmit antenna gain, expressed in dBi. The received signal strength at the i-th node is expressed in dBm. This refers to the receiver antenna gain, expressed in dBi. This refers to feeder loss, expressed in dB. Other miscellaneous losses, in dB, include additional losses caused by weather changes, multipath effects, etc. This is the jump number sequence.
[0033] This invention employs a radial basis function neural network to establish a mapping model between signal attenuation and soil moisture. The network's input feature vector contains the main factors affecting signal propagation: in: Let be the input feature vector for the i-th hop, an 8-dimensional column vector; This represents path loss, expressed in dB. The current jump number is a dimensionless integer. This refers to the communication frequency, measured in MHz. This refers to the ambient temperature, expressed in °C. Relative humidity of air, in percentages (%) Atmospheric pressure, measured in hPa; Soil temperature, in °C; Soil electrical conductivity, in mS / cm.
[0034] A radial basis function network consists of an input layer, hidden layers, and an output layer. The hidden layers use Gaussian radial basis functions. in: Let j be the j-th radial basis function, with an output range of (0,1]. The input feature vector; Let be the center vector of the j-th basis function, and Same dimension; The width parameter of the j-th basis function is related to the dimension of the input features; It is the Euclidean norm; The index of the basis function. .
[0035] The network output is the soil volumetric water content: in: This is an estimated value of soil moisture content for the i-th hop path, expressed in % . is the number of hidden layer nodes, a dimensionless positive integer; Let be the connection weight from the j-th hidden layer node to the output layer; it is dimensionless. This is the output of the j-th basis function; This represents the bias term for the output layer, in percentages.
[0036] The model training employs a two-stage strategy. The first stage uses K-means clustering to determine the basis function centers, with the clustering objective function being:
[0037] in: The clustering objective function; The number of clusters; For the j-th cluster; This is the k-th training sample; Let j be the j-th cluster center.
[0038] Cluster center update formula:
[0039] in: Let j be the cluster center; is the number of samples within the j-th cluster, a dimensionless positive integer; It is the kth sample belonging to the jth cluster.
[0040] The basis function width parameter is determined based on the distribution of the clusters:
[0041] in: Let be the width parameter of the j-th basis function; The number of samples within the cluster, when Time setting Avoid division by zero; These are samples belonging to the j-th cluster; Let j be the j-th cluster center.
[0042] The second stage optimizes the connection weights by minimizing the mean squared error:
[0043] in: The mean squared error is expressed in %². The number of training samples is a dimensionless positive integer. The target output for the i-th sample is expressed as % This is the network prediction output for the i-th sample, expressed in units of %.
[0044] The optimal weights are determined using the least squares method with regularization.
[0045] in: For the weight vector, 3D column vector; The output matrix of the radial basis functions has a size of . ; for Transpose of; Output vector for the target. 3D column vector; This is a regularization parameter, a dimensionless positive number, to prevent matrix singularities. for Identity matrix.
[0046] To avoid numerical problems when inverting a matrix, when the determinant When increasing the regularization parameter ,in Represents the determinant of a matrix. To determine the minimum permissible determinant value, take... .
[0047] During operation, a recursive least squares algorithm is used to update the weights online. in: Let be the weight vector at time t; This is the weight vector at time t-1; Let be the gain vector at time t. 3D column vector; The target output at time t, in % %. Let be the basis function output vector at time t. 3D column vector; This is the time step number.
[0048] The gain vector update formula must ensure that the denominator is not zero: in: It is the gain vector; Let be the covariance matrix at time t-1, with size . ; Output vectors for basis functions; The forgetting factor is dimensionless and ranges from 0.95 to 0.99, ensuring that the denominator is always greater than 0.
[0049] The covariance matrix is updated as follows:
[0050] in: Let be the covariance matrix at time t; Let be the covariance matrix at time t-1; It is the gain vector; Output vectors for basis functions; This is the forgetting factor, which takes a value greater than 0 and not equal to 0.
[0051] The covariance matrix is initialized as follows:
[0052] in: This is the initial covariance matrix; This is an initialization constant, with a value ranging from 100 to 1000; for Identity matrix.
[0053] Step S2: Compressed sensing sampling This step designs an adaptive sampling strategy based on the temporal sparsity of soil moisture. The temporal evolution of soil moisture is described using an autoregressive moving average model. in: Let be the soil moisture content at time t, in % %. is the autoregressive order, a dimensionless positive integer; is the order of the moving average, a dimensionless positive integer; Let be the i-th autoregressive coefficient, which is dimensionless; Let be the coefficient of the j-th moving average, which is dimensionless; Let be the white noise at time t, expressed as %, and follow the rules of white noise. distributed; For discrete time steps; and For serial numbers.
[0054] The model order was selected using the Akaike Information Criterion:
[0055] in: The value of the Akaike Information Criterion is dimensionless. The number of model parameters. Dimensionless; The sample size is a dimensionless positive integer. ; This is the sum of squared residuals, expressed as %². It is the natural logarithm.
[0056] The sum of squared residuals is calculated as follows:
[0057] in: This is the sum of squared residuals, expressed as %². The number of samples; These are actual values, expressed in % %. These are predicted values, expressed in % . This is the time step number.
[0058] The state space is represented as:
[0059] in: Let be a state vector with dimension . ; The state transition matrix has a size of . ; The input matrix has dimensions of . ; The observation matrix has dimensions of . ; White noise, expressed in % % These are observed values, expressed as a percentage.
[0060] The state transition matrix is constructed as follows: in: For autoregressive coefficients, dimensionless; when hour, The 1s and 0s in the matrix are constants.
[0061] One-step prediction based on the model: in: These are one-step predictions based on data up to time t, expressed in % (%). These are the autoregressive coefficients; These are historical observations, expressed in %; The moving average coefficient; This represents historical prediction error, expressed in percent.
[0062] The prediction error is:
[0063] in: The prediction error at time t is expressed in % %. The actual observed value at time t, in units of % %. These are predicted values based on time t-1, in units of %.
[0064] The sampling interval adjustment function is a piecewise function: in: The adjustment factor is dimensionless. The prediction error is expressed in % (%). The maximum extension factor is dimensionless and ranges from 3 to 5. The minimum shortening factor is dimensionless and ranges from 0.2 to 0.5. , , , The threshold parameter is expressed as a percentage. .
[0065] To avoid the denominator being zero, when When, the value of the second segment is... ;when When, the value of the fourth segment is... .
[0066] The next sampling interval is calculated as follows:
[0067] in: The next sampling interval, in seconds; The reference sampling interval is expressed in seconds. ; The adjustment factor is dimensionless.
[0068] To calculate the information entropy within a sliding window, the data must first be quantized.
[0069] in: Let be the quantization level of the i-th sample, a dimensionless integer; The value of the i-th sample is expressed as %; This is the minimum value, expressed in % %. The quantization interval is expressed as a percentage. ; This is for rounding down.
[0070] Information entropy is calculated as follows:
[0071] in: Information entropy, measured in bits; It is a quantized series, a dimensionless positive integer; Let be the probability of the i-th quantization level, which is dimensionless. ; It is the logarithm to the base 2. When When, define .
[0072] probability Statistical analysis revealed:
[0073] in: Let be the probability of the i-th quantization level; The number of samples falling into the i-th quantization level is a dimensionless, non-negative integer. The total number of samples within the window, a dimensionless positive integer. .
[0074] The final sampling interval is obtained by combining the prediction error and information entropy: in: The final sampling interval is expressed in seconds (s). The sampling interval is based on the prediction error, and the unit is seconds (s). This is the entropy adjustment coefficient, dimensionless, with a value ranging from 0.1 to 0.5; This is the reference entropy value, in bits. ; This represents the current information entropy, expressed in bits.
[0075] Sampling strategies need to consider energy constraints. Energy consumption model for a single sampling: in: The total energy consumption for a single sampling is expressed in mJ. The energy consumption of the sensor is expressed in mJ. Energy consumption is expressed in mJ. Transmission energy consumption, measured in mJ.
[0076] Transmission energy consumption is related to data volume and transmission distance:
[0077] in: Transmission energy consumption, measured in mJ; The circuit energy consumption coefficient is expressed in nJ / bit. This is the power amplifier coefficient, with units of nJ / (bit·m^α); The transmission distance is expressed in meters (m). ; is the path loss exponent, which is dimensionless and takes the value of 2 in free space and 4 in multipath environment. This represents the data length, measured in bits.
[0078] Under energy constraints, the sampling interval must satisfy:
[0079] in: The final sampling interval is expressed in seconds (s). Energy consumption per sampling, in mJ; Available power, in mW. ; This is the minimum allowable sampling interval, measured in seconds, to prevent sampling from being too frequent.
[0080] Step S3: Interoperability of Heterogeneous Protocols This step enables interconnection of four protocols: LoRa, NB-IoT, ZigBee, and WiFi. Protocol identification is achieved through feature matching. Feature vectors are defined as follows:
[0081] in: For feature vectors, 3D column vector; Let i be the i-th eigenvalue; The characteristic quantity is a dimensionless positive integer. .
[0082] For the LoRa protocol, feature extraction includes preamble length, synchronization word, and spreading factor: in: This is the length of the preamble, in bytes. Synchronization word, 16-bit unsigned integer; is the spreading factor, a dimensionless integer, with values from 7 to 12.
[0083] The matching degree is calculated using weighted Euclidean distance:
[0084] in: The distance from protocol p is dimensionless; Let be the weight of the i-th feature, dimensionless, satisfying . and ; These are the actual eigenvalues; This is the reference characteristic value for protocol p; The number of features; Indicates the protocol type.
[0085] The protocol with the smallest distance is selected from the recognition results:
[0086] in: The identified protocol type; A set of protocols; The distance to protocol p.
[0087] The unified intermediate data format is defined as:
[0088] in: To standardize frame format; For public heads; For data payload; To extend metadata.
[0089] The public header contains six fields: in: The source address is a 32-bit unsigned integer. The target address is a 32-bit unsigned integer. This is a timestamp, Unix time, in seconds; The message type is an 8-bit unsigned integer. This refers to the payload length, in bytes. For cyclic redundancy check, use a 16-bit unsigned integer.
[0090] Address mapping uses a hash function to ensure the uniqueness of addresses from different protocols: in: For uniform addressing, use a 32-bit unsigned integer; For hash functions; For protocol type identification; This is the original protocol address; Indicates string concatenation; This indicates the modulo operation.
[0091] When the data exceeds the maximum transmission unit of the target protocol, it is fragmented: in: The number of slices is a dimensionless positive integer. Total data length, in bytes; The maximum transmission unit is byte. This is the fragment header length, in bytes. To round up. When When, set Avoid having a denominator of zero.
[0092] Construction of the i-th slice:
[0093] in: For the i-th slice; For the intro; This is the original load; This is the offset, in bytes. The payload length of the i-th slice is expressed in bytes. .
[0094] Quality of Service (QoS) mapping during protocol conversion:
[0095] in: The service quality level of the target protocol, a dimensionless integer; The quality of service level of the source protocol, a dimensionless integer; The maximum quality of service level for the target protocol, a dimensionless positive integer; The maximum quality of service level of the source protocol, a dimensionless positive integer. .
[0096] Step S4: Device profiling and self-organizing network This step constructs node capability profiles to achieve adaptive networking. A four-dimensional profile vector is created for each node:
[0097] in: Let i be the image vector of node i, a 4-dimensional column vector; This represents the remaining battery percentage, ranging from 0 to 100. This is a communication link quality indicator, with a value range of 0 to 100; This represents CPU utilization, with a value ranging from 0 to 100. This represents the percentage of available storage space, ranging from 0 to 100. This is the node sequence number.
[0098] The overall ability score is calculated as follows: in: The overall capability score for node i is dimensionless; The energy weighting coefficient is dimensionless. This is a dimensionless link quality weight coefficient. The processing capability weighting coefficient is dimensionless. The storage space weight coefficients are dimensionless; the weight coefficients satisfy... And each weight .
[0099] The weights are dynamically adjusted based on the network state. Define the network state vector: in: This is the network state vector; This refers to the data transmission rate, measured in kbps. Average remaining battery power, expressed as % The number of active nodes is a dimensionless positive integer.
[0100] Weighting adjustment strategy: in: Average remaining battery power, expressed as % This is the current data rate, in kbps. This is the maximum data rate, measured in kbps. .
[0101] Cluster head election uses a distributed algorithm. Each node broadcasts its own capability score. in: This is the broadcast message for node i; For node identification; Assess abilities; This is a timestamp, measured in seconds.
[0102] After receiving the scores from its neighboring nodes, node i determines whether it should become the cluster head: in: This is the cluster head flag for node i, where 1 indicates it is a cluster head and 0 indicates it is not. Let i be the set of neighboring nodes of node i; The score for node j.
[0103] Non-cluster head nodes choose to join the nearest cluster head:
[0104] in: The cluster to which node i belongs; For the set of cluster head nodes; Let be the hop count distance from node i to cluster head h.
[0105] The size of the cluster is constrained by energy balance:
[0106] in: Let h be the number of members in cluster h, which is dimensionless. The remaining charge of cluster head h is expressed as % . Average network power consumption, expressed as a percentage. ; The average cluster size is dimensionless.
[0107] Objective function for network topology optimization: in: The objective function for topology optimization is dimensionless. The value represents the coverage rate, ranging from 0 to 1. The connectivity value ranges from 0 to 1. The value is 0 to 1, representing the normalized energy consumption cost. , , To optimize weights and satisfy .
[0108] Coverage is calculated as follows:
[0109] in: For coverage; The area covered is in m². This is the total area, in m². .
[0110] Connectivity is calculated as follows:
[0111] in: Connectivity; The number of connected node pairs, dimensionless; The total number of nodes is dimensionless. .
[0112] Step S5: Collaborative Perception Verification This step improves data reliability through a multi-node cross-validation mechanism. Validation groups are divided based on the spatial location of the nodes.
[0113] in: This is the kth verification group; The node number; From node i to the group center The distance, in meters; The radius of perception is measured in meters (m).
[0114] For the data collected at node i Its credibility is calculated using Bayesian inference: in: is the posterior probability that the data at node i is reliable, and its value ranges from 0 to 1; This represents a reliable data event for node i; This represents the current data for node i, expressed as % . The data set of adjacent nodes; It is the likelihood function; This is the prior probability; This represents the marginal probability.
[0115] Prior probabilities are obtained through historical statistics:
[0116] in: This is the prior probability; Let be the number of times the historical data of node i has been verified as correct; it is a dimensionless, non-negative integer. Let be the total number of times node i has been recorded in its historical data, a dimensionless positive integer. .
[0117] Likelihood functions reflect data consistency: in: It is the likelihood function; The verification group to which node i belongs; This represents the data for neighbor node j, expressed in % %. The standard deviation of noise is measured in %. It can be obtained by analyzing historical static data of the sensor under stable conditions, or estimated based on the accuracy parameters provided in the sensor manual; To verify the number of nodes in the group, use a dimensionless positive integer.
[0118] Marginal probabilities are calculated using the law of total probability: in: Marginal probability; This indicates an event where the data at node i is unreliable. .
[0119] Trust value updates use a sliding window mechanism:
[0120] in: Let be the trust value of node i at time t, ranging from 0 to 1; The trust value at time t-1; The forgetting factor ranges from 0.7 to 0.9. Let t be the performance index at time t, with a value between 0 and 1.
[0121] Performance metrics are defined as follows: in: For performance indicators; The data for node i is expressed in % (%). This represents the mean of the data within the group, expressed in % %. The noise standard deviation is expressed in percent.
[0122] Outlier corrections were performed using a weighted average: in: These are the corrected data values, expressed in % %. Let be the trust value of node j; The data for node j is expressed in % (%). For the validation group; denominator .
[0123] Step S6: Fault self-diagnosis switching This step establishes a mutual monitoring mechanism between nodes. The heartbeat signal is defined as: in: This represents the heartbeat signal of node i. For node identification; This is the current timestamp, in seconds. For node status codes; is the heartbeat sequence number, a dimensionless positive integer.
[0124] Heartbeat Loss Detection: in: This is a sign of lost heartbeat. The current time is expressed in seconds. The time when the heartbeat of node i was last received is in seconds. The loss threshold is set to 3 to 5; The heart rate cycle is measured in seconds (s). .
[0125] Multi-path detection verification fault:
[0126] in: Let J be the set of probe paths from node J to node I. This is the k-th detection path; The number of probe paths is a dimensionless positive integer.
[0127] Fault type determination: in: Fault type; This is the response flag for the k-th path, where 1 indicates a response and 0 indicates no response. This represents the total number of paths.
[0128] Alternate route quality assessment: in: The path quality score is dimensionless. is the path hop count, a dimensionless positive integer; The path average signal strength is expressed in dBm and normalized to 0-100. The minimum remaining battery power at each node along the path, expressed as a percentage. , , Let be the weighting coefficient, satisfying .
[0129] Path reliability assessment:
[0130] in: For path reliability, the value ranges from 0 to 1; Let be the failure probability of the i-th node, taking a value from 0 to 1; This represents the number of nodes in the path.
[0131] Switching Decisions:
[0132] in: For switching decisions; For switching revenue, dimensionless; Switching costs are dimensionless. The decision threshold is set to a value between 1.2 and 1.5.
[0133] On the other hand, combining Figure 2 This invention provides an agricultural irrigation system based on the Internet of Things. The system includes six core modules: a sensing and estimation module, a sampling and optimization module, a protocol interoperability module, a self-organizing network module, a collaborative verification module, and a fault switching module. The modules work together to achieve intelligent irrigation control.
[0134] The perception estimation module is responsible for virtual soil moisture sensing based on communication signals. This module collects signal strength data from each hop in the mesh network in real time, analyzes the signal propagation characteristics in soils with different moisture levels, and establishes a mapping relationship between signal attenuation and soil moisture. Specifically, the module obtains wireless signal strength indicators from IoT nodes and records the signal attenuation of each data packet during multi-hop transmission, including node identification, reception time, signal strength, hop count, and communication frequency information. By processing the collected signal data, considering the influence of ambient temperature and air humidity on signal propagation, compensation and correction are performed to calculate the actual path loss value for each hop. This module maintains a radial basis function neural network model, inputs the processed signal attenuation data into the model, and outputs the estimated soil moisture value for the corresponding path segment.
[0135] The obtained humidity estimates are transmitted as important parameters to other modules of the system. After receiving this humidity data, the sampling optimization module adjusts the sensor's sampling frequency based on humidity change trends. When the humidity data shows that the soil moisture content is stable, the sampling interval is extended accordingly; when a rapid change in humidity is detected, the sampling interval is shortened accordingly to ensure the capture of critical information.
[0136] The sampling optimization module maintains an autoregressive moving average model to predict humidity change trends, processes virtual sensing data from the sensing estimation module, and comprehensively considers multiple factors such as prediction error, information entropy, energy constraints, and data importance. Data importance is dynamically set according to crop growth stages, with higher weights assigned during irrigation and lower weights during dormancy. The model parameters are updated online using a recursive least squares algorithm to adapt to changes in soil properties.
[0137] The sampled and optimized data needs to be transmitted between heterogeneous IoT devices, a task undertaken by the protocol interoperability module. When this module receives data, it analyzes the characteristic fields of the data frame to identify the protocol type. For LoRa, it identifies the preamble and synchronization word; for NB-IoT, it identifies the narrowband physical broadcast channel; for ZigBee, it identifies the frame control field conforming to the IEEE 802.15.4 standard; and for WiFi, it identifies the frame control structure conforming to the IEEE 802.11 standard.
[0138] After identifying the protocol type, the protocol interoperability module extracts the payload from the original data frame and converts it into a unified format containing source address, destination address, timestamp, message type, payload length, and cyclic redundancy check. When the target device uses a different protocol, the module re-encapsulates the data according to the requirements of the target protocol. If the data length exceeds the maximum transmission unit of the target protocol, fragmentation is performed, with each fragment accompanied by a sequence number and total fragment count information to ensure correct reassembly at the receiving end.
[0139] Data that has undergone protocol conversion enters the network transport layer managed by the self-organizing network module. This module establishes a capability profile for each node in the network, which includes four dimensions: remaining power, communication link quality, processor load, and storage space. Based on this four-dimensional profile, a comprehensive capability score is calculated, and the weighting coefficients are dynamically adjusted according to the network status: when the network is in low-power mode, the power weight is increased; when the data transmission volume is large, the link quality weight is increased.
[0140] The self-organizing network module determines cluster head nodes through distributed election. Each node broadcasts its own capability score, and after receiving scores from all neighboring nodes, the node with the highest score becomes the cluster head. If scores are the same, the node with the smaller identifier becomes the cluster head. Non-cluster head nodes measure the signal strength of each cluster head and select the cluster head with the strongest signal to join. When node energy consumption is uneven or network load is unbalanced, a re-election process is triggered to select a new cluster head node.
[0141] Network topology information is transmitted to the collaborative verification module to determine the spatial relationships for data verification. This module divides nodes into verification groups based on their geographical location and communication range. Nodes within the same verification group monitor the same or adjacent soil areas. The reliability of each node's data is calculated using Bayesian inference; the prior probability is based on the node's historical performance, and the likelihood function reflects the consistency between the current data and the data of its neighboring nodes.
[0142] The collaborative verification module maintains a node trust network, recording the reliability history of each node. When nodes interact directly, the direct trust level is updated based on data consistency; when evaluating nodes that do not interact directly, the indirect trust level is calculated through recommendations from common neighbors. The trust value is dynamically updated using a sliding window mechanism. When abnormal data with low trust is detected, it is corrected using a weighted average of the data from trusted neighbor nodes.
[0143] Anomalies detected during data verification are notified to the failover module. This module monitors the liveness of all nodes in the network through a heartbeat mechanism, sending heartbeat signals periodically, including node identifier, timestamp, status code, and sequence number. If a node fails to receive a heartbeat signal for several consecutive cycles, a fault diagnosis process is triggered.
[0144] Fault diagnosis employs a multi-path detection method. The fault switching module selects multiple different paths to send probe messages to suspected faulty nodes. If all paths fail to respond, the node is determined to be faulty; if some paths respond, the link is determined to be faulty. This module pre-calculates and maintains multiple backup paths, and the quality of each path is comprehensively evaluated based on hop count, signal strength, and remaining node power. When the primary path fails, the backup path with the highest quality is selected for switching.
[0145] After fault handling is completed, the fault switching module feeds back the updated network status to the ad hoc network module, triggering topology reconfiguration. The faulty node information is notified to the collaborative verification module, temporarily lowering the trust value of that node. The perception estimation module replans the signal acquisition path based on the new network topology, and the sampling optimization module adjusts the distribution of sampling nodes.
[0146] The system facilitates information flow between modules via a message bus. Sensing data begins with signal acquisition at the bottom layer, undergoes humidity inversion, sampling optimization, protocol conversion, network transmission, and quality verification, before reaching the irrigation control terminal. Control commands are sent along the reverse path, undergoing protocol adaptation, routing selection, and reliable transmission before reaching the execution equipment. Anomaly information and status updates are propagated among modules to ensure system consistency.
[0147] This invention constructs a complete Internet of Things (IoT) irrigation control system through the organic integration of six modules. The data flow and control feedback between the modules form a closed-loop system, realizing virtual sensing of soil moisture, dynamic optimization of sampling strategies, seamless conversion of heterogeneous protocols, adaptive adjustment of network topology, collaborative guarantee of data quality, and fault-tolerant switching of system operation.
[0148] This system is not a static network, but an intelligent entity that can dynamically adjust its sampling frequency and network topology based on its own energy consumption, load status, and environmental changes such as humidity change rate. It can also perform self-checking, self-correction, collaborative verification, and self-repair fault switching on the data it collects. Compared with traditional centralized or static IoT solutions, it has a high degree of autonomy and robustness.
[0149] The above description is only a preferred embodiment of the present invention and is not intended to limit the present invention. Any modifications, equivalent substitutions, or improvements made within the spirit and principles of the present invention should be included within the protection scope of the present invention.
Claims
1. An agricultural irrigation method based on the Internet of Things, characterized in that, Includes the following steps: S1: Multi-hop signal attenuation sensing, acquiring wireless signal strength indication values during multi-hop communication between IoT nodes, establishing a radial basis function neural network mapping model of signal attenuation and soil moisture. The mapping model uses path loss, hop count, communication frequency, ambient temperature, air humidity, atmospheric pressure, soil temperature, and soil conductivity as input feature vectors. The basis function centers are determined by K-means clustering, and the connection weights are optimized by least squares method. The soil moisture values of each segment on the multi-hop path are inverted based on the real-time collected multi-hop signal attenuation data. S2: Compressed sensing sampling analyzes the temporal variation characteristics of soil moisture based on the autoregressive moving average model, calculates the prediction error and information entropy, divides the sampling state into a stable period and a changing period according to the magnitude of the prediction error, extends the sampling interval during the stable period, shortens the sampling interval during the changing period, and determines the final sampling frequency in combination with energy constraints. S3: Heterogeneous protocol interoperability, identifies the IoT protocol type of the access device, and converts data frames of LoRa, NB-IoT, ZigBee and WiFi protocols into a unified intermediate format containing source address, destination address, timestamp, message type, payload length and cyclic redundancy check. When the data length exceeds the maximum transmission unit of the target protocol, fragmentation processing is performed. S4: Device profiling self-organizing network. It constructs a four-dimensional capability profile for each IoT node, including remaining power, communication link quality, processor load, and storage space. The node with the highest comprehensive capability score is selected as the cluster head through a distributed election algorithm. Non-cluster head nodes join the corresponding cluster according to signal strength, forming an adaptive mesh network topology. S5: Collaborative perception verification, dividing verification groups according to node spatial location, calculating node data credibility through Bayesian inference, wherein the Bayesian inference uses the node’s historical accuracy as the prior probability and data consistency as the likelihood function, and corrects low credibility data by using a weighted average of neighboring nodes. S6: Fault self-diagnosis and switching, establish a heartbeat monitoring mechanism between nodes, start multi-path detection when no heartbeat is received for several consecutive cycles, determine the fault type based on the detection response, pre-maintain backup paths and automatically switch when a fault occurs.
2. The agricultural irrigation method based on the Internet of Things according to claim 1, characterized in that, The radial basis function neural network mapping model in step S1 is updated online using a recursive least squares algorithm. The gain vector is calculated using the covariance matrix and the basis function output vector, and the weight vector is iteratively adjusted according to the prediction error.
3. The agricultural irrigation method based on the Internet of Things according to claim 1, characterized in that, The sampling frequency adjustment in step S2 adopts a piecewise function, determines the adjustment factor based on the relationship between the prediction error and multiple thresholds, and performs a secondary correction on the sampling interval through information entropy.
4. The agricultural irrigation method based on the Internet of Things according to claim 1, characterized in that, In step S3, the protocol conversion identifies the protocol type through feature matching. Protocol-specific fields are saved through extended metadata. During fragmentation, each fragment contains a fragment header and part of the payload. The fragment header records the fragment sequence number and the total number of fragments.
5. The agricultural irrigation method based on the Internet of Things according to claim 1, characterized in that, In step S4, when multiple nodes have the same capability score, the node identifier is used as the arbitration basis for cluster head election; when the cluster head load exceeds the threshold, a re-election is triggered.
6. The agricultural irrigation method based on the Internet of Things according to claim 1, characterized in that, The node trust value in step S5 is updated using a sliding window mechanism, which combines the trust level from direct interaction with the indirect trust level recommended by common neighbors.
7. An agricultural irrigation system based on the Internet of Things, characterized in that, include: The perception estimation module is used to collect signal strength data of multi-hop communication between IoT nodes, establish the mapping relationship between signal attenuation and soil moisture through radial basis function neural network, and invert soil moisture distribution based on path loss. The sampling optimization module is used to maintain the autoregressive moving average model to predict humidity changes, dynamically adjust the sampling frequency based on prediction error and information entropy, and optimize the sampling strategy under the condition of satisfying energy constraints. The protocol interoperability module is used to identify LoRa, NB-IoT, ZigBee and WiFi protocol types, perform bidirectional format conversion between protocols, and support data fragmentation and reassembly; The self-organizing network module is used to build a four-dimensional capability profile of nodes, determine cluster heads through distributed election, and dynamically maintain the mesh network topology. The collaborative verification module is used to divide the spatial verification group, evaluate the credibility of the data through Bayesian inference, and perform weighted correction on abnormal data. The failover module is used to perform heartbeat monitoring and multipath detection, maintain backup paths, and implement failover.
8. The IoT-based agricultural irrigation system according to claim 7, characterized in that, The perception estimation module updates the network model parameters through incremental learning, and triggers model retraining when the root mean square error exceeds the threshold.
9. The IoT-based agricultural irrigation system according to claim 7, characterized in that, The sampling optimization module sets data importance weights based on crop growth stages and determines sampling decisions by comprehensively considering prediction accuracy, energy consumption costs, and data importance.
10. The IoT-based agricultural irrigation system according to claim 7, characterized in that, Each module interacts with the others via a message bus. Humidity data from the sensing and estimation module triggers the sampling optimization module to adjust its strategy. The protocol interoperability module ensures data flow between heterogeneous devices. The topology information from the self-organizing network module is used by the collaborative verification module to divide verification groups. Fault information from the fault switching module is fed back to the self-organizing network module to trigger topology reconfiguration.