Sensor network time synchronization method

Through the time synchronization method of cluster topology structure and dynamic frequency compensation, the problems of insufficient adaptability to network topology changes and high energy consumption of traditional algorithms in power equipment monitoring scenarios are solved, and high-precision time synchronization and low-energy long-term online monitoring are achieved.

CN120640391APending Publication Date: 2025-09-12XIAN PINGGAO SMART ENERGY CO LTD +1
View PDF 0 Cites 1 Cited by

Patent Information

Application Number
CN202511022643.0
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-07-24
Publication Date
2025-09-12

AI Technical Summary

Technical Problem

Traditional time synchronization algorithms in power equipment monitoring scenarios have problems such as insufficient adaptability to network topology changes, difficulty in maintaining high-precision synchronization, and high energy consumption, and cannot meet the long-term online monitoring needs in complex industrial environments.

Method used

A cluster topology is adopted. The clock frequency offset between the master clock signal and the cluster head node is quantified for dynamic calibration. The logical clock of the cluster head node is calibrated in combination with the improved TPSN protocol. The clock drift and offset between the cluster head node and the child nodes are calibrated within the cluster. The clock mapping relationship of the FTSP protocol is combined with the least squares method to determine the clock drift and offset, and dynamic frequency compensation and abnormal data filtering are implemented.

Benefits of technology

While maintaining microsecond-level synchronization accuracy, it significantly reduces communication energy consumption, improves network robustness and node endurance, adapts to network topology changes under complex working conditions, and meets long-term online monitoring needs.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120640391A_ABST
    Figure CN120640391A_ABST
Patent Text Reader

Abstract

The invention discloses a sensor network time synchronization method, which comprises the following steps: firstly, clustering and networking sensor nodes according to equipment to which the sensor nodes belong, and for clusters, fusing clock frequency offset between a quantized master control clock signal and a cluster head node into an improved TPSN protocol to dynamically calibrate a logic clock of the cluster head node; and for the interior of the cluster, calibrating the logic clock of the child node in the cluster based on the clock drift amount and the clock offset amount of the cluster head node and the child node in the cluster. According to the method, the characteristics of a power equipment monitoring scene are combined, and a dynamic hierarchical adjustment mechanism and a bidirectional calibration strategy are introduced, so that the time-varying influence of frequency deviation on the synchronization error can be remarkably suppressed, and the adaptability to network topology change is improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of sensor time synchronization, and more particularly to a sensor network time synchronization method. Background Art

[0002] Sensor nodes in online monitoring systems for power equipment are typically deployed in complex industrial environments with high voltage and strong electromagnetic interference, and have topological characteristics such as large network scale and widely distributed nodes. While traditional time synchronization algorithms, such as TPSN and RBS, can meet the requirements of conventional wireless sensor networks, they have significant limitations in power monitoring scenarios:

[0003] First, the dynamic changes in the operating conditions of power equipment and the complex electromagnetic environment easily lead to frequent fluctuations in network topology, and traditional algorithms are not robust enough;

[0004] Second, the monitoring system needs to achieve microsecond-level time synchronization accuracy, but existing algorithms have difficulty maintaining high-precision synchronization under complex working conditions;

[0005] Third, due to node energy constraints, the high energy consumption characteristics of traditional algorithms cannot meet the needs of long-term online monitoring.

[0006] Therefore, how to overcome the above limitations is an urgent problem that those skilled in the art need to solve. Summary of the Invention

[0007] In view of this, the present invention provides a sensor network time synchronization method, which aims to solve the problem of adaptability of traditional algorithms in the prior art to changes in network topology; the problem that existing algorithms are difficult to maintain high-precision synchronization under complex working conditions; and the high energy consumption characteristics of traditional algorithms cannot adapt to long-term online monitoring needs.

[0008] In order to achieve the above object, the present invention adopts the following technical solutions:

[0009] On the one hand, the present application provides a sensor network time synchronization method, the steps comprising:

[0010] Cluster the sensor nodes according to the devices they belong to;

[0011] Between clusters, the clock frequency offset between the master clock signal and the cluster head node is quantified and combined with the improved TPSN protocol to dynamically calibrate the logical clock of the cluster head node;

[0012] Within the cluster, the logical clocks of the child nodes in the cluster are calibrated through the clock drift and clock offset between the cluster head node and the child nodes in the cluster.

