A high-precision master-slave time synchronization method suitable for time synchronization networks

Through the master-slave time synchronization method, by introducing a hot backup mechanism of high-precision master nodes and backup master nodes, the problem of insufficient clock accuracy and reliability in the time synchronization network is solved, and high-precision and stable time synchronization is achieved.

CN116232512BActive Publication Date: 2025-09-19CHINESE AERONAUTICAL RADIO ELECTRONICS RES INST
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202211162377.8
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-09-23
Publication Date
2025-09-19
Estimated Expiration
2042-09-23

AI Technical Summary

Technical Problem

Existing time synchronization networks suffer from problems such as decreased clock accuracy, high synchronization complexity, and insufficient reliability. Especially in TTE and TSN networks, the complex state machine of the SM and the uncertainty of the path delay measurement of the CM lead to unstable network synchronization.

Method used

A high-precision master-slave time synchronization method is adopted. Through the hot backup mechanism of the master node and the backup master node, combined with a two-step time synchronization operation, high-precision time correction and path delay measurement are achieved, reducing the complexity and communication overhead of network time synchronization.

Benefits of technology

It improves the accuracy and reliability of time synchronization, simplifies the cold start process of synchronization nodes, and ensures that the network can still maintain high-precision time synchronization when the master node fails.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN116232512B_ABST
    Figure CN116232512B_ABST
Patent Text Reader

Abstract

The present invention belongs to the field of communication technology and discloses a high-precision master-slave time synchronization method suitable for a time synchronization network. The method includes: in a network topology with a master node as the root node, a slave node and / or a backup master node sends a synchronization frame to the master node; the master node solidifies the received synchronization frame, calculates a solidified time point, encapsulates the solidified time point in a new synchronization frame, and sends the new synchronization frame to the slave node and / or the backup master node. After the synchronization establishment phase is completed, the master node uses the solidified time point of the first synchronization frame sent back to the slave node and / or the backup master node as the start time, and periodically sends synchronization frames to the slave node and / or the backup master node. The method can provide a high-precision time synchronization service and a fault-tolerant time synchronization service based on a backup master clock for the time synchronization network.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention belongs to the field of communication technology, and in particular relates to a high-precision master-slave time synchronization method suitable for a time synchronization network. Background Art

[0002] The SAE AS6802 standard, developed by the American Automobile Manufacturers Association, defines a distributed time synchronization protocol for Time-Triggered Ethernet (TTE). The SAE AS6802 standard specifies three different synchronization roles: the Synchronization Master (SM), the Synchronization Client (SC), and the Compression Master (CM). End systems are typically configured as SMs and SCs, while switches are typically configured as CMs. Synchronization nodes (SMs, SCs, and CMs) with the same synchronization priority within the same synchronization domain form a cluster. The SAE AS6802 standard specifies a two-step time synchronization method. In the first step, the SM sends a protocol control frame (PCF) to the CMs within the cluster at the start of the synchronization cycle, requesting synchronization. This PCF frame carries transparent clock information. In the second step, the CM extracts the transparent clock information from the PCF frame and executes a fixed-time algorithm to obtain a fixed time point. The fixed time point is then compressed using a fault-tolerant averaging algorithm across all PCF frames sent by the SMs within the cluster to obtain a compressed time point. The CM derives the dispatch time based on the compression time and sends the compressed PCF to the SM and SC at the dispatch time. The SM and SC solidify the PCF frame sent by the CM and compare the solidified time of the PCF frame with the expected time to obtain the clock correction factor for the local clock, which is used to adjust the local clock. The CM also calculates the compression time and the expected time defined by the local clock and performs local clock correction operations, thus completing time synchronization for all synchronized nodes in the cluster.

[0003] The IEEE 802.1AS-2020 standard, launched by the Institute of Electrical and Electronics Engineers (IEEE), provides a time synchronization method for Time-Sensitive Networks (TSN). IEEE 802.1AS-2020 specifies a master-slave time synchronization protocol. This protocol operates in two phases: clock offset measurement and path delay measurement. The first phase, known as the clock offset measurement phase, measures the time deviation between the master and slave clocks. Step 1: The master clock periodically sends synchronization frames to each slave clock at pre-set intervals. These frames carry an estimated time from the master clock. The slave clock records the exact time of receipt of the synchronization frame as t2. Step 2: The master clock broadcasts a follow-up message, which is associated with the synchronization frame and contains the precise timestamp t0 of when the synchronization frame was sent to the communication path. The slave clock receives the follow-up frame and obtains the timestamp t0. The second phase of the synchronization process is the delay measurement phase, which measures the path transmission delay between the master and slave clocks. First, the slave clock sends a delay request message to the master clock, marking it with the exact sending timestamp t4. The master clock receives the delay request message, marks it with the exact receiving timestamp t5, and writes this timestamp value into the delay response frame it subsequently sends. Next, the master clock sends a delay response frame to the slave clock. The slave clock receives the delay response frame and parses it to obtain the value of t5. Based on t0 and t2, combined with t4 and t5, the network transmission delay between the slave clock and the master clock is calculated.

[0004] In a TTE network, the SM's synchronization state machine has a cumulative total of eight synchronization states, while the CM's synchronization state machine has a cumulative total of six synchronization states, and the SC's synchronization state machine has a cumulative total of three synchronization states. As the time source for the network's global clock reference, the SM's state machine is overly complex. From a cold start, it requires a cumulative three rounds of synchronization frame exchanges with the CM to achieve normal synchronization, which is time-consuming. In a TSN network, there is only one master clock within a domain. The master clock periodically sends time synchronization messages to synchronize slave clocks, and the slave clocks also send synchronization measurement frames to measure path delays. Due to the unequal round-trip path delays, averaging introduces uncertainty in path measurement, resulting in reduced clock accuracy. Furthermore, since there is only one master clock in the network, if the master clock fails, each clock uses the best master clock algorithm to select a new master clock. This results in a period of time without a master clock in the network, causing synchronization nodes to lose synchronization, potentially compromising the determinism and real-time nature of time-critical messages, and leading to other network failures such as packet loss. In order to achieve high-precision time synchronization, reduce the communication overhead of network time synchronization, and improve the reliability of time synchronization, the present invention proposes a high-precision master-slave time synchronization method. Summary of the Invention

[0005] The purpose of the present invention is to provide a high-precision master-slave time synchronization method suitable for a time synchronization network, so as to solve the problem of high-precision time synchronization, while ensuring the reliability of network time synchronization and reducing the complexity of time synchronization.

