WO2011100906A2 - Method and apparatus for simulating packet delay variation in current network - Google Patents

Method and apparatus for simulating packet delay variation in current network Download PDF

Info

Publication number
WO2011100906A2
WO2011100906A2 PCT/CN2011/072611 CN2011072611W WO2011100906A2 WO 2011100906 A2 WO2011100906 A2 WO 2011100906A2 CN 2011072611 W CN2011072611 W CN 2011072611W WO 2011100906 A2 WO2011100906 A2 WO 2011100906A2
Authority
WO
WIPO (PCT)
Prior art keywords
network
delay
live
clock
time
Prior art date
Application number
PCT/CN2011/072611
Other languages
French (fr)
Chinese (zh)
Other versions
WO2011100906A3 (en
Inventor
吴国强
唐纯勇
Original Assignee
华为技术有限公司
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 华为技术有限公司 filed Critical 华为技术有限公司
Priority to PCT/CN2011/072611 priority Critical patent/WO2011100906A2/en
Priority to CN201180000356.XA priority patent/CN102171966B/en
Publication of WO2011100906A2 publication Critical patent/WO2011100906A2/en
Publication of WO2011100906A3 publication Critical patent/WO2011100906A3/en

Links

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L41/00Arrangements for maintenance, administration or management of data switching networks, e.g. of packet switching networks
    • H04L41/14Network analysis or design
    • H04L41/145Network analysis or design involving simulating, designing, planning or modelling of a network

Definitions

  • the embodiments of the present invention relate to the field of communications technologies, and in particular, to a method and apparatus for simulating a current network packet delay jitter. Background technique
  • IP networks With the development of IP networks, most communication networks now implement IP transmission. Since the IP network is an asynchronous network, it is impossible to obtain a clock through the physical link of the IP network. At present, the clock synchronization of the IP clock is relatively mature. However, in the case where the intermediate network device does not support IEEE (Institute of Electrical and Electronics Engineers) 1588, it is necessary to know the IP packet delay jitter of the transmission network (Packet). Delay Variation, hereinafter referred to as: PDV), can achieve IP clock synchronization well. The PDV indicates the delay jitter of the packet leaving the transmitting end to the receiving end. The PDV reflects the network characteristics of the intermediate transmission process.
  • IEEE Institute of Electrical and Electronics Engineers
  • a master clock on a ground base station controller communicates clock information with a base station (BTS) in other places through microwave transmission, and implements clock synchronization between the base station's slave clock and the base station controller's master clock through a clock algorithm.
  • BTS base station
  • the master clock on the ground base station controller communicates the clock information with the base station in other places through satellite transmission, and realizes the clock synchronization between the slave clock of the base station and the master clock of the base station controller by the clock algorithm.
  • the existing technology can set up various transmission network networking in the laboratory to simulate the environment of the live network, thereby implementing PDV testing on various transmission networks to verify whether the clock algorithm adapts to the transmission characteristics of the existing network.
  • the cost of constructing various transmission networks in the laboratory is relatively high, and for complex transmission networks, the environment built by the laboratory may not be able to simulate the environment of the existing network, so that the test data is not accurate.
  • the embodiment of the invention provides a method for simulating the delay of the current network packet delay, which includes:
  • the slave clock device After receiving the second clock packet, sending a fourth time to the slave clock device, so that the slave clock device adjusts the slave clock and the master according to the first time, the second time, the third time, and the fourth time Clock synchronization; the fourth time is a sum of a time when the second clock packet is received and a second network delay of the live network;
  • the first network delay of the live network and the second network delay of the live network in each period are sequentially acquired from the live network in a period of t.
  • the embodiment of the invention provides a device for simulating the current network packet delay jitter, which comprises:
  • a first sending module configured to send a first clock packet including a first time to the slave clock device in a period of t, so that the slave clock device receives the first clock packet and returns a second clock packet;
  • the moment is the difference between the time when the first clock packet is sent and the time delay of the first network in the live network; the time when the slave clock device receives the first clock packet is the second time; the slave clock device sends the The moment of the second clock packet is the third moment;
  • a second sending module configured to send a fourth time to the slave clock device after receiving the second clock packet, so that the slave clock device is configured according to the first time, the second time, the third time, and the first
  • the fourth time adjustment slave clock is synchronized with the master clock; the fourth time is the sum of the time when the second clock packet is received and the second network delay of the live network;
  • the first network delay of the live network and the second network delay of the live network in each period are sequentially acquired from the live network in a period of t.
  • the method and device for simulating the current network packet delay jitter in the embodiment of the present invention inserting the network delay of the existing network
  • the main clock device and the slave clock device used in the simulation enable the PDV data of the live network to be inserted and played back in the simulated environment, thereby realizing the process of simulating the PDV of the live network, thereby enabling the existing network to be performed in the simulated environment.
  • Embodiment 1 is a flowchart of Embodiment 1 of a method for simulating a packet delay of an existing network packet according to the present invention
  • Embodiment 2 is a flowchart of Embodiment 2 of a method for simulating a packet delay of an existing network packet according to the present invention
  • Figure 3 is a schematic diagram of network delay of the live network
  • Embodiment 1 of an analog network packet delay jitter device according to the present invention
  • FIG. 5 is a schematic diagram of Embodiment 2 of a device for simulating a current network packet delay jitter according to the present invention. detailed description
  • FIG. 1 is a flowchart of Embodiment 1 of a method for simulating a packet delay of an existing network packet according to the present invention. As shown in FIG. 1, the method includes:
  • Step 101 Send a first clock packet including the first time to the slave clock device in a period of t, so that the slave clock device returns the second clock packet after receiving the first clock packet.
  • the embodiment of the present invention provides a method for simulating the live network PDV, that is, the embodiment of the present invention can simulate the appearance network PDV by using a simple method, and then perform PDV test according to the same to implement clock synchronization. Therefore, PDV testing can be performed on the live network without performing PDV testing on the live network or in the same scenario as the existing network in the lab.
  • PDV test The purpose is to adapt the PDV characteristics of the transmission network through various clock algorithms, and finally ensure that the slave clock in the transmission network is synchronized with the master clock.
  • the master clock device is used as the execution body.
  • the primary clock device periodically sends a first clock packet to the slave clock device, where the first clock packet includes the first time; the first time is the time when the first clock packet is sent by the master clock device. The difference between the first network delay of the live network;
  • the clock device After receiving the first clock packet, the clock device returns a second clock packet to the master clock device.
  • the time when the clock device receives the first clock packet is the second time, and the time when the slave clock device sends the second clock packet is The third moment.
  • the difference between the second time and the first time is used as the current network delay.
  • the master clock device since the master clock device directly sends the first clock packet to the slave clock device, for example, in the laboratory, the master clock device can send the first clock packet to the slave clock device through a network cable (for example, 20 cm in length). Therefore, there is almost no delay between the master clock device and the slave clock device. Therefore, the difference between the second time and the first time is equal to the first network time delay of the live network.
  • the first network delay of the current network is the network delay of the packet sent by the active device to the current network slave device, and the network delay obtained from the clock device is equivalent to the received packet from the device in the current network.
  • Network latency The active network master device may be, for example, a BSC or a BSC master control unit, and the current network slave device may be, for example, a BTS or a BTS master control unit.
  • the first network delay of the live network in each period and the second network delay of the live network are obtained from the existing network in order of t.
  • the first network delay of the existing network and the second network delay of the live network can be obtained from the existing network in the period of t.
  • the t can be a value according to an actual situation, and the embodiment of the present invention does not limit the value of t.
  • Step 102 After receiving the second clock packet, send a fourth time to the slave clock device, so that the slave clock device adjusts the slave clock to synchronize with the master clock according to the first time, the second time, the third time, and the fourth time.
  • the master clock device After receiving the second clock packet, the master clock device sends a fourth time to the slave clock device.
  • the fourth time is the sum of the time when the master clock device receives the second clock packet and the second network delay of the current network.
  • the difference between the fourth time and the third time is used as the current network delay; wherein the third time is the time when the second clock packet is sent from the clock device.
  • the slave clock device can send the second clock packet to the master clock device through the network cable (for example, 20 cm in length). Therefore, there is almost no delay between the slave clock device and the master clock device, and thus, the difference between the fourth time and the third time is equal to the second network delay of the live network.
  • the network delay of the current network is the network delay of the packets sent from the device to the active device on the live network.
  • the network delay obtained from the clock device is equivalent to the packet sent by the slave device in the current network.
  • the network delay to the active network master device is the network delay of the packets sent from the device to the active device on the live network.
  • the slave clock After receiving the fourth time from the clock device, the slave clock can be adjusted according to the first time, the second time, the third time, and the fourth time, so that the slave clock is synchronized with the master clock.
  • the process of adjusting the slave clock to synchronize with the master clock according to the first time, the second time, the third time, and the fourth time is, for example, the following:
  • the slave circuit obtains the line delay D according to Equation 1, and then obtains the time deviation P between the slave clock and the master clock according to Equation 2, and then adjusts to synchronize with the master clock according to the time offset P, for example: if the time deviation P is 0.2S, then The slave clock is clocked down by 0.2 s to synchronize the slave clock with the master clock.
  • the network delay of the live network is inserted into the master clock device and the slave clock device for the simulation, so that the PDV data of the live network can be inserted and played back in the simulated environment, and the process of simulating the PDV of the live network is implemented. This allows PDV testing of the live network in a simulated environment.
  • Embodiment 2 is a flowchart of Embodiment 2 of a method for simulating a packet delay of an existing network packet according to the present invention. As shown in FIG. 2, the method includes:
  • Step 201 Obtain PDV data of the current network, that is, obtain the first network delay of the live network and the second network delay of the live network.
  • Figure 3 is a schematic diagram of the network delay of the live network.
  • the BSC in the current network transmits the packet to the BTS through a complex transmission network, where the BSC is present.
  • the clock in the BSC is the master clock
  • the BTS is the slave device on the live network
  • the clock in the BTS is the slave clock.
  • the master clock sends the tl information to the slave clock through the Sync file.
  • t2 is sent, and the slave clock sends a Delay-req message to the master clock, and the master clock sends t4 to the slave clock through the Delay-resp message.
  • the time information of tl, t2, t3, t4 is obtained from the clock.
  • the Delay-req packet sent from the clock to the primary clock may carry t3 or not.
  • T2-tl is the first network delay of the existing network
  • t4-t3 is the second network delay of the existing network.
  • the first network delay (Atl) of the live network and the second network delay (At2) of the live network can be obtained by: parsing the BSC received by the BTS on the remote or near-end BTS maintenance station The received packet receives the first network delay of the current network and the second network delay of the current network in a period of t; wherein each network acquires a first network delay of the existing network and a second network delay of the existing network.
  • the packets sent by the BSC received by the BTS are parsed, and tl, t2, t3, and t4 are obtained.
  • tl, t2, t3, and t4 are obtained.
  • the tl can be learned and the Delay-resp message can be parsed.
  • t4 and t2 and t3 are known from the BTS, so that the first network delay of the live network and the second network delay of the live network can be obtained.
  • the current network may send multiple packets.
  • multiple network network first network delays and multiple live network second network delays may be obtained.
  • multiple live networks may be used.
  • the network delay and the second network delay of the plurality of existing networks respectively select one live network first network delay and one live network second network delay as the adopted values. For example: Set the Sync packet sending frequency to 128*n packets/second, where n is an integer greater than or equal to 1, with a period of 1 second; then 128*n points per 1 second, you can get 128* n the first network delay of the existing network and the second network delay of the 128*n live network, and then select the first network delay of the live network and the second network delay of the live network in the current period.
  • There may be multiple methods for selecting one of the plurality of existing network first network delays (or the current network second network delay) for example:
  • the first type selects the smallest one from the plurality of existing network first network delays; the second type uses the average value of the first network delay values of all the live networks in each period as the selected current period.
  • the delay and the second network delay of the live network that is, the delay in the uplink direction and the downlink direction can be considered symmetric in this method.
  • Step 202 Insert the PDV data of the live network obtained in step 201 into the simulation environment to simulate the PDV of the live network.
  • the master clock device and the slave clock device in this embodiment may be devices in a lab environment.
  • the insertion of the upstream and downstream directions will be specifically described below.
  • Upstream direction (that is, the direction in which the master clock device sends packets to the slave clock device):
  • the sync clock packet reaches the slave clock
  • Downstream direction that is, the direction in which packets are sent from the clock device to the master clock device:
  • the slave clock device issues the Delay-req clock packet, it times the time stamp t3 ', where the delay-req clock packet can also be time stamped.
  • the network delay between the master clock device and the slave clock device is almost 0, that is, t2, -tl, 0, t4'-t3' ⁇ 0, whereby the uplink delay obtained from the clock device is Atl, downlink.
  • the delay is At2; that is, the network delay obtained from the clock device is the same as that in the live network.
  • the period of the clock packet sent by the master clock device and the slave clock device is the same as the period of the PDV data of the live network. That is to say, the PDV data of the live network is obtained by the period t, and the clock packet is sent in the simulation environment in the period of t, and the corresponding network delay data is inserted.
  • the method provided by the embodiment of the present invention can simulate the PDV characteristics of the live network in a laboratory environment, and then perform PDV testing on the master clock device and the slave clock device in the embodiment, that is, adapt to the transmission network through various clock algorithms.
  • the PDV feature ultimately guarantees that the slave clock is synchronized with the master clock.
  • the PDV data can be collected at the remote or near-end BTS maintenance station, and then the PDV jitter test of the clock algorithm under the complex transmission network can be realized in the laboratory environment, thereby verifying the delay of the IP clock algorithm in advance. Whether the time jitter capability meets the requirements of the live network, and does not need to wait until the clock algorithm is online to find the problem.
  • the foregoing storage medium includes: a medium that can store program codes, such as a ROM, a RAM, a magnetic disk, or an optical disk.
  • FIG. 4 is a schematic diagram of Embodiment 1 of the present invention for simulating a packet delay jitter device. As shown in FIG. 4, the device includes: a first sending module 41 and a second sending module 43.
  • the first sending module 41 is configured to send the first clock packet including the first time to the slave clock device in a period of t, so that the slave clock device receives the first clock packet and returns a second clock packet; The moment is the difference between the time when the first clock packet is sent and the time delay of the first network in the live network; the time when the slave clock device receives the first clock packet is the second time; the slave clock device sends the The time at which the second clock packet is described is the third time.
  • the second sending module 43 is configured to send the second clock packet to the slave clock device. Four times, so that the slave clock device synchronizes the slave clock with the master clock according to the first time, the second time, the third time, and the fourth time; the fourth time is the second clock packet received The sum of the time and the second network delay of the live network.
  • the first network delay of the live network and the second network delay of the current network in each period are sequentially obtained from the current network by using t.
  • the first network delay of the current network is the network delay of the packet sent by the active device to the current network to receive the packet from the device.
  • the second network delay of the current network is sent by the slave device on the live network to the current network. The network delay at which the master device receives packets.
  • the analog network packet delay jitter device provided in this embodiment may be included in the master clock device in the foregoing method embodiment.
  • the simulated current network packet delay jitter device provided in this embodiment is used to implement the method shown in FIG. 1 or FIG. Method embodiment.
  • the first sending module and the second sending module insert the network delay of the existing network into the master clock device and the slave clock device for the simulation, so that the PDV data of the live network can be inserted and played back in the simulated environment.
  • the process of simulating the live network PDV is implemented, so that the PDV test can be performed on the live network in the simulated environment.
  • FIG. 5 is a schematic diagram of a second embodiment of a device for simulating a packet delay jitter in the present invention.
  • the device may further include: The second network delay is obtained by the block 45.
  • the obtaining module 45 may include: a parsing unit 451 and a selecting unit 453.
  • the parsing unit 451 is configured to obtain at least one existing network first network delay and at least one existing network second network delay in each period by parsing the packet sent by the active network master device received by the current network.
  • the selecting unit 453 is configured to select the first network delay and the live network of the live network in the current period according to the at least one live network first network delay and the at least one live network second network delay in each period. The second network delay.
  • the selecting unit 453 may include any one or more of the following subunits: a first subunit 4531, a second subunit 4533, a third subunit 4535, a fourth subunit 4537, and a fifth subunit 4539.
  • the first subunit 4531 is configured to delay from the at least one live network first network in each period The one with the smallest value is selected as the first network delay of the live network in the current period, and the smallest one of the at least one existing network second network delay in each period is selected as the live network in the current period. Two network delays.
  • the second sub-unit 4533 is configured to use the average value of the values of the first network delays of all the live networks in each period as the first network delay of the live network in the current period, and the second network of all the live networks in each period.
  • the average value of the network delay is used as the second network delay of the live network in this period.
  • the third sub-unit 4535 is configured to use the average value of the values of the first network delays of all the live networks in each period as the first network delay of the live network in the current period, and the second network of all the live networks in each period.
  • the average value of the network delay is used as the second network delay of the live network in this period.
  • the fourth sub-unit 4537 is configured to use the average value after removing the maximum value and the minimum value of the values of all the first network delays in the current network in each period as the first network delay of the live network in the current period, and each period is The value of the second network delay of all existing networks in the current network is the average value after the maximum value and the minimum value are removed as the second network delay of the live network in the current period.
  • the fifth subunit 4539 is configured to use 1/2 of the sum of the values of all the first network delays of the existing network in each period and the minimum value of the values of all the second network delays as the current period.
  • the first network delay of the current network and the second network delay of the existing network are configured to use 1/2 of the sum of the values of all the first network delays of the existing network in each period and the minimum value of the values of all the second network delays as the current period. The first network delay of the current network and the second network delay of the existing network.
  • the second sending module 43 is specifically configured to: obtain a line delay according to Equation 1, obtain a time deviation between the slave clock and the master clock according to Equation 2, and then adjust the slave clock to synchronize with the master clock according to the time offset.
  • analog network packet delay jitter device provided in this embodiment is used to implement the foregoing method embodiments.
  • the first sending module and the second sending module insert the network delay of the existing network into the master clock device and the slave clock device for the simulation, so that the PDV data of the live network can be inserted and played back in the simulated environment.
  • the process of simulating the live network PDV is implemented, so that the PDV test can be performed on the live network in the simulated environment.
  • the embodiment of the present invention further provides an analog network packet delay jitter system, where the system includes a slave clock device and a master clock device, where the master clock device includes any of the simulated live networks provided by the embodiment shown in FIG. 4 or FIG. Packet delay jitter device.
  • the simulated live network packet delay jitter system provided in this embodiment is used to implement the foregoing method embodiments.
  • the master clock device inserts the network delay of the existing network into the master clock device and the slave clock device for the simulation, so that the PDV data of the live network can be inserted and played back in the simulated environment, and the simulated live network PDV is realized.
  • the process which allows PDV testing of the live network in a simulated environment.

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Data Exchanges In Wide-Area Networks (AREA)
  • Synchronisation In Digital Transmission Systems (AREA)

