CN114885414A - Algorithm for increasing time synchronization precision - Google Patents

Algorithm for increasing time synchronization precision Download PDF

Info

Publication number
CN114885414A
CN114885414A CN202210485556.9A CN202210485556A CN114885414A CN 114885414 A CN114885414 A CN 114885414A CN 202210485556 A CN202210485556 A CN 202210485556A CN 114885414 A CN114885414 A CN 114885414A
Authority
CN
China
Prior art keywords
time
ntr
time slot
data
equipment
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN202210485556.9A
Other languages
Chinese (zh)
Inventor
范以训
胡屾
慕国锋
张哲�
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
SHAANXI LINGYUN ELECTRONICS GROUP CO LTD
Original Assignee
SHAANXI LINGYUN ELECTRONICS GROUP CO LTD
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by SHAANXI LINGYUN ELECTRONICS GROUP CO LTD filed Critical SHAANXI LINGYUN ELECTRONICS GROUP CO LTD
Priority to CN202210485556.9A priority Critical patent/CN114885414A/en
Publication of CN114885414A publication Critical patent/CN114885414A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W56/00Synchronisation arrangements
    • H04W56/001Synchronization between nodes
    • YGENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02DCLIMATE CHANGE MITIGATION TECHNOLOGIES IN INFORMATION AND COMMUNICATION TECHNOLOGIES [ICT], I.E. INFORMATION AND COMMUNICATION TECHNOLOGIES AIMING AT THE REDUCTION OF THEIR OWN ENERGY USE
    • Y02D30/00Reducing energy consumption in communication networks
    • Y02D30/70Reducing energy consumption in communication networks in wireless communication networks

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Synchronisation In Digital Transmission Systems (AREA)

Abstract

The invention discloses an algorithm for increasing time synchronization precision, which comprises the following steps: data acquisition: the non-NTR equipment sends out an inquiry signal to the NTR equipment according to the allocated time-correcting time slot, the NTR equipment sends out a reply signal in the latter half of the time slot after receiving the inquiry signal, the reply signal contains the time T1 of receiving the inquiry signal, and the non-NTR equipment detects the time T2 of receiving the reply signal; according to the formula
Figure DDA0003629749340000011
Calculating the time delta t to be calibrated; step two: predicting; step three: performing interpolation calculation; step four: correcting; according to the synchronous filtering method, the time slot error of the non-NTR equipment is smaller relative to the time slot error of the NTR equipment, so that the subsequent deviation is smaller, the precision is obviously and greatly improved, and the actual use can be met; the invention adjusts the system error for many times by adding the filtering method between two RTTs, ensures the smaller drift of the non-NTR equipment time slot in the network relative to the NTR equipment time slot, and increases the precision of distance measurement, timing and the like.

Description