[0013] Preferably, the sensor nodes are clustered and networked according to their device numbers, including:

[0014] Allocate device numbers to all sensor nodes based on the device to which they belong;

[0015] Randomly select a sensor node and determine whether the device to which it belongs has a cluster head. If not, use the current node as the cluster head of the corresponding device cluster. If so, return to select other sensor nodes until all sensor nodes are traversed.

[0016] Preferably, a fixed-cycle synchronization mechanism is adopted between clusters.

[0017] Preferably, dynamically calibrating the logical clock of the cluster head node includes:

[0018] determining a frequency deviation based on the frequency of the master clock signal and the clock frequency offset;

[0019] Calibrate the logical clock of the cluster head node according to the frequency deviation using the following formula;

[0020] C_xuni=C_time+offset+Δf / f0×(C_time-T_syn)

[0021] Where C_xuni represents the logical clock of the cluster head node, C_time represents the local clock of the cluster head node, offset represents the relative time deviation between the node local clock and the reference clock, f0 represents the nominal frequency of the crystal oscillator of the cluster head node, Δf represents the frequency deviation, and T_syn represents the local clock of the cluster head node at the end of the last synchronization.

[0022] In an optional embodiment, the inter-cluster time synchronization step includes:

[0023] Set the message count Num = 0, the clock offset Offset = 0, and determine whether the timing period is established. If not, return to continue judging; if yes, the cluster head node sends a synchronization request, marked T1, the management node receives the synchronization request, marked T2, the management node returns a confirmation packet, marked T3, and then determine whether the cluster head node receives the confirmation packet. If not, it will periodically retransmit the synchronization request to the cluster head node. If yes, mark T4, the next step is to add 1 to Num, calculate and record Offset, and then determine whether Num ≥ threshold one. If not, return to determine the timing period. If yes, use least squares estimation to compensate for the frequency drift skew and adjust the logical clock.

[0024] Preferably, based on the clock mapping relationship in the FTSP protocol, the clock drift and clock offset between the cluster head node and the sub-nodes in the cluster are determined by the least square method.

[0025] Preferably, after the inter-cluster time synchronization is completed, the intra-cluster time synchronization is started, and abnormal data determination is triggered according to the time scale difference of different periods.

[0026] As a preference, the time scale difference expression is:

[0027]

[0028] Where δ represents the time difference, T represents the synchronization period, f0 represents the nominal frequency of the crystal oscillator of the cluster head node, and f A A function that represents the actual frequency of the node clock crystal changing with time t.

[0029] Preferably, abnormal data determination includes:

[0030] When the absolute deviation between the clock drift and the historical value exceeds the preset threshold, the current synchronization data is determined to be abnormal and filtered.

[0031] In an optional embodiment, the intra-cluster time synchronization step includes:

[0032] Set the message count Num = 0, the clock offset offset = 0, and determine whether the cluster head has completed synchronization. If not, continue to determine; if yes, the cluster head node broadcasts a synchronization request, marked as T1, the cluster member node receives the synchronization request, marked as T2, the next step is to add 1 to Num, calculate and record two timestamps, and then determine whether Num ≥ threshold 2 is established. If not, return to determine whether the cluster head has completed synchronization. If yes, use least squares estimation to compensate for the frequency drift skew, and then determine whether skew ≥ threshold 3 is established. If yes, return to set the message count Num = 0, the clock offset offset = 0, if not, adjust the logical clock.

[0033] In a second aspect, the present application discloses a sensor network time synchronization system, which includes a main control device, sensor nodes distributed inside the device to be monitored, and a time synchronization device, wherein:

[0034] The time synchronization device uses any of the above-mentioned sensor network time synchronization methods to synchronize the time of the main control device and the sensor nodes.

[0035] Compared with the prior art, the sensor network time synchronization method disclosed in the present invention has the following beneficial effects:

[0036] 1. A sensor network time synchronization protocol is used at the inter-cluster communication layer to maintain inter-cluster synchronization accuracy and limit single-hop communication paths, effectively balancing the conflict between accuracy and communication overhead of the TPSN protocol during network expansion. The improved algorithm quantifies the relative deviation between the actual and nominal crystal oscillator frequencies and implements dynamic frequency compensation, significantly suppressing the time-varying impact of frequency deviation on synchronization error. This extends the synchronization period and reduces synchronization energy consumption, while ensuring the continued effectiveness of network time synchronization.