[0006] The technical solution of the present invention:

[0007] A high-precision master-slave time synchronization method applicable to a time synchronization network, the method comprising:

[0008] Establish synchronization phase:

[0009] Step 1: After a cold start or re-request to establish synchronization, the slave node and / or backup master node sends a synchronization frame to the master node in the network;

[0010] Step 2: The master node receives the synchronization frame sent by the slave node and / or the backup master node, solidifies the synchronization frame, and then uses the solidified time point of the synchronization frame sent by the slave node and / or the backup master node as the dispatch time point. The solidified time point is encapsulated as a timestamp in the synchronization frame and dispatched to the slave node and / or the backup master node;

[0011] Step 3: The slave node and / or the backup master node calculates a primary correction factor and a secondary correction factor; the two correction factors are added together to obtain a new time correction factor to correct the local clock;

[0012] Maintain synchronization phase:

[0013] Step 4: At the end of the synchronization phase, the master node dispatches synchronization frames to the slave node and / or backup master node every other synchronization period, starting from the dispatch time of the first synchronization frame sent to the slave node and / or backup master node.

[0014] Step 5: The slave node and / or the backup master node calculates a time correction factor to correct the local clock.

[0015] The characteristics and further improvements of the technical solution of the present invention are:

[0016] (1) A high-precision clock source synchronization node capable of synchronizing the timing of other nodes in the network serves as the master node. The master nodes in the network are divided according to priority, with the master node with the highest priority in the current network serving as the current master node. When the network is operating normally, all synchronization nodes except the master node only accept the clock source information of the current master node to calibrate their own local clocks, and the remaining master nodes perform hot backup time synchronization operations and serve as backup master nodes.

[0017] Each backup master node only receives synchronization frames from the current master node to calibrate its own local clock, and does not receive synchronization frames from other backup master nodes to calibrate its own local clock. If the current master node fails or no longer functions, the backup master node with the highest current level will take over as the current master node.

[0018] (2) a synchronization node that receives a synchronization frame from the master node and performs time synchronization operations based on the time synchronization information of the master node contained in the synchronization frame, serving as a slave node;

[0019] When the network is operating normally, the slave node also receives synchronization frames from the backup master node, but only uses the time information of the synchronization frame sent by the current master node to correct the local clock. It does not use the time information of the synchronization frame sent by the backup master node to correct the local clock and only performs hot backup processing; if the current master node fails, or loses power, or no longer works, the slave node will use the time information of the synchronization frame from the highest-level backup master node to correct the local clock, and report the synchronization failure information to all backup master nodes in the network.

[0020] (3) The timing accuracy of the master node should be higher than the timing accuracy of the remaining slave nodes in the network, and the total number of the master nodes should be at least 2.

[0021] (4) According to the distance from the main node M p The number of hops is used to perform network level calculation on the synchronization nodes. k}division;

[0022] The master node is regarded as the root node of all synchronization nodes in the entire switching network and is recorded as level 10 in the hierarchy. p belongs to l k The synchronization node SD of level 1 is denoted as The subscript k indicates the level;

[0023] Each master node regularly updates and maintains the network topology with itself as the root node.

[0024] (5) In step 3,

[0025] The slave node and / or backup master node extracts the solidified time point encapsulated in the synchronization frame sent by the master node, compares it with the first expected solidified time point of the local clock, and calculates the main correction factor; and solidifies the synchronization frame sent by the master node to obtain the solidified time point, compares it with the second expected solidified time point of the local clock, and calculates the secondary correction factor. The two time correction factors are accumulated to obtain a new time correction factor to correct the local clock.

[0026] (6) Step 5 is as follows:

[0027] The slave node solidifies the synchronization frame sent by the master node, obtains the solidified time point, compares it with the expected solidified time point of the local clock, and calculates the time correction factor to correct the local clock. If the solidified time point of the synchronization frame sent by the master node does not fall within the time window set by the slave node, the local clock is corrected based on the solidified time point of the synchronization frame sent by the master node with the highest level that falls within the time window.

[0028] The backup master node solidifies the synchronization frame sent by the current master node, obtains the solidification time point, compares it with the expected solidification time point of the local clock, calculates the time correction factor, and uses it to correct the local clock; if the solidification time point of the synchronization frame sent by the current master node does not fall within the time window set by the backup master node, the current backup master node requests the master node with the highest level in the network to establish a synchronization operation.

[0029] (7) In the synchronization maintenance phase, the master node M p In a network topology with a root node as the root node, an observation window with a length of δ is opened on both sides of any expected solidification time pre-set by the slave node and / or the backup master node to form a time window centered on the expected solidification time. Therefore, the length of a time window TW = 2×δ.

[0030] The present invention is applicable to master-slave time synchronization in a time synchronization network with multiple master clocks. The advantages of the method are:

[0031] (1) The method of the present invention fully considers the characteristics of network time synchronization and provides a master-slave time synchronization method suitable for switching networks connected in various topologies such as star and ring.

[0032] (2) The method of the present invention takes into account the characteristics of path delay and provides a synchronization method that can achieve high-precision path delay measurement, eliminate the asymmetry and introduced uncertainty of the synchronization round-trip path delay, and improve the accuracy of time synchronization.

[0033] (3) The method of the present invention takes into account the complexity of the network time synchronization mechanism and proposes a two-step master-slave time synchronization operation, which simplifies the synchronization operation after the synchronization node is cold started, shortens the cold start time of the synchronization node, and at the same time ensures that the local clock has very high time accuracy after synchronization is established between the master and slave nodes.

[0034] (4) The two-stage master-slave time synchronization method provided by the method of the present invention is that the current master node synchronizes time with all backup master nodes and slave nodes, thereby improving the accuracy of time synchronization. At the same time, the master node adopts periodic single-step timing operation to reduce communication overhead, and adopts a hot backup mechanism based on the backup master clock to improve the reliability and robustness of the time synchronization mechanism of the network slave nodes. BRIEF DESCRIPTION OF THE DRAWINGS

[0035] Figure 1 is a schematic diagram of the network physical topology of the present invention;

[0036] Figure 2 It is a tree network topology with the master node M1 as the root node;

[0037] Figure 3 It is a tree network topology with the master node M2 ​​as the root node;

[0038] Figure 4 It is a frame interaction diagram of the time synchronization between the current master node and other synchronization nodes;

[0039] Figure 5 It is a frame interaction diagram of the time synchronization between the backup master node and other slave nodes;

[0040] Figure 6 The present invention proposes a master-slave time synchronization method based on a backup master clock applicable to a time synchronization network. DETAILED DESCRIPTION