Algorithm for increasing time synchronization precision
Technical Field
The invention belongs to the technical field of radio communication, and particularly relates to an algorithm for increasing time synchronization precision.
Background
Time synchronization is the basis for wireless communication time division network operation, and is especially important for wireless network devices requiring ranging or timing.
Wireless time division network systems are typically designed according to a TDMA protocol in which the time of transmission is allocated in time slots, i.e. the user transmission messages are cycled in time.
When planning a wireless network, a device or a device with certain characteristics is designated as a Network Time Reference (NTR), the device sends a network access signal in a fixed time slot, and after receiving the signal, the device to be added into the network resolves related information and then adds into the network according to a related protocol.
After the network is accessed, the non-NTR device performs Timing by using a Round-Trip Timing (RTT). The realization method of RTT is as follows: the non-NTR device sends an inquiry signal to the NTR in a time-correcting time slot allocated to the non-NTR device, the NTR sends a reply signal at the midpoint of the time slot after receiving the inquiry signal, and the reply signal contains the arrival time T1 of the received inquiry signal. The non-NTR device measures the time of arrival T2 of the received reply signal.
The equation for solving Δ t can be established:
Figure BDA0003629749320000011
where Δ t is the time to be corrected and Td is the half-slot time.
With the development Of electronic technologies, the requirements for distance measurement, timing, and the like are continuously increased, and the communication network mainly functions to complete communication, so that the number Of Time slots for Time correction that can be allocated is small, which inevitably results in poor measurement accuracy, too large Time Of Arrival (TOA) data for measurement, and the measured errors due to clock drift Of clocks between two devices, displacement change between airplanes, and the like between two measurements are also increased, thereby affecting the accuracy Of distance measurement, timing, and the like.
Disclosure of Invention
The invention aims to provide a software filtering method to solve the problem that the precision is influenced by overlarge error caused by overlong RTT distance twice. The algorithm is realized in the correlation algorithm of non-NTR equipment.
In order to achieve the purpose, the invention provides the following technical scheme: an algorithm for increasing the accuracy of time synchronization, comprising the following steps: data acquisition: the non-NTR equipment sends out an inquiry signal to the NTR equipment according to the allocated time-correcting time slot, the NTR equipment sends out a reply signal in the latter half of the time slot after receiving the inquiry signal, the reply signal contains the time T1 of receiving the inquiry signal, and the non-NTR equipment detects the time T2 of receiving the reply signal; according to the formula
Figure BDA0003629749320000021
Calculating the time delta t to be calibrated; carrying out exception judgment on the acquired data, carrying out data iteration when the data is normal, and writing the data into a data cache; if the data is abnormal, iteration is not carried out, the data is abandoned, and the previous data is continuously used;
step two: and (3) prediction: pre-judging the offset direction and unit offset of the clock of the non-NTR equipment relative to the NTR equipment according to the acquired data;
step three: performing interpolation calculation; calculating time slots and time correction values required to be corrected next time according to the predicted deviation direction and unit deviation;
step four: and (3) correction: and adjusting once when the adjustment value calculated according to the interpolation exceeds a certain threshold value so as to reduce the error.
Preferably, the initial acquisition of data is performed when the device is on the network, and it is required to ensure that the time intervals of the first n groups of data acquisition are different; and to prevent cumulative errors, data acquisition needs to be ongoing and iterative.
Preferably, the prediction is performed once after each data acquisition, and after n times, the prediction is not performed after the first n-1 data acquisition; and (3) performing prediction in an idle period after data acquisition, setting a corresponding flag bit on a prediction result, and performing reliability analysis and marking if abnormal data occurs in the prediction process.
Preferably, the interpolation calculation depends on the past n acquisition values, and the correction value is increased according to the variation trend among the acquisition values so as to reduce the error in a maximum mode.
Preferably, during the correction, it is necessary to determine whether the next time slot is an RTT time slot, and if the next time slot is an RTT time slot, the adjustment and correction are not performed; whether the lower time slot is a sending time slot or not needs to be judged, and if the lower time slot is the sending time slot, the adjustment needs to be carried out after the sending is finished.
Compared with the prior art, the invention has the beneficial effects that: according to the synchronous filtering method, the time slot error of the non-NTR equipment is smaller relative to the time slot error of the NTR equipment, so that the subsequent deviation is smaller, the precision is obviously and greatly improved, and the actual use can be met; the invention adjusts the system error for many times by adding the filtering method between two RTTs, ensures the smaller drift of the non-NTR equipment time slot in the network relative to the NTR equipment time slot, and increases the precision of distance measurement, timing and the like.
Drawings
FIG. 1 is a schematic flow chart of the software filtering principle of the present invention;
FIG. 2 is a schematic view of a data acquisition process according to the present invention;
FIG. 3 is a flow chart illustrating prediction according to the present invention;
FIG. 4 is a schematic diagram of an interpolation process according to the present invention;
FIG. 5 is a schematic view of a calibration process according to the present invention;
fig. 6 is a schematic diagram of an implementation method of RTT according to the present invention.
Detailed Description
The technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the drawings in the embodiments of the present invention, and it is obvious that the described embodiments are only a part of the embodiments of the present invention, and not all of the embodiments. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present invention.
Referring to fig. 1 to 6, the present invention provides a technical solution: an algorithm for increasing the accuracy of time synchronization, comprising the following steps: data acquisition: the non-NTR equipment sends out inquiry signal to NTR equipment according to allocated time-correcting time slot, after receiving inquiry signal the NTR equipment can send out answer signal in the latter half of said time slotThe answer signal contains the time T1 of receiving the inquiry signal, and the non-NTR equipment detects the time T2 of receiving the answer signal; according to the formula
Figure BDA0003629749320000041
Calculating the time delta t to be calibrated; carrying out exception judgment on the acquired data, carrying out data iteration when the data is normal, and writing the data into a data cache; if the data is abnormal, iteration is not carried out, the data is abandoned, and the previous data is continuously used;
step two: and (3) prediction: pre-judging the offset direction and unit offset of the clock of the non-NTR equipment relative to the NTR equipment according to the acquired data;
step three: performing interpolation calculation; calculating time slots and time correction values required to be corrected next time according to the predicted deviation direction and unit deviation;
step four: and (3) correction: and adjusting once when the adjustment value calculated according to the interpolation exceeds a certain threshold value so as to reduce the error.
In this embodiment, preferably, the initial acquisition of data is performed when the device accesses the network, and it is required to ensure that the time intervals of the first n sets of data acquisition are different; and to prevent cumulative errors, data acquisition needs to be ongoing and iterative.
In this embodiment, preferably, the prediction is performed once after each data acquisition, and after n times, the prediction is not performed after the first n-1 data acquisitions; and (3) performing prediction in an idle period after data acquisition, setting a corresponding flag bit on a prediction result, and performing reliability analysis and marking if abnormal data occurs in the prediction process.
In this embodiment, preferably, the interpolation calculation depends on the past n times of collected values, and the correction value is increased according to the variation trend among the collected values to try to reduce the error to the maximum.
In this embodiment, preferably, during the correction, it is required to determine whether the next time slot is an RTT time slot, and if the next time slot is an RTT time slot, the adjustment and correction are not performed; whether the lower time slot is a sending time slot or not needs to be judged, and if the lower time slot is the sending time slot, the adjustment needs to be carried out after the sending is finished.
Although embodiments of the present invention have been shown and described, it will be appreciated by those skilled in the art that changes, modifications, substitutions and alterations can be made in these embodiments without departing from the principles and spirit of the invention, the scope of which is defined in the appended claims and their equivalents.