[0037] 2. For ordinary nodes within a cluster that are covered by a single hop, a flooding synchronization protocol is applied to avoid the multi-hop error accumulation defects of structured protocols. At the same time, due to its topology independence, it has good adaptability to node addition and removal.

[0038] The hybrid algorithm disclosed in this application maintains microsecond-level synchronization accuracy while having the ability to robustly handle abnormal data. Moreover, the communication energy consumption of the hybrid algorithm is only 58.96% of that of the traditional TPSN algorithm. This feature can effectively improve the endurance of wireless sensor nodes. BRIEF DESCRIPTION OF THE DRAWINGS

[0039] In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the following briefly introduces the drawings required for use in the embodiments or the description of the prior art. Obviously, the drawings described below are merely embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on the provided drawings without paying any creative work.

[0040] Figure 1 This is a structural diagram of the substation power equipment monitoring system of the present invention;

[0041] Figure 2 It is the cluster topology diagram of the present invention;

[0042] Figure 3 This is a comparison chart of the clustering effects of the AEFCH of the present invention and the traditional LEACH;

[0043] Figure 4 This is a flow chart of the sensor network time synchronization method of the present invention;

[0044] Figure 5 This is a diagram of the process of clustering nodes into a network according to device numbers in the present invention;

[0045] Figure 6 This is a flow chart of inter-cluster time synchronization in the present invention;

[0046] Figure 7 This is a flow chart of intra-cluster time synchronization in the present invention;

[0047] Figure 8 Error comparison between the traditional TPSN and the improved frequency-compensated TPSN of the present invention;

[0048] Figure 9 The error comparison between the traditional FTSP and the improved FTSP when there is no abnormal data in the present invention;

[0049] Figure 10 The error comparison between the traditional FTSP and the improved FTSP in the presence of abnormal data of the present invention;

[0050] Figure 11The figure shows the energy consumption comparison between the hybrid time synchronization of the present invention and the traditional TPSN communication. DETAILED DESCRIPTION

[0051] The following will clearly and completely describe the technical solutions in the embodiments of the present invention in conjunction with the accompanying drawings. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without making creative efforts are within the scope of protection of the present invention.

[0052] In the following description, many specific details are set forth to facilitate a full understanding of the present invention. However, the present invention may also be implemented in other ways different from those described herein. Those skilled in the art may make similar generalizations without violating the connotation of the present invention. Therefore, the present invention is not limited to the specific embodiments disclosed below.

[0053] In the substation power equipment monitoring scenario, networked master control devices are usually deployed as management nodes to integrate sensor data, such as Figure 1 Specifically, the clock signal of the master control device is used as the global benchmark, and the time calibration of the entire network is completed through a structured protocol.

[0054] Considering that a single power device is equipped with multiple parameter monitoring sensors, in order to avoid the accumulation of multi-hop communication errors and minimize the clock deviation of the sensor nodes inside the device, the following is adopted: Figure 2 The cluster topology shown builds a device-level synchronization unit.

[0055] However, when clustering networks, the number of cluster heads in the traditional LEACH clustering process is random, which may cause sensor nodes monitoring multiple physical quantities of the same device to be distributed in different cluster domains, resulting in a multi-hop cumulative effect of time synchronization errors and significantly reducing the clock synchronization accuracy of sensors within the device.

[0056] Aiming at the actual operating environment of substation power equipment monitoring, this application proposes an Average Energy Fixed-number Clustering Hierarchy (AEFCH) algorithm with a fixed number of cluster heads. It mainly assigns device numbers to all sensor nodes according to the devices to which the sensor nodes belong. Then, a sensor node is randomly selected to determine whether the device to which it belongs has a cluster head. If not, the current node is used as the cluster head of the corresponding device cluster. If so, it returns to select other sensor nodes until all sensor nodes are traversed.

[0057] Its clustering effect is significantly improved in terms of error and accuracy compared to traditional LEACH clustering. For the effect comparison chart, refer to Figure 3 .

[0058] In one embodiment, after completing node clustering, time synchronization is performed:

[0059] This application uses a software-level parameter compensation algorithm to jointly estimate and correct the frequency deviation, drift effect, and phase offset of node clocks, thereby improving clock frequency stability and extending the effective synchronization period. The synchronization process is divided into two levels: the first network synchronization stage completes the clock calibration between the cluster head node and the master control device, and the second network synchronization stage achieves clock alignment of nodes within the cluster using the cluster head node benchmark, thus forming a hierarchical synchronization architecture.

