CN109068384A - A kind of method for synchronizing time and system - Google Patents
A kind of method for synchronizing time and system Download PDFInfo
- Publication number
- CN109068384A CN109068384A CN201810970327.XA CN201810970327A CN109068384A CN 109068384 A CN109068384 A CN 109068384A CN 201810970327 A CN201810970327 A CN 201810970327A CN 109068384 A CN109068384 A CN 109068384A
- Authority
- CN
- China
- Prior art keywords
- time
- time synchronization
- moment
- synchronization terminal
- terminal
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Pending
Links
- 238000000034 method Methods 0.000 title claims abstract description 50
- 230000002123 temporal effect Effects 0.000 claims abstract description 12
- 230000005540 biological transmission Effects 0.000 claims description 43
- 230000008569 process Effects 0.000 abstract description 11
- 238000004891 communication Methods 0.000 abstract description 6
- 238000005516 engineering process Methods 0.000 abstract description 4
- 230000001360 synchronised effect Effects 0.000 description 12
- 238000001514 detection method Methods 0.000 description 4
- 230000004044 response Effects 0.000 description 4
- 238000004364 calculation method Methods 0.000 description 3
- 238000010168 coupling process Methods 0.000 description 3
- 238000005859 coupling reaction Methods 0.000 description 3
- 230000006870 function Effects 0.000 description 3
- 238000012544 monitoring process Methods 0.000 description 3
- RTZKZFJDLAIYFH-UHFFFAOYSA-N Diethyl ether Chemical compound CCOCC RTZKZFJDLAIYFH-UHFFFAOYSA-N 0.000 description 2
- 230000008878 coupling Effects 0.000 description 2
- 238000010586 diagram Methods 0.000 description 2
- 108700009949 PTP protocol Proteins 0.000 description 1
- 230000006399 behavior Effects 0.000 description 1
- 238000012937 correction Methods 0.000 description 1
- 238000011161 development Methods 0.000 description 1
- 239000004744 fabric Substances 0.000 description 1
- 230000006872 improvement Effects 0.000 description 1
- 230000007246 mechanism Effects 0.000 description 1
- 230000004048 modification Effects 0.000 description 1
- 238000012986 modification Methods 0.000 description 1
- 238000005192 partition Methods 0.000 description 1
- 230000000737 periodic effect Effects 0.000 description 1
- 238000012545 processing Methods 0.000 description 1
- 238000000926 separation method Methods 0.000 description 1
- 238000006467 substitution reaction Methods 0.000 description 1
Classifications
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04W—WIRELESS COMMUNICATION NETWORKS
- H04W56/00—Synchronisation arrangements
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04W—WIRELESS COMMUNICATION NETWORKS
- H04W56/00—Synchronisation arrangements
- H04W56/001—Synchronization between nodes
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04W—WIRELESS COMMUNICATION NETWORKS
- H04W56/00—Synchronisation arrangements
- H04W56/001—Synchronization between nodes
- H04W56/0015—Synchronization between nodes one node acting as a reference for the others
Abstract
The embodiment of the invention provides a kind of method for synchronizing time and systems, are related to field of communication technology, can be transmitted by information at the time of master and slave time synchronization terminal room, time of the accurate adjustment from time synchronization terminal.This method comprises: main time synchronization terminal, at the first moment to from time synchronization terminal sending time sync message and the first time information;From time synchronization terminal, it is based on the time synchronization message, sends third time information to main time synchronization terminal in second the first time information of reception, and at the third moment;Main time synchronization terminal in the 4th reception third time information, and sends the 4th time information extremely from time synchronization terminal;The time difference between master and slave time synchronization terminal is calculated from time synchronization terminal according to the first moment, the second moment, third moment and the 4th moment, and according to the time difference, calibrates temporal.Technical solution provided in an embodiment of the present invention is applicable in the time synchronization process of terminal.
Description
[technical field]
The present invention relates to field of communication technology more particularly to a kind of method for synchronizing time and systems.
[background technique]
With the fast development of the communication technology, smart phone, tablet computer have almost spread over the most area in the world.It removes
But communication function, smart phone and tablet computer are just to look at the time there are one the common function of user.
Because of network delay, hardware device and other reasons, when will lead to time and the standard of smart phone or tablet computer
Between having time it is poor.In the prior art, imperfect for the time calibration technology of smart phone, tablet computer, so as to cause intelligence
Energy mobile phone, tablet computer generate large error when carrying out time synchronization.
[summary of the invention]
In view of this, the embodiment of the invention provides a kind of method for synchronizing time and system, can accurately calibrate from when
Between synchronous terminal time, reduce terminal carry out time synchronization when generation error.
In a first aspect, the embodiment of the present invention provides a kind of method for synchronizing time, it is suitable for clock synchronization system, the time
Synchronization system includes main time synchronization terminal and from time synchronization terminal, which comprises
The main time synchronization terminal, the first moment to it is described from time synchronization terminal sending time sync message and
First time information;
It is described from time synchronization terminal, be based on the time synchronization message, the main time synchronization described in the second reception
The first time information that terminal is sent;
It is described from time synchronization terminal, send third time information to the main time synchronization terminal at the third moment;
The main time synchronization terminal, the third moment letter sent from time synchronization terminal described in the 4th reception
Breath;
The main time synchronization terminal sends the 4th time information to described from time synchronization terminal;
It is described from time synchronization terminal, according to first moment, second moment, third moment and described
4th moment calculated the main time synchronization terminal and the time difference between time synchronization terminal;
It is described that temporal is calibrated according to the time difference from time synchronization terminal.
The aspect and any possible implementation manners as described above, it is further provided a kind of implementation, the main time
Synchronous terminal and the time difference expression formula between time synchronization terminal are as follows:
Wherein, T1 indicates first moment, and T2 indicates second moment, and T3 indicates the third moment, and T4 is indicated
4th moment, Δ T indicate the time difference, and T0 indicates time delay.
The aspect and any possible implementation manners as described above, it is further provided a kind of implementation, the main time
The number of synchronous terminal be 1, it is described from the number of time synchronization terminal be one or more.
The aspect and any possible implementation manners as described above, it is further provided a kind of implementation, when it is described from when
Between synchronous terminal number be it is multiple when, the clock synchronization system further includes Precision Time Protocol PTP transmitting device, the side
Method further include:
The main time synchronization terminal issues the time synchronization report to the PTP transmitting device at first moment
Text;
The PTP transmitting device receives the time synchronization message that the main time synchronization terminal is sent;
The time synchronization message is forwarded to multiple described from time synchronization terminal by the PTP transmitting device.
The aspect and any possible implementation manners as described above, it is further provided a kind of implementation, the time are same
Step system include: connection regional network clock synchronization system, moving area net clock synchronization system or telecommunications regional network time it is same
At least one of step system.
Second aspect, the embodiment of the present invention provide a kind of method for synchronizing time, are suitable for clock synchronization system, the time
Synchronization system includes main time synchronization terminal and from time synchronization terminal, which comprises
The main time synchronization terminal, in the first moment issuing time sync message, and to described from time synchronization terminal
Send the first time information;
It is described from time synchronization terminal, be based on the time synchronization message, the main time synchronization described in the second reception
The first time information that terminal is sent;
It is described from time synchronization terminal, send third time information to the main time synchronization terminal at the third moment;
The main time synchronization terminal, the third moment letter sent from time synchronization terminal described in the 4th reception
Breath;
It is described from time synchronization terminal, send the second time information to the main time synchronization terminal;
The main time synchronization terminal, according to first moment, second moment, third moment and described
4th moment calculated the main time synchronization terminal and the time difference between time synchronization terminal;
The time difference is sent to described from time synchronization terminal by the main time synchronization terminal;
It is described that temporal is calibrated according to the time difference from time synchronization terminal.
The third aspect, the embodiment of the present invention provide a kind of clock synchronization system, and the system comprises main time synchronization terminals
With from time synchronization terminal, the main time synchronization terminal includes that the first transmission unit, the second receiving unit and third send list
Member, described to include the first receiving unit, the second transmission unit, computing unit and calibration unit from time synchronization terminal:
First transmission unit, in the first moment sending time sync message and the first time information;
First receiving unit, for being based on the time synchronization message, the first moment described in the second reception
Information;
Second transmission unit, for sending third time information at the third moment;
Second receiving unit is used for the third time information described in the 4th reception;
The third transmission unit, for sending the 4th time information;
The computing unit, for according to first moment, second moment, the third moment and described the
Four moment calculated main time synchronization terminal and from the time difference between time synchronization terminal;
The calibration unit, for according to the time difference, the calibration time from time synchronization terminal.
The aspect and any possible implementation manners as described above, it is further provided a kind of implementation, the main time
Synchronous terminal and the time difference expression formula between time synchronization terminal are as follows:
Wherein, T1 indicates first moment, and T2 indicates second moment, and T3 indicates the third moment, and T4 is indicated
4th moment, Δ T indicate the time difference, and T0 indicates time delay.
The aspect and any possible implementation manners as described above, it is further provided a kind of implementation, the system is also
Including PTP transmitting device, the PTP transmitting device includes receiving module and forwarding module, and first transmission unit includes hair
Cloth module:
The release module, in the first moment issuing time sync message;
The receiving module, for receiving the time synchronization message;
The forwarding module, for forwarding the time synchronization message.
Fourth aspect, the embodiment of the present invention provide a kind of clock synchronization system, and the system comprises main time synchronization terminals
With from time synchronization terminal, the main time synchronization terminal includes the first transmission unit, the second receiving unit, computing unit and the
Four transmission units, it is described to include the first receiving unit, the second transmission unit, third transmission unit and calibration from time synchronization terminal
Unit:
First transmission unit is used in the first moment issuing time sync message, and sends the first time information;
First receiving unit, for being based on the time synchronization message, the first moment described in the second reception
Information;
Second transmission unit, for sending third time information at the third moment;
Second receiving unit is used for the third time information described in the 4th reception;
The third transmission unit, for sending the second time information;
The computing unit, for according to first moment, second moment, the third moment and described the
Four moment calculated main time synchronization terminal and from the time difference between time synchronization terminal;
4th transmission unit, for sending the time difference;
The calibration unit, for according to the time difference, calibration to be described from time synchronization terminal time.
The embodiment of the invention provides a kind of method for synchronizing time and systems, same by main time synchronization terminal and from the time
It walks information at the time of between terminal to transmit, and then calculates the time difference between master and slave time synchronization terminal, and then can basis
The time difference being calculated accurately adjusts the time from time synchronization terminal, solves time synchronization error in the prior art
Greatly, inaccurate problem.
[Detailed description of the invention]
In order to illustrate the technical solution of the embodiments of the present invention more clearly, below will be to needed in the embodiment attached
Figure is briefly described, it should be apparent that, drawings in the following description are only some embodiments of the invention, for this field
For those of ordinary skill, without creative efforts, it can also be obtained according to these attached drawings other attached drawings.
Fig. 1 is a kind of method for synchronizing time flow chart provided in an embodiment of the present invention;
Fig. 2 is another method for synchronizing time flow chart provided in an embodiment of the present invention;
Fig. 3 is another method for synchronizing time flow chart provided in an embodiment of the present invention;
Fig. 4 is a kind of composition block diagram of clock synchronization system provided in an embodiment of the present invention;
Fig. 5 is the composition block diagram of another clock synchronization system provided in an embodiment of the present invention.
[specific embodiment]
For a better understanding of the technical solution of the present invention, being retouched in detail to the embodiment of the present invention with reference to the accompanying drawing
It states.
It will be appreciated that described embodiments are only a part of the embodiments of the present invention, instead of all the embodiments.Base
Embodiment in the present invention, it is obtained by those of ordinary skill in the art without making creative efforts it is all its
Its embodiment, shall fall within the protection scope of the present invention.
The term used in embodiments of the present invention is only to be not intended to be limiting merely for for the purpose of describing particular embodiments
The present invention.In the embodiment of the present invention and the "an" of singular used in the attached claims, " described " and "the"
It is also intended to including most forms, unless the context clearly indicates other meaning.
Depending on context, word as used in this " if " can be construed to " ... when " or
" when ... " or " in response to determination " or " in response to detection ".Similarly, depend on context, phrase " if it is determined that " or
If " detection (condition or event of statement) " can be construed to " when determining " or " in response to determination " or " work as detection
When (condition or event of statement) " or " in response to detection (condition or event of statement) ".
It should be appreciated that term "and/or" used herein is only a kind of incidence relation for describing affiliated partner, indicate
There may be three kinds of relationships, for example, A and/or B, can indicate: individualism A, exist simultaneously A and B, individualism B these three
Situation.In addition, character "/" herein, typicallys represent the relationship that forward-backward correlation object is a kind of "or".
The embodiment of the invention provides a kind of method of time synchronization, can accurately calibrate from time synchronization terminal when
Between, solve the problems, such as time synchronization inaccuracy in the prior art.
Method for synchronizing time provided in an embodiment of the present invention is suitable for clock synchronization system, the clock synchronization system packet
Include main time synchronization terminal and from time synchronization terminal.
Specifically, the main time synchronization terminal can be smart phone or tablet computer (Tablet Computer)
Or radio hand-held equipment etc.;It is described from time synchronization terminal, likewise, be also possible to smart phone or tablet computer or
Radio hand-held equipment etc..Wherein, main time synchronization terminal is as the master clock in clock synchronization system, when the time is standard
Between.From time synchronization terminal as the slave clock in clock synchronization system, the time is the time to be calibrated.
It should be noted that in a clock synchronization system, main time synchronization terminal only one, from time synchronization end
End can have one or more.
As shown in Figure 1, the method specifically includes the following steps:
101, the main time synchronization terminal, at the first moment to described from time synchronization terminal sending time sync message
And first time information.
Wherein, time synchronization message carries out time synchronization from time synchronization terminal for notifying.
It should be noted that the first moment here is the time based on main time synchronization terminal.
102, described from time synchronization terminal, it is based on the time synchronization message, the main time described in the second reception
The first time information that synchronous terminal is sent.
It should be noted that the second moment here is based on the time from time synchronization terminal.
Because main time synchronization terminal with from time synchronization terminal there are time difference and message transmitting procedure generate when
Between postpone, therefore the first moment and the second moment are different time point, and one has been differed between the first moment and the second moment
Time difference and a time delay.
103, described from time synchronization terminal, it is whole to the main time synchronization that third time information is sent at the third moment
End.
Equally, the third moment is based on the time from time synchronization terminal.
104, the main time synchronization terminal, the third moment sent from time synchronization terminal described in the 4th reception
Information.
Equally, the 4th moment was the time based on main time synchronization terminal.
Assuming that differ a positive time difference and a time delay between the first moment and the second moment, then third moment
A negative time difference and a time delay have been differed between the 4th moment.
Specifically, can prolong according to the first moment, the second moment, third moment, composition time difference at the 4th moment and time
Two slow calculation formula, and then calculate the size of two parameters of time difference and time delay.
105, the main time synchronization terminal sends the 4th time information to described from time synchronization terminal.
106, described from time synchronization terminal, according to first moment, second moment, the third moment and
4th moment calculates the main time synchronization terminal and the time difference between time synchronization terminal.
107, described that temporal is calibrated according to the time difference from time synchronization terminal.
It is the time for needing to calibrate from time synchronization terminal, it is contemplated that school because main time synchronization terminal is the standard time
The convenience of quasi- process, relevant time information can be sent to from time synchronization terminal by main time synchronization terminal, to make
The size for calculating two parameters of time difference and time delay according to four moment from time synchronization terminal, finally from time synchronization
Terminal directly according to the time difference, calibrates temporal.
Foregoing invention embodiment provide method for synchronizing time, by main time synchronization terminal and from time synchronization terminal it
Between at the time of information transmit, and then calculate the time difference between master and slave time synchronization terminal, and then can be according to being calculated
Time difference accurately adjust the time from time synchronization terminal, solve that time synchronization error in the prior art is big, inaccuracy
The problem of.
It should be noted that in above-described embodiment, main time synchronization terminal can periodic sending time sync message,
So that from time synchronization terminal according to the continuous calibration temporal of above-mentioned steps process cycle.
Alternatively, temporal can not also periodically be calibrated from time synchronization terminal, but by itself
Software program carries out behavior monitoring, for example ticketing service software rob ticket, shopping software carries out the article second and the times such as kills when monitoring
Property require it is stringent, when needing the operation of timing, then temporal is calibrated.
Alternatively, main time synchronization terminal and from time synchronization terminal be the node in local area network when, pass through the main time
Synchronous terminal carries out time monitoring and judgement to from time synchronization terminal, when judging there is larger mistake from time synchronization terminal time
When poor, then sending time sync message, makes to carry out time calibration from time synchronization terminal according to above method process, to realize
Time synchronization.
Further illustrate be, it is contemplated that the applicable scene of the embodiment of the present invention, the clock synchronization system can be connection
Logical regional network clock synchronization system, moving area net clock synchronization system or telecommunications regional network clock synchronization system.Specifically,
These regional networks can be a cell, for example can have multiple mobile phone users in each cell, and multiple mobile phone users constitute one
A clock synchronization system.
Furthermore, it is understood that, if enabling first moment is T1, second moment is T2, institute in conjunction with preceding method process
Stating the third moment is T3, and the 4th moment is T4, and the time difference is Δ T, time delay T0, then the embodiment of the present invention
Alternatively possible implementation, the realization for step 106 additionally provide calculation process in detail below, comprising:
T1+T0=T2- Δ T (1)
T3+T0=T4+ Δ T (2)
Δ T and T0 can be calculated according to formula (1) and formula (2):
Time difference Δ T then is subtracted from time synchronization terminal by itself current time, both the time after available calibration.
It, can only when by main time synchronization terminal to time calibration is carried out from time synchronization terminal in preceding method process
Primary calibration one from time synchronization terminal, therefore in order to pass through main time synchronization terminal simultaneously calibrate it is multiple from time synchronization end
End, the clock synchronization system further includes being set to the main time synchronization terminal and the essence between time synchronization terminal
True time protocol (Precision Time Protocol, PTP) transmitting device, the PTP transmitting device are same in the reception main time
After walking the time synchronization message that terminal is sent, time synchronization message can be forwarded to simultaneously multiple from time synchronization terminal.
Here, PTP transmitting device can be the transparent clock dress for supporting the boundary clock device of PTP either to support PTP
It sets.Wherein, boundary clock and transparent clock are all physical mechanisms, for intersect multiport network equipment, as bridge, router and
Repeater etc. provides accurately PTP protocol.The application range of boundary clock and transparent clock is from extensive multiport ether
The daisy chain equipment of network switch to two or three of ports all relates to.Specifically, boundary clock can serve certain Single port
Main time synchronization terminal, and every other port is acted on as main time synchronization terminal.Transparent clock is not used as one
It is main or from time synchronization terminal, but deliver the event message of PTP and the correction of the residence time between bridge is provided.
Furthermore, it is understood that in conjunction with preceding method process, the alternatively possible implementation of the embodiment of the present invention, for step
The transmission of time synchronization message additionally provides following possible implementation in rapid 101, as shown in Figure 2, comprising:
1011, the main time synchronization terminal, it is same to the PTP transmitting device publication time at first moment
Walk message.
1012, the PTP transmitting device receives the time synchronization message that the main time synchronization terminal is sent.
1013, the time synchronization message is forwarded to multiple described from time synchronization terminal by the PTP transmitting device.
PTP transmitting device is used to receive the time synchronization message for carrying out autonomous time synchronization terminal, and by time synchronization message
It is forwarded to multiple from time synchronization terminal progress time calibration.When there are PTP transmitting device, PTP transmitting device can be passed through
By time synchronization message simultaneously be transmitted to it is multiple from time synchronization terminal in clock synchronization system, it is subsequent multiple from the time in this way
Synchronous terminal can be performed simultaneously above method process, to carry out time calibration.
Method for synchronizing time provided in an embodiment of the present invention is suitable for clock synchronization system, the clock synchronization system packet
Include main time synchronization terminal and from time synchronization terminal, as shown in figure 3, the method specifically includes the following steps:
201, the main time synchronization terminal, in the first moment issuing time sync message, and to described from time synchronization
Terminal sends the first time information.
202, described from time synchronization terminal, it is based on the time synchronization message, the main time described in the second reception
The first time information that synchronous terminal is sent.
203, described from time synchronization terminal, it is whole to the main time synchronization that third time information is sent at the third moment
End.
204, the main time synchronization terminal, the third moment sent from time synchronization terminal described in the 4th reception
Information.
205, described from time synchronization terminal, the second time information is sent to the main time synchronization terminal.
206, the main time synchronization terminal, according to first moment, second moment, the third moment and
4th moment calculates the main time synchronization terminal and the time difference between time synchronization terminal.
207, the time difference is sent to described from time synchronization terminal by the main time synchronization terminal.
208, described that temporal is calibrated according to the time difference from time synchronization terminal.
In the embodiment, step 201 to step 204 is with reference to the step 101 in above-described embodiment to step 104.
The embodiment mainly for during the time calibration of time synchronization terminal, main time synchronization terminal with from the time
The calculation method of time difference provides different implementations between synchronous terminal, is detailed in step 205 to step 208.The implementation
Example calculates the master and slave time between terminal by main time synchronization terminal in view of unified management and resource-effective factor
Time difference.It is sent to main time synchronization terminal from time synchronization terminal by the second time information first, then by main time synchronization
Terminal calculates the time difference between master and slave time synchronization terminal, and then main time synchronization terminal will be sent to from the time time difference
Synchronous terminal, to make accurately to calibrate temporal according to the time difference from time synchronization terminal.This implementation, can be with
Only in main time synchronization terminal be arranged time difference computing module, save resource, and in clock synchronization system it is all from when
Between time difference between synchronous terminal and main time synchronization terminal calculated by main time synchronization terminal, can be managed collectively.
The embodiment of the present invention improves a kind of clock synchronization system, is suitable for above-mentioned steps 101 to step 107 correlation technique stream
Journey, as shown in figure 4, the system comprises main time synchronization terminal and from time synchronization terminal, the main time synchronization terminal packet
The first transmission unit 31, the second receiving unit 34 and third transmission unit 35 are included, it is described to be connect from time synchronization terminal including first
Receive unit 32, the second transmission unit 33, computing unit 36 and calibration unit 37:
First transmission unit 31, in the first moment sending time sync message and the first time information.
First receiving unit 32, for being based on the time synchronization terminal, when first described in the second reception
Carve information.
Second transmission unit 33, for sending third time information at the third moment.
Second receiving unit 34 is used for the third time information described in the 4th reception.
The third transmission unit 35, for sending the 4th time information.
The computing unit 36, for according to first moment, second moment, third moment and described
4th moment calculated main time synchronization terminal and from the time difference between time synchronization terminal.
The calibration unit 37, for according to the time difference, the calibration time from time synchronization terminal.
Optionally, the main time synchronization terminal and the time difference expression formula between time synchronization terminal are as follows:
Wherein, T1 indicates first moment, and T2 indicates second moment, and T3 indicates the third moment, and T4 is indicated
4th moment, Δ T indicate the time difference, and T0 indicates time delay.
Optionally, the system also includes PTP transmitting devices, and the PTP transmitting device includes receiving module and forwarding
Module, first transmission unit 31 include release module:
The release module, for issuing the time synchronization message at first moment.
The receiving module, for receiving the time synchronization message.
The forwarding module, for forwarding the time synchronization message.
The embodiment of the present invention provides a kind of clock synchronization system, as shown in figure 5, the system comprises main time synchronization terminals
With from time synchronization terminal, the main time synchronization terminal includes the first transmission unit 41, the second receiving unit 44, computing unit
46 and the 4th send list 47, described to send from time synchronization terminal including the first receiving unit 42, the second transmission unit 43, third
Unit 45 and calibration unit 48:
First transmission unit 41 is used in the first moment issuing time sync message, and sends the first time information.
First receiving unit 42 is used for the first time information described in the second reception.
Second transmission unit 43, for sending third time information at the third moment.
Second receiving unit 44 is used for the third time information described in the 4th reception.
The third transmission unit 45, for sending the second time information.
The computing unit 46, for according to first moment, second moment, third moment and described
4th moment calculated main time synchronization terminal and from the time difference between time synchronization terminal.
4th transmission unit 47, for sending the time difference.
The calibration unit 48, for according to the time difference, calibration to be described from time synchronization terminal time.
It is apparent to those skilled in the art that for convenience and simplicity of description, the system of foregoing description,
The specific work process of device and unit, can refer to corresponding processes in the foregoing method embodiment, and details are not described herein.
In several embodiments provided by the present invention, it should be understood that disclosed system, device and method can be with
It realizes by another way.For example, the apparatus embodiments described above are merely exemplary, for example, the unit
It divides, only a kind of logical function partition, there may be another division manner in actual implementation, for example, multiple units or group
Part can be combined or can be integrated into another system, or some features can be ignored or not executed.Another point, it is shown
Or the mutual coupling, direct-coupling or communication connection discussed can be through some interfaces, device or unit it is indirect
Coupling or communication connection can be electrical property, mechanical or other forms.
The unit as illustrated by the separation member may or may not be physically separated, aobvious as unit
The component shown may or may not be physical unit, it can and it is in one place, or may be distributed over multiple
In network unit.It can select some or all of unit therein according to the actual needs to realize the mesh of this embodiment scheme
's.
It, can also be in addition, the functional units in various embodiments of the present invention may be integrated into one processing unit
It is that each unit physically exists alone, can also be integrated in one unit with two or more units.Above-mentioned integrated list
Member both can take the form of hardware realization, can also realize in the form of hardware adds SFU software functional unit.
The above-mentioned integrated unit being realized in the form of SFU software functional unit can store and computer-readable deposit at one
In storage media.Above-mentioned SFU software functional unit is stored in a storage medium, including some instructions are used so that a computer
It is each that device (can be personal computer, server or network equipment etc.) or processor (Processor) execute the present invention
The part steps of embodiment the method.And storage medium above-mentioned includes: USB flash disk, mobile hard disk, read-only memory (Read-
Only Memory, ROM), random access memory (Random Access Memory, RAM), magnetic or disk etc. it is various
It can store the medium of program code.
The foregoing is merely illustrative of the preferred embodiments of the present invention, is not intended to limit the invention, all in essence of the invention
Within mind and principle, any modification, equivalent substitution, improvement and etc. done be should be included within the scope of the present invention.
Claims (10)
1. a kind of method for synchronizing time is suitable for clock synchronization system, the clock synchronization system includes main time synchronization terminal
With from time synchronization terminal, which is characterized in that the described method includes:
The main time synchronization terminal, at the first moment to described from time synchronization terminal sending time sync message and first
Time information;
It is described from time synchronization terminal, be based on the time synchronization message, the main time synchronization terminal described in the second reception
The first time information sent;
It is described from time synchronization terminal, send third time information to the main time synchronization terminal at the third moment;
The main time synchronization terminal, the third time information sent from time synchronization terminal described in the 4th reception;
The main time synchronization terminal sends the 4th time information to described from time synchronization terminal;
It is described from time synchronization terminal, according to first moment, second moment, the third moment and the described 4th
Moment calculates the main time synchronization terminal and the time difference between time synchronization terminal;
It is described that temporal is calibrated according to the time difference from time synchronization terminal.
2. the method according to claim 1, wherein the main time synchronization terminal is with described from time synchronization end
Time difference expression formula between end are as follows:
Wherein, T1 indicates first moment, and T2 indicates second moment, and T3 indicates the third moment, described in T4 expression
4th moment, Δ T indicate the time difference, and T0 indicates time delay.
3. the method according to claim 1, wherein the number of the main time synchronization terminal be 1, it is described from
The number of time synchronization terminal is one or more.
4. according to the method described in claim 3, when it is described from the number of time synchronization terminal be it is multiple when, which is characterized in that
The clock synchronization system further includes Precision Time Protocol PTP transmitting device, the method also includes:
The main time synchronization terminal issues the time synchronization message to the PTP transmitting device at first moment;
The PTP transmitting device receives the time synchronization message that the main time synchronization terminal is sent;
The time synchronization message is forwarded to multiple described from time synchronization terminal by the PTP transmitting device.
5. the method according to claim 1, wherein the clock synchronization system includes: the connection regional network time
At least one of synchronization system, moving area net clock synchronization system or telecommunications regional network clock synchronization system.
6. a kind of method for synchronizing time is suitable for clock synchronization system, the clock synchronization system includes main time synchronization terminal
With from time synchronization terminal, which is characterized in that the described method includes:
The main time synchronization terminal is sent in the first moment issuing time sync message, and to described from time synchronization terminal
First time information;
It is described from time synchronization terminal, be based on the time synchronization message, the main time synchronization terminal described in the second reception
The first time information sent;
It is described from time synchronization terminal, send third time information to the main time synchronization terminal at the third moment;
The main time synchronization terminal, the third time information sent from time synchronization terminal described in the 4th reception;
It is described from time synchronization terminal, send the second time information to the main time synchronization terminal;
The main time synchronization terminal, according to first moment, second moment, the third moment and the described 4th
Moment calculates the main time synchronization terminal and the time difference between time synchronization terminal;
The time difference is sent to described from time synchronization terminal by the main time synchronization terminal;
It is described that temporal is calibrated according to the time difference from time synchronization terminal.
7. a kind of clock synchronization system, which is characterized in that the system comprises main time synchronization terminal and from time synchronization terminal,
The main time synchronization terminal includes the first transmission unit, the second receiving unit and third transmission unit, described from time synchronization
Terminal includes the first receiving unit, the second transmission unit, computing unit and calibration unit:
First transmission unit, in the first moment sending time sync message and the first time information;
First receiving unit, for being based on the time synchronization message, the first time information described in the second reception;
Second transmission unit, for sending third time information at the third moment;
Second receiving unit is used for the third time information described in the 4th reception;
The third transmission unit, for sending the 4th time information;
The computing unit, for according to first moment, second moment, the third moment and it is described 4th when
It carves, calculates main time synchronization terminal and from the time difference between time synchronization terminal;
The calibration unit, for according to the time difference, the calibration time from time synchronization terminal.
8. system according to claim 7, which is characterized in that the main time synchronization terminal is with described from time synchronization end
Time difference expression formula between end are as follows:
Wherein, T1 indicates first moment, and T2 indicates second moment, and T3 indicates the third moment, described in T4 expression
4th moment, Δ T indicate the time difference, and T0 indicates time delay.
9. system according to claim 7, which is characterized in that the system also includes PTP transmitting device, the PTP is passed
Defeated device includes receiving module and forwarding module, and first transmission unit includes release module:
The release module, for issuing the time synchronization message to the PTP transmitting device at first moment;
The receiving module, for receiving the time synchronization message;
The forwarding module, for forwarding the time synchronization message.
10. a kind of clock synchronization system, which is characterized in that the system comprises main time synchronization terminal and from time synchronization end
End, the main time synchronization terminal include the first transmission unit, the second receiving unit, computing unit and the 4th transmission unit, institute
Stating from time synchronization terminal includes the first receiving unit, the second transmission unit, third transmission unit and calibration unit:
First transmission unit is used in the first moment issuing time sync message, and sends the first time information;
First receiving unit, for being based on the time synchronization message, the first time information described in the second reception;
Second transmission unit, for sending third time information at the third moment;
Second receiving unit is used for the third time information described in the 4th reception;
The third transmission unit, for sending the second time information;
The computing unit, for according to first moment, second moment, the third moment and it is described 4th when
It carves, calculates main time synchronization terminal and from the time difference between time synchronization terminal;
4th transmission unit, for sending the time difference;
The calibration unit, for according to the time difference, calibration to be described from time synchronization terminal time.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201810970327.XA CN109068384A (en) | 2018-08-23 | 2018-08-23 | A kind of method for synchronizing time and system |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201810970327.XA CN109068384A (en) | 2018-08-23 | 2018-08-23 | A kind of method for synchronizing time and system |
Publications (1)
Publication Number | Publication Date |
---|---|
CN109068384A true CN109068384A (en) | 2018-12-21 |
Family
ID=64756682
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201810970327.XA Pending CN109068384A (en) | 2018-08-23 | 2018-08-23 | A kind of method for synchronizing time and system |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN109068384A (en) |
Cited By (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN111208866A (en) * | 2019-12-27 | 2020-05-29 | 视联动力信息技术股份有限公司 | System time adjusting method and device |
WO2020143571A1 (en) * | 2019-01-09 | 2020-07-16 | 华为技术有限公司 | Synchronization method and apparatus |
WO2021147042A1 (en) * | 2020-01-22 | 2021-07-29 | 华为技术有限公司 | Time synchronization method and device |
Citations (11)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN101790230A (en) * | 2009-01-23 | 2010-07-28 | 华为技术有限公司 | Precision time protocol node, time stamp operation method and time synchronization system |
CN102195766A (en) * | 2010-03-01 | 2011-09-21 | 杭州华三通信技术有限公司 | Time synchronization method and clock device |
CN102457371A (en) * | 2010-10-27 | 2012-05-16 | 华为技术有限公司 | Time synchronization method and related equipment and system |
CN102546071A (en) * | 2011-12-23 | 2012-07-04 | 北京北方烽火科技有限公司 | Clock synchronization method and system |
CN102833062A (en) * | 2012-09-25 | 2012-12-19 | 广东电网公司珠海供电局 | Time synchronization method and system for synchronous messages of IEEE1588 (Precision Time Protocol) master-slave clocks of intelligent transformer substation |
US20130301634A1 (en) * | 2012-05-11 | 2013-11-14 | Kristian Ehlers | Timing synchronization for networks with radio links |
CN104467928A (en) * | 2013-09-18 | 2015-03-25 | 华为技术有限公司 | Method and equipment for cooperation between terminal equipment |
CA2960299A1 (en) * | 2014-09-12 | 2016-03-17 | Siemens Canada Limited | Clock synchronization over redundant networks |
CN106488550A (en) * | 2016-12-20 | 2017-03-08 | 华为技术有限公司 | Determine the method and apparatus of terminal and base station clock time deviation |
CN106604383A (en) * | 2015-10-15 | 2017-04-26 | 中兴通讯股份有限公司 | Time synchronization method, main time synchronization device and communication system |
CN106921456A (en) * | 2015-12-24 | 2017-07-04 | 中国科学院沈阳自动化研究所 | Multi-hop wireless backhaul network time synchronization error compensation method based on PTP protocol |
-
2018
- 2018-08-23 CN CN201810970327.XA patent/CN109068384A/en active Pending
Patent Citations (11)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN101790230A (en) * | 2009-01-23 | 2010-07-28 | 华为技术有限公司 | Precision time protocol node, time stamp operation method and time synchronization system |
CN102195766A (en) * | 2010-03-01 | 2011-09-21 | 杭州华三通信技术有限公司 | Time synchronization method and clock device |
CN102457371A (en) * | 2010-10-27 | 2012-05-16 | 华为技术有限公司 | Time synchronization method and related equipment and system |
CN102546071A (en) * | 2011-12-23 | 2012-07-04 | 北京北方烽火科技有限公司 | Clock synchronization method and system |
US20130301634A1 (en) * | 2012-05-11 | 2013-11-14 | Kristian Ehlers | Timing synchronization for networks with radio links |
CN102833062A (en) * | 2012-09-25 | 2012-12-19 | 广东电网公司珠海供电局 | Time synchronization method and system for synchronous messages of IEEE1588 (Precision Time Protocol) master-slave clocks of intelligent transformer substation |
CN104467928A (en) * | 2013-09-18 | 2015-03-25 | 华为技术有限公司 | Method and equipment for cooperation between terminal equipment |
CA2960299A1 (en) * | 2014-09-12 | 2016-03-17 | Siemens Canada Limited | Clock synchronization over redundant networks |
CN106604383A (en) * | 2015-10-15 | 2017-04-26 | 中兴通讯股份有限公司 | Time synchronization method, main time synchronization device and communication system |
CN106921456A (en) * | 2015-12-24 | 2017-07-04 | 中国科学院沈阳自动化研究所 | Multi-hop wireless backhaul network time synchronization error compensation method based on PTP protocol |
CN106488550A (en) * | 2016-12-20 | 2017-03-08 | 华为技术有限公司 | Determine the method and apparatus of terminal and base station clock time deviation |
Cited By (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
WO2020143571A1 (en) * | 2019-01-09 | 2020-07-16 | 华为技术有限公司 | Synchronization method and apparatus |
CN111432465A (en) * | 2019-01-09 | 2020-07-17 | 华为技术有限公司 | Synchronization method and device |
CN111208866A (en) * | 2019-12-27 | 2020-05-29 | 视联动力信息技术股份有限公司 | System time adjusting method and device |
WO2021147042A1 (en) * | 2020-01-22 | 2021-07-29 | 华为技术有限公司 | Time synchronization method and device |
CN114868354A (en) * | 2020-01-22 | 2022-08-05 | 华为技术有限公司 | Time synchronization method and device |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
US11496235B2 (en) | Symmetric path/link over LAG interface using LLDP for time synchronization between two nodes using PTP | |
US9742514B2 (en) | Method, apparatus, and system for generating timestamp | |
TW432838B (en) | Synchronization for cellular telecommunications network | |
CN109756430A (en) | A kind of processing method and processing device of rule | |
WO2014083640A1 (en) | Communication apparatus, communication system and time synchronization method | |
US10778359B2 (en) | Time synchronization method, programmable logic device, single board and network element | |
US9900120B2 (en) | Clock synchronization method and apparatus | |
US20160080100A1 (en) | Method for precision time protocol synchronization network and apparatus | |
CN109068384A (en) | A kind of method for synchronizing time and system | |
CN109996325B (en) | Clock synchronization system and method of wireless sensor network | |
CN101170373A (en) | Clock synchronization realization method for loop network | |
CN105228178B (en) | A kind of aircraft environment parameter detecting system and detection method based on wireless communication | |
EP3174237B1 (en) | Time synchronization method and apparatus for network devices and time synchronization server | |
CN110785984A (en) | Information acquisition method, information acquisition device and electronic equipment | |
CN103188064A (en) | Clock synchronization method and clock synchronization device | |
US20230291489A1 (en) | Methods, systems and apparatuses for 5g time synchronization | |
CN108834435B (en) | Method, node and computer readable medium for controlling transmission timing | |
CN108243396B (en) | Time synchronization processing method and device | |
CN112235861B (en) | Time synchronization method, time synchronization system and equipment suitable for self-organizing network | |
US10250477B2 (en) | Method and controller for announcing bandwidth of cluster system | |
CN103516454A (en) | Clock synchronization method, device and communication apparatus | |
JP6616184B2 (en) | Data transmission method and apparatus | |
CN104411011B (en) | Femto cell, clock server time service, synchronous method and system | |
CN105119675B (en) | A kind of synchronous method and synchronization system of target device | |
CN107005991B (en) | Transmission method, terminal device, base station and the communication system of upstream data packet |
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 | ||
RJ01 | Rejection of invention patent application after publication | ||
RJ01 | Rejection of invention patent application after publication |
Application publication date: 20181221 |