Claims (5)

1. An algorithm for increasing the accuracy of time synchronization, characterized by: the method comprises the following steps: data acquisition: the non-NTR equipment sends out an inquiry signal to the NTR equipment according to the allocated time-correcting time slot, the NTR equipment sends out a reply signal in the latter half of the time slot after receiving the inquiry signal, the reply signal contains the time T1 of receiving the inquiry signal, and the non-NTR equipment detects the time T2 of receiving the reply signal; according to the formula
Figure FDA0003629749310000011
Calculating the time delta t to be calibrated; carrying out abnormity judgment on the acquired data, carrying out data iteration when the data is normal, and writing the data into a data cache; if the data is abnormal, iteration is not carried out, the data is abandoned, and the previous data is continuously used;
step two: and (3) prediction: pre-judging the offset direction and unit offset of the clock of the non-NTR equipment relative to the NTR equipment according to the acquired data;
step three: performing interpolation calculation; calculating time slots and time correction values required to be corrected next time according to the predicted deviation direction and unit deviation;
step four: and (3) correction: and adjusting once when the adjustment value calculated according to the interpolation exceeds a certain threshold value so as to reduce the error.
2. An algorithm for increasing the accuracy of time synchronization according to claim 1, wherein: initially acquiring data when equipment accesses a network, wherein time intervals of first n groups of data acquisition need to be ensured to be different; and to prevent cumulative errors, data acquisition needs to be ongoing and iterative.
3. An algorithm for increasing the accuracy of time synchronization according to claim 1, wherein: predicting once after each data acquisition, and after n times, not predicting after the first n-1 times of data acquisition; and (3) performing prediction in an idle period after data acquisition, setting a corresponding flag bit on a prediction result, and performing reliability analysis and marking if abnormal data occurs in the prediction process.
4. An algorithm for increasing the accuracy of time synchronization according to claim 1, wherein: the interpolation calculation depends on the past n-time acquisition values, and the correction value is increased according to the variation trend among the acquisition values to strive for maximum error reduction.
5. An algorithm for increasing the accuracy of time synchronization according to claim 1, wherein: during correction, whether the next time slot is an RTT time slot or not needs to be judged, and if the next time slot is the RTT time slot, adjustment and correction are not carried out; whether the lower time slot is a sending time slot or not needs to be judged, and if the lower time slot is the sending time slot, the adjustment needs to be carried out after the sending is finished.
CN202210485556.9A 2022-05-06 2022-05-06 Algorithm for increasing time synchronization precision Pending CN114885414A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202210485556.9A CN114885414A (en) 2022-05-06 2022-05-06 Algorithm for increasing time synchronization precision

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202210485556.9A CN114885414A (en) 2022-05-06 2022-05-06 Algorithm for increasing time synchronization precision

Publications (1)