[0060] For the first-level network, in a specific embodiment, an improved frequency compensation TPSN synchronization mechanism is adopted;

[0061] TPSN is a typical time synchronization protocol in the field of wireless sensor networks. It builds a hierarchical network topology and implements a two-way message exchange mechanism between parent and child nodes, so that the child node clock is aligned with the parent node reference, thereby achieving time synchronization accuracy in the microsecond range.

[0062] To maintain the continuity of sensor node time parameters, conventional methods use a logical clock update strategy, which constructs a virtual mapping relationship between the local clock and the reference clock rather than directly correcting the physical clock value. The logical clock mapping model established by this algorithm can be expressed as:

[0063] C_xuni=C_time+offset

[0064] Among them, C_xuni represents the logical clock of the node, C_time represents the local clock of the node, and offset represents the relative time deviation between the local clock of the node and the reference clock.

[0065] Furthermore, this application introduces a virtual clock frequency compensation mechanism based on the TPSN protocol. The frequency compensation enhancement mechanism adopts a fixed-cycle synchronization mechanism. The core idea is: by quantifying the clock frequency offset between the parent and child nodes, dynamic frequency calibration is implemented on the logical clock parameters, thereby weakening the cumulative effect of the crystal oscillator frequency offset on the timing error after synchronization, and achieving the extension of the effective synchronization time.

[0066] The steps include:

[0067] 1) The frequency deviation ρ is determined based on the frequency of the master clock signal and the clock frequency offset. In this embodiment, it can be obtained by least squares estimation. This parameter is represented as a dimensionless quantity, and its physical connotation corresponds to the relative deviation ratio of the clock frequencies of the child node and the parent node:

[0068] ρ=(f m -f r ) / f r =Δf / f r

[0069] Among them, f m is the frequency of the child node to be synchronized, f r is the parent node clock frequency.

[0070] In actual application scenarios, the improved TPSN algorithm is applied to the first-level network synchronization between the network master and the cluster head nodes of each device. The network master can obtain the standard time, so the parent node frequency is regarded as the nominal frequency. Therefore, in the improved TPSN algorithm based on software frequency compensation, the frequency deviation is:

[0071] Δf=ρ·f r

[0072] By quantifying the deviation between the actual frequency of the node crystal oscillator and the nominal value, Δf=ρ·f r The imported formula is: C_xuni=C_time+offset+Δf / f0×(C_time-T_syn). The results show that it can effectively suppress the cumulative effect of crystal oscillator frequency offset on the timing error after synchronization and improve the maintenance time of the synchronization state.

[0073] 2) By quantifying the deviation between the actual frequency of the node crystal oscillator and the nominal value, the frequency deviation is introduced into the following formula to calibrate the logical clock of the cluster head node, thereby effectively suppressing the cumulative effect of the crystal oscillator frequency offset on the timing error after synchronization and improving the maintenance time of the synchronization state;

[0074] C_xuni=C_time+offset+Δf / f0×(C_time-T_syn)

[0075] Where C_xuni represents the logical clock of the cluster head node, C_time represents the local clock of the cluster head node, offset represents the relative time deviation between the node local clock and the reference clock, f0 represents the nominal frequency of the crystal oscillator of the cluster head node, Δf represents the frequency deviation, and T_syn represents the local clock of the cluster head node at the end of the last synchronization.

[0076] This mechanism can reduce the triggering frequency of time synchronization by reducing the periodic synchronization requirements, achieve optimal control of network energy consumption, and ultimately extend the overall operation cycle of the wireless sensor network.

[0077] For a secondary network, in a specific embodiment, an improved abnormal data processing flood synchronization strategy is applied; specifically, it includes: determining the clock drift and clock offset between the cluster head node and the sub-nodes in the cluster, and calibrating the logical clocks of the sub-nodes in the cluster according to the clock drift and clock offset.

[0078] Optionally, the present application determines the clock drift and clock offset between the cluster head node and the child nodes in the cluster by the least squares method based on the clock mapping relationship in the FTSP protocol; wherein the mathematical model of the mapping relationship is characterized as follows:

[0079] C_xuni=α·C_time+b

[0080] Where α is the clock drift and b is the clock offset. A linear regression method based on the least squares method is used to solve the clock drift and offset parameters, thereby achieving high-precision time synchronization control.

