CN111106890B - Method and equipment for time synchronization - Google Patents
Method and equipment for time synchronization Download PDFInfo
- Publication number
- CN111106890B CN111106890B CN201811266459.0A CN201811266459A CN111106890B CN 111106890 B CN111106890 B CN 111106890B CN 201811266459 A CN201811266459 A CN 201811266459A CN 111106890 B CN111106890 B CN 111106890B
- Authority
- CN
- China
- Prior art keywords
- time
- difference value
- local
- test instrument
- time difference
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Active
Links
Images
Classifications
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04J—MULTIPLEX COMMUNICATION
- H04J3/00—Time-division multiplex systems
- H04J3/02—Details
- H04J3/06—Synchronising arrangements
- H04J3/0635—Clock or time synchronisation in a network
- H04J3/0638—Clock or time synchronisation among nodes; Internode synchronisation
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04B—TRANSMISSION
- H04B7/00—Radio transmission systems, i.e. using radiation field
- H04B7/14—Relay systems
- H04B7/15—Active relay systems
- H04B7/185—Space-based or airborne stations; Stations for satellite systems
- H04B7/1851—Systems using a satellite or space-based relay
Landscapes
- Engineering & Computer Science (AREA)
- Computer Networks & Wireless Communication (AREA)
- Signal Processing (AREA)
- Physics & Mathematics (AREA)
- Astronomy & Astrophysics (AREA)
- Aviation & Aerospace Engineering (AREA)
- General Physics & Mathematics (AREA)
- Electric Clocks (AREA)
- Synchronisation In Digital Transmission Systems (AREA)
Abstract
The invention discloses a method and equipment for time synchronization, which are used for solving the problems of lower test precision and larger limitation of a test instrument for time synchronization test in the prior art. According to the clock difference of the satellite time of the time equipment and the local time at the first comparison time and the clock difference of the satellite time of the test instrument and the local time at the second comparison time, the local time of the test instrument is adjusted according to the first time difference and the second time difference, and the time source error of the test instrument in the transmission process of receiving the satellite time is reduced, so that the precision of the test instrument for time synchronization test is improved.
Description
Technical Field
The present invention relates to the field of communications technologies, and in particular, to a method and an apparatus for performing time synchronization.
Background
With the development of science and technology, the requirements of various industries on time synchronization are higher and higher, particularly in some key industries with important concerns, accurate time synchronization is very important for designing a plurality of key infrastructures for national economic and social safety, and effective operation of a communication system, a financial system and an electric power system depends on high-precision time synchronization.
Currently, these systems usually acquire time information by building a time synchronization network to meet the requirement of high time precision for time synchronization. For a time synchronization network, a time server is usually deployed at the upstream of a transmission network, the time server acquires a time source through a satellite time service receiver, and then transmits time to a downstream application end according to a time synchronization protocol such as PTP (precision time protocol), and in order to verify whether the time synchronization network meets the time precision requirement, a time synchronization test instrument is required to test the time precision.
The existing time synchronization test instrument usually obtains a time source through a satellite time service receiver, and then compares the time source with a time signal output by network equipment to obtain a time precision test result, however, the time synchronization test instrument has certain time source errors, so that the time precision of the network equipment test is low.
At present, in order to avoid errors of a time source of a time synchronization test instrument, in a laboratory test, a loopback test can be used for testing the time accuracy of network equipment or errors introduced by a network, namely, the output of the time synchronization test instrument is used as an input source of the network equipment, then, a time output signal of the network equipment is looped back to be used as the input of the time synchronization test instrument, and the time synchronization test instrument tests the time output signal of the network equipment by taking the time of the time synchronization test instrument as a reference.
In summary, the current test instrument has lower test precision and larger limitation when performing time synchronization test.
Disclosure of Invention
The invention provides a method and equipment for time synchronization, which are used for solving the problems of lower test precision and larger limitation of a test instrument in time synchronization test in the prior art.
In a first aspect, a method for performing time synchronization provided in an embodiment of the present invention includes:
determining a first time difference value and a second time difference value, wherein the first time difference value is a clock error of the satellite time of the time equipment and the local time at a first comparison time, and the second time difference value is a clock error of the satellite time of the test instrument and the local time at a second comparison time; and adjusting the local time of the test instrument according to the first time difference value and the second time difference value.
According to the method, the clock error of the satellite time of the time equipment and the clock error of the local time at the first comparison time and the clock error of the test instrument and the clock error of the satellite time of the test instrument and the local time at the second comparison time are adjusted according to the first time difference and the second time difference, and the time source error of the test instrument in the transmission process of receiving the satellite time is reduced, so that the precision of the test instrument for time synchronization test is improved.
In an alternative embodiment, before determining the first time difference value and the second time difference value, requesting the time device to obtain time information of the time device, wherein the time information includes satellite time and local time of the time device; or the time information is the first time difference value; and determining the first time difference value according to the received time information.
According to the method, when the time information is sent by the time equipment, the satellite time and the local time of the time equipment can be selected to be sent, the first time difference value can also be selected to be sent, and the sending mode is more flexible.
In an optional implementation manner, the request for obtaining the time information is sent to the time device through the set address information of the time device.
According to the method, the time information acquisition request can be sent to different time equipment by setting the addresses of different time equipment, so that the time equipment capable of acquiring the time information is wider in range, more flexible in operation and wider in applicability.
In an optional implementation manner, before the local time of the test instrument is adjusted according to the first time difference value and the second time difference value, it is determined that the time difference value between the first comparison time and the second comparison time does not exceed a time threshold;
the first comparison time is satellite time used for determining a first time difference value, and the second comparison time is satellite time used for determining a second time difference value.
According to the method, the satellite positions are stable in a certain time, so that the comparison time of the satellite positions is basically consistent, when the second time difference value of the test instrument is determined, the second comparison time can be selected by setting the threshold, the range of the second comparison time is larger, and the method is easier to operate.
In an alternative embodiment, the local time of the test meter is adjusted based on the time difference between the first time difference and the second time difference.
According to the method, the local time of the test instrument is adjusted according to the difference value of the first time difference value and the second time difference value, the time source error of the test instrument in the transmission process of receiving the satellite time can be reduced, and the precision of the test instrument for time synchronization test is improved.
In an alternative embodiment, the time device is a time server or a standard time device.
According to the method, the time server or the standard time equipment has high-precision time, and the precision of the test instrument in time precision measurement can be correspondingly improved when the test instrument is adjusted according to the time server or the standard time equipment.
In a second aspect, an embodiment of the present invention provides an apparatus for performing time synchronization, including: a processor and a transceiver:
the processor is configured to perform data transmission through the transceiver, and determine a first time difference value and a second time difference value, where the first time difference value is a clock difference between a satellite time of the time device and a local time at a first comparison time, and the second time difference value is a clock difference between the satellite time of the test instrument and the local time at a second comparison time; and adjusting the local time of the test instrument according to the first time difference value and the second time difference value.
Optionally, the processor is further configured to:
after requesting to acquire the time information of the time equipment from the time equipment, determining the first time difference value according to the received time information;
wherein the time information comprises a satellite time and a local time of the time device; or the time information is the first time difference value.
Optionally, the processor is specifically configured to:
and sending a request for acquiring the time information to the time equipment through the set address information of the time equipment.
Optionally, the processor is further configured to:
before adjusting the local time of the test instrument according to the first time difference value and the second time difference value, determining that the time difference value between the first comparison time and the second comparison time does not exceed a time threshold;
the first comparison time is satellite time used for determining a first time difference value, and the second comparison time is satellite time used for determining a second time difference value.
Optionally, the processor is specifically configured to:
and adjusting the local time of the test meter according to the time difference between the first time difference value and the second time difference value.
Optionally, the time device is a time server or a standard time device.
Optionally, the device is a test meter.
In a third aspect, an embodiment of the present invention further provides an apparatus for performing time synchronization, where the apparatus includes:
at least one processing unit and at least one memory unit, wherein the memory unit has stored program code that, when executed by the processing unit, causes the processing unit to perform the functions of the embodiments of the first aspect described above.
In a fourth aspect, the present invention further provides a computer-readable medium, on which a computer program is stored, which when executed by a processor implements the steps of the above method.
In addition, for technical effects brought by any one implementation manner of the second aspect to the fourth aspect, reference may be made to technical effects brought by different implementation manners of the first aspect, and details are not described here.
Drawings
In order to more clearly illustrate the technical solutions in the embodiments of the present invention, the drawings needed to be used in the description of the embodiments will be briefly introduced below, and it is obvious that the drawings in the following description are only some embodiments of the present invention, and it is obvious for those skilled in the art to obtain other drawings based on these drawings without inventive exercise.
Fig. 1 is a schematic flow chart of a method for performing time synchronization according to an embodiment of the present invention;
fig. 2 is a schematic view of a scenario of a first solution according to an embodiment of the present invention;
fig. 3 is a schematic view of a scenario of a second solution provided in an embodiment of the present invention;
FIG. 4 is a functional diagram of a test meter according to an embodiment of the present invention;
FIG. 5 is a schematic structural diagram of a device for synchronization according to an embodiment of the present invention;
FIG. 6 is a schematic diagram of another apparatus for synchronization according to an embodiment of the present invention;
fig. 7 is a flowchart illustrating a method for performing synchronization integrity under a scenario of a second embodiment of the present invention.
Detailed Description
In order to make the objects, technical solutions and advantages of the present invention clearer, the present invention will be described in further detail with reference to the accompanying drawings, and it is apparent that the described embodiments are only a part of the embodiments of the present invention, not all of the embodiments. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present invention.
Some of the words that appear in the text are explained below:
1. "and/or" describes the association relationship of the associated objects, meaning that there may be three relationships, e.g., a and/or B, which may mean: a exists alone, A and B exist simultaneously, and B exists alone. The character "/" generally indicates that the former and latter associated objects are in an "or" relationship.
The embodiments of the present invention are described in further detail below with reference to the drawings.
As shown in fig. 1, an embodiment of the present invention provides a method for synchronous testing, which specifically includes the following steps:
step 100: determining a first time difference value and a second time difference value, wherein the first time difference value is the clock error of the satellite time of the time equipment and the local time at a first comparison moment, and the second time difference value is the clock error of the satellite time of the test instrument and the local time at a second comparison moment;
step 101: and adjusting the local time of the test instrument according to the first time difference value and the second time difference value.
According to the scheme, the clock error of the satellite time of the time equipment and the clock error of the local time at the first comparison time and the clock error of the test instrument and the clock error of the satellite time of the test instrument and the local time at the second comparison time are adjusted according to the first time difference and the second time difference, and the time source error of the test instrument in the transmission process of receiving the satellite time is reduced, so that the precision of the test instrument for time synchronization test is improved.
The execution subject of the embodiment of the present invention may be a test instrument (which may also be referred to as a test device), which may be used to measure the time accuracy of the device.
The time device in the embodiment of the invention can be a time server or a standard time device.
The standard Time equipment has absolute standard Time, if the standard Time equipment is used, the first Time difference value of the standard Time equipment is the difference value between UTC (Coordinated Universal Time) Time and satellite Time, namely the Time error of the satellite Time relative to the UTC Time, the local Time of the test instrument is adjusted according to the first Time difference value of the standard Time equipment and the second Time difference value of the test instrument, the Time error of the local Time of the test instrument relative to the UTC Time can be indirectly compared, and the absolute Time precision of the test instrument can be improved by adjusting the local Time of the test instrument through the method disclosed by the invention.
The Time server is a Time source of a Time Synchronization network, and transmits Time to a downstream application end through a Time Synchronization Protocol such as PTP (Precision Time Synchronization Protocol).
That is, the present invention provides two schemes to improve the time accuracy of the test meter, which are described below:
in the first scheme, the time equipment is standard time equipment.
The standard time equipment has various types, and the corresponding standard time also has various types, such as UTC, international atomic time TAI (international atomic time), GPS (Global Positioning system) time, and the like, and the specific manner of the embodiment of the present invention is described below by taking the standard time as UTC as an example:
the method includes that a test instrument and a UTC device with an absolute time source UTC acquire satellite time through a satellite receiver, the UTC device has continuously updated local time and satellite time, an IP address in the same network segment as the UTC device is allocated, the UTC device communicates with the UTC device by searching the IP address of the UTC device, after communication is successful, a request for acquiring time information is sent to the UTC device, and after the UTC device receives the request, the UTC device sends the time information, wherein the UTC device sends the time information in various modes, which is exemplified below:
the first sending mode is as follows: the local time and the satellite time are transmitted.
The UTC equipment transmits the received satellite time and local time when receiving the satellite time;
accordingly, after receiving the time information transmitted by the UTC device, a clock offset (first time difference) between the satellite time of the UTC device and the local time is calculated based on the time information.
And a second transmission mode: sending a first time difference value;
the UTC device determines a clock difference between the local time and the satellite time at a time, which difference is transmitted as a first time difference value to the UTC device, wherein the UTC device determines the time of the first time difference value.
Correspondingly, the receiving UTC equipment sends the first time difference value.
For time equipment, the addresses of the time equipment in different networks are different, and the embodiment of the invention supports setting different destination addresses, so that a receiving source can be flexibly selected to send request information.
It should be noted that, different destination addresses are supported to be set to implement communication with the time device, the above-mentioned manner of passing through the IP address is only an example, and the communication with other time devices may also be performed by a wireless access manner or a wired connection manner of the mobile communication network, for example: any mode capable of realizing communication with time equipment, such as a Medium Access Control (MAC) address, is applicable to the embodiment of the present invention.
Further, in order to ensure the accuracy of adjusting the test instrument according to the first time difference and the second time difference, an optional case is that the UTC device and the test instrument acquire satellite time at the same time, and since the satellite positions are stable within a certain time, the comparison times of the two are kept basically consistent. In implementation, it is sufficient to ensure that a time difference between a first comparison time corresponding to the determined first time difference of the UTC device and a second comparison time corresponding to the determined second time difference of the test instrument does not exceed a time threshold.
The first comparison time is satellite time used for determining a first time difference value, and the second comparison time is satellite time used for determining a second time difference value.
For example, if the time threshold between the first comparison time and the second comparison time is 1s, when the satellite time corresponding to the first comparison time is 12.
The method comprises the steps that a test instrument stores a time difference value of the test instrument in a certain time period, after the satellite time of the UTC equipment at a first comparison time is determined, the time range of a second comparison time under a currently set time threshold is determined according to the first comparison time, the time difference value of the test instrument at any time in the time range under the time threshold is found according to the time difference value stored in the test instrument, and the time difference value at the same time as the first comparison time of the UTC equipment is optimally selected to serve as the second time difference value.
The test instrument sends the time information in the sending manner, the test instrument may also send the satellite time at a certain time within the time threshold range and the local time, and the specific implementation manner may be the sending manner of the UTC device described above by determining the second time difference of the test instrument, which is not described herein again.
Scheme II: the time equipment is a time server;
the time server obtains satellite time through the satellite receiver, the satellite time has continuously updated local time and satellite time, the time server is a time source of a time synchronization network, and the synchronization network transmits the time to the tested equipment through time synchronization protocols such as PTP.
The manner in which the test instrument sends the request for obtaining the time information to the time server and the time server sends the time information to the test instrument may refer to the specific implementation of the UTC device, and is not described herein again.
For the way of determining the first time difference of the time server and the second time difference of the test instrument, reference may be made to the specific implementation of determining the first time difference of the UTC device and determining the second time difference of the test instrument, and details are not described here.
In implementation, a first time difference value of the time device and a second time difference value of the test instrument are determined, wherein the first time difference value is a clock error of the satellite time of the time device and the local time at a first comparison time, and the second time difference value is a clock error of the satellite time of the test instrument and the local time at a second comparison time;
and adjusting the local time of the test instrument according to the time difference between the first time difference value and the second time difference value so as to enable the adjusted local time of the test instrument to be consistent with the local time of the time equipment, wherein the adjusted local time is taken as the test reference time by the test instrument.
For example, the satellite time of the UTC device at the first comparison time is represented as m 1 Local time is denoted by n 1 The first time difference value of the UTC equipment at the comparison time is A;
the satellite time of the test instrument at the second comparison time is expressed as m 2 Local time is denoted by n 2 The first time difference value of the UTC equipment at the comparison time is B;
there are various algorithms for determining the first time difference value and the second time difference value by debugging, which are exemplified as follows:
the first algorithm is as follows: the first time difference value is equal to the satellite time minus the local time;
wherein, if A = m 1 -n 1 Then B = m 2 -n 2 If the value of A or B presents negative number, it represents that the satellite time of the corresponding device is slower than the local time.
And adjusting the local time of the test instrument according to the difference value of the first time difference value A and the second time difference value B.
For example, a =10ns, B = -5ns, and then a-B =15ns, it indicates that the satellite time of the UTC device is faster than the local time by 10ns, and the satellite time is slower than the local time by 5s due to the self time source error of the test meter, and it is necessary to reduce the local time by 15ns, that is, the local time of the test meter is slowed by 15ns, and at this time, the local time is used as the test reference time.
And (3) algorithm II: the first time difference value is equal to the local time minus the satellite time;
wherein, if A = n 1 -m 1 Then B = n 2 -m 2 If the value of A or B is negative, the satellite time of the corresponding device is faster than the local time.
And adjusting the local time of the test instrument according to the difference value of the first time difference value A and the second time difference value B.
For example, a =10ns, B = -5ns, and a-B =15ns, it indicates that the satellite time of the UTC device is slower than the local time by 10ns, and the satellite time is faster than the local time by 5s due to the self time source error of the test instrument, and the local time needs to be accelerated by 15ns, that is, the local time of the test instrument needs to be accelerated by 15ns, and at this time, the local time is used as the test reference time.
It should be noted that the above-mentioned manner of calculating the time difference between the UTC device and the test instrument and the first time difference and the second time difference is only an example, and there are various manners of calculating the difference, for example, when calculating the first time difference and the second time difference, a negative value representing the satellite time may be added to the local time, and the difference obtained by subtraction or addition is only a specific operation of a numerical value in a different expression form; for example, when the difference between the first time difference and the second time difference is calculated, the first time difference may be subtracted from the second time difference, and if the result obtained by using different algorithms may have a positive or negative score, the adjustment mode of the local time of the test instrument may be adjusted adaptively, but the adjustment principle is not changed, and any algorithm capable of passing through the first time difference and the second time difference is adapted to the present invention.
After the local time of the test instrument is adjusted, the test instrument takes the adjusted local time as the test reference time, and the time precision of the tested equipment is measured by receiving the time output information of the tested equipment.
In the implementation, the test instrument can be adjusted before the test instrument measures the time precision of the tested equipment, and the test instrument can also be adjusted in the test process of the test instrument. The specific adjustment modes are various, and the following examples are given:
the first adjustment mode is as follows: adjusting the instrument to be tested according to the adjustment record;
and recording the adjustment value of the instrument to be tested, wherein the test instrument can be disconnected from communication in the test process of the instrument to be tested and adjusted according to the adjustment value.
The second adjustment mode is as follows: adjusting the instrument to be measured according to the adjustment record;
the device is communicated with the measured instrument and the time equipment at any time, and the measured equipment can be adjusted periodically.
For the first scenario, as shown in fig. 2, the local time of the test instrument is adjusted in the above manner according to the first time difference of the UTC device and the second time difference of the test instrument, and the adjusted test instrument has higher absolute time accuracy and a more accurate measurement result of the absolute time accuracy of the device under test.
For the second scheme, as shown in fig. 3, according to the first time difference of the time server serving as the time source of the device to be tested and the second time difference of the test instrument, the local time of the test instrument is adjusted in the above manner, and the adjusted local time of the test instrument is consistent with the time of the time server, so that the measurement result of the test instrument on the device to be tested is equivalent to the time deviation caused by the transmission network from the time server to the device to be tested, that is, the time precision of the test instrument during the current network test is improved.
Of these, there are 4 time sync transfer devices in each of fig. 2 and 3, which function to transfer the time sync of the time server to the devices in the synchronization network.
The time sync transfer devices in the figures may be any devices having time sync transfer capabilities, the number of which depends on the particular synchronization network, and the figures are only examples.
It should be noted that, the device for time synchronization in the embodiment of the present invention may be a test instrument, and may also be used as a separate device for adjusting the local time of the test instrument; the present invention may also be integrated into a test instrument as a functional module, and used as a module with an adjustment function in the test instrument.
As shown in fig. 4, a schematic structural diagram of a device that embeds a device for performing time synchronization into a test meter according to an embodiment of the present invention is provided, and the integrated test meter also has a function of the device for performing time synchronization.
Based on the same inventive concept, the embodiment of the present invention further provides a device for performing time synchronization, and since the device corresponding to the device is a device corresponding to the method for performing time synchronization according to the embodiment of the present invention, and the principle of the method for solving the problem is similar to that of the device, the implementation of the device may refer to the implementation of the method for performing time synchronization, and repeated details are omitted.
As shown in fig. 5, an embodiment of the present invention provides an apparatus for performing time synchronization, including: processor 500 and transceiver 501:
the processor 500 is configured to perform data transmission through the transceiver 501, and determine a first time difference value and a second time difference value, where the first time difference value is a clock difference between a satellite time of the time device and a local time at a first comparison time, and the second time difference value is a clock difference between the satellite time of the test instrument and the local time at a second comparison time; and adjusting the local time of the test instrument according to the first time difference value and the second time difference value.
Optionally, the processor 500 is further configured to:
after requesting to acquire the time information of the time equipment from the time equipment, determining the first time difference value according to the received time information;
wherein the time information comprises a satellite time and a local time of the time device; or the time information is the first time difference value.
Optionally, the processor 500 is further configured to:
before the local time of the test instrument is adjusted according to the first time difference value and the second time difference value, determining that the time difference value between the first comparison time and the second comparison time does not exceed a time threshold;
the first comparison time is satellite time used for determining a first time difference value, and the second comparison time is satellite time used for determining a second time difference value.
Optionally, the processor 500 is specifically configured to:
and sending a request for acquiring the time information to the time equipment through the set address information of the time equipment.
Optionally, the processor 500 is further configured to:
and adjusting the local time of the test instrument according to the time difference between the first time difference value and the second time difference value.
Optionally, the time device is a time server or a standard time device.
Optionally, the device is a test meter.
Based on the same concept, as shown in fig. 6, the present invention provides an apparatus for performing time synchronization, the apparatus comprising:
at least one processing unit 600 and at least one memory unit 601, wherein the memory unit 601 stores program code that, when executed by the processing unit 600, causes the processing unit 600 to perform the following:
determining a first time difference value and a second time difference value, wherein the first time difference value is a clock error of the satellite time of the time equipment and the local time at a first comparison time, and the second time difference value is a clock error of the satellite time of the test instrument and the local time at a second comparison time; and adjusting the local time of the test instrument according to the first time difference value and the second time difference value.
Optionally, the processing unit 600 is further configured to:
after requesting the time equipment to acquire the time information of the time equipment, determining the first time difference value according to the received time information;
wherein the time information comprises a satellite time and a local time of the time device; or the time information is the first time difference value.
Optionally, the processing unit 600 is specifically configured to:
and sending a request for acquiring the time information to the time equipment through the set address information of the time equipment.
Optionally, the processing unit 600 is further configured to:
before adjusting the local time of the test instrument according to the first time difference value and the second time difference value, determining that the time difference value between the first comparison time and the second comparison time does not exceed a time threshold;
the first comparison time is satellite time used for determining a first time difference value, and the second comparison time is satellite time used for determining a second time difference value.
Optionally, the processing unit 600 is specifically configured to:
and adjusting the local time of the test instrument according to the time difference between the first time difference value and the second time difference value.
Optionally, the time device is a time server or a standard time device.
Optionally, the device is a test meter.
In some possible implementations, the aspects of time synchronization provided by the embodiments of the present invention can also be implemented in the form of a program product including program code for causing a computer device to perform the steps of the method for time synchronization according to various exemplary embodiments of the present invention described in this specification when the program code runs on the computer device.
The program product may employ any combination of one or more readable media. The readable medium may be a readable signal medium or a readable storage medium. A readable storage medium may be, for example, but not limited to, an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any combination of the foregoing. More specific examples (a non-exhaustive list) of the readable storage medium include: an electrical connection having one or more wires, a portable diskette, a hard disk, a Random Access Memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disc read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing.
A program product for time synchronization according to an embodiment of the present invention may employ a portable compact disc read only memory (CD-ROM) and include program code, and may be run on a server device. However, the program product of the present invention is not limited thereto, and in this document, the readable storage medium may be any tangible medium containing or storing the program, which can be used by or in connection with an information transmission, apparatus, or device.
A readable signal medium may include a propagated data signal with readable program code embodied therein, for example, in baseband or as part of a carrier wave. Such a propagated data signal may take any of a variety of forms, including, but not limited to, electro-magnetic, optical, or any suitable combination thereof. A readable signal medium may also be any readable medium other than a readable storage medium that can transmit, propagate, or transport the program for use by or in connection with the periodic network action system, apparatus, or device.
Program code embodied on a readable medium may be transmitted using any appropriate medium, including but not limited to wireless, wireline, optical fiber cable, RF, etc., or any suitable combination of the foregoing.
Program code for carrying out operations for aspects of the present invention may be written in any combination of one or more programming languages, including an object oriented programming language such as Java, C + + or the like and conventional procedural programming languages, such as the "C" programming language or similar programming languages. The program code may execute entirely on the user's computing device, partly on the user's device, as a stand-alone software package, partly on the user's computing device and partly on a remote computing device, or entirely on the remote computing device or server. In situations involving remote computing devices, the remote computing devices may be connected to the user computing device through any kind of network, including a Local Area Network (LAN) or a Wide Area Network (WAN), or may be connected to external computing devices.
The embodiment of the invention also provides a storage medium readable by the computing equipment aiming at the time synchronization method, namely, the content is not lost after power failure. The storage medium stores therein a software program, which includes program code, and when the program code runs on a computing device, the software program is read and executed by one or more processors to implement the scheme of time synchronization of any one of the above network-side devices according to the embodiments of the present invention.
The embodiment of the invention also provides a storage medium readable by the computing equipment for the time synchronization method, namely, the content is not lost after power failure. The storage medium stores therein a software program comprising program code which, when executed on a computing device, when read and executed by one or more processors, implements any of the above aspects of time synchronization of embodiments of the present invention.
Based on the same inventive concept, the embodiment of the present invention further provides a method for performing time synchronization, and since the device corresponding to the method is a method corresponding to the device in the system for performing time synchronization according to the embodiment of the present invention, and the principle of the method for solving the problem is similar to that of the device, the implementation of the method can refer to the implementation of the system for performing time synchronization, and repeated details are omitted.
Taking the device for performing time synchronization in the embodiment of the present invention as a test instrument and the UTC device as a time device, as shown in fig. 7, a complete method for performing time synchronization in the embodiment of the present invention includes:
step 700: the test instrument sends a request for acquiring time information to the UTC equipment and the test instrument;
step 701: the UTC equipment and the test instrument send time information to the test instrument;
step 702: the test instrument determines a first time difference value of the UTC equipment at a first comparison time according to the time information of the UTC equipment, and determines a second time difference value of the test instrument at a second comparison time after determining that the time difference value between the first comparison time and the second comparison time does not exceed a time threshold;
step 703: and the test meter adjusts the local time of the test meter according to the time difference between the first time difference value and the second time difference value.
It should be noted that the above manner is only an example, and the time device may be a time server or other standard time devices.
The present application is described above with reference to block diagrams and/or flowchart illustrations of methods, apparatus (systems) and/or computer program products according to embodiments of the application. It will be understood that one block of the block diagrams and/or flowchart illustrations, and combinations of blocks in the block diagrams and/or flowchart illustrations, can be implemented by computer program instructions. These computer program instructions may be provided to a processor of a general purpose computer, special purpose computer, and/or other programmable data processing apparatus to produce a machine, such that the instructions, which execute via the processor of the computer and/or other programmable data processing apparatus, create means for implementing the functions/acts specified in the block diagrams and/or flowchart block or blocks.
Accordingly, the subject application may also be embodied in hardware and/or in software (including firmware, resident software, micro-code, etc.). Furthermore, the application may take the form of a computer program product on a computer-usable or computer-readable storage medium having computer-usable or computer-readable program code embodied in the medium for use by or in connection with an instruction execution system. In the context of this application, a computer-usable or computer-readable medium may be any medium that can contain, store, communicate, propagate, or transport the program for use by or in connection with the instruction execution system, apparatus, or device.
It will be apparent to those skilled in the art that various changes and modifications may be made in the present invention without departing from the spirit and scope of the invention. Thus, if such modifications and variations of the present invention fall within the scope of the claims of the present invention and their equivalents, the present invention is also intended to include such modifications and variations.
Claims (11)
1. A method for time synchronization, the method comprising:
sending a time information acquisition request to the time equipment through the set address information of the time equipment;
determining a first time difference value and a second time difference value according to the received time information, wherein the first time difference value is the clock error of the satellite time of the time equipment and the local time at a first comparison moment, and the second time difference value is the clock error of the satellite time of the test instrument and the local time at a second comparison moment;
adjusting the local time of the test instrument according to the first time difference value and the second time difference value, wherein the local time is used as test reference time for testing the time precision of the tested equipment; when the time equipment is standard time equipment, the adjusted local time is the absolute standard time of the test instrument, the test time precision is the absolute time precision, when the time equipment is a time server, the adjusted local time is the relative time of the test instrument, and the test time precision is the relative time precision.
2. The method of claim 1, wherein the time information comprises a satellite time and a local time of the time device; or the time information is the first time difference value.
3. The method of claim 1, wherein prior to adjusting the local time of the test meter based on the first time difference value and the second time difference value, further comprising:
determining that the time difference between the first comparison time and the second comparison time does not exceed a time threshold;
the first comparison time is satellite time used for determining a first time difference value, and the second comparison time is satellite time used for determining a second time difference value.
4. The method of claim 1, wherein said adjusting the local time of the test meter based on the first time difference value and the second time difference value comprises:
and adjusting the local time of the test instrument according to the time difference between the first time difference value and the second time difference value.
5. An apparatus for time synchronization, comprising: a processor and a transceiver:
the processor is configured to perform data transmission through the transceiver, send a request for obtaining time information to the time device through the set address information of the time device, and determine a first time difference value and a second time difference value according to the received time information, where the first time difference value is a clock difference between a satellite time of the time device and a local time at a first comparison time, and the second time difference value is a clock difference between the satellite time of the test instrument and the local time at a second comparison time; adjusting the local time of the test instrument according to the first time difference value and the second time difference value, wherein the local time is used as test reference time for testing the time precision of the tested equipment; when the time equipment is standard time equipment, the adjusted local time is the absolute standard time of the test instrument, the test time precision is the absolute time precision, when the time equipment is a time server, the adjusted local time is the relative time of the test instrument, and the test time precision is the relative time precision.
6. The device of claim 5, wherein the time information includes a satellite time and a local time of the time device; or the time information is the first time difference value.
7. The device of claim 5, wherein the processor is further to:
before the local time of the test instrument is adjusted according to the first time difference value and the second time difference value, determining that the time difference value between the first comparison time and the second comparison time does not exceed a time threshold;
the first comparison time is satellite time used for determining a first time difference value, and the second comparison time is satellite time used for determining a second time difference value.
8. The device of claim 5, wherein the processor is specifically configured to:
and adjusting the local time of the test instrument according to the time difference between the first time difference value and the second time difference value.
9. The apparatus of claim 5, wherein the apparatus is a test meter.
10. An apparatus for time synchronization, the apparatus comprising: at least one processing unit and at least one memory unit, wherein the memory unit stores program code which, when executed by the processing unit, causes the processing unit to perform the steps of the method according to any one of claims 1 to 4.
11. A computer-storable medium on which a computer program is stored which, when being executed by a processor, carries out the steps of the method according to any one of claims 1 to 4.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201811266459.0A CN111106890B (en) | 2018-10-29 | 2018-10-29 | Method and equipment for time synchronization |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201811266459.0A CN111106890B (en) | 2018-10-29 | 2018-10-29 | Method and equipment for time synchronization |
Publications (2)
Publication Number | Publication Date |
---|---|
CN111106890A CN111106890A (en) | 2020-05-05 |
CN111106890B true CN111106890B (en) | 2022-12-13 |
Family
ID=70419628
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201811266459.0A Active CN111106890B (en) | 2018-10-29 | 2018-10-29 | Method and equipment for time synchronization |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN111106890B (en) |
Citations (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN106707736A (en) * | 2015-11-17 | 2017-05-24 | 惠州市德赛西威汽车电子股份有限公司 | Automobile instrument clock precision measuring method and automobile instrument clock precision measuring device |
Family Cites Families (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
EP2879322A4 (en) * | 2012-07-27 | 2016-04-06 | Nec Corp | Communication apparatus, time synchronization system, and time synchronization method |
CN105182273A (en) * | 2015-09-08 | 2015-12-23 | 中国电力科学研究院 | Calibration system used for verifying assembly line time value |
CN109150352A (en) * | 2018-07-20 | 2019-01-04 | 中国科学院国家授时中心 | It is a kind of to compare the split-second precision reproducing method for controlling crystal oscillator based on satellite common vision |
-
2018
- 2018-10-29 CN CN201811266459.0A patent/CN111106890B/en active Active
Patent Citations (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN106707736A (en) * | 2015-11-17 | 2017-05-24 | 惠州市德赛西威汽车电子股份有限公司 | Automobile instrument clock precision measuring method and automobile instrument clock precision measuring device |
Also Published As
Publication number | Publication date |
---|---|
CN111106890A (en) | 2020-05-05 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
JP6343395B2 (en) | Distribution of dynamic accuracy information in IEEE 1588 clock network | |
CN113572560B (en) | Method, electronic device, and storage medium for determining clock synchronization accuracy | |
CN111435159A (en) | Method and equipment for positioning | |
EP2811672A1 (en) | Communication apparatus, communication system, and communication method for time synchronization | |
CN108809617B (en) | Time delay compensation method and terminal | |
KR101716630B1 (en) | Communication device, communication method and computer readable recording medium recording program | |
CN112395231B (en) | Method and device for calculating data delay time among multiple processors | |
CN102857333A (en) | Device and method for synchronizing data packet from sensor network | |
US20220086074A1 (en) | Detection device, detection method, and detection program | |
CN109996326B (en) | Communication device, method, system, electronic apparatus, and computer-readable storage medium | |
US20110016232A1 (en) | Time stamping apparatus and method for network timing synchronization | |
CN111106890B (en) | Method and equipment for time synchronization | |
US20240235887A9 (en) | Network node for a vehicle | |
MX2020012264A (en) | Communication method, terminal device, and network device. | |
CN114415560A (en) | Data synchronous acquisition and processing method and device and storage medium | |
CN114500317A (en) | Method and device for comprehensively detecting train clock synchronization network test | |
CN112256714A (en) | Data synchronization method and device, electronic equipment and computer readable medium | |
CN115802471A (en) | Clock synchronization method and equipment | |
CN108781179A (en) | Communication equipment, communication system, communication means and there is the recording medium of signal procedure in above-noted | |
US12114276B2 (en) | Device and method for monitoring two time bases of two communication devices with the aid of a computer | |
CN115226026A (en) | UE positioning method, device, equipment and storage medium | |
CN111884678A (en) | Distribution line distance measurement method based on HPLC technology | |
US20220167292A1 (en) | Wireless communication device, system, and storage medium | |
CN111314021A (en) | Data transmission method and device, electronic equipment and computer readable storage medium | |
CN109379252B (en) | Network delay measurement method and device based on programmable logic device |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
PB01 | Publication | ||
PB01 | Publication | ||
SE01 | Entry into force of request for substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
GR01 | Patent grant | ||
GR01 | Patent grant |