Abstract

Embodiments of the invention provide a method and an apparatus for simulating Packet Delay Variation (PDV) in a current network. The method includes: a first clock packet including a first time is transmitted, with the period of t, to a slave clock device, so that the slave clock device returns a second clock packet after receiving the first clock packet, wherein the first time is a difference value between the time for transmitting the first clock packet and a first network delay in the current network, the time when the slave clock device receives the first clock packet is a second time, and the time when the slave clock device transmits the second clock packet is a third time; after the second clock packet is received, a fourth time is transmitted to the slave clock device, so that the slave clock device adjusts, according to the first time, the second time, the third time and the fourth time, the slave clock to synchronize with a master clock, wherein the fourth time is a sum of the time when the second clock packet is received and a second network delay in the current network. The embodiments of the invention achieve simulating the PDV procedure in the current network, can perform a PDV test for the current network in a simulation environment, and achieve the feasibility validation for clock algorithms in the current network.

Description

模拟现网包时延抖动方法和装置  Method and device for simulating current network packet delay jitter
技术领域 Technical field
本发明实施例涉及通信技术领域, 尤其涉及一种模拟现网包时延抖动方 法和装置。 背景技术  The embodiments of the present invention relate to the field of communications technologies, and in particular, to a method and apparatus for simulating a current network packet delay jitter. Background technique
随着 IP网络的发展, 现在大部分通信网络都实现了 IP传输。 由于 IP网 络是一个异步的网络, 因此无法通过 IP网络的物理链路获取时钟。 目前, IP 时钟实现时钟同步相对成熟, 但是在中间网络设备不支持 IEEE(Institute of Electrical and Electronics Engineers, 美国电气和电子工程师协会)1588的情况 下,需要知道传输网络的 IP包时延抖动(Packet Delay Variation,以下简称为: PDV )特性才能很好的实现 IP时钟同步。 其中, PDV表示报文离开发送端 时刻到接收端接收时刻的时延抖动情况, PDV反应了中间传输过程的网络特 性。  With the development of IP networks, most communication networks now implement IP transmission. Since the IP network is an asynchronous network, it is impossible to obtain a clock through the physical link of the IP network. At present, the clock synchronization of the IP clock is relatively mature. However, in the case where the intermediate network device does not support IEEE (Institute of Electrical and Electronics Engineers) 1588, it is necessary to know the IP packet delay jitter of the transmission network (Packet). Delay Variation, hereinafter referred to as: PDV), can achieve IP clock synchronization well. The PDV indicates the delay jitter of the packet leaving the transmitting end to the receiving end. The PDV reflects the network characteristics of the intermediate transmission process.
随着现代传输技术的发展, 传输网络组网形式越来越复杂。 常用的传输 网络组网场景包括有微波传输网络、 卫星传输网络、 WIFI、 ADSL, XDSL、 MCWill ( Multi-Carrier Wireless Information Local Loo , 多载波无线信息本地 环路)、 交换机等。 这些组网场景中传输网络的 PDV特性各不相同, 非常复 杂。 例如: 在微波传输网络中, 地面基站控制器上的主时钟将时钟信息通过 微波传输与其他地方的基站 (BTS )通信, 通过时钟算法实现基站的从时钟 与基站控制器的主时钟的时钟同步; 在卫星传输网络中, 地面基站控制器上 的主时钟将时钟信息通过卫星传输与其他地方的基站通信, 通过时钟算法实 现基站的从时钟与基站控制器的主时钟的时钟同步。  With the development of modern transmission technologies, the form of transmission network networking is becoming more and more complex. Commonly used transmission Network networking scenarios include microwave transmission networks, satellite transmission networks, WIFI, ADSL, XDSL, MCWill (Multi-Carrier Wireless Information Local Loo), and switches. The PDV characteristics of the transport network in these networking scenarios are different and complex. For example, in a microwave transmission network, a master clock on a ground base station controller communicates clock information with a base station (BTS) in other places through microwave transmission, and implements clock synchronization between the base station's slave clock and the base station controller's master clock through a clock algorithm. In the satellite transmission network, the master clock on the ground base station controller communicates the clock information with the base station in other places through satellite transmission, and realizes the clock synchronization between the slave clock of the base station and the master clock of the base station controller by the clock algorithm.
现有的技术可以在实验室中搭建各种传输网络组网来模拟现网的环境, 从而实现对各种传输网络进行 PDV测试,以验证时钟算法是否适应现网的传 输特性。 然而, 由于现网传输网络越来越复杂, 使得在实验室搭建各种传输 网络的成本较高, 并且对于复杂的传输网络, 实验室搭建的环境可能无法模 拟现网的环境, 致使测试数据不准确。 发明内容 The existing technology can set up various transmission network networking in the laboratory to simulate the environment of the live network, thereby implementing PDV testing on various transmission networks to verify whether the clock algorithm adapts to the transmission characteristics of the existing network. However, due to the increasingly complex transmission network of the existing network, the cost of constructing various transmission networks in the laboratory is relatively high, and for complex transmission networks, the environment built by the laboratory may not be able to simulate the environment of the existing network, so that the test data is not accurate. Summary of the invention
本发明实施例提供一种模拟现网包时延抖动方法和装置, 以实现降低 Embodiments of the present invention provide a method and apparatus for simulating a current network packet delay jitter to achieve reduction
PDV测试的成本, 提高 PDV测试的准确性。 The cost of PDV testing increases the accuracy of PDV testing.
本发明实施例提供一种模拟现网包时延抖动方法, 包括:  The embodiment of the invention provides a method for simulating the delay of the current network packet delay, which includes:
以 t为周期向从时钟设备发送包含第一时刻的第一时钟包, 以使所述从 时钟设备接收所述第一时钟包后返回第二时钟包; 所述第一时刻为发送所述 第一时钟包的时刻与现网第一网络时延的差值; 所述从时钟设备接收所述第 一时钟包的时刻为第二时刻; 所述从时钟设备发送所述第二时钟包的时刻为 第三时刻;  Transmitting, by the clock device, a first clock packet including the first time to the slave clock device, so that the slave clock device receives the first clock packet and returns a second clock packet; The difference between the time of the first clock packet and the time of the first network packet of the current network; the time when the slave clock device receives the first clock packet is the second time; the time when the slave clock device sends the second clock packet For the third moment;
接收所述第二时钟包后, 向所述从时钟设备发送第四时刻, 以使所述从 时钟设备根据所述第一时刻、 第二时刻、 第三时刻和第四时刻调整从时钟与 主时钟同步; 所述第四时刻为接收所述第二时钟包的时刻与现网第二网络时 延之和;  After receiving the second clock packet, sending a fourth time to the slave clock device, so that the slave clock device adjusts the slave clock and the master according to the first time, the second time, the third time, and the fourth time Clock synchronization; the fourth time is a sum of a time when the second clock packet is received and a second network delay of the live network;
每个周期内的所述现网第一网络时延和所述现网第二网络时延为以 t为 周期依次从现网中获取到的。  The first network delay of the live network and the second network delay of the live network in each period are sequentially acquired from the live network in a period of t.
本发明实施例提供一种模拟现网包时延抖动装置, 包括:  The embodiment of the invention provides a device for simulating the current network packet delay jitter, which comprises:
第一发送模块, 用于以 t为周期向从时钟设备发送包含第一时刻的第一 时钟包, 以使所述从时钟设备接收所述第一时钟包后返回第二时钟包; 所述 第一时刻为发送所述第一时钟包的时刻与现网第一网络时延的差值; 所述从 时钟设备接收所述第一时钟包的时刻为第二时刻; 所述从时钟设备发送所述 第二时钟包的时刻为第三时刻;  a first sending module, configured to send a first clock packet including a first time to the slave clock device in a period of t, so that the slave clock device receives the first clock packet and returns a second clock packet; The moment is the difference between the time when the first clock packet is sent and the time delay of the first network in the live network; the time when the slave clock device receives the first clock packet is the second time; the slave clock device sends the The moment of the second clock packet is the third moment;
第二发送模块, 用于接收所述第二时钟包后, 向所述从时钟设备发送第 四时刻, 以使所述从时钟设备根据所述第一时刻、 第二时刻、 第三时刻和第 四时刻调整从时钟与主时钟同步; 所述第四时刻为接收所述第二时钟包的时 刻与现网第二网络时延之和;  a second sending module, configured to send a fourth time to the slave clock device after receiving the second clock packet, so that the slave clock device is configured according to the first time, the second time, the third time, and the first The fourth time adjustment slave clock is synchronized with the master clock; the fourth time is the sum of the time when the second clock packet is received and the second network delay of the live network;
每个周期内的所述现网第一网络时延和所述现网第二网络时延为以 t为 周期依次从现网中获取到的。  The first network delay of the live network and the second network delay of the live network in each period are sequentially acquired from the live network in a period of t.
本发明实施例的模拟现网包时延抖动方法和装置, 将现网的网络时延插 入用于模拟的主时钟设备和从时钟设备中,使得现网的 PDV数据可以在模拟 的环境中插入回放, 实现了模拟现网 PDV的过程, 由此可以在模拟的环境中 对现网进行 PDV测试, 以实现现网时钟算法的可行性验证。 附图说明 The method and device for simulating the current network packet delay jitter in the embodiment of the present invention, inserting the network delay of the existing network The main clock device and the slave clock device used in the simulation enable the PDV data of the live network to be inserted and played back in the simulated environment, thereby realizing the process of simulating the PDV of the live network, thereby enabling the existing network to be performed in the simulated environment. PDV test to verify the feasibility of the existing network clock algorithm. DRAWINGS
为了更清楚地说明本发明实施例中的技术方案, 下面将对实施例描述中 所需要使用的附图作一简单地介绍, 显而易见地, 下面描述中的附图是本发 明的一些实施例, 对于本领域普通技术人员来讲, 在不付出创造性劳动的前 提下, 还可以根据这些附图获得其他的附图。  In order to more clearly illustrate the technical solutions in the embodiments of the present invention, a brief description of the drawings to be used in the description of the embodiments will be briefly made. It is obvious that the drawings in the following description are some embodiments of the present invention. Other drawings may also be obtained from those of ordinary skill in the art in view of the drawings.
图 1为本发明模拟现网包时延抖动方法实施例一的流程图;  1 is a flowchart of Embodiment 1 of a method for simulating a packet delay of an existing network packet according to the present invention;
图 2为本发明模拟现网包时延抖动方法实施例二的流程图;  2 is a flowchart of Embodiment 2 of a method for simulating a packet delay of an existing network packet according to the present invention;
图 3为现网的网络时延的示意图;  Figure 3 is a schematic diagram of network delay of the live network;
图 4为本发明模拟现网包时延抖动装置实施例一的示意图;  4 is a schematic diagram of Embodiment 1 of an analog network packet delay jitter device according to the present invention;
图 5为本发明模拟现网包时延抖动装置实施例二的示意图。 具体实施方式  FIG. 5 is a schematic diagram of Embodiment 2 of a device for simulating a current network packet delay jitter according to the present invention. detailed description
为使本发明实施例的目的、 技术方案和优点更加清楚, 下面将结合本发 明实施例中的附图, 对本发明实施例中的技术方案进行清楚、 完整地描述, 显然, 所描述的实施例是本发明一部分实施例, 而不是全部的实施例。 基于 本发明中的实施例, 本领域普通技术人员在没有作出创造性劳动前提下所获 得的所有其他实施例, 都属于本发明保护的范围。  The technical solutions in the embodiments of the present invention are clearly and completely described in the following with reference to the accompanying drawings in the embodiments of the present invention. It is a partial embodiment of the invention, and not all of the embodiments. All other embodiments obtained by those skilled in the art based on the embodiments of the present invention without creative efforts are within the scope of the present invention.
图 1为本发明模拟现网包时延抖动方法实施例一的流程图,如图 1所示, 该方法包括:  FIG. 1 is a flowchart of Embodiment 1 of a method for simulating a packet delay of an existing network packet according to the present invention. As shown in FIG. 1, the method includes:
步骤 101、 以 t为周期向从时钟设备发送包含第一时刻的第一时钟包, 以 使从时钟设备接收第一时钟包后返回第二时钟包。  Step 101: Send a first clock packet including the first time to the slave clock device in a period of t, so that the slave clock device returns the second clock packet after receiving the first clock packet.
为了实现现网的 IP时钟同步, 本发明实施例提供模拟现网 PDV的方法, 即本发明实施例可以采用简单的方法模拟出现网 PDV, 然后据此进行 PDV 测试, 以实现时钟同步。 由此使得无需到现网的现场进行 PDV测试, 也无需 在实验室搭建与现网一样的场景, 就可以对现网进行 PDV测试。 PDV测试 的目的是通过各种时钟算法来适应传输网络的 PDV特性,最终保证传输网络 中从时钟与主时钟同步。 In order to implement the IP clock synchronization of the existing network, the embodiment of the present invention provides a method for simulating the live network PDV, that is, the embodiment of the present invention can simulate the appearance network PDV by using a simple method, and then perform PDV test according to the same to implement clock synchronization. Therefore, PDV testing can be performed on the live network without performing PDV testing on the live network or in the same scenario as the existing network in the lab. PDV test The purpose is to adapt the PDV characteristics of the transmission network through various clock algorithms, and finally ensure that the slave clock in the transmission network is synchronized with the master clock.
本实施例以主时钟设备为执行主体。  In this embodiment, the master clock device is used as the execution body.
主时钟设备以 t为周期, 周期性的向从时钟设备发送第一时钟包, 其中 该第一时钟包中包含第一时刻; 该第一时刻为主时钟设备发送该第一时钟包 的时刻与现网第一网络时延的差值;  The primary clock device periodically sends a first clock packet to the slave clock device, where the first clock packet includes the first time; the first time is the time when the first clock packet is sent by the master clock device. The difference between the first network delay of the live network;
从时钟设备接收到第一时钟包后, 向主时钟设备返回第二时钟包; 其中, 从时钟设备接收到第一时钟包的时刻为第二时刻, 从时钟设备发送第二时钟 包的时刻为第三时刻。  After receiving the first clock packet, the clock device returns a second clock packet to the master clock device. The time when the clock device receives the first clock packet is the second time, and the time when the slave clock device sends the second clock packet is The third moment.
从时钟设备接收到第一时钟包后, 以第二时刻和第一时刻的差值作为本 次的网络时延。 本实施例中, 由于主时钟设备直接将第一时钟包发送给从时 钟设备, 例如在实验室中, 主时钟设备可以通过网线(例如长度为 20厘米) 将第一时钟包发送给从时钟设备, 所以主时钟设备和从时钟设备之间几乎没 有时延, 由此, 第二时刻和第一时刻的差值等于现网第一网络时延。  After receiving the first clock packet from the clock device, the difference between the second time and the first time is used as the current network delay. In this embodiment, since the master clock device directly sends the first clock packet to the slave clock device, for example, in the laboratory, the master clock device can send the first clock packet to the slave clock device through a network cable (for example, 20 cm in length). Therefore, there is almost no delay between the master clock device and the slave clock device. Therefore, the difference between the second time and the first time is equal to the first network time delay of the live network.
其中, 现网第一网络时延为现网主设备发送报文到现网从设备接收报文 的网络时延, 由此从时钟设备获得的网络时延相当于现网中从设备接收报文 的网络时延。 现网主设备例如可以为 BSC或 BSC的主控单元, 现网从设备 例如可以为 BTS或 BTS的主控单元。  The first network delay of the current network is the network delay of the packet sent by the active device to the current network slave device, and the network delay obtained from the clock device is equivalent to the received packet from the device in the current network. Network latency. The active network master device may be, for example, a BSC or a BSC master control unit, and the current network slave device may be, for example, a BTS or a BTS master control unit.
每个周期内的现网第一网络时延和现网第二网络时延为以 t为周期依次 从现网中获取到的。 可以以 t为周期, 从现网中获取到多个现网第一网络时 延和现网第二网络时延。 其中, 所述的 t 可以根据实际情况取值, 本发明实 施例并不限定 t的取值。  The first network delay of the live network in each period and the second network delay of the live network are obtained from the existing network in order of t. The first network delay of the existing network and the second network delay of the live network can be obtained from the existing network in the period of t. The t can be a value according to an actual situation, and the embodiment of the present invention does not limit the value of t.
步骤 102、 接收第二时钟包后, 向从时钟设备发送第四时刻, 以使从时 钟设备根据第一时刻、 第二时刻、 第三时刻和第四时刻调整从时钟与主时钟 同步。  Step 102: After receiving the second clock packet, send a fourth time to the slave clock device, so that the slave clock device adjusts the slave clock to synchronize with the master clock according to the first time, the second time, the third time, and the fourth time.
主时钟设备接收第二时钟包后, 向从时钟设备发送第四时刻; 其中第四 时刻为主时钟设备接收第二时钟包的时刻与现网第二网络时延之和。  After receiving the second clock packet, the master clock device sends a fourth time to the slave clock device. The fourth time is the sum of the time when the master clock device receives the second clock packet and the second network delay of the current network.
从时钟设备接收到第四时刻包后, 以第四时刻和第三时刻的差值作为本 次的网络时延; 其中, 第三时刻为从时钟设备发送第二时钟包的时刻。 本实 施例中, 由于从时钟设备直接将第二时钟包发送给主时钟设备, 例如在实验 室中, 从时钟设备可以通过网线(例如长度为 20厘米)将第二时钟包发送给 主时钟设备, 所以从时钟设备和主时钟设备之间几乎没有时延, 由此, 第四 时刻和第三时刻的差值等于现网第二网络时延。 After receiving the fourth time packet from the clock device, the difference between the fourth time and the third time is used as the current network delay; wherein the third time is the time when the second clock packet is sent from the clock device. Real In the embodiment, since the second clock packet is directly sent from the clock device to the master clock device, for example, in the laboratory, the slave clock device can send the second clock packet to the master clock device through the network cable (for example, 20 cm in length). Therefore, there is almost no delay between the slave clock device and the master clock device, and thus, the difference between the fourth time and the third time is equal to the second network delay of the live network.
其中, 现网第二网络时延为现网从设备发送报文到现网主设备接收报文 的网络时延, 由此从时钟设备获得的网络时延相当于现网中从设备发送报文 到现网主设备的网络时延。  The network delay of the current network is the network delay of the packets sent from the device to the active device on the live network. The network delay obtained from the clock device is equivalent to the packet sent by the slave device in the current network. The network delay to the active network master device.
从时钟设备接收到第四时刻后, 可以根据第一时刻、 第二时刻、 第三时 刻和第四时刻, 使用时钟算法调整从时钟, 以使从时钟与主时钟同步。  After receiving the fourth time from the clock device, the slave clock can be adjusted according to the first time, the second time, the third time, and the fourth time, so that the slave clock is synchronized with the master clock.
具体的, 从时钟设备根据第一时刻、 第二时刻、 第三时刻和第四时刻调 整从时钟与主时钟同步的过程例如可以为:  Specifically, the process of adjusting the slave clock to synchronize with the master clock according to the first time, the second time, the third time, and the fourth time is, for example, the following:
从时钟根据式 1得到线路时延 D, 之后根据式 2得到从时钟与主时钟的 时间偏差 P, 然后再根据时间偏差 P调整与主时钟同步, 例如: 若得到时间 偏差 P为 0.2S, 则将从时钟调慢 0.2S, 使得从时钟与主时钟同步。  The slave circuit obtains the line delay D according to Equation 1, and then obtains the time deviation P between the slave clock and the master clock according to Equation 2, and then adjusts to synchronize with the master clock according to the time offset P, for example: if the time deviation P is 0.2S, then The slave clock is clocked down by 0.2 s to synchronize the slave clock with the master clock.
其中, 式 1为: D = [ ( t2-tl ) + ( t4-t3 ) ]/2;  Where Equation 1 is: D = [ ( t2-tl ) + ( t4-t3 ) ]/2;
式 2为: P = t2-tl-D; tl表示第一时刻, t2表示第二时刻, t3表示第三时 刻, t4表示第四时刻, D表示线路时延, P表示时间偏差。  Equation 2 is: P = t2-tl-D; tl represents the first time, t2 represents the second time, t3 represents the third time, t4 represents the fourth time, D represents the line delay, and P represents the time deviation.
本实施例中, 将现网的网络时延插入用于模拟的主时钟设备和从时钟设 备中, 使得现网的 PDV数据可以在模拟的环境中插入回放, 实现了模拟现网 PDV的过程, 由此可以在模拟的环境中对现网进行 PDV测试。  In this embodiment, the network delay of the live network is inserted into the master clock device and the slave clock device for the simulation, so that the PDV data of the live network can be inserted and played back in the simulated environment, and the process of simulating the PDV of the live network is implemented. This allows PDV testing of the live network in a simulated environment.
图 2为本发明模拟现网包时延抖动方法实施例二的流程图,如图 2所示, 该方法包括:  2 is a flowchart of Embodiment 2 of a method for simulating a packet delay of an existing network packet according to the present invention. As shown in FIG. 2, the method includes:
步骤 201、 获取现网的 PDV数据, 即获取现网第一网络时延和现网第二 网络时延。  Step 201: Obtain PDV data of the current network, that is, obtain the first network delay of the live network and the second network delay of the live network.
现网的网络时延可以参见图 3 , 图 3为现网的网络时延的示意图; 如图 3 所示, 现网中的 BSC通过复杂的传输网络将报文传输给 BTS, 其中 BSC为 现网主设备, BSC中的时钟为主时钟, BTS为现网从设备, BTS中的时钟为 从时钟。  For the network delay of the current network, see Figure 3, Figure 3 is a schematic diagram of the network delay of the live network. As shown in Figure 3, the BSC in the current network transmits the packet to the BTS through a complex transmission network, where the BSC is present. On the network master device, the clock in the BSC is the master clock, the BTS is the slave device on the live network, and the clock in the BTS is the slave clock.
如图 3所示, 主时钟通过 Sync 文将 tl信息发送给从时钟, 从时钟收 到 Sync报文后得到 t2, 从时钟向主时钟发送 Delay— req报文, 主时钟再通过 Delay— resp报文将 t4发给从时钟。 由此, 从时钟就获得了 tl , t2, t3 , t4的时 间信息。 其中, 从时钟向主时钟发送的 Delay— req报文中, 可以携带 t3 , 也可 以不携带 t3。 As shown in Figure 3, the master clock sends the tl information to the slave clock through the Sync file. After the Sync message is obtained, t2 is sent, and the slave clock sends a Delay-req message to the master clock, and the master clock sends t4 to the slave clock through the Delay-resp message. Thus, the time information of tl, t2, t3, t4 is obtained from the clock. The Delay-req packet sent from the clock to the primary clock may carry t3 or not.
其中, tl为 Sync报文离开 BSC的时刻; t2为 Sync报文到达 BTS的时 刻; t3为 Delay— req报文离开 BTS的时刻; t4为 Delay— req报文到达 BSC的 时刻; tl , t2, t3 , t4均可以精确到纳秒。 t2-tl即为所述的现网第一网络时延, t4-t3即为所述的现网第二网络时延。  Where tl is the time when the Sync message leaves the BSC; t2 is the time when the Sync message arrives at the BTS; t3 is the time when the Delay-req message leaves the BTS; t4 is the time when the Delay-req message arrives at the BSC; tl, t2, Both t3 and t4 can be accurate to nanoseconds. T2-tl is the first network delay of the existing network, and t4-t3 is the second network delay of the existing network.
il 设 主 时 钟 和 从 时 钟 完 全 同 步 , 那 么 网 络 时 延 Delay=[(t2-tl)+(t4-t3)]/2=[(t4-tl)-(t3-t2)]/2。 由此可以得出, 网络时延 Delay已 经与主时钟和从时钟是否完全同步没有关系, 而只与主时钟和从时钟本身精 度有关。 所以只要使用精度为纳秒的计数器即可实现纳秒级的精度时钟和纳 秒级的时延时间 Delay值的测量, 可以使用 FPGA来实现纳秒级精度。  Il sets the master clock and the slave clock to complete the synchronization, then the network delay Delay=[(t2-tl)+(t4-t3)]/2=[(t4-tl)-(t3-t2)]/2. It can be concluded that the network delay Delay has not been related to whether the master clock and the slave clock are completely synchronized, but only related to the accuracy of the master clock and the slave clock itself. Therefore, as long as the nanosecond precision clock and the nanosecond delay time delay value can be measured by using a counter with a nanosecond accuracy, FPGA can be used to achieve nanosecond accuracy.
获取现网的 PDV数据, 即为周期性的获取现网的 Atl=t2-tl , At2=t4-t3。 具体的, 可以通过以下方式获取现网第一网络时延( Atl )和所述现网第 二网络时延(At2 ) : 在远端或近端的 BTS维护台上, 通过解析 BTS接收的 BSC发送的报文, 以 t为周期获取现网第一网络时延和现网第二网络时延; 其中每个周期内获取一个现网第一网络时延和一个现网第二网络时延。  Obtain the PDV data of the live network, that is, periodically obtain the Atl=t2-tl and At2=t4-t3 of the live network. Specifically, the first network delay (Atl) of the live network and the second network delay (At2) of the live network can be obtained by: parsing the BSC received by the BTS on the remote or near-end BTS maintenance station The received packet receives the first network delay of the current network and the second network delay of the current network in a period of t; wherein each network acquires a first network delay of the existing network and a second network delay of the existing network.
在远端或近端的 BTS维护台上, 解析 BTS接收的 BSC发送的报文, 可 以获知 tl , t2, t3和 t4;例如,解析 Sync报文,即可以获知 tl ,解析 Delay— resp 报文可以获知 t4, 而 t2和 t3是可以从 BTS获知的, 由此就可以获得现网第 一网络时延和现网第二网络时延。  On the remote or near-end BTS maintenance station, the packets sent by the BSC received by the BTS are parsed, and tl, t2, t3, and t4 are obtained. For example, if the Sync packet is parsed, the tl can be learned and the Delay-resp message can be parsed. It can be known that t4, and t2 and t3 are known from the BTS, so that the first network delay of the live network and the second network delay of the live network can be obtained.
在一个周期内, 现网可能发送多个报文, 根据这些报文, 可以获得多个 现网第一网络时延和多个现网第二网络时延; 然后可以从多个现网第一网络 时延和多个现网第二网络时延中分别选取一个现网第一网络时延和一个现网 第二网络时延来作为采用值。 例如: 将 Sync报文发包频率设置为 128*n包 / 秒, 其中 n为大于等于 1的整数, 以 1秒为一个周期; 那么每 1秒中有 128*n 个点,即可以得到 128*n个现网第一网络时延和 128*n个现网第二网络时延, 然后从中选取本周期内的现网第一网络时延和现网第二网络时延。 从多个现网第一网络时延(或现网第二网络时延) 中选取一个的方法可 以有多种, 例如: In a period, the current network may send multiple packets. According to these packets, multiple network network first network delays and multiple live network second network delays may be obtained. Then, multiple live networks may be used. The network delay and the second network delay of the plurality of existing networks respectively select one live network first network delay and one live network second network delay as the adopted values. For example: Set the Sync packet sending frequency to 128*n packets/second, where n is an integer greater than or equal to 1, with a period of 1 second; then 128*n points per 1 second, you can get 128* n the first network delay of the existing network and the second network delay of the 128*n live network, and then select the first network delay of the live network and the second network delay of the live network in the current period. There may be multiple methods for selecting one of the plurality of existing network first network delays (or the current network second network delay), for example:
第一种, 从多个现网第一网络时延中选取数值最小的一个; 第二种, 将 每个周期内的所有现网第一网络时延的数值的平均值作为选取的本周期内的 现网第一网络时延; 第三种, 将每个周期内的所有现网第一网络时延的数值 去掉最大值和最小值后的平均值作为本周期内的现网第一网络时延;第四种, 将每个周期内的第一网络时延的数值的最小值和第一网络时延的数值的最小 值之和的 1/2 同时作为本周期内的现网第一网络时延和现网第二网络时延, 即此种方法中可以认为上行方向和下行方向的时延是对称的。  The first type selects the smallest one from the plurality of existing network first network delays; the second type uses the average value of the first network delay values of all the live networks in each period as the selected current period. The first network delay of the live network; the third type, when the value of the first network delay of all the live networks in each period is removed from the maximum value and the minimum value as the first network in the current network Fourth, the 1/2 of the sum of the minimum value of the first network delay in each period and the minimum value of the first network delay is taken as the first network in the current network in the current period. The delay and the second network delay of the live network, that is, the delay in the uplink direction and the downlink direction can be considered symmetric in this method.
从多个现网第二网络时延中选取一个的方法与选取现网第一网络时延的 方法^ :目同。 The method of selecting from a plurality of current network and a second network delay in the current network selection method for a first network delay ^: the same mesh.
步骤 202、 将步骤 201中获取的现网的 PDV数据, 在模拟环境中插入回 放, 以模拟现网的 PDV。  Step 202: Insert the PDV data of the live network obtained in step 201 into the simulation environment to simulate the PDV of the live network.
在模拟环境中, 例如在实验室环境中, 插入回放现网的 PDV数据。 本实 施例中的主时钟设备和从时钟设备可以为实验室环境中的设备。 下面对上行 和下行方向的插入进行具体描述。  In a simulated environment, such as in a lab environment, insert playback of PDV data from the live network. The master clock device and the slave clock device in this embodiment may be devices in a lab environment. The insertion of the upstream and downstream directions will be specifically described below.
上行方向 (即主时钟设备向从时钟设备发送报文的方向) : 主时钟设备 在发出 sync时钟包时 , 打上时间戳 tl ' ' , tl "=tl '-Atl ; 当 sync时钟包到达从 时钟设备时, 从时钟设备获得一个 t2,; 此时, 从时钟设备获得的上行时延为 t2'-tl "=t2'-tl '+Atl ;  Upstream direction (that is, the direction in which the master clock device sends packets to the slave clock device): When the master clock device issues the sync clock packet, it times the time stamp tl ' ', tl "=tl '-Atl ; when the sync clock packet reaches the slave clock The device obtains a t2 from the clock device; at this time, the uplink delay obtained from the clock device is t2'-tl "=t2'-tl '+Atl;
下行方向 (即从时钟设备向主时钟设备发送报文的方向) : 从时钟设备 在发出 Delay— req时钟包时, 打上时间戳 t3 ' , 其中, Delay— req时钟包中也可 以不打时间戳 t3,; 当 Delay— req时钟包到达主时钟设备时, 主时钟设备获得 一个 t4,, 然后主时钟设备向从时钟设备返回 Delay— resp时钟包, 并打上时间 戳 t4" , t4"=t4,+At2;此时,从时钟设备获得的下行时延为 t4,,- t3'=t4'+At2-t3'„ 其中, tl,为主时钟设备发送 Sync 时钟包的时刻; t2,为从时钟设备接收 到 Sync 时钟包的时刻; t3,为从时钟设备发送 Delay— req时钟包的时刻; t4, 为主时钟设备接收到 Delay— req时钟包的时刻。 Downstream direction (that is, the direction in which packets are sent from the clock device to the master clock device): When the slave clock device issues the Delay-req clock packet, it times the time stamp t3 ', where the delay-req clock packet can also be time stamped. T3,; When the Delay-req clock packet arrives at the master clock device, the master clock device obtains a t4, and then the master clock device returns a Delay- resp clock packet to the slave clock device, and times the time stamp t 4", t4"=t4 , +At2; At this time, the downlink delay obtained from the clock device is t4,, - t3'=t4'+At2-t3'„ where tl is the time at which the Sync clock packet is transmitted for the master clock device; t2 is slave The time at which the clock device receives the Sync clock packet; t3, the time at which the Delay-req clock packet is sent from the clock device; t4, the time at which the master clock device receives the Delay-req clock packet.
由于本实施例中的主时钟设备和从时钟设备可以是实验室环境中的, 所 以在主时钟设备和从时钟设备之间的网络时延几乎为 0 , 即 t2,-tl, 0 , t4'-t3'~0, 由此, 从时钟设备获得的上行时延为 Atl , 下行时延为 At2; 即从 时钟设备获得的网络时延与现网中的相同。 Since the master clock device and the slave clock device in this embodiment can be in a laboratory environment, The network delay between the master clock device and the slave clock device is almost 0, that is, t2, -tl, 0, t4'-t3'~0, whereby the uplink delay obtained from the clock device is Atl, downlink. The delay is At2; that is, the network delay obtained from the clock device is the same as that in the live network.
将现网的 PDV数据在模拟环境中插入回放时,主时钟设备和从时钟设备 发送时钟包的周期与现网的 PDV数据的周期相同。 也就是说, 现网的 PDV 数据是以 t为周期获取到的, 则在模拟环境中以 t为周期发送时钟包, 并插入 相应的网络时延数据。  When the PDV data of the live network is inserted into the playback environment in the simulation environment, the period of the clock packet sent by the master clock device and the slave clock device is the same as the period of the PDV data of the live network. That is to say, the PDV data of the live network is obtained by the period t, and the clock packet is sent in the simulation environment in the period of t, and the corresponding network delay data is inserted.
本发明实施例提供的方法, 可以在实验室的环境中模拟现网的 PDV特 性, 然后对本实施例中的主时钟设备和从时钟设备进行 PDV测试, 即通过各 种时钟算法来适应传输网络的 PDV特性, 最终保证从时钟与主时钟同步。  The method provided by the embodiment of the present invention can simulate the PDV characteristics of the live network in a laboratory environment, and then perform PDV testing on the master clock device and the slave clock device in the embodiment, that is, adapt to the transmission network through various clock algorithms. The PDV feature ultimately guarantees that the slave clock is synchronized with the master clock.
本发明实施例提供的方法, 具有以下效果:  The method provided by the embodiment of the invention has the following effects:
可以解决现有在实验室环境下搭建各种复杂组网遇到的困难, 还可以降 低搭建各种复杂组网的庞大的物料成本和测试成本;  It can solve the difficulties encountered in constructing various complex networks in the laboratory environment, and can also reduce the huge material cost and testing cost of constructing various complex networks;
在远端或近端的 BTS维护台即可实现 PDV数据的采集, 然后在实验室 环境下就可以实现复杂传输组网下的时钟算法 PDV抖动测试,由此可以提前 验证 IP时钟算法的抗延时抖动能力是否满足现网要求, 而无需等到该时钟算 法上网后才发现问题。  The PDV data can be collected at the remote or near-end BTS maintenance station, and then the PDV jitter test of the clock algorithm under the complex transmission network can be realized in the laboratory environment, thereby verifying the delay of the IP clock algorithm in advance. Whether the time jitter capability meets the requirements of the live network, and does not need to wait until the clock algorithm is online to find the problem.
本领域普通技术人员可以理解: 实现上述方法实施例的全部或部分步骤 可以通过程序指令相关的硬件来完成, 前述的程序可以存储于一计算机可读 取存储介质中, 该程序在执行时, 执行包括上述方法实施例的步骤; 前述的 存储介质包括: ROM, RAM,磁碟或者光盘等各种可以存储程序代码的介质。  A person skilled in the art can understand that all or part of the steps of implementing the above method embodiments may be completed by using hardware related to program instructions, and the foregoing program may be stored in a computer readable storage medium, and the program is executed when executed. The foregoing steps include the steps of the foregoing method embodiments. The foregoing storage medium includes: a medium that can store program codes, such as a ROM, a RAM, a magnetic disk, or an optical disk.
图 4为本发明模拟现网包时延抖动装置实施例一的示意图,如图 4所示, 该装置包括: 第一发送模块 41和第二发送模块 43。  FIG. 4 is a schematic diagram of Embodiment 1 of the present invention for simulating a packet delay jitter device. As shown in FIG. 4, the device includes: a first sending module 41 and a second sending module 43.
第一发送模块 41用于以 t为周期向从时钟设备发送包含第一时刻的第一 时钟包, 以使所述从时钟设备接收所述第一时钟包后返回第二时钟包; 所述 第一时刻为发送所述第一时钟包的时刻与现网第一网络时延的差值; 所述从 时钟设备接收所述第一时钟包的时刻为第二时刻; 所述从时钟设备发送所述 第二时钟包的时刻为第三时刻。  The first sending module 41 is configured to send the first clock packet including the first time to the slave clock device in a period of t, so that the slave clock device receives the first clock packet and returns a second clock packet; The moment is the difference between the time when the first clock packet is sent and the time delay of the first network in the live network; the time when the slave clock device receives the first clock packet is the second time; the slave clock device sends the The time at which the second clock packet is described is the third time.
第二发送模块 43用于接收所述第二时钟包后,向所述从时钟设备发送第 四时刻, 以使所述从时钟设备根据所述第一时刻、 第二时刻、 第三时刻和第 四时刻调整从时钟与主时钟同步; 所述第四时刻为接收所述第二时钟包的时 刻与现网第二网络时延之和。 The second sending module 43 is configured to send the second clock packet to the slave clock device. Four times, so that the slave clock device synchronizes the slave clock with the master clock according to the first time, the second time, the third time, and the fourth time; the fourth time is the second clock packet received The sum of the time and the second network delay of the live network.
其中, 每个周期内的所述现网第一网络时延和所述现网第二网络时延为 以 t为周期依次从现网中获取到的。 现网第一网络时延为现网主设备发送报 文到现网从设备接收报文的网络时延; 现网第二网络时延为所述现网从设备 发送报文到所述现网主设备接收报文的网络时延。  The first network delay of the live network and the second network delay of the current network in each period are sequentially obtained from the current network by using t. The first network delay of the current network is the network delay of the packet sent by the active device to the current network to receive the packet from the device. The second network delay of the current network is sent by the slave device on the live network to the current network. The network delay at which the master device receives packets.
本实施例中各个模块的工作流程和工作原理参见上述各方法实施例中的 描述, 在此不再赘述。 本实施例提供的模拟现网包时延抖动装置可以包含在 上述方法实施例中的主时钟设备中, 本实施例提供的模拟现网包时延抖动装 置用于实现图 1或图 2所示的方法实施例。  For the working process and working principle of each module in this embodiment, refer to the description in the foregoing method embodiments, and details are not described herein again. The analog network packet delay jitter device provided in this embodiment may be included in the master clock device in the foregoing method embodiment. The simulated current network packet delay jitter device provided in this embodiment is used to implement the method shown in FIG. 1 or FIG. Method embodiment.
本实施例中, 第一发送模块和第二发送模块将现网的网络时延插入用于 模拟的主时钟设备和从时钟设备中,使得现网的 PDV数据可以在模拟的环境 中插入回放, 实现了模拟现网 PDV的过程, 由此可以在模拟的环境中对现网 进行 PDV测试。  In this embodiment, the first sending module and the second sending module insert the network delay of the existing network into the master clock device and the slave clock device for the simulation, so that the PDV data of the live network can be inserted and played back in the simulated environment. The process of simulating the live network PDV is implemented, so that the PDV test can be performed on the live network in the simulated environment.
图 5为本发明模拟现网包时延抖动装置实施例二的示意图, 在图 4所示 实施例的基础上, 该装置还可以包括: 用于获取现网第一网络时延和现网第 二网络时延的获耳 莫块 45。  FIG. 5 is a schematic diagram of a second embodiment of a device for simulating a packet delay jitter in the present invention. On the basis of the embodiment shown in FIG. 4, the device may further include: The second network delay is obtained by the block 45.
获取模块 45可以包括: 解析单元 451和选取单元 453。  The obtaining module 45 may include: a parsing unit 451 and a selecting unit 453.
解析单元 451用于通过解析现网从设备接收的现网主设备发送的报文, 在每个周期内获取至少一个现网第一网络时延和至少一个现网第二网络时 延。  The parsing unit 451 is configured to obtain at least one existing network first network delay and at least one existing network second network delay in each period by parsing the packet sent by the active network master device received by the current network.
选取单元 453用于根据每个周期内的所述至少一个现网第一网络时延和 所述至少一个现网第二网络时延, 选取本周期内的现网第一网络时延和现网 第二网络时延。  The selecting unit 453 is configured to select the first network delay and the live network of the live network in the current period according to the at least one live network first network delay and the at least one live network second network delay in each period. The second network delay.
进一步的, 选取单元 453可以包括以下子单元中的任意一个或多个: 第 一子单元 4531、 第二子单元 4533、 第三子单元 4535、 第四子单元 4537和第 五子单元 4539。  Further, the selecting unit 453 may include any one or more of the following subunits: a first subunit 4531, a second subunit 4533, a third subunit 4535, a fourth subunit 4537, and a fifth subunit 4539.
第一子单元 4531 用于从每个周期内的所述至少一个现网第一网络时延 中选择数值最小的一个作为本周期内的现网第一网络时延, 从每个周期内的 所述至少一个现网第二网络时延中选择数值最小的一个作为本周期内的现网 第二网络时延。 The first subunit 4531 is configured to delay from the at least one live network first network in each period The one with the smallest value is selected as the first network delay of the live network in the current period, and the smallest one of the at least one existing network second network delay in each period is selected as the live network in the current period. Two network delays.
第二子单元 4533 用于将每个周期内的所有现网第一网络时延的数值的 平均值作为本周期内的现网第一网络时延, 将每个周期内的所有现网第二网 络时延的数值的平均值作为本周期内的现网第二网络时延。  The second sub-unit 4533 is configured to use the average value of the values of the first network delays of all the live networks in each period as the first network delay of the live network in the current period, and the second network of all the live networks in each period. The average value of the network delay is used as the second network delay of the live network in this period.
第三子单元 4535 用于将每个周期内的所有现网第一网络时延的数值的 平均值作为本周期内的现网第一网络时延, 将每个周期内的所有现网第二网 络时延的数值的平均值作为本周期内的现网第二网络时延。  The third sub-unit 4535 is configured to use the average value of the values of the first network delays of all the live networks in each period as the first network delay of the live network in the current period, and the second network of all the live networks in each period. The average value of the network delay is used as the second network delay of the live network in this period.
第四子单元 4537 用于将每个周期内的所有现网第一网络时延的数值去 掉最大值和最小值后的平均值作为本周期内的现网第一网络时延, 将每个周 期内的所有现网第二网络时延的数值去掉最大值和最小值后的平均值作为本 周期内的现网第二网络时延。  The fourth sub-unit 4537 is configured to use the average value after removing the maximum value and the minimum value of the values of all the first network delays in the current network in each period as the first network delay of the live network in the current period, and each period is The value of the second network delay of all existing networks in the current network is the average value after the maximum value and the minimum value are removed as the second network delay of the live network in the current period.
第五子单元 4539 用于将每个周期内的所有现网第一网络时延的数值的 最小值与所有第二网络时延的数值的最小值之和的 1/2 同时作为本周期内的 现网第一网络时延和现网第二网络时延。  The fifth subunit 4539 is configured to use 1/2 of the sum of the values of all the first network delays of the existing network in each period and the minimum value of the values of all the second network delays as the current period. The first network delay of the current network and the second network delay of the existing network.
进一步的, 第二发送模块 43具体用于: 根据式 1得到线路时延, 根据式 2得到从时钟与主时钟的时间偏差, 然后根据时间偏差调整从时钟与主时钟 同步。  Further, the second sending module 43 is specifically configured to: obtain a line delay according to Equation 1, obtain a time deviation between the slave clock and the master clock according to Equation 2, and then adjust the slave clock to synchronize with the master clock according to the time offset.
式 1为: D = [ ( t2-tl ) + ( t4-t3 ) ]/2; 式 2为: P = t2-tl-D; 其中, tl表 示第一时刻, t2表示第二时刻, t3表示第三时刻, t4表示第四时刻, D表示 线路时延, P表示时间偏差。  Equation 1 is: D = [ ( t2-tl ) + ( t4-t3 ) ]/2; Equation 2 is: P = t2-tl-D; where tl represents the first moment, t2 represents the second moment, t3 represents At the third moment, t4 represents the fourth moment, D represents the line delay, and P represents the time offset.
本实施例中各个模块和单元的工作流程和工作原理参见上述各方法实施 例中的描述, 在此不再赘述。 本实施例提供的模拟现网包时延抖动装置用于 实现上述各方法实施例。  For the working process and working principle of each module and unit in this embodiment, refer to the description in the foregoing method embodiments, and details are not described herein again. The analog network packet delay jitter device provided in this embodiment is used to implement the foregoing method embodiments.
本实施例中, 第一发送模块和第二发送模块将现网的网络时延插入用于 模拟的主时钟设备和从时钟设备中,使得现网的 PDV数据可以在模拟的环境 中插入回放, 实现了模拟现网 PDV的过程, 由此可以在模拟的环境中对现网 进行 PDV测试。 本发明实施例还提供一种模拟现网包时延抖动系统, 该系统包括从时钟 设备和主时钟设备, 其中该主时钟设备包括图 4或图 5所示实施例提供的任一 模拟现网包时延抖动装置。 In this embodiment, the first sending module and the second sending module insert the network delay of the existing network into the master clock device and the slave clock device for the simulation, so that the PDV data of the live network can be inserted and played back in the simulated environment. The process of simulating the live network PDV is implemented, so that the PDV test can be performed on the live network in the simulated environment. The embodiment of the present invention further provides an analog network packet delay jitter system, where the system includes a slave clock device and a master clock device, where the master clock device includes any of the simulated live networks provided by the embodiment shown in FIG. 4 or FIG. Packet delay jitter device.
本实施例提供的模拟现网包时延抖动系统用于实现上述各方法实施例。 本实施例中, 主时钟设备将现网的网络时延插入用于模拟的主时钟设备 和从时钟设备中, 使得现网的 PDV数据可以在模拟的环境中插入回放, 实现 了模拟现网 PDV的过程, 由此可以在模拟的环境中对现网进行 PDV测试。  The simulated live network packet delay jitter system provided in this embodiment is used to implement the foregoing method embodiments. In this embodiment, the master clock device inserts the network delay of the existing network into the master clock device and the slave clock device for the simulation, so that the PDV data of the live network can be inserted and played back in the simulated environment, and the simulated live network PDV is realized. The process, which allows PDV testing of the live network in a simulated environment.
最后应说明的是: 以上实施例仅用以说明本发明的技术方案, 而非对其 限制; 尽管参照前述实施例对本发明进行了详细的说明, 本领域的普通技术 人员应当理解: 其依然可以对前述各实施例所记载的技术方案进行修改, 或 者对其中部分技术特征进行等同替换; 而这些修改或者替换, 并不使相应技 术方案的本质脱离本发明各实施例技术方案的精神和范围。  It should be noted that the above embodiments are only for explaining the technical solutions of the present invention, and are not intended to be limiting; although the present invention has been described in detail with reference to the foregoing embodiments, it will be understood by those skilled in the art that: The technical solutions described in the foregoing embodiments are modified, or some of the technical features are equivalently replaced. The modifications and substitutions do not depart from the spirit and scope of the technical solutions of the embodiments of the present invention.