[0081] However, this method is significantly sensitive to timestamp outliers. During the synchronization process, due to factors such as nodes misreceiving cross-network information, delayed interrupt responses leading to time stamp lags, and malicious attacks on network clocks, the time stamp data used in model fitting often contains non-ideal components, making it difficult to accurately characterize the dynamic changes in node clock frequencies.

[0082] Since the first-level network adopts a fixed-cycle synchronization mechanism, the cluster head node immediately starts the synchronization process of cluster members in the second-level network after completing the time synchronization with the network main controller, so that the inter-cluster synchronization also has periodic characteristics. The time difference collected in each synchronization interval shows a certain range characteristic:

[0083] When the node sends data in the first synchronization cycle, the local clock is recorded as t1. After a time interval of T, the second synchronization is triggered and recorded as t2. The difference between t1 and t2, t2-t1=T+δ, is usually characterized as a physical quantity related to the crystal oscillator frequency drift under normal working conditions, that is:

[0084]

[0085] Where δ represents the time difference, T represents the synchronization period, f0 represents the nominal frequency of the crystal oscillator of the cluster head node, and f A A function that represents the actual frequency of the node clock crystal changing with time t.

[0086] In one embodiment, when the synchronization period is 30s and the crystal oscillator frequency deviation is 10ppm, the theoretical estimate of the time difference δ is approximately 0.3ms. Abnormal operating conditions will cause this value to deviate from the normal fluctuation range. That is, when the time difference δ deviates from the normal fluctuation range, an abnormal operating condition determination is made.

[0087] When determining abnormal data, based on the factory accuracy specifications of crystal oscillators and analysis of measured data, the frequency offset range is between 0 and 100 ppm. Therefore, the frequency deviation rate change threshold is set to Φ = 100 ppm. If the absolute deviation between the newly calculated clock frequency offset and the historical value exceeds Φ, the current synchronization data is considered abnormal, and data filtering is performed until the parameter update is completed in the subsequent synchronization cycle.

[0088] In a complete embodiment, the sensor network time synchronization method of the present application includes the following steps: Figure 4 Shown, including:

[0089] First, node 1, node 2, ..., node N are initialized and the node times are checked to see if they are consistent. If yes, the system exits. If not, the system performs the following operations:

[0090] 1. Cluster the nodes according to the device number. Refer to the steps Figure 5 :

[0091] First, node numbers are assigned to all nodes in the entire network, and device numbers are assigned to nodes according to the detected devices. Then the management node generates a random node number, and then determines whether the device to which the node number belongs has generated a cluster head node. If so, it returns to the management node to generate a random node number. If not, the node is selected as the cluster head for networking. Then it is determined whether all devices have cluster head nodes. If not, it returns to the management node to generate a random node number. If so, it ends and the nodes are clustered and networked according to the device number.

[0092] 2. The cluster head node and the management node exchange time information to complete inter-cluster time synchronization. The steps are similar to step 6, including:

[0093] First, set the message count Num = 0 and the clock offset Offset = 0, and then determine whether the timing period is equal to 30 seconds. If not, return to determine whether the timing period is equal to 30 seconds. If the cluster head node sends a synchronization request, mark T1, and then the management node receives the synchronization request, mark T2, and then the management node returns a confirmation packet, mark T3, and then determine whether the cluster head node receives the confirmation packet. If not, it will periodically retransmit the synchronization request to the cluster head node. If yes, mark T4, the next step is to add 1 to Num, calculate and record Offset, and then determine whether Num ≥ 8. If not, return to determine whether the timing period is 30 seconds. If yes, use least squares estimation to compensate for the frequency drift skew. Next, adjust the logical clock, end, complete the exchange of time information between the cluster head node and the management node, and complete the time synchronization between clusters.

[0094] 3. Cluster head node floods time information to complete time synchronization within the cluster, refer to Figure 7 , the steps include:

[0095] First, set the message count Num = 0 and the clock offset offset = 0, and then determine whether the cluster head has completed synchronization. If not, return to determine whether the cluster head has completed synchronization. If so, the cluster head node broadcasts a synchronization request, marked T1, and the cluster member node receives the synchronization request, marked T2. The next step is to add 1 to Num, calculate and record two timestamps, and then determine whether Num ≥ 8. If not, return to determine whether the cluster head has completed synchronization. If so, use least squares estimation to compensate for the frequency drift skew, and then determine whether skew ≥ 100ppm. If so, return to set the message count Num = 0 and the clock offset offset = 0. If not, adjust the logical clock and end. The cluster head node floods the time information, completes the time synchronization within the cluster, and the entire algorithm ends.

[0096] In an exemplary embodiment, a sensor network time synchronization system is designed, which includes a main control device, sensor nodes distributed inside the device to be monitored, and a time synchronization device, wherein:

[0097] The time synchronization device uses any of the above-mentioned sensor network time synchronization methods to synchronize the time of the main control device and the sensor nodes.

[0098] In an exemplary embodiment, the above-mentioned time synchronization method is simulated, and the entire process from simulation to result output includes:

[0099] Simulation experiments were conducted on the MATLAB platform to analyze and simulate the algorithm's synchronization error and communication overhead. Ten monitored devices were randomly distributed within a 150-meter square area. Each device had 10 monitoring sensors randomly placed within a 15-meter square area, for a total of 100 sensor nodes. Each node's crystal oscillator frequency was 32 MHz, and the node drift followed a normal distribution with a mean of 1 and a standard deviation of 20 ppm. Initial node errors ranged from 10 to 500 μs, and the least-squares estimation was performed using eight sets of timestamp data.

[0100] The simulation parameters are: 10 devices, 10 nodes per device, 32MHz nominal node frequency, N(1, 20ppm2) node frequency drift, 10-500μs node initial time deviation, N(1.5μs, 0.5μs2) transmission delay, 8 estimated time scale logarithms, and 0.5J single node energy.

[0101] Result analysis: Figure 8The paper presents a comparison of the average synchronization error between the traditional TPSN algorithm and the improved frequency-compensated TPSN algorithm during inter-cluster synchronization. Traditional TPSN only compensates for the instantaneous time deviation between the node and the reference clock during synchronization. While achieving a synchronization accuracy of approximately 2μs at the moment of synchronization, the cumulative effect of crystal oscillator frequency deviation causes the time error to continue to grow.

[0102] Under experimental conditions, the initial clock deviation was approximately 125 μs, which increased to 170 μs before synchronization due to frequency offset. Both algorithms were able to converge the error to the order of 2 μs after the initial synchronization. However, due to the lack of frequency offset compensation, the traditional algorithm's error increased to 149 μs, 301 μs, and 451 μs at 10, 20, and 30 seconds, respectively, making it difficult to maintain long-term synchronization stability.

[0103] This shows that traditional algorithms rely on high-frequency synchronization operations to maintain low deviations, resulting in significant consumption of network communication resources. In contrast, the improved algorithm significantly suppresses the time-varying impact of frequency deviation on synchronization error by quantifying the relative deviation between the actual crystal oscillator frequency and the nominal value and implementing dynamic frequency compensation. This extends the synchronization period, reduces synchronization energy consumption, and ensures the continued effectiveness of network time synchronization.

[0104] The cluster head node uses the FTSP time synchronization protocol to broadcast its global time information, and the member nodes in the cluster dynamically compensate the local virtual clock based on the FTSP linear regression model, thereby achieving virtual time consistency with the cluster head node. Figure 9 As shown in the synchronization error comparison curve, thanks to the inheritance of FTSP's high-precision characteristics in the intra-cluster synchronization link, the network synchronization accuracy of the CHTS protocol is significantly better than that of the TPSN consistency hybrid algorithm.

[0105] In order to verify the effectiveness of the abnormal data filtering mechanism for the FTSP synchronization protocol, this experiment sets up a ten-round synchronization test sequence, in which the sixth round injects abnormal data into the designated node to simulate the timestamp recording delay phenomenon, specifically by increasing the fixed delay in the data transmission link to 30 times the baseline value. Figure 10 The synchronization accuracy curves shown demonstrate that the improved FTSP protocol maintains 10μs-level synchronization accuracy under normal conditions. When abnormal data appears in the network, its anomaly detection module effectively identifies and eliminates the anomalous node, terminating the synchronization calculation process for that node in the current cycle. However, the traditional FTSP protocol lacks an anomaly detection mechanism, and abnormal data directly participates in the synchronization calculation, resulting in significant synchronization deviations.

[0106] A random communication overhead coefficient in the range of [0.001–0.005] was introduced into the simulation model to simulate the packet loss and channel contention in the actual communication environment. During the experiment, after each round of time synchronization algorithm execution, the total energy consumption data of the entire network nodes was collected. Based on the cumulative statistical results of 70 rounds of experimental data, the total energy consumption of the network nodes was generated. Figure 11 The communication energy consumption comparison curve of the hybrid time synchronization algorithm and the traditional TPSN protocol is shown.

[0107] Simulation results demonstrate that the hybrid time synchronization algorithm proposed in this paper significantly reduces communication energy consumption compared to traditional TPSN algorithms while maintaining similar synchronization accuracy, validating the algorithm's effectiveness. Under the same experimental conditions, the hybrid algorithm's communication energy consumption is only 58.96% of that of the traditional TPSN algorithm. This characteristic can effectively improve the endurance of wireless sensor nodes.

[0108] The various embodiments in this specification are described in a progressive manner, with each embodiment focusing on the differences from other embodiments. Reference can be made to the common and similar parts between the various embodiments. For the devices disclosed in the embodiments, since they correspond to the methods disclosed in the embodiments, the description is relatively simple, and the relevant parts can be referred to the method description.

[0109] The above description of the disclosed embodiments is intended to enable one skilled in the art to implement or use the present invention. Various modifications to these embodiments will be readily apparent to one skilled in the art, and the general principles defined herein may be implemented in other embodiments without departing from the spirit or scope of the present invention. Therefore, the present invention is not limited to the embodiments shown herein but is intended to conform to the widest scope consistent with the principles and novel features disclosed herein.

Claims

1. A sensor network time synchronization method, characterized in that: Cluster the sensor nodes according to the devices they belong to; Between clusters, the clock frequency offset between the master clock signal and the cluster head node is quantified and combined with the improved TPSN protocol to dynamically calibrate the logical clock of the cluster head node; Within the cluster, the logical clocks of the child nodes in the cluster are calibrated through the clock drift and clock offset between the cluster head node and the child nodes in the cluster.

2. The time synchronization method according to claim 1, wherein: Cluster the sensor nodes according to their device numbers, including: Allocate device numbers to all sensor nodes based on the device to which they belong; Randomly select a sensor node and determine whether the device to which it belongs has a cluster head. If not, use the current node as the cluster head of the corresponding device cluster. If so, return to select other sensor nodes until all sensor nodes are traversed.

3. The time synchronization method according to claim 1, wherein: A fixed-cycle synchronization mechanism is used between clusters.

4. The time synchronization method according to claim 1, wherein: Dynamically calibrate the logical clock of the cluster head node, including: determining a frequency deviation based on the frequency of the master clock signal and the clock frequency offset; Calibrate the logical clock of the cluster head node according to the frequency deviation using the following formula; C_xuni=C_time+offset+Δf / f0×(C_time-T_syn) Where C_xuni represents the logical clock of the cluster head node, C_time represents the local clock of the cluster head node, offset represents the relative time deviation between the node local clock and the reference clock, f0 represents the nominal frequency of the crystal oscillator of the cluster head node, Δf represents the frequency deviation, and T_syn represents the local clock of the cluster head node at the end of the last synchronization.

5. The time synchronization method according to claim 1, wherein: Based on the clock mapping relationship in the FTSP protocol, the clock drift and clock offset between the cluster head node and the sub-nodes in the cluster are determined by the least squares method.

6. The time synchronization method according to claim 3, wherein: After the inter-cluster time synchronization is completed, the intra-cluster time synchronization is started, and the abnormal data judgment is triggered according to the time difference of different periods.

7. The time synchronization method according to claim 6, characterized in that: The time-scale difference expression is: Where δ represents the time difference, T represents the synchronization period, f0 represents the nominal frequency of the crystal oscillator of the cluster head node, and f A A function that represents the actual frequency of the node clock crystal changing with time t.

8. The time synchronization method according to claim 6, characterized in that: Abnormal data determination includes: When the absolute deviation between the clock drift and the historical value exceeds the preset threshold, the current synchronization data is determined to be abnormal and filtered.

9. A sensor network time synchronization system, characterized in that: It includes a main control device, sensor nodes distributed inside the equipment to be monitored, and a time synchronization device, wherein: The time synchronization device applies the sensor network time synchronization method described in any one of claims 1 to 8 to perform time synchronization on the main control device and the sensor nodes.

Citation Information

Cited By

  • Remote meter high-precision synchronization method and system

    CN121727673A