[0041] The present invention will be further described in detail below with reference to the accompanying drawings and embodiments.

[0042] In this invention, a high-precision clock source synchronization node capable of synchronizing time with other network nodes is referred to as a master node. Master nodes in the network are prioritized, with the highest-ranking master node serving as the current master node. During normal network operation, all synchronization nodes other than the master node only use clock source information from the current master node to calibrate their local clocks. The remaining master nodes perform hot backup time synchronization operations and are referred to as backup master nodes.

[0043] In the present invention, each backup master node only receives synchronization frames from the current master node to correct its own local clock, and does not receive synchronization frames from other backup master nodes to correct its own local clock. If the current master node fails or no longer functions, the backup master node with the highest current level will be replaced as the current master node.

[0044] In the present invention, a synchronization node that receives synchronization frames from a master node and performs time synchronization based on the master node's time synchronization information contained in the synchronization frames is referred to as a slave node. During normal network operation, the slave node also receives synchronization frames from backup master nodes, but only uses the time information from the synchronization frames sent by the current master node to calibrate its local clock, not the time information from the synchronization frames sent by the backup master nodes, thus performing only hot backup operations. If the current master node fails, loses power, or otherwise ceases to function, the slave node will use the time information from the synchronization frames of the highest-ranked backup master node to calibrate its local clock and simultaneously report synchronization failure information to all backup master nodes in the network.

[0045] In the present invention, the current master node periodically sends synchronization frames to all slave nodes and backup master nodes, and each backup master node periodically sends synchronization frames to all slave nodes. For example, Figure 1 Shown is the physical connection topology of the time synchronization network.

[0046] In the present invention, the network nodes in the time synchronization network are either master nodes or slave nodes, that is, all nodes in the network participate in the time synchronization operation.

[0047] In the present invention, the timing accuracy of the master node should be higher than the timing accuracy of the remaining slave nodes in the network, and the total number of master nodes is usually at least 2 or more.

[0048] In the present invention, the physical topology of the time synchronization network includes multiple synchronization nodes, which are recorded in the form of a set as SD = {M1, M2, M3, ..., M p ,S1,S2,S3,…,S q}, M1 represents the first master node in SD, M2 represents the second master node in SD, M3 represents the third master node in SD, M p Indicates the last master node in the SD, and the subscript p indicates the identification number of the master node in the SD. For the convenience of explanation, M p It also means belonging to any master node in SD; S1 means belonging to the first slave node in SD, S2 means belonging to the second slave node in SD, S3 means belonging to the third slave node in SD, S q Indicates the last slave node in SD, and the subscript q indicates the identification number of the slave node in SD. For the convenience of explanation, S q It also represents any slave node in SD.

[0049] In the present invention, the master nodes are identified in order of priority, that is, M1 represents the first-level master node, M2 represents the second-level master node, M3 represents the third-level master node, and M p Indicates the last level master node, and the subscript p indicates the identification number of the p-th level master node. In the present invention, the currently active master node with the highest level is the current master node, and the remaining master nodes are backup master nodes.

[0050] In the present invention, according to the distance from the main node M p The number of hops Hops is used to perform network level calculation on the synchronization nodes Level={l0,l1,l2,…,l k In the present invention, the master node is regarded as the root node of all synchronization nodes in the entire switching network, and is recorded as level 10 in the hierarchy. Located at any master node M p belongs to l k The synchronization node SD of level 1 is denoted as The subscript k indicates the level. For the convenience of explanation, l k Represents any hierarchy. Each master node regularly updates and maintains the network topology with itself as the root node.

[0051] like Figure 2 As shown in the figure, a tree network topology is established with the current master node M1 as the root node. The backup master node M2 ​​and the slave nodes S1 and S2 all request time synchronization from the current master node M1. Then:

[0052] The master node M1 belongs to the root node of the network topology at level l0, which is recorded as

[0053] The slave node S1 in the one-hop path from the current master node M1 is recorded as the slave node of level l1 The slave node S2 in the single-hop path from the current master node M1 is recorded as the slave node of level l1

[0054] The backup master node M2 ​​in the two-hop path from the current master node M1 is recorded as the backup master node at level l2.

[0055] like Figure 3 The tree network topology is established with the master node M2 ​​as the root node. The slave nodes S1 and S2 also request time synchronization from the backup master node M2. Then:

[0056] The master node M2 ​​belongs to the root node of the network topology at level l0, which is recorded as

[0057] The slave node S1 in the single-hop path from the backup master node M2 ​​is recorded as the slave node of level l1 The slave node S2 in the single-hop path from the backup master node M2 ​​is recorded as the slave node of level l1

[0058] In the present invention, the current master node does not request a time synchronization operation from the backup master node.

[0059] In the present invention, the time synchronization period T sync The definition of can refer to the integration cycle of SAE AS6802 standard protocol. Each time synchronization cycle T sync Time 0 is recorded as the synchronization cycle start time. At the synchronization cycle start time, the current master node dispatches synchronization frames to the backup master node and the slave node for timing synchronization operation, and the backup master node dispatches synchronization frames to the slave node for timing synchronization operation.

[0060] In the present invention, since the time when each slave node and / or backup master node establishes time synchronization is not necessarily the same, the time when the synchronization cycle of each slave node and / or backup master node starts is not necessarily the same.

[0061] In the present invention, referring to the SAE AS6802 standard protocol, the dispatch time It refers to the moment when one synchronization node SD sends a synchronization frame to another synchronization node.

[0062] In the present invention, the time synchronization operation is divided into two stages: the first stage is the synchronization establishment stage, and the second stage is the synchronization maintenance stage.

[0063] In the present invention, during the synchronization establishment phase, each slave node sends a synchronization frame to all master nodes. After receiving the synchronization frame, the master node sends a new synchronization frame to each slave node. Each slave node corrects its local clock based on the information in the synchronization frame. At this point, each slave node is synchronized with each master node. During the synchronization establishment phase, each backup master node sends a synchronization frame to the current master node. After receiving the synchronization frame, the current master node sends a new synchronization frame to each backup master node. After receiving the synchronization frame, the current master node sends a new synchronization frame to each backup master node. Each backup master node corrects its local clock based on the information in the synchronization frame. At this point, each backup master node is synchronized with the current master node.

[0064] In the present invention, during the synchronization maintenance phase, the master node sends synchronization frames to each slave node every synchronization cycle starting from the dispatching moment of the synchronization frame sent back to each slave node during the synchronization establishment phase; during the synchronization maintenance phase, the current master node sends synchronization frames to each backup master node every synchronization cycle starting from the dispatching moment of the synchronization frame sent back to each backup master node during the synchronization establishment phase.

[0065] In the present invention, referring to the SAE AS6802 standard protocol, the time synchronization accuracy δ refers to the maximum difference between the local clocks of any two synchronization nodes in a time synchronization cycle.

[0066] In this invention, the definition of the maximum single-hop transmission delay (SHWD) can refer to the maximum transmission delay in the SAE AS6802 standard protocol. The maximum value of the accumulated transparent clock value in a synchronization frame transmitted by any synchronization node in the network to any adjacent node, after the adjacent node completes the solidification operation on the synchronization frame, is called the maximum single-hop transmission delay (SHWD).

[0067] In the present invention, the synchronization nodes in the network may perform transparent clock mechanism operations on the synchronization frames with reference to the SAE AS6802 standard protocol.

[0068] In the present invention, referring to the SAE AS6802 standard or IEEE 802.1 AS-2020, the synchronization frame It means that any master node M p The network topology where the root node belongs to l k Level synchronization node To the master node M p The data frame sent contains transparent clock information. The SD before the subscript arrow in the figure indicates the identity of the node that sends the synchronization frame. The SD after the subscript arrow indicates the identity of the synchronization node that sends the synchronization frame. SD is a slave node and / or a backup master node. If SD is a backup master node, then M p The current master node.

[0069] For example, It represents a synchronization frame sent by the slave node S2 belonging to level l1 in the network topology with the master node M1 as the root node to the master node M1.

[0070] In the present invention, referring to the SAE AS6802 standard or IEEE 802.1 AS-2020, the synchronization frame It means that any master node M p The master node M in the network topology is the root node p To belong to l k Level synchronization node The data frame sent contains transparent clock information. The SD before the subscript arrow in the figure indicates the identity of the node that sends the synchronization frame, and the SD after the subscript arrow indicates the identity of the node that receives the synchronization frame. SD is a slave node and / or a backup master node. If SD is a backup master node, then M p The current master node.

[0071] For example, It represents the synchronization frame sent by the master node M1 to the slave node S2 belonging to the level l1 in the network topology with the master node M1 as the root node.

[0072] In the present invention, the master node M p The root node belongs to l in the network topology k Any slave node and / or backup master node at the same level According to SAE AS6802 standard, the master node M p Incoming synchronization frame Perform solidification processing to obtain synchronization frame The curing time is recorded as The curing time The subscript SD in the sync node indicates the identity of the synchronization node. SD is a slave node and / or backup master node. If SD is a backup master node, then M p The current master node.

[0073] For example, Indicates the synchronization frame sent by the slave node S1 belonging to level l1 in the network topology with the master node M1 as the root node to the master node M1 The curing time obtained by performing the curing process.

[0074] In the present invention, the master node M p Any master node in the network topology that is the root node According to SAE AS6802 standard, k Any synchronization node at the level Synchronization frame Perform solidification processing to obtain synchronization frame The curing time is recorded as The curing time The superscript SD in the sync node indicates the identity of the synchronization node. SD can be a slave node and / or a backup master node. If SD is a backup master node, then M p The current master node.

[0075] For example, Indicates the synchronization frame sent by the master node M1 to the slave node S1 belonging to level l1 in the network topology with the master node M1 as the root node. The curing time obtained by performing the curing process.

[0076] In the present invention, in the synchronization phase, the master node M p The root node belongs to l in the network topology k Any slave node and / or backup master node at the same level Send synchronization frame To the master node M p Time synchronization is requested in the synchronization frame. The expected curing time is recorded as That is, any master node M p The network topology where the root node belongs to l k Any slave node and / or backup master node at the same level Pre-set master node M p Synchronization frame sent Expected solidification time The expected curing time The superscript SD in the sync node indicates the identity of the synchronization node. SD is a slave node and / or backup master node. If SD is a backup master node, then M p The current master node.

[0077] For example, Indicates the synchronization frame sent to the master node M1 by the local clock of the slave node S1 at level l1 in the network topology with the master node M1 as the root node during the synchronization establishment phase. The expected curing time.

[0078] In the present invention, in the synchronization phase, the master node M p Received Any slave node and / or backup master node at the same level Synchronization frame sent After that, the synchronization frame The solidified time point is the distribution time point, and a new synchronization frame is distributed To slave nodes and / or backup master nodes Then the slave node and / or backup master node Pre-set master node M p Send a new sync frame The expected curing time is recorded as The expected curing time The superscript SD in the sync node indicates the identity of the synchronization node. SD is a slave node and / or backup master node. If SD is a backup master node, then M p The current master node.

[0079] For example, Indicates the backup master node belonging to level l2 in the network topology with the current master node M1 as the root node The synchronization frame sent by the current master node M1 of the local clock setting The expected curing time.

[0080] In the present invention, the main correction factor It means that in the synchronization phase, the master node M p The root node belongs to l in the network topology k Secondary slave nodes and / or backup master nodes (Except the current master node) calculates its own preset synchronization frame The difference between the curing time and the expected curing time, that is, The main correction factor Subscript in The SD in the figure represents the identity of the synchronization node, and SD is the slave node and / or backup master node.

[0081] For example, Indicates the synchronization frame pre-set by the slave node S2 at level l1 in the network topology where the master node M1 is the root node and calculates its own local clock The difference between the curing time and the pre-curing time.

[0082] In the present invention, the secondary correction factor It means that in the synchronization phase, the master node M p The generated network topology belongs to l k Secondary slave nodes and / or backup master nodes (Except the master node) calculates its own preset synchronization frame The difference between the curing time and the pre-curing time, that is, The secondary correction factor Subscript in The SD in the figure represents the identity of the synchronization node, and SD is the slave node and / or backup master node.

[0083] For example, Indicates the synchronization frame preset by the slave node S1 at level l1 in the network topology where the master node M1 is the root node and calculates its own local clock. The difference between the curing time and the pre-curing time.

[0084] In the present invention, the time correction factor It means that during the synchronization maintenance phase, every time synchronization period T sync , with the master node M p The root node belongs to l in the network topology k Secondary slave nodes and / or backup master nodes Calculate the master node M p The expected scheduling time of the incoming synchronization frame and solidification moment The difference between The time correction factor Subscript in The SD in the figure represents the identity of the synchronization node, and SD is the slave node and / or backup master node.

[0085] For example, Indicates a synchronization node at level l1 in the network topology with the current master node M1 as the root node Calculate the expected scheduling time of the synchronization frame sent by the master node M1 and solidification moment The difference between .

[0086] In the present invention, referring to the SAE AS6802 standard, in the synchronization maintenance phase, the master node M p Any expected solidification time pre-set for the slave node and / or backup master node in the network topology of the root node An observation window is opened on each side of the The time window TW is the center, so the length of a time window is 2×δ, that is, TW=2×δ.

[0087] The present invention proposes a master-slave time synchronization method suitable for a time synchronization network with multiple master clocks. The method includes: in a network topology with a master node as the root node, slave nodes and / or backup master nodes sending synchronization frames to the master node; the master node then solidifies the received synchronization frames, calculates a solidified time point, encapsulates the solidified time point in a new synchronization frame, and sends the new synchronization frame to the slave nodes and / or backup master node. When the node sending the synchronization frame requesting synchronization is the backup master node, the master node receiving the synchronization frame is the current master node. Synchronous connections are now established between the slave node and the master node, and between the backup master node and the current master node. After the synchronization establishment phase is completed, the master node periodically sends synchronization frames to the slave nodes and / or backup master node, starting at the solidified time point of the first synchronization frame sent back to the slave node and / or backup master node. The network maintains high-precision, fault-tolerant, master-slave time synchronization based on the backup master clock. If a network node loses synchronization with the master node, the synchronization establishment phase is restarted to request synchronization.

[0088] See also Figure 6 As shown, a high-precision master-slave time synchronization method based on a backup master clock includes the following steps:

[0089] Phase 1: Establishing synchronization

[0090] Step 1: After a cold start or re-request to establish synchronization, the slave node and / or backup master node sends a synchronization frame to the master node in the network;

[0091] Step 2: The master node receives the synchronization frame sent by the slave node and / or the backup master node, solidifies the synchronization frame, and then uses the solidified time point of the synchronization frame sent by the slave node and / or the backup master node as the dispatch time point. The solidified time point is encapsulated into the synchronization frame as a timestamp and dispatched to the slave node and / or the backup master node;

[0092] Step 3: The slave node and / or backup master node extracts the fixed time point in the synchronization frame sent by the master node and compares it with the first expected fixed time point of the local clock to calculate the primary time correction factor. Simultaneously, the synchronization frame sent by the master node is fixed to obtain the fixed time point. This is compared with the second expected fixed time point of the local clock to calculate the secondary time correction factor. The two time correction factors are added together to obtain the new time correction factor to correct the local clock.

[0093] After the synchronization phase, the backup master node establishes time synchronization with the master node, and the slave node establishes time synchronization with the master node and the backup master node.

[0094] Phase 2: Maintaining synchronization

[0095] Step 4: At the end of the synchronization phase, the master node dispatches synchronization frames to the slave node and / or backup master node every other synchronization period, starting from the dispatch time of the first synchronization frame sent to the slave node and / or backup master node.

[0096] Step 5: The slave node and / or backup master node solidifies the synchronization frame sent by the master node to obtain a solidified time point, and then compares the solidified time point with the expected solidified time point of the local clock to calculate the time synchronization factor for correcting the local clock.

[0097] In the present invention, steps 1 to 5 are used to perform time synchronization on all synchronization nodes in the time synchronization network, and ultimately time synchronization of all synchronization nodes in the network is achieved.

[0098] The present invention proposes a master-slave time synchronization method based on a backup master clock, which can provide a high-precision time synchronization service for a time synchronization network.

[0099] Phase 1: Establishing synchronization

[0100] Step 1: After a cold start or re-request to establish synchronization, the slave node and / or backup master node sends a synchronization frame to the current master node in the network;

[0101] In the present invention, the time synchronization network uses the existing master node with the highest hierarchy as the current master node, and the remaining master nodes as backup master nodes. After a cold start or re-request to establish synchronization, each slave node sends a synchronization frame to each master node to request synchronization; each backup master node sends a synchronization frame to the current master node to request time synchronization.

[0102] Specifically, it belongs to k Secondary slave nodes and / or backup master nodes After a cold start or re-request to establish synchronization, dispatch a synchronization frame To the master node, request to establish time synchronization with the master node. For example, in the time synchronization network, Figure 1 The four synchronization nodes shown are composed of two master nodes and two slave nodes. Since the priority of master node M1 is higher than that of master node M2, master node M1 is the current master node of the network and master node M2 ​​is the backup master node.

[0103] See also Figure 1 、 Figure 2 、 Figure 4 As shown, after a cold start or re-request to establish synchronization, the network topology with the master node M1 as the root node is slave node To the master node Send synchronization frame Slave nodes To the master node Send synchronization frame Backup Master Node To the master node Send synchronization frame

[0104] See also Figure 1 、 Figure 3 、 Figure 5 As shown, after a cold start or re-request to establish synchronization, the network topology with the master node M2 ​​as the root node is slave node To the master node Send synchronization frame Slave nodes To the master node Send synchronization frame

[0105] Step 2: The master node receives the synchronization frame sent by the slave node and / or the backup master node, solidifies the synchronization frame, and then uses the solidified time point of the synchronization frame sent by the slave node and / or the backup master node as the dispatch time point. The solidified time point is encapsulated into the synchronization frame as a timestamp and dispatched to the slave node and / or the backup master node;

[0106] In the present invention, the master node receives synchronization frames from slave nodes and / or backup master nodes, solidifies the synchronization frames, and obtains the solidification time of the synchronization frames. Each backup master node sends synchronization frames to the current master node, and each slave node sends synchronization frames to the backup master node and the current master node.

[0107] Step 201: The master node solidifies the synchronization frame sent by the slave node and / or the backup master node to obtain the solidification time of the synchronization frame;

[0108] Specifically, in the present invention, the master node M p In the network topology where the root node is the master node, For l k Secondary slave nodes and / or backup master nodes Incoming synchronization frame Perform solidification processing, that is, the master node Extract synchronization frame The transparent clock information carried in the frame is processed according to the solidification method in the SAEAS6802 standard to obtain the synchronization frame. The solidification moment

[0109] For example, Figure 1 、 Figure 2、 Figure 4 As shown, based on the network topology generated by the master node M1,

[0110] Master Node Compute slave nodes Incoming synchronization frame For this synchronization frame Perform solidification processing to obtain synchronization frame The solidification moment

[0111] Master Node Compute slave nodes Incoming synchronization frame For this synchronization frame Perform solidification processing to obtain synchronization frame The solidification moment

[0112] Master Node Calculate backup primary point Incoming synchronization frame For this synchronization frame Perform solidification processing to obtain synchronization frame The solidification moment

[0113] For example, Figure 1 、 Figure 3 、 Figure 5 As shown, in the network topology with the backup master node M2 ​​as the root node,

[0114] Master Node Compute slave nodes Incoming synchronization frame For this synchronization frame Perform solidification processing to obtain synchronization frame The solidification moment

[0115] Master Node Compute slave nodes Incoming synchronization frame For this synchronization frame Perform solidification processing to obtain synchronization frame The solidification moment

[0116] Step 202: The master node uses the fixed time point of the synchronization frame sent by the slave node and / or the backup master node as the dispatch time point, encapsulates the fixed time point as a timestamp into the synchronization frame, and dispatches it to the slave node (or the backup master node);

[0117] Specifically, in the present invention, the master node M p In the network topology where the root node is the master node, To belong to l k Secondary slave nodes and / or backup master nodes Incoming synchronization frame The solidification moment As the distribution moment, the solidification moment Encapsulated into synchronization frames Then dispatch the synchronization frame To slave nodes and / or backup master nodes

[0118] For example, Figure 1 、 Figure 2 、 Figure 4 As shown, in the network topology with the master node M1 as the root node,

[0119] Master Node Take the slave node belonging to level l1 Incoming synchronization frame The solidification moment As the distribution moment, the solidification moment Encapsulated into synchronization frames Then dispatch the synchronization frame To the slave node

[0120] Master Node Take the slave node belonging to level l1 Incoming synchronization frame The solidification moment As the distribution moment, the solidification moment Encapsulated into synchronization frames Then dispatch the synchronization frame To the slave node

[0121] Current master node To belong to l k Backup master node Incoming synchronization frame The solidification moment As the distribution moment, the solidification moment Encapsulated into synchronization frames Then dispatch the synchronization frame To the backup master node

[0122] For example, Figure 1 、 Figure 3 、 Figure 5 As shown, in the network topology with the master node M2 ​​as the root node,

[0123] Master Node Take the slave node belonging to level l1 Incoming synchronization frame The solidification moment As the distribution moment, the solidification moment Encapsulated into synchronization frames Then dispatch the synchronization frame To the slave node

[0124] Master Node Take the slave node belonging to level l1 Incoming synchronization frame The solidification moment As the distribution moment, the solidification moment Encapsulated into synchronization frames Then dispatch the synchronization frame To the slave node

[0125] Step 3: The slave node and / or backup master node extracts the fixed time point in the synchronization frame sent by the master node and compares it with the first expected fixed time point of the local clock to calculate the primary time correction factor. Simultaneously, the synchronization frame sent by the master node is fixed to obtain the fixed time point. This is compared with the second expected fixed time point of the local clock to calculate the secondary time correction factor. The two time correction factors are added together to obtain the new time correction factor to correct the local clock.

[0126] In the present invention, a slave node extracts the fixed time point encapsulated in the synchronization frame sent by the master node and compares it with the first expected fixed time point of the local clock to calculate a primary time correction factor. Simultaneously, the synchronization frame sent by the master node is fixed to obtain a fixed time point, which is compared with the second expected fixed time point of the local clock to calculate a secondary time correction factor. The two time correction factors are accumulated to obtain a new time correction factor to correct the local clock.

[0127] In the present invention, the backup master node extracts the fixed time point in the synchronization frame sent by the current master node, compares it with the first expected fixed time point of the local clock, and calculates the primary time correction factor. Simultaneously, the synchronization frame sent by the master node is fixed to obtain the fixed time point, which is compared with the second expected fixed time point of the local clock to calculate the secondary time correction factor. The two time correction factors are accumulated to obtain a new time correction factor to correct the local clock.

[0128] Step 301: The slave node and / or the backup master node extracts the fixed time point in the synchronization frame sent by the master node, compares it with the first expected fixed time point of the local clock, and calculates the master time correction factor;

[0129] Specifically, in the present invention, the master node M p The resulting network topology belongs to l k Secondary slave nodes and / or backup master nodes Extract the master node M p Incoming synchronization frame Curing time point of the package And with the expected solidification moment set in advance Compare and calculate the main time correction factor Right now

[0130] For example, Figure 1 、 Figure 2 、 Figure 4 As shown, in the network topology with the master node M1 as the root node,

[0131] Slave nodes Extract the master node Incoming synchronization frame Curing time of the package And with the expected solidification moment set in advance Compare and calculate the main time correction factor Right now

[0132] Slave nodes Extract the master node Incoming synchronization frame Curing time of the package And with the expected solidification moment set in advance Compare and calculate the main time correction factor Right now

[0133] Backup Master Node Extract the current master node Synchronization frame Curing time of the package And with the expected solidification moment set in advance Compare and calculate the main time correction factor Right now

[0134] For example, Figure 1 、 Figure 3 、 Figure 5 As shown, in the network topology with the master node M2 ​​as the root node,

[0135] Slave nodes Extract the master node Incoming synchronization frame Curing time of the package And with the expected solidification moment set in advance Compare and calculate the main time correction factor Right now

[0136] Slave nodes Extract the master node Incoming synchronization frame Curing time of the package And with the expected solidification moment set in advance Compare and calculate the main time correction factor Right now

[0137] Step 302: The slave node and / or the backup master node solidifies the synchronization frame sent by the master node, obtains the solidified time point, compares it with the second expected solidified time point of the local clock, calculates the secondary time correction factor, and then accumulates the primary time correction factor and the secondary time correction factor to correct the local clock.

[0138] Specifically, in the present invention, the master node M p The resulting network topology belongs to l k Secondary slave nodes and / or backup master nodes For the master node M p Incoming synchronization frame Perform solidification processing to obtain synchronization frames The solidification moment and the second expected solidification time point pre-set by the local clock Compare and calculate the time correction factor and Then add the primary time correction factor and the secondary time correction factor, that is, Used to correct the local clock

[0139] For example, Figure 1 、 Figure 2 、 Figure 4 As shown, in the network topology with the master node M1 as the root node,

[0140] Slave nodes For the master node Incoming synchronization frame Perform solidification processing to obtain synchronization frames The solidification moment and the second expected solidification time point pre-set by the local clock The difference between the two is used to obtain the time correction factor and Then add the primary time correction factor and the secondary time correction factor, that is, Used to calibrate the local clock;

[0141] Slave nodes For the master node Incoming synchronization frame Perform solidification processing to obtain synchronization frames The solidification moment and the second expected solidification time point pre-set by the local clock The difference between the two is used to obtain the time correction factor and Then add the primary time correction factor and the secondary time correction factor, that is, Used to calibrate the local clock;

[0142] Backup Master Node For the current master node Incoming synchronization frame Perform solidification processing to obtain synchronization frames The solidification moment and the second expected solidification time point pre-set by the local clock The difference between the two is used to obtain the time correction factor and Then add the primary time correction factor and the secondary time correction factor, that is, Used to calibrate the local clock;

[0143] For example, Figure 1 、 Figure 3 、 Figure 5 As shown, in the network topology with the master node M2 ​​as the root node,

[0144] Slave nodes For the master node Incoming synchronization frame Perform solidification processing to obtain synchronization frames The solidification moment and the second expected solidification time point pre-set by the local clock The difference between the two is used to obtain the time correction factor and Then add the primary time correction factor and the secondary time correction factor, that is, Used to calibrate the local clock;

[0145] Slave nodes For the master node Incoming synchronization frame Perform solidification processing to obtain synchronization frames The solidification moment and the second expected solidification time point pre-set by the local clock The difference between the two is used to obtain the time correction factor and Then add the primary time correction factor and the secondary time correction factor, that is, Used to calibrate the local clock;

[0146] Phase 2: Maintaining synchronization

[0147] Step 4: At the end of the synchronization phase, the master node dispatches synchronization frames to the slave node and / or backup master node every other synchronization period, starting from the dispatch time of the first synchronization frame sent to the slave node and / or backup master node.

[0148] In the present invention, in a network topology with a master node as the root node, after a slave node and / or backup master node establishes synchronization with the master node, the master node dispatches synchronization frames to the slave node and / or backup master node every synchronization period, starting with the dispatch time of the first synchronization frame sent to the slave node and / or backup master node. This ensures that after synchronization is established, the slave node maintains synchronization with each master node periodically; and after synchronization is established, the backup master node maintains synchronization with the current master node periodically.

[0149] Specifically, in the present invention, the master node M p In the network topology where the root node is located, after the synchronization phase is completed, the master node M p To send to l k Any slave node and / or backup master node at the same level The first synchronization frame The distribution time is the starting time, and every synchronization period T sync Dispatches synchronization frames to slave nodes and / or backup master nodes.

[0150] For example, Figure 1 、 Figure 2 and Figure 4 As shown, in the network topology with the current master node M1 as the root node,

[0151] With the current master node In the network topology with the root node as the root node, after the synchronization phase is completed, the current master node To send to the L1 slave node The first synchronization frame The distribution time is the starting time, and every synchronization period T sync Dispatches synchronization frames to slave nodes.

[0152] With the current master node In the network topology with the root node as the root node, after the synchronization phase is completed, the current master node To send to the L1 slave node The first synchronization frame The distribution time is the starting time, and every synchronization period T sync Dispatches synchronization frames to slave nodes.

[0153] With the current master node In the network topology with the root node as the root node, after the synchronization phase is completed, the current master node Sent to the L2 level backup master node The first synchronization frame The distribution time is the starting time, and every synchronization period T sync Dispatches synchronization frames to the backup master node.

[0154] For example, Figure 1 、 Figure 3 and Figure 5 As shown, in the network topology with the backup master node M2 ​​as the root node,

[0155] Backup master node In the network topology with the root node as the backup node, after the synchronization phase is completed, the backup master node To send to the L1 slave node The first synchronization frame The distribution time is the starting time, and every synchronization period T sync Dispatches synchronization frames to slave nodes.

[0156] Backup master node In the network topology with the root node as the backup node, after the synchronization phase is completed, the backup master node To send to the L1 slave node The first synchronization frame The distribution time is the starting time, and every synchronization period T sync Dispatches synchronization frames to slave nodes.

[0157] Step 5: The slave node and / or backup master node solidifies the synchronization frame sent by the master node to obtain a solidified time point, and then compares the solidified time point with the expected solidified time point of the local clock to calculate the time synchronization factor for correcting the local clock.

[0158] In the present invention, a slave node solidifies the synchronization frame sent by the master node to obtain a solidified time point. This time point is then compared with the expected solidified time point of the local clock to calculate a time correction factor, which is used to correct the local clock. If the solidified time point of the synchronization frame sent by the master node does not fall within the time window set by the slave node, the local clock is corrected using the solidified time point of the synchronization frame sent by the master node with the highest degree of accuracy that falls within the time window.

[0159] In the present invention, the backup master node solidifies the synchronization frame sent by the current master node, obtains the solidified time point, compares it with the expected solidified time point of the local clock, and calculates a time correction factor to correct the local clock. If the solidified time point of the synchronization frame sent by the current master node does not fall within the time window set by the backup master node, the current backup master node requests to establish synchronization with the highest-ranking master node in the network.

[0160] Specifically, in the present invention, the master node M p The resulting network topology belongs to l k Secondary slave nodes and / or backup master nodes For the master node M p Incoming synchronization frame Perform curing treatment and calculate the curing time point and the expected solidified time pre-set by the local clock Compare and calculate the time correction factor Right now

[0161] For example, Figure 1 、 Figure 2 、 Figure 4 As shown, in the network topology with the master node M1 as the root node,

[0162] Slave nodes For the master node Incoming synchronization frame Perform solidification processing to obtain synchronization frames The solidification moment and the expected solidified time point pre-set by the local clock The time correction factor is obtained by taking the difference between and Used to calibrate the local clock;

[0163] Slave nodes For the master node Incoming synchronization frame Perform solidification processing to obtain synchronization frames The solidification moment and the expected solidified time point pre-set by the local clock The time correction factor is obtained by taking the difference between Right now Used to calibrate the local clock;

[0164] Backup Master Node For the current master node Incoming synchronization frame Perform solidification processing to obtain synchronization frames The solidification moment and the fixed time point pre-set by the local clock The time correction factor is obtained by taking the difference between and Used to calibrate the local clock;

[0165] For example, Figure 1 、 Figure 3 、 Figure 5 As shown, in the network topology with the master node M2 ​​as the root node,

[0166] Slave nodes For the master node Incoming synchronization frame Perform solidification processing to obtain synchronization frames The solidification moment and the expected solidified time point pre-set by the local clock The time correction factor is obtained by taking the difference between and Used to calibrate the local clock;

[0167] Slave nodes For the master node Incoming synchronization frame Perform solidification processing to obtain synchronization frames The solidification moment and the second expected solidification time point pre-set by the local clock The time correction factor is obtained by taking the difference between and Used to correct the local clock.

[0168] An embodiment of the present invention provides a master-slave time synchronization method based on a backup master clock applicable to a time synchronization network. The method includes: in a network topology with a master node as the root node, a slave node and / or a backup master node sends a synchronization frame to the master node; the master node then solidifies the received synchronization frame, calculates a solidified time point, and then encapsulates the solidified time point in a new synchronization frame, and sends the new synchronization frame to the slave node and / or the backup master node. When the node that sends the synchronization frame to request synchronization is the backup master node, the master node that receives the synchronization frame is the current master node. At this point, synchronization connections are established between the slave node and the master node, and between the backup master node and the current master node. After the synchronization establishment phase is completed, the master node uses the solidified time point of the first synchronization frame sent back to the slave node and / or the backup master node as the start time, and periodically sends synchronization frames to the slave node and / or the backup master node. The network maintains high-precision, fault-tolerant, master-slave time synchronization based on the backup master clock. Once a network node loses synchronization with the master node, it will restart the synchronization phase to request synchronization; it can achieve high-precision path delay measurement, eliminate the asymmetry and uncertainty introduced by the synchronization round-trip path delay, and improve the accuracy of time synchronization; a two-step master-slave time synchronization operation is proposed, which simplifies the synchronization operation after the synchronization node is cold started, shortens the cold start time of the synchronization node, and at the same time ensures that the local clock has very high time accuracy after synchronization is established between the master and slave nodes.

Claims

1. A high-precision master-slave time synchronization method suitable for a time synchronization network, characterized in that: The method comprises: Establish synchronization phase: Step 1: After a cold start or re-request to establish synchronization, the slave node and / or backup master node sends a synchronization frame to the master node in the network; Step 2: The master node receives the synchronization frame sent by the slave node and / or the backup master node, solidifies the synchronization frame, and then uses the solidified time point of the synchronization frame sent by the slave node and / or the backup master node as the dispatch time point. The solidified time point is encapsulated as a timestamp in the synchronization frame and dispatched to the slave node and / or the backup master node; Step 3: Calculate the primary correction factor and the secondary correction factor from the slave node and / or the backup master node; add the two correction factors to obtain a new time correction factor to correct the local clock; in step 3, The slave node and / or backup master node extracts the fixed time point encapsulated in the synchronization frame sent by the master node, compares it with the first expected fixed time point of the local clock, and calculates the primary correction factor; and solidifies the synchronization frame sent by the master node to obtain the fixed time point, compares it with the second expected fixed time point of the local clock, and calculates the secondary correction factor. The two time correction factors are accumulated to obtain a new time correction factor to correct the local clock; Maintain synchronization phase: Step 4: At the end of the synchronization phase, the master node dispatches synchronization frames to the slave node and / or backup master node every other synchronization period, starting from the dispatch time of the first synchronization frame sent to the slave node and / or backup master node. Step 5: The slave node and / or the backup master node calculates a time correction factor to correct the local clock.

2. A high-precision master-slave time synchronization method suitable for a time synchronization network according to claim 1, characterized in that: A high-precision clock source synchronization node capable of synchronizing time with other nodes in the network serves as the master node. The master nodes in the network are divided into priority order, with the master node with the highest priority in the current network serving as the current master node. When the network is operating normally, all synchronization nodes except the master node only accept the clock source information of the current master node to correct their own local clocks. The remaining master nodes perform hot backup time synchronization operations and serve as backup master nodes. Each backup master node only receives synchronization frames from the current master node to correct its own local clock, and does not receive synchronization frames from other backup master nodes to correct its own local clock. If the current master node fails or no longer functions, the backup master node with the highest current level will take over as the current master node.

3. A high-precision master-slave time synchronization method suitable for a time synchronization network according to claim 2, characterized in that: A synchronization node that receives synchronization frames from the master node and performs time synchronization operations based on the time synchronization information of the master node contained in the synchronization frames, serving as a slave node; When the network is operating normally, the slave node also receives synchronization frames from the backup master node, but only uses the time information of the synchronization frame sent by the current master node to correct the local clock. It does not use the time information of the synchronization frame sent by the backup master node to correct the local clock and only performs hot backup processing; if the current master node fails, or loses power, or no longer works, the slave node will use the time information of the synchronization frame from the highest-level backup master node to correct the local clock, and report the synchronization failure information to all backup master nodes in the network.

4. A high-precision master-slave time synchronization method suitable for a time synchronization network according to claim 1, characterized in that: The timing accuracy of the master node should be higher than the timing accuracy of the remaining slave nodes in the network, and the total number of the master nodes is at least 2.

5. The high-precision master-slave time synchronization method applicable to a time synchronization network according to claim 2, characterized in that: According to the distance from the master node M p The number of hops is used to perform network level calculation on the synchronization nodes. k }division; The master node is regarded as the root node of all synchronization nodes in the entire switching network and is recorded as level 10 in the hierarchy. p belongs to l k The synchronization node SD of level 1 is denoted as The subscript k indicates the level; Each master node regularly updates and maintains the network topology with itself as the root node.

6. A high-precision master-slave time synchronization method suitable for a time synchronization network according to claim 5, characterized in that: Step 5 is as follows: The slave node solidifies the synchronization frame sent by the master node, obtains the solidified time point, compares it with the expected solidified time point of the local clock, and calculates the time correction factor to correct the local clock. If the solidified time point of the synchronization frame sent by the master node does not fall within the time window set by the slave node, the local clock is corrected based on the solidified time point of the synchronization frame sent by the master node with the highest level that falls within the time window. The backup master node solidifies the synchronization frame sent by the current master node, obtains the solidification time point, compares it with the expected solidification time point of the local clock, calculates the time correction factor, and uses it to correct the local clock; if the solidification time point of the synchronization frame sent by the current master node does not fall within the time window set by the backup master node, the current backup master node requests the master node with the highest level in the network to establish a synchronization operation.

7. A high-precision master-slave time synchronization method suitable for a time synchronization network according to claim 6, characterized in that: In the synchronization maintenance phase, the master node M p In a network topology with a root node as the root node, an observation window with a length of δ is opened on both sides of any expected solidification time pre-set by the slave node and / or the backup master node to form a time window centered on the expected solidification time. Therefore, the length of a time window TW = 2×δ.

Citation Information

Patent Citations

  • Directional beam based wireless network master-slave synchronization method

    CN106455036A

  • Master-salve clock synchronization method suitable for multi-synchronization domain time -triggered Ethernet

    CN107070578A