Publication Number Publication Date
CN114885414A true CN114885414A (en) 2022-08-09

Family

ID=82674444

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202210485556.9A Pending CN114885414A (en) 2022-05-06 2022-05-06 Algorithm for increasing time synchronization precision

Country Status (1)

Country Link
CN (1) CN114885414A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN115979277A (en) * 2023-02-22 2023-04-18 广州导远电子科技有限公司 Time synchronization method, device, electronic equipment and computer readable storage medium

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPH1124786A (en) * 1997-07-09 1999-01-29 Nec Corp Time correction system
CN104135333A (en) * 2014-07-24 2014-11-05 航天恒星科技有限公司 Time synchronization method of open loop network for TDMA (Time Division Multiple Address) node based on kalman filter
CN110445739A (en) * 2019-08-13 2019-11-12 北京智芯微电子科技有限公司 The compensation method of sampling frequency offset and device
CN111865462A (en) * 2020-05-26 2020-10-30 石化盈科信息技术有限责任公司 Time synchronization method and device based on Internet of things, computer and storage medium
CN113890667A (en) * 2021-12-06 2022-01-04 天津七一二通信广播股份有限公司 Reverse integral filtering round-trip time correction method and system

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPH1124786A (en) * 1997-07-09 1999-01-29 Nec Corp Time correction system
CN104135333A (en) * 2014-07-24 2014-11-05 航天恒星科技有限公司 Time synchronization method of open loop network for TDMA (Time Division Multiple Address) node based on kalman filter
CN110445739A (en) * 2019-08-13 2019-11-12 北京智芯微电子科技有限公司 The compensation method of sampling frequency offset and device
CN111865462A (en) * 2020-05-26 2020-10-30 石化盈科信息技术有限责任公司 Time synchronization method and device based on Internet of things, computer and storage medium
CN113890667A (en) * 2021-12-06 2022-01-04 天津七一二通信广播股份有限公司 Reverse integral filtering round-trip time correction method and system

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
陈威 等: "基于卡尔曼滤波的Link-22数据链网络时间同步算法", 应用科技, vol. 43, no. 06, 31 December 2016 (2016-12-31) *

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN115979277A (en) * 2023-02-22 2023-04-18 广州导远电子科技有限公司 Time synchronization method, device, electronic equipment and computer readable storage medium
CN115979277B (en) * 2023-02-22 2023-06-02 广州导远电子科技有限公司 Time synchronization method, apparatus, electronic device, and computer-readable storage medium

Similar Documents

Publication Publication Date Title
CN1263317C (en) Embedded loop delay compensation circuit used for multiple channel transceiver
US8108557B2 (en) System and method for measuring clock skew on a network
US8447004B2 (en) Estimation and compensation of clock variation in received signal
WO2001050674A1 (en) Synchronization in packet-switched telecommunications system
US20050180466A1 (en) System and method for maintaining a common sense of time on a network segment
EP3284217A1 (en) Methods, systems, and computer readable media for synchronizing timing among network interface cards (nics) in a network equipment test device
CN101848051B (en) Method and device for performing clock synchronization between equipment
CN102231907A (en) Clock synchronization method and apparatus in transmission system
US8301181B2 (en) Oscillator calibration
CN105306159A (en) Clock timestamp compensation method and clock timestamp compensation device
US20190018145A1 (en) Communications system
CN114885414A (en) Algorithm for increasing time synchronization precision
CN113691341A (en) TDMA network synchronization method
CN1965270B (en) Measuring clock jitter
US20200382233A1 (en) Information processing apparatus and time synchronization method
EP2627040B1 (en) Method for eliminating systematical error components in a set of one-way delay measurement results for communications between two or more computing systems in a communication network, apparatus for performing the method and computer program product
CN117675072A (en) Synchronization time determining method, time synchronization device, time synchronization system and medium
US10069584B2 (en) Frequency calibration apparatus and method
CN113141225A (en) Time synchronization method, device, storage medium and terminal
CN112765073A (en) Data sampling method, system, storage medium and computer equipment
US8718038B2 (en) Node system and supervisory node
CN109525349B (en) Distributed time synchronization method based on noise estimation and trust weighting
JP6893070B2 (en) Information communication system
Chen et al. A Fast Clock Synchronization Method for Wireless Sensor Networks Based on Grey Prediction.
CN116980065B (en) Clock calibration method, clock calibration device, terminal equipment and storage medium

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination