Network one-way time delay measurement system and method
By using a measurement end connected via a full-duplex network and employing 1PPS signal synchronization and time delay calibration, the problems of low efficiency and synchronization difficulties in network time delay measurement in existing technologies are solved, achieving high-precision unidirectional time delay measurement, which is suitable for full-duplex high-speed communication.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- NAT TIME SERVICE CENT CHINESE ACAD OF SCI
- Filing Date
- 2025-12-31
- Publication Date
- 2026-04-17
AI Technical Summary
In existing technologies, network latency measurement is inefficient and cannot accurately obtain the one-way latency of uplink and downlink, which is especially unsuitable for high-speed communication scenarios. Furthermore, existing methods cannot achieve time synchronization in enclosed spaces.
The first and second measurement terminals, connected via a network in full-duplex mode, use a time reference module to generate interrupt signals and time codes to measure uplink and downlink delays. Combined with 1PPS signal synchronization, the transmission, reception, and reading delays are calibrated, and the one-way transmission delay is calculated.
It improves the accuracy and efficiency of one-way network latency measurement, enables time synchronization in enclosed spaces, is suitable for full-duplex high-speed communication scenarios, and provides more accurate network status monitoring and time synchronization accuracy.
Smart Images

Figure CN121887680A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of latency measurement technology, specifically to a network one-way latency measurement system and method. Background Technology
[0002] In related technologies, with the popularization of networks, network time synchronization services have been widely applied in various fields such as transportation, finance, healthcare, education, and manufacturing. It is currently the most widely used wired time synchronization service method, and these fields have increasingly higher requirements for time synchronization accuracy. Internet latency is one of the inherent properties of networks and an important parameter for evaluating network performance. Measuring internet latency allows for real-time monitoring of network operation, timely resolution of network congestion, and the establishment of network latency models based on latency measurement data. This is crucial for studying and optimizing network structure, improving network performance, enhancing network service quality, and increasing network time synchronization accuracy.
[0003] One-way latency testing often uses single-duplex mode, such as NTP and PTP timing methods. This method has significant drawbacks: first, it's inefficient; measuring the same amount of data in single-duplex mode takes more than twice as long as in full-duplex mode. Second, it's unsuitable for high-speed communication scenarios; half-duplex latency measurement is not applicable to full-duplex communication such as video calls and real-time data transmission. Furthermore, most current network latency measurements use ping to obtain bidirectional round-trip latency, which cannot accurately determine the one-way latency of uplink and downlink.
[0004] It should be noted that the information disclosed in the background section above is only used to enhance the understanding of the background of the present invention, and therefore may include information that does not constitute prior art known to those skilled in the art. Summary of the Invention
[0005] This invention provides a network one-way latency measurement system, a network one-way latency measurement method, a computer program product, and an electronic device, which can effectively overcome the defects existing in the prior art.
[0006] Other features and advantages of the invention will become apparent from the following detailed description, or may be learned in part by practice of the invention.
[0007] According to a first aspect of the present invention, a method for measuring one-way network latency is provided, the method comprising: The first measuring end determines the local 1PPS signal and generates an interrupt signal based on the rising edge of the local 1PPS signal; The first measurement signal generation unit corresponding to the first measurement terminal responds to the interrupt signal to generate a downlink delay measurement signal; sends the downlink delay measurement signal to the second measurement terminal; and configures the corresponding transmission delay ΔT. send2; The second measurement terminal receives the downlink delay measurement signal, reads the time code signal to determine the corresponding arrival time T2 and the corresponding reading delay ΔT. read2 ; and configure the corresponding receiving delay ΔT recv2 ; The downlink transmission delay is determined based on the rising edge, arrival time, and various delays of the local 1PPS signal.
[0008] In some exemplary embodiments, sending the downlink delay measurement signal to the second measurement terminal includes: The first measurement signal generation unit sends the downlink delay measurement signal to the first measurement signal output unit and configures the corresponding transmission delay ΔT. send2 ; The measurement signal output unit sends the downlink delay measurement signal to the second measurement terminal.
[0009] In some exemplary embodiments, the second measuring end receives a downlink delay measurement signal and reads a time code signal to determine the corresponding arrival time T2 and the corresponding reading delay ΔT. read2 ; and configure the corresponding receiving delay ΔT recv2 ,include: The second measurement signal input unit of the second measurement end receives the downlink delay measurement signal and sends the downlink delay measurement signal to the second measurement signal receiving unit; and configures the corresponding receiving delay ΔT. recv2 The second measurement signal receiving unit confirms receipt of the downlink delay measurement signal, reads the time code signal from the second local time establishment unit to determine the corresponding arrival time T2, and configures the corresponding reading delay ΔT. read2 .
[0010] In some exemplary embodiments, determining the downlink transmission delay based on the rising edge, arrival time, and various delays of the local 1PPS signal includes: ΔT_down = T2 - (ΔT) read2 +ΔT recv2 +ΔT send2 ) Where ΔT_down is the downlink transmission delay.
[0011] In some exemplary embodiments, the method further includes: The second measuring end determines the local 1PPS signal and generates an interrupt signal based on the rising edge of the local 1PPS signal; The second measurement signal generation unit corresponding to the second measurement terminal responds to the interrupt signal to generate an uplink delay measurement signal; sends the uplink delay measurement signal to the first measurement terminal; and configures the corresponding transmission delay ΔT. send1 ; The first measurement terminal receives the uplink delay measurement signal and reads the time code signal to determine the corresponding arrival time T1 and the corresponding reading delay ΔT. read1 ; and configure the corresponding receiving delay ΔT recv1 ; The uplink transmission delay is determined based on the rising edge, arrival time, and various delays of the local 1PPS signal.
[0012] In some exemplary embodiments, the uplink transmission delay is determined based on the rising edge, arrival time, and various delays of the local 1PPS signal, including... ΔT_up=T1-(ΔT recv1 +ΔT read1 +ΔT send1 ) Where T1 is the arrival time of the uplink delay measurement signal determined by the first measurement signal receiving unit of the first measurement end; ΔT read1 The reading delay ΔT corresponds to the time code signal read by the first measurement signal receiving unit. recv1 The receiving delay ΔT is the time delay for the first measurement signal receiving unit to receive the uplink delay measurement signal transmitted by the first measurement signal input unit. send1 The transmission delay is from the second measurement signal generation unit to the second measurement signal transmission unit.
[0013] In some exemplary embodiments, the rising edge of the local 1PPS signal at the first measurement end is synchronized with the rising edge of the local 1PPS signal at the second measurement end.
[0014] In some exemplary embodiments, the method further includes: The first and second measurement terminals are connected using a short network cable, and the transmission delay, reception delay, and reading delay are calibrated.
[0015] According to a second aspect of the present invention, a network one-way latency measurement system is provided, the system comprising: a first measurement terminal and a second measurement terminal disposed opposite to each other; each measurement terminal comprising: The time reference module is used to generate an interrupt signal based on the rising edge of the local 1PPS signal, and send the interrupt signal and time code to the time delay measurement module; The delay measurement module is used to generate a delay measurement signal based on the interrupt signal and send it to the opposite measurement end, and configure the corresponding transmission delay; and to receive the delay measurement signal sent by the opposite measurement end, and record the corresponding reception time, configure the corresponding reading delay, and reception delay. The receiving time is used to calculate the transmission delay by combining the sending delay and the receiving delay.
[0016] In some exemplary embodiments, the local 1PPS signals of the first and second measuring ends are kept synchronized; the interrupt signal and time code signal between the first and second measuring ends are kept synchronized.
[0017] According to a third aspect of the present invention, a computer program product is provided, on which a computer program is stored, wherein the computer program, when executed by a processor, implements the above-described network one-way latency measurement method.
[0018] According to a fourth aspect of the present invention, a storage medium is provided having a computer program stored thereon, which, when executed by a processor, performs the above-described one-way network latency measurement.
[0019] The method and system provided in the embodiments of the present invention consist of two measurement terminals. These terminals have identical structures and functions, each containing a time reference module and a delay measurement module. The time reference module provides time codes and interrupt signals to the delay measurement module. The 1PPS signals at both ends are kept synchronized, and an interrupt signal is generated based on the 1PPS signal, which can simultaneously trigger the transmission of uplink and downlink delay measurement signals. The first and second measurement terminals receive the uplink and downlink delay measurement signals at times T1 and T2, respectively. The measured time values are stored in real time at both ends, and the one-way uplink and downlink delays of the network are calculated based on these time values. This invention improves the measurement accuracy and efficiency of one-way network delay and, by analyzing the one-way delay data, grasps the network communication status, which is of great significance for improving network service quality and network timing accuracy.
[0020] It should be understood that the above general description and the following detailed description are exemplary and explanatory only, and are not intended to limit the invention. Attached Figure Description
[0021] The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate embodiments consistent with the invention and, together with the description, serve to explain the principles of the invention. It is obvious that the drawings described below are merely some embodiments of the invention, and those skilled in the art can obtain other drawings based on these drawings without any inventive effort.
[0022] Figure 1 This schematic diagram illustrates a network one-way delay measurement system according to an exemplary embodiment of the present invention. Figure 2 This schematic diagram illustrates a first measuring end according to an exemplary embodiment of the present invention; Figure 3 The diagram illustrates a time delay measurement process according to an exemplary embodiment of the present invention. Figure 4 This diagram schematically illustrates a time delay calibration principle in an exemplary embodiment of the present invention. Figure 5 The diagram illustrates an exemplary embodiment of the present invention: a method for measuring one-way network latency. Detailed Implementation
[0023] Exemplary embodiments will now be described more fully with reference to the accompanying drawings. However, these exemplary embodiments can be implemented in many forms and should not be construed as limited to the examples set forth herein; rather, they are provided so that the invention will be more comprehensive and complete, and will fully convey the concept of the exemplary embodiments to those skilled in the art. The described features, structures, or characteristics may be combined in any suitable manner in one or more embodiments.
[0024] Furthermore, the accompanying drawings are merely illustrative of the invention and are not necessarily drawn to scale. The same reference numerals in the drawings denote the same or similar parts, and therefore repeated descriptions of them will be omitted. Some block diagrams shown in the drawings are functional entities and do not necessarily correspond to physically or logically independent entities. These functional entities can be implemented in software, in one or more hardware modules or integrated circuits, or in different network and / or processor devices and / or microcontroller devices.
[0025] In related technologies, most current network latency measurements use ping to obtain bidirectional round-trip latency. This method cannot accurately determine the unidirectional latency of uplink and downlink. Compared to bidirectional latency, unidirectional latency can better reflect the asymmetry of latency between the sending and receiving ends and more accurately reflect the actual application of the network. However, unidirectional latency measurement requires time synchronization between the sending and receiving ends. Some existing technical solutions estimate clock characteristics, assuming that clock characteristics drift linearly. However, in reality, as clocks age, the drift slope of clock characteristics changes, and the clock deviation between the two ends cannot be subtracted using a fixed offset slope. Other solutions propose using GPS signals to synchronize the time of the two ends of the measurement, but two problems still exist: First, it is difficult to implement due to deployment environment limitations. Network equipment rooms are mostly enclosed spaces, lacking the conditions for connecting external GPS antennas, making measurement impossible. Second, it does not fully consider read latency, send latency, and receive latency, and does not calibrate device latency, resulting in the measured latency including both device latency and network latency, and lacks a clear implementation method. The existing publicly available technologies do not cover how to construct a feasible, high-precision, and complete one-way network delay measurement system and method.
[0026] To address the shortcomings and deficiencies of existing technologies, this example embodiment provides a network one-way latency measurement system, with reference to... Figure 1As shown, the system includes a first measurement terminal and a second measurement terminal. The first and second measurement terminals can be directly connected via a network. By utilizing the network to transmit uplink and downlink delay measurement signals, full-duplex simultaneous measurement of the transmission delay between the two terminals is performed. Each measurement terminal includes: a time reference module, used to generate an interrupt signal based on the rising edge of the local 1PPS signal and send the interrupt signal and time code to the delay measurement module; a delay measurement module, used to generate a delay measurement signal based on the interrupt signal and send it to the counterpart measurement terminal, and record the corresponding transmission time; and a module that receives the delay measurement signal sent by the counterpart measurement terminal and records the corresponding reception time. The transmission time and reception time are used to calculate the transmission delay by combining the transmission delay and reception delay. Additionally, a power supply unit may be included.
[0027] For example, refer to Figure 2 As shown, the time reference module includes a passive timekeeping unit, a signal receiving unit, a local clock, and a local time establishment unit. The signal receiving unit generates a 1PPS signal and a time code signal based on the received BPC time synchronization signal. The passive timekeeping unit disciplines the rubidium clock and generates the 1PPS signal, and parses the received satellite signal to generate a time code signal. The local time establishment unit determines the validity of the time code and 1PPS outputs from the signal receiving unit and the passive timekeeping unit according to preset rules, and determines the local 1PPS signal by combining it with the 10MHz signal output from the local clock. The local clock provides a 10MHz signal to the local time establishment unit.
[0028] Specifically, the passive timekeeping unit includes a satellite receiver and a rubidium clock. It receives satellite signals, parses the time code, and disciplines the rubidium clock. A Kalman filter algorithm is used to filter the difference between the 1PPS output by the rubidium clock and the 1PPS output by the satellite receiver. Then, a straight line is fitted using the least squares method, with the slope representing the rubidium clock frequency drift. After 4 hours, the external satellite signal is disconnected. The rubidium clock is then disciplined using the slope for 48 hours, ensuring a drift within 10µs. After 48 hours, discipline is no longer required, and the rubidium clock keeps time according to its own frequency, outputting Keep_1PPS and the time code.
[0029] The signal receiving unit can receive BPC signals indoors where the BPC timing signal is strong, and generate BPC_1PPS and time code.
[0030] The local clock uses a temperature-controlled crystal oscillator, providing a 10MHz operating frequency for the local time establishment unit.
[0031] The local time establishment unit determines the validity of the time code and 1PPS output by the signal receiving unit and the passive timekeeping unit. It also combines this with the 10MHz signal from the received local clock, measuring the difference ΔT_1PPS between BPC_1PPS and Keep_1PPS, and selecting one as the local Local_1PPS. Local_1PPS is the basis for the interrupt signal, and the judgment criteria are as follows: (1) When the external BPC signal is invalid, Local_1PPS uses Keep_1PPS; (2) When the external BPC signal is valid and ΔT_1PPS > 100μs, it indicates that the BPC signal deviation is large, and Local_1PPS adopts Keep_1PPS; (3) When the external BPC signal is valid and ΔT_1PPS < 100μs, it indicates that the BPC signal deviation is small, and Local_1PPS adopts BPC_1PPS. For example, the delay measurement module includes: a delay measurement configuration unit, used to configure the signal characteristic information of the delay measurement signal and send the signal characteristic information to the measurement signal generation unit; wherein, the signal characteristic information includes: the number of bytes contained in the signal message, the time interval of message transmission, and the network protocol of the delay measurement signal; a measurement signal generation unit, used to respond to an interrupt signal, generate a delay measurement signal according to the signal characteristic configuration information, and send the delay measurement signal to the measurement signal output unit; a measurement signal output unit, used to send the delay measurement signal to the opposite measurement end; a measurement signal input unit, used to receive the delay measurement signal sent to the opposite measurement end and transmit the signal to the measurement signal receiving unit; a measurement signal receiving unit, used to receive the delay measurement signal and record the corresponding reception time; calculate the transmission delay based on the reception time and transmit it to the delay measurement data processing unit; and a delay measurement data processing unit, used to store and analyze the signal and the corresponding time measurement data.
[0032] Specifically, refer to Figure 3 As shown, the first measurement end is used as an example for explanation. The delay measurement configuration unit configures the characteristics of the delay measurement signal, including the number of bytes contained in the delay measurement signal message, the time interval between the transmission of each delay measurement message, and the network protocol through which the delay measurement signal passes, and outputs the configuration information to the measurement signal generation unit.
[0033] After receiving the interrupt signal from the local time establishment unit, the measurement signal generation unit generates a downlink delay measurement signal and sends it to the measurement signal output unit. All bits of the downlink delay measurement signal are set to 1.
[0034] The signal output unit outputs the downlink delay measurement signal to the second measurement terminal through the physical interface.
[0035] The signal input unit receives the uplink delay measurement signal from the second measurement terminal through the physical interface and transmits it to the measurement signal receiving unit.
[0036] After confirming receipt of the delay measurement signal, the measurement signal receiving unit reads the time code signal and records the reception time T1. All bits of the uplink delay measurement signal message are set to 2. The measurement signal receiving unit transmits the reception time of the uplink measurement signal to the delay measurement data processing unit.
[0037] The measurement data processing unit will store the data for at least 30 days, analyze and model the data distribution patterns, and obtain the characteristics of the uplink one-way latency. It will then perform comprehensive calculations on the output.
[0038] For example, the power supply unit consists of a battery and a power display unit. The battery is a rechargeable battery that can operate for 4 hours without power, and the power display shows the current power level of the test terminal. The battery unit provides DC voltage to the first and second time reference modules, ensuring normal operation of the measurement terminal after a power outage while also providing portability.
[0039] For example, the delay includes: a read delay, which is the delay when the measurement signal receiving unit reads the time code signal from the local time establishment unit when it determines that it has received a delay measurement signal. The read delays of the first measurement end and the second measurement end are respectively: ΔT read1 and ΔT read2 .
[0040] The transmission delay is the time delay from the measurement signal generation unit to the measurement signal transmission unit. It can be the time delay of the measurement signal from the application layer, transport layer, network layer, data link layer to the physical layer network interface card. The transmission delays of the first and second measurement ends are respectively: ΔT send2 and ΔT send1 .
[0041] The reception delay is the time delay from the measurement signal input unit to the measurement signal receiving unit, which can be the delay of the signal from the physical layer network card to the data link layer, network layer, transport layer, and application layer. The reception delays of the first measurement end and the second measurement end are respectively: ΔT recv1 and ΔT recv2 The uplink and downlink latency of the network are ΔT_up and ΔT_down, respectively.
[0042] refer to Figure 3 As shown, taking the upstream measurement as an example, it can specifically include: (1) The second measuring end acquires external time signals, including: acquiring external time signals includes acquiring BPC timing signals through an antenna indoors, parsing and generating BPC_1PPS and time code signals, and briefly acquiring satellite timing signals through a satellite antenna outdoors before switching to a timekeeping state and outputting Keep_1PPS and time code signals. The time codes of the two time sources include: year, month, day, hour, minute, and second.
[0043] (2) The second measurement end establishes local time, including: In the time reference module, the local time establishment unit outputs a 10MHz signal through the local clock to measure two external 1PPS signals, and selects one 1PPS signal as the local 1PPS time source. The time code is also selected from this signal. The year, month, day, hour, minute, and second of the time code are converted into the total number of seconds from 0:00:00 on January 1, 1970 to the present in UTC time. Milliseconds and microseconds are added according to the 1PPS signal and the 10MHz signal. The synchronization accuracy of the BPC time signal and the satellite time signal is at the microsecond level. The local time at both ends of the measurement will be kept at the microsecond level of synchronization.
[0044] (3) The second measurement end reads the time and generates an uplink delay measurement signal, including: the local time establishment unit generates an interrupt signal based on the rising edge of the local 1PPS signal and sends it to the measurement signal generation unit. The measurement signal generation unit generates a downlink delay measurement signal based on the UDP or TCP protocol, with a byte range of 1~2000 and a transmission interval set to milliseconds, according to the configuration signal input by the delay measurement configuration unit. The application layer reads the time code of the time reference unit, responds to the interrupt signal input by the local time establishment unit, and sends the downlink delay measurement signal. In addition, the transmission time can also be recorded by reading the time code signal.
[0045] (4) The second measurement end transmits the uplink delay measurement signal, including: after the uplink delay measurement signal is generated, the measurement signal generation unit sends the uplink delay measurement signal to the measurement signal output unit (through the application layer to the physical layer network card and other layers). This step generates the transmission delay ΔT. send1 And transmit it to the first measurement terminal via the network.
[0046] (6) The first measurement end reads the time and records the arrival time of the uplink delay measurement signal, including: at the first measurement end, the measurement signal input unit receives the uplink delay measurement signal and sends it to the measurement signal receiving unit (through the physical layer network card to the application layer and other layers). This step generates the reception delay ΔT. recv1 After the measurement signal receiving unit confirms receipt of the uplink delay measurement signal, the application layer reads the time code signal from the time reference unit and records the timestamp T2 at this time as the reception time. This step generates the reading delay ΔT. read1 .
[0047] The uplink delay measurement signal is transmitted at the rising edge of 1PPS, i.e., the moment when the count value is 0 less than one second later. The uplink delay measurement signal is received at T1 - ΔT. read1 The time delay between the sending and receiving times is ΔT. send1 +ΔT_up+ΔT recv1 The local times of the two measuring ends are kept synchronized, resulting in the following formula: T1-ΔT read1 -0 = ΔT send1 +ΔT_up+ΔT recv1 The above equation can be simplified to: ΔT_up=T1-(ΔT recv1 +ΔT read1 +ΔT send1 ) T1 can be read at the first measuring end, ΔT recv1 +ΔT read1 +ΔT send1 Deductions are made based on the standard.
[0048] The downlink measurement principle is the same as the uplink measurement principle, which yields the following: ΔT_down = T2 - (ΔT) read2 +ΔT recv2 +ΔT send2 ) T2 can be read at the second measuring end, ΔT read2 +ΔT recv2 +ΔT send2 Deductions are made based on the standard.
[0049] For example, refer to Figure 4 As shown, delay calibration is achieved by comparing the 1PPS signal output by the time reference module. Before testing, a short network cable is used to directly connect the two ends of the test. The transmission delay at both ends of the measurement is negligible. Taking the uplink delay calibration as an example, the second delay measurement module takes the local 1PPS output as 1PPS_1. The second delay measurement module sends the uplink delay measurement signal to the first measurement end at the rising edge of the local 1PPS. After receiving the uplink delay measurement signal, the first delay measurement module reads the time code of the first time reference module and writes 1 to the register of the first time reference module. The first time reference module uses a high-speed processor to detect the digit 1 and generates a 1PPS signal 1PPS_2. The difference between 1PPS_1 and 1PPS_2 is measured by an external time interval counter. The difference includes the transmission delay ΔT of the second measurement end. send1 The receiving delay ΔT at the first measurement end recv1 and read latency ΔT read1 The difference of 1PPS between the two ends can be obtained as follows: ΔT recv1 +ΔTread1 +ΔT send1 .
[0050] Similarly, by measuring the difference between 1PPS_3 and 1PPS_4 using a time interval counter, we can obtain: ΔT read2 +ΔT recv2 +ΔT send2 .
[0051] The time delay can be calibrated through the above measurements.
[0052] In this example embodiment, a method for measuring one-way network latency is provided, which can be applied to the aforementioned one-way network latency measurement system. (Reference) Figure 5 As shown, the method includes: Step S11: The first measuring end determines the local 1PPS signal and generates an interrupt signal based on the rising edge of the local 1PPS signal. Step S12: The first measurement signal generation unit corresponding to the first measurement end responds to the interrupt signal to generate a downlink delay measurement signal; sends the downlink delay measurement signal to the second measurement end; and configures the corresponding transmission delay ΔT. send2 ; Step S13: The second measurement terminal receives the downlink delay measurement signal, reads the time code signal to determine the corresponding arrival time T2 and the corresponding reading delay ΔT. read2 ; and configure the corresponding receiving delay ΔT recv2 ; Step S14: Determine the downlink transmission delay based on the rising edge, arrival time, and various delays of the local 1PPS signal.
[0053] The above-described method will be described in detail below with reference to the accompanying drawings and embodiments.
[0054] In step S11, the first measuring end determines the local 1PPS signal and generates an interrupt signal based on the rising edge of the local 1PPS signal.
[0055] Specifically, the first and second measurement terminals transmit and receive delay measurement signals in full-duplex mode. The time reference module provides the delay measurement module with a time code accurate to microseconds, and the 1PPS signals of the first and second measurement terminals maintain microsecond-level time synchronization during the measurement process.
[0056] For the first measurement end, the first time reference module can be located on the server side, and the delay measurement module can be located on the front-end terminal device. The local time establishment unit in the first time reference module uses the selected 1PPS signal as the local 1PPS time source and establishes the local time based on the time code signal and the local clock signal. An interrupt signal is generated based on the local 1PPS time source and sent to the first measurement signal generation unit in the first delay measurement module.
[0057] In step S12, the first measurement signal generation unit corresponding to the first measurement terminal generates a downlink delay measurement signal in response to the interrupt signal; sends the downlink delay measurement signal to the second measurement terminal; and configures the corresponding transmission delay ΔT. send2 .
[0058] For example, sending the downlink delay measurement signal to the second measurement terminal includes: The first measurement signal generation unit sends the downlink delay measurement signal to the first measurement signal output unit and configures the corresponding transmission delay ΔT. send2 ; The measurement signal output unit sends the downlink delay measurement signal to the second measurement terminal.
[0059] The first measurement signal generation unit sends the downlink delay measurement signal to the first measurement signal output unit, and configures the corresponding transmission delay ΔT. send2 ; The first measurement signal output unit sends the downlink delay measurement signal to the second measurement terminal.
[0060] Specifically, for the first measurement end, in the first delay measurement module, the first measurement signal generation unit generates a delay measurement signal based on the configuration information containing signal characteristics input by the time measurement configuration unit. After receiving the interrupt signal from the local time establishment unit, it sends the downlink delay measurement signal to the first measurement signal output unit, and sends it at a time when the count value is 0 below the second, that is, the rising edge of the 1PPS signal is defined as the 0 time. At the same time, the corresponding transmission delay ΔT is determined. send2 The first measurement signal output unit then sends the downlink delay measurement signal to the second measurement terminal.
[0061] In step S13, the second measuring terminal receives the downlink delay measurement signal, reads the time code signal to determine the corresponding arrival time T2 and the corresponding reading delay ΔT. read2 ; and configure the corresponding receiving delay ΔT recv2 .
[0062] For example, step S13 described above includes: The second measurement signal input unit of the second measurement end receives the downlink delay measurement signal and sends the downlink delay measurement signal to the second measurement signal receiving unit; and configures the corresponding receiving delay ΔT. recv2 The second measurement signal receiving unit confirms receipt of the downlink delay measurement signal, reads the time code signal from the second local time establishment unit to determine the corresponding arrival time T2, and configures the corresponding reading delay ΔT. read2 .
[0063] Specifically, at the second measurement end, in the second delay measurement module, the downlink delay measurement signal is received by the second measurement signal input unit and then transmitted to the second measurement signal receiving unit, corresponding to the receiving delay ΔT. recv2 After confirming receipt of the downlink delay measurement signal, the second measurement signal receiving unit reads the time code from the local time establishment unit in the second time reference module and records the reception time T2. The corresponding reading delay ΔT is... read2 .
[0064] In step S14, the downlink transmission delay is determined based on the rising edge, arrival time, and various delays of the local 1PPS signal.
[0065] For example, determining the downlink transmission delay ΔT_down based on the rising edge, arrival time, and various delays of the local 1PPS signal includes: ΔT_down = T2 - (ΔT) read2 +ΔT recv2 +ΔT send2 ) Wherein, T2 is the arrival time at which the second measurement signal receiving unit confirms receipt of the downlink delay measurement signal.
[0066] For example, the method further includes: Step S21: The second measuring end determines the local 1PPS signal and generates an interrupt signal based on the rising edge of the local 1PPS signal; Step S22: The second measurement signal generation unit corresponding to the second measurement terminal responds to the interrupt signal to generate an uplink delay measurement signal; sends the uplink delay measurement signal to the first measurement terminal; and configures the corresponding transmission delay ΔT. send1 ; Step S23: The first measuring end receives the uplink delay measurement signal, reads the time code signal to determine the corresponding arrival time T1 and the corresponding reading delay ΔT. read1 ; and configure the corresponding receiving delay ΔT recv1 ; Step S24: Determine the uplink transmission delay based on the rising edge, arrival time, and various delays of the local 1PPS signal.
[0067] For example, the uplink transmission delay ΔT_up is determined based on the sending time, arrival time, and various delays, including... ΔT_up=T1-(ΔT recv1 +ΔT read1 +ΔT send1 ) Where T1 is the arrival time of the uplink delay measurement signal determined by the first measurement signal receiving unit of the first measurement end; ΔT read1 The reading delay ΔT corresponds to the time code signal read by the first measurement signal receiving unit. recv1 The receiving delay ΔT is the time delay for the first measurement signal receiving unit to receive the uplink delay measurement signal transmitted by the first measurement signal input unit. send1 The transmission delay is from the second measurement signal generation unit to the second measurement signal transmission unit. Specifically, for the second test end, based on the same principle, it can send an uplink delay measurement signal to the first test end and perform delay measurement.
[0068] In some embodiments, considering the synchronization of 1PPS signals at the first and second measurement ends, the first and second test ends can simultaneously transmit downlink delay measurement signals and uplink delay measurement signals, thereby achieving simultaneous measurement of uplink and downlink delay. That is, while the first measurement end transmits the downlink delay measurement signal to the second measurement end, considering 1PPS signal synchronization, the second measurement end uses the same control method to simultaneously transmit the uplink delay measurement signal to the first test end and perform delay measurement.
[0069] Specifically, the second measurement signal generation unit corresponding to the second measurement end generates an uplink delay measurement signal based on the configuration information containing signal characteristics input by the second delay measurement configuration unit; and after receiving the interrupt signal input by the local time establishment unit, it sends the uplink delay measurement signal to the first measurement end.
[0070] For example, the method further includes: connecting the first measurement end and the second measurement end through a short network cable, and calibrating the transmission delay, reception delay and reading delay.
[0071] The beneficial effects of the method provided in the embodiments of the present invention include: 1. The network latency testing system provided by this invention ensures time synchronization between the two measurement ends by receiving BPC timing signals indoors and acquiring local passive timekeeping signals outdoors, thereby improving the reliability of the testing system.
[0072] 2. This invention uses a full-duplex method to measure network latency and employs 1PPS rising edge triggering at both ends to ensure consistent transmission times and reduce the use of timestamps, thereby improving measurement efficiency and real-time performance. It can provide a better measurement method for full-duplex high-speed communication application scenarios.
[0073] 3. The measuring end provided by this invention is equipped with a battery unit, which can receive external time signals in open outdoor locations by relying on the battery unit. After completing clock discipline, it switches to passive timekeeping mode, enabling the device to acquire time signals outdoors and maintain the time until it is moved indoors. This eliminates the limitations of the deployment environment during the measurement process and improves the versatility of the time delay measurement system.
[0074] 4. The measurement terminal provided by this invention has a time delay measurement data processing unit, which stores the time delay measurement data and performs calculations and modeling on the data. This is of great importance for understanding the network operation status and improving the accuracy of network time synchronization.
[0075] 5. The measurement terminal provided by the present invention has a measurement signal configuration unit, which can configure the length of the measurement signal byte, the time interval for transmission, and the network protocol for transmission, thereby increasing the applicability of the network latency measurement system.
[0076] 6. This invention elaborates on the various delay components of a network delay measurement system and provides a delay calibration method. By calibrating the delay, various delay interferences are eliminated, and the delay is attributed to uplink and downlink delay, thereby increasing the effectiveness of the delay measurement system.
[0077] It should be noted that the above figures are merely illustrative of the processes included in the method according to exemplary embodiments of the present invention, and are not intended to be limiting. It is readily understood that the processes shown in the above figures do not indicate or limit the temporal order of these processes. Furthermore, it is readily understood that these processes may, for example, be executed synchronously or asynchronously in multiple modules.
[0078] It should be noted that although several modules or units of the device for performing actions have been mentioned in the detailed description above, this division is not mandatory. In fact, according to embodiments of the present invention, the features and functions of two or more modules or units described above can be embodied in one module or unit. Conversely, the features and functions of one module or unit described above can be further divided and embodied by multiple modules or units.
[0079] The flowcharts and block diagrams in the accompanying drawings illustrate the architecture, functionality, and operation of possible implementations of systems, methods, and computer program products according to various embodiments of the present invention. In this regard, each block in a flowchart or block diagram may represent a module, segment, or portion of code containing one or more executable instructions for implementing a specified logical function. It should also be noted that in some alternative implementations, the functions indicated in the blocks may occur in a different order than those indicated in the drawings. For example, two consecutively indicated blocks may actually be executed substantially in parallel, and they may sometimes be executed in reverse order, depending on the functions involved. It should also be noted that each block in a block diagram or flowchart, and combinations of blocks in a block diagram or flowchart, may be implemented using a dedicated hardware-based system that performs the specified function or operation, or using a combination of dedicated hardware and computer instructions.
[0080] The units described in the embodiments of the present invention can be implemented in software or hardware, and the described units can also be located in a processor. The names of these units do not necessarily limit the specific unit itself.
[0081] It should be noted that, as another aspect, this application also provides a storage medium, which may be included in an electronic device or may exist independently without being assembled into the electronic device. The aforementioned storage medium carries one or more programs, which, when executed by an electronic device, cause the electronic device to perform the methods described in the following embodiments. For example, the electronic device may perform... Figure 1 The steps of the method shown.
[0082] In one embodiment, this application provides a computer program product including a computer program that, when executed by a processor, implements the steps in the above-described method embodiments.
[0083] Furthermore, the above figures are merely illustrative of the processes included in the method according to exemplary embodiments of the present invention, and are not intended to be limiting. It is readily understood that the processes shown in the above figures do not indicate or limit the temporal order of these processes. Additionally, it is readily understood that these processes may be executed synchronously or asynchronously, for example, in multiple modules.
[0084] Other embodiments of the invention will readily occur to those skilled in the art upon consideration of the specification and practice of the invention herein. This application is intended to cover any variations, uses, or adaptations of the invention that follow the general principles of the invention and include common knowledge or customary techniques in the art not disclosed herein. The specification and embodiments are to be considered exemplary only, and the true scope and spirit of the invention are indicated by the claims.
[0085] It should be understood that the present invention is not limited to the precise structure described above and shown in the accompanying drawings, and various modifications and changes can be made without departing from its scope. The scope of the invention is limited only by the appended claims.
Claims
1. A method for measuring one-way network delay, characterized in that, The method includes: The first measuring end determines the local 1PPS signal and generates an interrupt signal based on the rising edge of the local 1PPS signal; The first measurement signal generating unit corresponding to the first measurement end generates a downlink time delay measurement signal in response to the interrupt signal; sends the downlink time delay measurement signal to the second measurement end; and configures a corresponding sending time delay ΔT send2 ; The second measurement end receives the downlink delay measurement signal, reads the time code signal to determine the corresponding arrival time T2 and the corresponding reading delay ΔT read2 ; and configures the corresponding receiving delay ΔT recv2 ; The downlink transmission delay is determined based on the rising edge, arrival time, and various delays of the local 1PPS signal.
2. The method according to claim 1, characterized in that, Sending the downlink delay measurement signal to the second measurement terminal includes: The first measurement signal generating unit sends the downlink time delay measurement signal to the first measurement signal output unit, and configures a corresponding sending time delay ΔT send2 ; The measurement signal output unit sends the downlink delay measurement signal to the second measurement terminal.
3. The method according to claim 1, characterized in that, The second measurement end receives the downlink delay measurement signal, reads the time code signal to determine the corresponding arrival time T2 and the corresponding reading delay ΔT read2 ; as well as , configure the corresponding receiving delay ΔT recv2 , comprising: The second measurement signal input unit of the second measurement end receives the downlink delay measurement signal and sends the downlink delay measurement signal to the second measurement signal receiving unit; and configure the corresponding receiving delay ΔT recv2 The second measurement signal receiving unit confirms the reception of the downlink delay measurement signal, reads the time code signal to determine the corresponding arrival time T2 to the second local time establishing unit, and configures the corresponding reading delay ΔT read2 .
4. The method according to any one of claim 2 or 3, characterized in that, The downlink transmission delay is determined based on the rising edge, arrival time, and various delays of the local 1PPS signal, including: ΔT_down=T2-( ΔT read2 +ΔT recv2 +ΔT send2 ) Where ΔT_down is the downlink transmission delay.
5. The method according to any one of claims 1-4, characterized in that, The method further includes: The second measuring end determines the local 1PPS signal and generates an interrupt signal based on the rising edge of the local 1PPS signal; The second measurement signal generation unit corresponding to the second measurement terminal responds to the interrupt signal to generate an uplink delay measurement signal; sends the uplink delay measurement signal to the first measurement terminal; and configures the corresponding transmission delay ΔT. send1 ; The first measurement terminal receives the uplink delay measurement signal and reads the time code signal to determine the corresponding arrival time T1 and the corresponding reading delay ΔT. read1 ; and configure the corresponding receiving delay ΔT recv1 ; The uplink transmission delay is determined based on the rising edge, arrival time, and various delays of the local 1PPS signal.
6. The method according to claim 5, characterized in that, The uplink transmission delay is determined based on the rising edge, arrival time, and various delays of the local 1PPS signal, including... ΔT_up=T1-(ΔT recv1 +ΔT read1 +ΔT send1 ) Where T1 is the arrival time of the uplink delay measurement signal determined by the first measurement signal receiving unit of the first measurement end; ΔT read1 The reading delay ΔT corresponds to the time code signal read by the first measurement signal receiving unit. recv1 The receiving delay ΔT is the time delay for the first measurement signal receiving unit to receive the uplink delay measurement signal transmitted by the first measurement signal input unit. send1 The transmission delay is from the second measurement signal generation unit to the second measurement signal transmission unit.
7. The method according to claim 5, characterized in that, The rising edge of the local 1PPS signal at the first measurement end is synchronized with the rising edge of the local 1PPS signal at the second measurement end.
8. The method according to claim 1, characterized in that, The method further includes: The first and second measurement terminals are connected using a short network cable, and the transmission delay, reception delay, and reading delay are calibrated.
9. A network one-way delay measurement system, characterized in that, The system includes: a first measuring end and a second measuring end positioned opposite to each other; each measuring end includes: The time reference module is used to generate an interrupt signal based on the rising edge of the local 1PPS signal, and send the interrupt signal and time code to the time delay measurement module; The delay measurement module is used to generate a delay measurement signal based on the interrupt signal and send it to the opposite measurement end, and configure the corresponding transmission delay; and to receive the delay measurement signal sent by the opposite measurement end, and record the corresponding reception time, configure the corresponding reading delay, and reception delay. The receiving time is used to calculate the transmission delay by combining the sending delay and the receiving delay.
10. The system according to claim 1, characterized in that, The local 1PPS signals of the first and second measurement terminals are kept synchronized; the interrupt signals and time code signals between the first and second measurement terminals are kept synchronized.