Claims

权 利 要求 Rights request
1、 一种模拟现网包时延抖动方法, 其特征在于, 包括:  A method for simulating a current network packet delay jitter, which is characterized by comprising:
以 t为周期向从时钟设备发送包含第一时刻的第一时钟包, 以使所述从 时钟设备接收所述第一时钟包后返回第二时钟包; 所述第一时刻为发送所述 第一时钟包的时刻与现网第一网络时延的差值; 所述从时钟设备接收所述第 一时钟包的时刻为第二时刻; 所述从时钟设备发送所述第二时钟包的时刻为 第三时刻;  Transmitting, by the clock device, a first clock packet including the first time to the slave clock device, so that the slave clock device receives the first clock packet and returns a second clock packet; The difference between the time of the first clock packet and the time of the first network packet of the current network; the time when the slave clock device receives the first clock packet is the second time; the time when the slave clock device sends the second clock packet For the third moment;
接收所述第二时钟包后, 向所述从时钟设备发送第四时刻, 以使所述从 时钟设备根据所述第一时刻、 第二时刻、 第三时刻和第四时刻调整从时钟与 主时钟同步; 所述第四时刻为接收所述第二时钟包的时刻与现网第二网络时 延之和;  After receiving the second clock packet, sending a fourth time to the slave clock device, so that the slave clock device adjusts the slave clock and the master according to the first time, the second time, the third time, and the fourth time Clock synchronization; the fourth time is a sum of a time when the second clock packet is received and a second network delay of the live network;
每个周期内的所述现网第一网络时延和所述现网第二网络时延为以 t为 周期依次从现网中获取到的。  The first network delay of the live network and the second network delay of the live network in each period are sequentially acquired from the live network in a period of t.
2、 根据权利要求 1所述的模拟现网包时延抖动方法, 其特征在于: 所述现网第一网络时延为现网主设备发送报文到现网从设备接收报文的 网络时延;  The method for simulating the current network packet delay jitter according to claim 1, wherein: the first network delay of the live network is when the active network master sends a packet to the network that receives the packet from the device. Delay
所述现网第二网络时延为所述现网从设备发送报文到所述现网主设备接 收报文的网络时延。  The second network delay of the live network is the network delay of the packet sent by the current network slave device to the current network master device.
3、 根据权利要求 2所述的模拟现网包时延抖动方法, 其特征在于, 通过 以下方式获取所述现网第一网络时延和所述现网第二网络时延:  The method for simulating the current network packet delay jitter according to claim 2, wherein the first network delay of the live network and the second network delay of the live network are obtained by:
通过解析所述现网从设备接收的所述现网主设备发送的报文, 在每个周 期内获取至少一个现网第一网络时延和至少一个现网第二网络时延;  Acquiring at least one existing network first network delay and at least one existing network second network delay in each period by parsing the packet sent by the current network master device received by the current network from the device;
根据每个周期内的所述至少一个现网第一网络时延和所述至少一个现网 第二网络时延, 选取本周期内的现网第一网络时延和现网第二网络时延。  Selecting the first network delay of the live network and the second network delay of the live network in the current period according to the at least one live network first network delay and the at least one live network second network delay in each period .
4、 根据权利要求 3所述的模拟现网包时延抖动方法, 其特征在于, 所述 根据每个周期内的所述至少一个现网第一网络时延和所述至少一个现网第二 网络时延, 选取本周期内的现网第一网络时延和现网第二网络时延的过程, 包括:  The method for simulating the current network packet delay jitter according to claim 3, wherein the at least one live network first network delay and the at least one live network second according to each period Network delay, the process of selecting the first network delay of the live network and the delay of the second network of the live network in the current period, including:
从每个周期内的所述至少一个现网第一网络时延中选择数值最小的一个 作为本周期内的现网第一网络时延, 从每个周期内的所述至少一个现网第二 网络时延中选择数值最小的一个作为本周期内的现网第二网络时延; 或者 将每个周期内的所有现网第一网络时延的数值的平均值作为本周期内的 现网第一网络时延, 将每个周期内的所有现网第二网络时延的数值的平均值 作为本周期内的现网第二网络时延; 或者 Selecting the smallest one from the first network delay of the at least one live network in each period As the first network delay of the live network in the current period, the smallest one of the at least one live network second network delay in each period is selected as the second network delay of the live network in the current period; or The average value of the first network delay of all live networks in each period is taken as the first network delay of the live network in the current period, and the average value of the second network delay of all the live networks in each period is averaged. The value is used as the second network delay of the live network in this period; or
将每个周期内的所有现网第一网络时延的数值的平均值作为本周期内的 现网第一网络时延, 将每个周期内的所有现网第二网络时延的数值的平均值 作为本周期内的现网第二网络时延; 或者  The average value of the first network delay of all live networks in each period is taken as the first network delay of the live network in the current period, and the average value of the second network delay of all the live networks in each period is averaged. The value is used as the second network delay of the live network in this period; or
将每个周期内的所有现网第一网络时延的数值去掉最大值和最小值后的 平均值作为本周期内的现网第一网络时延, 将每个周期内的所有现网第二网 络时延的数值去掉最大值和最小值后的平均值作为本周期内的现网第二网络 时延; 或者  The average value of all the first network delays in the current network is removed from the maximum and minimum values as the first network delay in the current network, and all the live networks in each period are second. The value of the network delay is the average value after the maximum value and the minimum value are removed as the second network delay of the live network in the current period; or
将每个周期内的所有现网第一网络时延的数值的最小值与所有第二网络 时延的数值的最小值之和的 1/2 同时作为本周期内的现网第一网络时延和现 网第二网络时延。  The 1/2 of the sum of the minimum value of the first network delay of all the live networks in each period and the minimum value of the values of all the second network delays is taken as the first network delay of the live network in the current period. And the second network delay of the existing network.
5、根据权利要求 2-4任一所述的模拟现网包时延抖动方法,其特征在于: 所述现网主设备为基站控制器或基站控制器的主控单元; 所述现网从设备为 基站收发台或基站收发台的主控单元。  The method for simulating the current network packet delay jitter according to any one of claims 2-4, wherein: the active network master device is a base station controller or a base controller of a base station controller; The device is the main control unit of the base transceiver station or the base transceiver station.
6、根据权利要求 1-4任一所述的模拟现网包时延抖动方法,其特征在于, 所述从时钟设备根据所述第一时刻、 第二时刻、 第三时刻和第四时刻调整从 时钟与主时钟同步的过程, 包括:  The method for simulating the current network packet delay jitter according to any one of claims 1-4, wherein the slave clock device adjusts according to the first time, the second time, the third time, and the fourth time The process of synchronizing the clock from the master clock includes:
所述从时钟根据式 1得到线路时延, 根据式 2得到所述从时钟与所述主 时钟的时间偏差, 然后根据所述时间偏差调整与所述主时钟同步;  Obtaining a line delay according to Equation 1 according to Equation 1, obtaining a time deviation of the slave clock from the master clock according to Equation 2, and then adjusting synchronization with the master clock according to the time offset;
式 1为: D = [ ( t2-tl ) + ( t4-t3 ) ]/2; 式 2为: P = t2-tl-D; 其中, tl表 示第一时刻, t2表示第二时刻, t3表示第三时刻, t4表示第四时刻, D表示 线路时延, P表示时间偏差。  Equation 1 is: D = [ ( t2-tl ) + ( t4-t3 ) ]/2; Equation 2 is: P = t2-tl-D; where tl represents the first moment, t2 represents the second moment, t3 represents At the third moment, t4 represents the fourth moment, D represents the line delay, and P represents the time offset.
7、 一种模拟现网包时延抖动装置, 其特征在于, 包括:  7. A device for simulating a current network packet delay jitter, characterized in that:
第一发送模块, 用于以 t为周期向从时钟设备发送包含第一时刻的第一 时钟包, 以使所述从时钟设备接收所述第一时钟包后返回第二时钟包; 所述 第一时刻为发送所述第一时钟包的时刻与现网第一网络时延的差值; 所述从 时钟设备接收所述第一时钟包的时刻为第二时刻; 所述从时钟设备发送所述 第二时钟包的时刻为第三时刻; a first sending module, configured to send a first clock packet including a first time to the slave clock device in a period of t, so that the slave clock device receives the first clock packet and returns a second clock packet; The first time is the difference between the time when the first clock packet is sent and the first network delay of the current network; the time when the slave clock device receives the first clock packet is the second time; the slave clock device sends The moment of the second clock packet is a third moment;
第二发送模块, 用于接收所述第二时钟包后, 向所述从时钟设备发送第 四时刻, 以使所述从时钟设备根据所述第一时刻、 第二时刻、 第三时刻和第 四时刻调整从时钟与主时钟同步; 所述第四时刻为接收所述第二时钟包的时 刻与现网第二网络时延之和;  a second sending module, configured to send a fourth time to the slave clock device after receiving the second clock packet, so that the slave clock device is configured according to the first time, the second time, the third time, and the first The fourth time adjustment slave clock is synchronized with the master clock; the fourth time is the sum of the time when the second clock packet is received and the second network delay of the live network;
每个周期内的所述现网第一网络时延和所述现网第二网络时延为以 t为 周期依次从现网中获取到的。  The first network delay of the live network and the second network delay of the live network in each period are sequentially acquired from the live network in a period of t.
8、 根据权利要求 7所述的模拟现网包时延抖动装置, 其特征在于: 所述现网第一网络时延为现网主设备发送报文到现网从设备接收报文的 网络时延;  The device for simulating the current network packet delay jitter according to claim 7, wherein: the first network delay of the live network is when the active network master sends a packet to the network that receives the packet from the device. Delay
所述现网第二网络时延为所述现网从设备发送报文到所述现网主设备接 收报文的网络时延。  The second network delay of the live network is the network delay of the packet sent by the current network slave device to the current network master device.
9、 根据权利要求 8所述的模拟现网包时延抖动装置, 其特征在于, 还包 括用于获取所述现网第一网络时延和所述现网第二网络时延的获耳 莫块, 所 述获取模块包括:  The device for simulating the current network packet delay jitter according to claim 8, further comprising: obtaining the first network delay of the live network and the delay of the second network of the live network Block, the obtaining module includes:
解析单元, 用于通过解析所述现网从设备接收的所述现网主设备发送的 报文, 在每个周期内获取至少一个现网第一网络时延和至少一个现网第二网 络时延;  a parsing unit, configured to: when parsing the packet sent by the current network master device received by the current network slave device, acquiring at least one existing network first network delay and at least one existing network second network in each period Delay
选取单元, 用于根据每个周期内的所述至少一个现网第一网络时延和所 述至少一个现网第二网络时延, 选取本周期内的现网第一网络时延和现网第 二网络时延。  a selecting unit, configured to select, according to the at least one existing network first network delay and the at least one existing network second network delay in each period, the first network delay and the current network in the current period The second network delay.
10、 根据权利要求 9所述的模拟现网包时延抖动装置, 其特征在于, 所 述选取单元包括:  The device for simulating the current network packet delay jitter according to claim 9, wherein the selecting unit comprises:
第一子单元, 用于从每个周期内的所述至少一个现网第一网络时延中选 择数值最小的一个作为本周期内的现网第一网络时延, 从每个周期内的所述 至少一个现网第二网络时延中选择数值最小的一个作为本周期内的现网第二 网络时延; 和 /或 第二子单元, 用于将每个周期内的所有现网第一网络时延的数值的平均 值作为本周期内的现网第一网络时延, 将每个周期内的所有现网第二网络时 延的数值的平均值作为本周期内的现网第二网络时延; 和 /或 a first subunit, configured to select, from the at least one live network first network delay in each period, a value of the lowest network as the first network delay in the current network, from each period in the period Determining, in the current network, the second network delay, the one having the smallest value as the second network delay in the current network; and/or a second subunit, configured to use an average value of the values of the first network delays of all the live networks in each period as the first network delay in the current network, and all the second networks in each period. The average value of the network delay is used as the second network delay of the live network in the current period; and/or
第三子单元, 用于将每个周期内的所有现网第一网络时延的数值的平均 值作为本周期内的现网第一网络时延, 将每个周期内的所有现网第二网络时 延的数值的平均值作为本周期内的现网第二网络时延; 和 /或  a third sub-unit, configured to use an average value of the values of the first network delays of all the live networks in each period as the first network delay of the live network in the current period, and the second network of all the live networks in each period The average value of the network delay is used as the second network delay of the live network in the current period; and/or
第四子单元, 用于将每个周期内的所有现网第一网络时延的数值去掉最 大值和最小值后的平均值作为本周期内的现网第一网络时延, 将每个周期内 的所有现网第二网络时延的数值去掉最大值和最小值后的平均值作为本周期 内的现网第二网络时延; 和 /或  The fourth sub-unit is configured to use the average value of the first network delay of all the live networks in each period after removing the maximum value and the minimum value as the first network delay of the live network in the current period, and each period is The value of the second network delay of all existing networks in the current network is the average value after the maximum value and the minimum value are removed as the second network delay in the live network in the current period; and/or
第五子单元, 用于将每个周期内的所有现网第一网络时延的数值的最小 值与所有第二网络时延的数值的最小值之和的 1/2 同时作为本周期内的现网 第一网络时延和现网第二网络时延。  a fifth sub-unit, configured to use 1/2 of a sum of a minimum value of all the first network delays of each live network in each period and a minimum value of values of all second network delays as the current period The first network delay of the current network and the second network delay of the existing network.
11、 权利要求 7-10任一所述的模拟现网包时延抖动装置, 其特征在于, 所述第二发送模块具体用于: 根据式 1得到线路时延, 根据式 2得到所述从 时钟与所述主时钟的时间偏差, 然后根据所述时间偏差调整与所述主时钟同 步;  The analog network packet delay jitter device according to any one of claims 7 to 10, wherein the second sending module is specifically configured to: obtain a line delay according to Equation 1, and obtain the slave according to Equation 2. a time deviation of the clock from the master clock, and then adjusting to synchronize with the master clock according to the time offset;
式 1为: D = [ ( t2-tl ) + ( t4-t3 ) ]/2; 式 2为: P = t2-tl-D; 其中, tl表 示第一时刻, t2表示第二时刻, t3表示第三时刻, t4表示第四时刻, D表示 线路时延, P表示时间偏差。  Equation 1 is: D = [ ( t2-tl ) + ( t4-t3 ) ]/2; Equation 2 is: P = t2-tl-D; where tl represents the first moment, t2 represents the second moment, t3 represents At the third moment, t4 represents the fourth moment, D represents the line delay, and P represents the time offset.
PCT/CN2011/072611 2011-04-11 2011-04-11 Method and apparatus for simulating packet delay variation in current network WO2011100906A2 (en)

Priority Applications (2)

Application Number Priority Date Filing Date Title
PCT/CN2011/072611 WO2011100906A2 (en) 2011-04-11 2011-04-11 Method and apparatus for simulating packet delay variation in current network
CN201180000356.XA CN102171966B (en) 2011-04-11 2011-04-11 Method and apparatus for simulating packet delay jitter in current network

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
PCT/CN2011/072611 WO2011100906A2 (en) 2011-04-11 2011-04-11 Method and apparatus for simulating packet delay variation in current network

Publications (2)

Publication Number Publication Date
WO2011100906A2 true WO2011100906A2 (en) 2011-08-25
WO2011100906A3 WO2011100906A3 (en) 2012-03-15

Family

ID=44483376

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2011/072611 WO2011100906A2 (en) 2011-04-11 2011-04-11 Method and apparatus for simulating packet delay variation in current network

Country Status (2)

Country Link
CN (1) CN102171966B (en)
WO (1) WO2011100906A2 (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103986601A (en) * 2014-05-16 2014-08-13 北京东土科技股份有限公司 Message transmission delay obtaining method and device

Families Citing this family (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103580846B (en) * 2013-08-23 2017-03-01 北京东土科技股份有限公司 A kind of method and system across non-1588 network transmission precision interval clock messages
CN106211306B (en) 2015-04-30 2020-04-03 华为技术有限公司 Communication network delay jitter smoothing method, device and system
CN106210708B (en) * 2015-04-30 2019-02-01 杭州海康威视数字技术股份有限公司 A kind of detection method and system of picture delay
CN110971489A (en) * 2019-12-04 2020-04-07 盛科网络(苏州)有限公司 Simulation test method and device for variable deflection based on simulation clock generator
CN116266818A (en) * 2021-12-17 2023-06-20 中兴通讯股份有限公司 Information measurement method and device

Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US7848242B2 (en) * 2007-06-14 2010-12-07 Agere Systems Inc. Methods and apparatus for testing adaptive timing characteristics of packet-based timing protocol
CN101951312A (en) * 2010-09-15 2011-01-19 电信科学技术第五研究所 E1 link-based bidirectional time-frequency synchronous transmission method and master-slave device

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101834712B (en) * 2010-04-19 2012-11-14 浙江大学 Method for realizing accurate time synchronization by utilizing IEEE1588 protocol

Patent Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US7848242B2 (en) * 2007-06-14 2010-12-07 Agere Systems Inc. Methods and apparatus for testing adaptive timing characteristics of packet-based timing protocol
CN101951312A (en) * 2010-09-15 2011-01-19 电信科学技术第五研究所 E1 link-based bidirectional time-frequency synchronous transmission method and master-slave device

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103986601A (en) * 2014-05-16 2014-08-13 北京东土科技股份有限公司 Message transmission delay obtaining method and device

Also Published As

Publication number Publication date
CN102171966A (en) 2011-08-31
WO2011100906A3 (en) 2012-03-15
CN102171966B (en) 2013-03-20

Similar Documents

Publication Publication Date Title
WO2011100906A2 (en) Method and apparatus for simulating packet delay variation in current network
US7876791B2 (en) Synchronizing apparatus and method in packet network
KR102009588B1 (en) Time synchronization method and system, and network device
JP5576747B2 (en) Communication system and time synchronization method
US9077468B2 (en) Methods and apparatus for communication synchronization
US8670439B2 (en) Method for accurate distribution of time to a receiver node in an access network
CN101455014B (en) Methods and devices for sending transmission-time or reception-time information for a transmitted or received message
US20210144666A1 (en) Synchronizing tsn master clocks in wireless networks
CN103929293B (en) Asymmetrically-delayed time synchronization method and system
CN103905135B (en) Realize the method, apparatus and system of time synchronized
CN103999521B (en) Delay compensation during being synchronized in base station in a cellular communication network
CN102244603B (en) Method, equipment and system for transmitting message bearing time
WO2012055360A1 (en) Method for time synchronization and device and system thereof
TW201427306A (en) Apparatus and method for enabling a passive optical network on supporting time synchronization
EP3284244A1 (en) Methods, systems, and computer readable media for emulating network devices with different clocks
CN102299788A (en) Method and device for controlling automatic transmission of IEEE1558 (Institute of Electrical and Electronic Engineers 1558) protocol message
CN108155982A (en) A kind of timestamp processing method and equipment
CN108028817A (en) Timing Synchronization for the cell with limit backhaul
CN103259640A (en) Method and device for synchronizing time
KR20090071923A (en) Method for synchronization using single timesync frame in bridged local area network and appratus thereof
WO2015089848A1 (en) Precision time protocol synchronization method and node
WO2018099375A1 (en) Synchronization method, synchronization device, synchronization apparatus and communication system
WO2010102565A1 (en) Method, apparatus and system for time synchronization
CN104601269A (en) Master and slave clock synchronization method and system
CN111934804B (en) Method, device and system for synchronizing communication equipment

Legal Events

Date Code Title Description
WWE Wipo information: entry into national phase

Ref document number: 201180000356.X

Country of ref document: CN

121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 11744264

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase in:

Ref country code: DE

122 Ep: pct application non-entry in european phase

Ref document number: 11744264

Country of ref document: EP

Kind code of ref document: A2