Method for measuring time synchronization precision between network nodes
By employing a multi-channel parallel acquisition and buffer-arbitration scheduling method, the problems of long-term continuous measurement and multi-node data conflict in existing technologies are solved, enabling efficient statistical analysis and long-term verification of synchronization accuracy in industrial communication systems.
Patent Information
- Application Number
- CN202511738901.5
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-11-25
- Publication Date
- 2026-02-13
AI Technical Summary
Existing technologies cannot achieve long-term continuous measurement and synchronization accuracy of multi-node data, making it difficult to verify the synchronization performance in industrial systems over a long period of time.
By employing multi-channel parallel acquisition, buffer-arbitration scheduling, and queued processing, and through signal edge detection, timestamp latching, buffer and timestamp submission modules, combined with the preset rules of the arbitration module, we can achieve accurate identification of synchronization events of multiple network nodes and continuous long-term data retention.
It enables accurate identification of synchronization events across multiple network nodes and continuous long-term data retention, improving the reliability and applicability of time synchronization accuracy measurement and meeting the long-term verification requirements for synchronization performance in the industrial communication field.
Smart Images

Figure CN121530518A_ABST
Abstract
Description
TECHNICAL FIELD
[0001] The application belongs to the field of network node time synchronization performance measurement, and particularly relates to a method for measuring time synchronization precision between network nodes. BACKGROUND
[0002] In the network node time synchronization precision measurement scene, the current mainstream methods mainly include three types:
[0003] 1) 1PPS direct measurement method: taking 1PPS signal as a synchronization reference, collecting 1PPS edge time of the measured node, and obtaining synchronization precision by comparing the time difference between the reference 1PPS and the node 1PPS;
[0004] 2) Master station issuing - slave station local error statistics method: the master station issues synchronization instructions to each slave station, the slave station locally calculates the error between the instruction receiving time and the theoretical issuing time, and the master station further statistically obtains the synchronization precision of each node;
[0005] 3) Master station issuing - slave station back transmission time method: the master station issues synchronization instructions, the slave station transmits its local time back to the master station, the master station calculates the deviation between the back transmission time and the theoretical synchronization time, and obtains the synchronization precision.
[0006] Among them, the 1PPS direct measurement method is the current optimal and most intuitive and simple way, and common implementation means includes:
[0007] Using an oscilloscope to measure: obtaining the precision of a single synchronization event by triggering single sampling, or observing the synchronization precision distribution in a short time by using afterglow function;
[0008] Using a logic analyzer to measure: collecting the synchronization signal edge time in a period of time, and statistically obtaining the synchronization precision in the period of time.
[0009] However, the above methods have common defects, that is, they are limited by the local storage capacity, data transmission bandwidth and other factors of the oscilloscope / logic analyzer, and cannot realize long-time (such as hours, days) continuous measurement, and it is difficult to cover the synchronization precision fluctuation scene in the long-term running process of the industrial system.
[0010] Therefore, it is urgent to provide a time synchronization precision measurement method which can support multi-node parallel collection and long-time continuous recording, so as to meet the long-term verification demand of synchronization performance in the field of industrial communication. SUMMARY
[0011] In view of the defects that the existing time synchronization precision measurement method cannot continuously collect for a long time, and multi-node data is easy to conflict and lose, the application provides a time synchronization precision measurement method based on "synchronization signal pulse timestamp" collection and storage, through multi-channel parallel collection, cache-arbitration scheduling, queuing processing and other technical means, accurate identification of multi-network node synchronization events, continuous long-time data retention, and finally efficient statistics of synchronization precision are realized.
[0012] The technical scheme adopted by the application to achieve the above-mentioned purpose is:
[0013] A method for measuring time synchronization precision between network nodes, comprising the following steps:
[0014] 1) A plurality of signal edge detection circuits respectively collect edge trigger conditions of corresponding measured signals;
[0015] 2) When a trigger signal of a certain channel is detected, an edge timestamp latching module of the corresponding channel latches the edge timestamp of the current channel in combination with the reference time provided by the timing counter, and the latched timestamp data is cached into the cache and timestamp submission module of the corresponding channel;
[0016] 3) Each cache and timestamp submission module initiates a data submission request to the arbitration module, and after receiving a response from the arbitration module, the cache data that passes the response is submitted to the timestamp queue;
[0017] 4) The timestamp queue uniformly collects the timestamp data of multiple channels according to the receiving order.
[0018] The latched timestamp data includes a timestamp and a channel number corresponding to the trigger.
[0019] The arbitration module responds to the scheduling request according to a preset rule, and the preset rule includes a cyclic priority scheduling or a fixed priority scheduling.
[0020] If there is data that does not pass the arbitration module scheduling request, it continues to be temporarily stored in the corresponding cache and timestamp submission module waiting for the next arbitration scheduling.
[0021] A system for measuring time synchronization precision between network nodes, comprising:
[0022] A signal edge detection circuit for respectively collecting edge trigger conditions of corresponding measured signals;
[0023] An edge timestamp latching module for latching the edge timestamp of the current channel in combination with the reference time provided by the timing counter when a trigger signal of a certain channel is detected, and the latched timestamp data is stored in the cache and timestamp submission module of the corresponding channel;
[0024] A cache and timestamp submission module is configured to initiate a data submission request to the arbitration module and submit the passed cache data to the timestamp queue;
[0025] An arbitration module is configured to schedule the request according to a preset rule and provide a response signal;
[0026] A timestamp queue is configured to uniformly collect the timestamp data of multiple channels according to the receiving order.
[0027] The present application has the following advantages and benefits:
[0028] 1. The present application can realize accurate identification of multiple network node synchronization events, continuous long-time data retention, and efficient statistics of synchronization accuracy, and can meet the needs of long-term verification of synchronization performance in the fields of industrial wireless communication, industrial Ethernet, field bus, etc.
[0029] 2. The present application solves the defects of the traditional method that cannot measure for a long time and the conflict of multi-node data, and improves the reliability and applicability of time synchronization accuracy measurement. BRIEF DESCRIPTION OF DRAWINGS
[0030] Figure 1 Structure block diagram of the time synchronization accuracy measurement system;
[0031] Figure 2 Independent integrated system schematic diagram of the embodiment 1 of the present application;
[0032] Figure 3 Split system schematic diagram of the embodiment 2 of the present application, which comprises a collection device and a host computer. DETAILED DESCRIPTION
[0033] The present application will be further described in detail below in combination with the drawings and embodiments.
[0034] The core execution logic of the present method is a time synchronization accuracy measurement system, and the overall structure thereof is shown in Figure 1 The modules and data flow process are as follows:
[0035] The implementation process of the time synchronization accuracy measurement system is as follows: the multi-channel signal edge detection circuit respectively collects the edges of the corresponding measured signals, triggers the corresponding edge timestamp latching module, completes the latching of the edge timestamp in combination with the reference time provided by the timing counter, the latched timestamp data is transmitted to the corresponding cache and timestamp submission module for temporary storage, each cache module initiates a data submission request to the arbitration module, after receiving the response of the arbitration module to the scheduling request according to the preset rule and providing the response, each cache module submits the passed cache data to the timestamp queue, and finally the timestamp queue uniformly collects the timestamp data of multiple channels, thereby providing an ordered data source for subsequent storage or analysis.
[0036] Function description of each module
[0037] The signal edge detection module (1, 2…n) corresponds to the synchronization signal output end of one network node to be measured per path, captures the rising edge or falling edge of the synchronization signal in real time and triggers the subsequent timestamp collection process; the timing counter provides a high-precision reference time with nanosecond-level resolution for the entire system as the time reference of the timestamp; the edge timestamp latching module (1, 2…n) corresponds to each edge detection module one by one, when the detection module identifies the signal edge, the current reference time output by the timing counter is immediately latched to generate the timestamp data of the synchronization event; the cache and timestamp submission module (1, 2…n) records the timestamp data output by the corresponding latching module, realizes the sequential storage of multiple groups of timestamp data, and initiates a data submission request to the arbitration module, after receiving the response from the arbitration module, the corresponding timestamp data is submitted to the timestamp queue, if no response is received, the data continues to be temporarily stored in the corresponding cache module waiting for the next arbitration scheduling; the arbitration module receives the request of each "cache and timestamp submission" module, judges whether the request is responded according to the preset rules such as "cyclic priority" or "fixed priority", if the request is passed, the "cache and timestamp submission" module is provided with a response; the timestamp queue stores the timestamp data of the "cache and timestamp submission" module in the order of receiving, as a data transfer hub, and outputs data to the timestamp storage, synchronization accuracy calculation and other modules, thereby supporting long-time measurement and accuracy statistics.
[0038] Connection relationship of each module
[0039] The signal edge sampling module is connected with the corresponding edge timestamp latching module through a level signal line; the timing counter is connected with each edge timestamp latching module through a system clock line to provide a reference time signal for it; each edge timestamp latching module is connected with the corresponding cache and timestamp submission module through a data signal line; all cache and timestamp submission modules are connected to the arbitration module through a request signal line and a response signal line, and are connected with the timestamp queue through a data transmission line; the arbitration module is connected with the cache and timestamp submission module through a request signal line and a response signal line; finally, each module completes the transmission of signals and data through the above-mentioned link to form a complete time synchronization accuracy measurement system connection architecture.
[0040] Embodiment
[0041] The time synchronization accuracy measurement method of the application supports two implementation forms, which are suitable for different application scenarios:
[0042] Form 1: independent integrated system, as shown in the figure, all functional modules are integrated in an independent device (or embedded system): Figure 2
[0043] Module integration mode: signal edge detection circuit, timing counter, arbitration, timestamp queue, timestamp storage, synchronization accuracy calculation, report generation and other modules are integrated in the same hardware carrier (such as special test equipment, embedded main control board);
[0044] Applicable scenario: scenarios that require portable testing and on-site rapid deployment (such as industrial equipment on-site synchronization accuracy sampling);
[0045] Core advantage: high system integration, no additional communication link required, easy to deploy.
[0046] Form 2: "acquisition device + host computer" split system, as shown in Figure 3 , which is divided into a timestamp acquisition device and a host computer system, and transmits data through a bus / network:
[0047] 1) Timestamp acquisition device: integrates signal edge detection circuit, timing counter, arbitration, and timestamp queue module, responsible for front-end synchronization signal acquisition, timestamp latching, and preliminary scheduling;
[0048] 2) Host computer system: integrates timestamp storage, synchronization accuracy calculation, and report generation modules, receives timestamp data transmitted by the acquisition device through a bus (such as CAN, RS485) or network (such as Ethernet), and completes data storage, accuracy analysis, and report output;
[0049] Applicable scenario: scenarios that require long-term mass data storage and remote analysis (such as long-term synchronization performance monitoring of industrial systems);
[0050] Core advantage: lightweight acquisition device, host computer can use high-performance hardware to realize large data processing and storage.
[0051] Time synchronization accuracy is a basic technical requirement for the implementation of collaborative functions in various network protocols. The present invention relates to the measurement technology of time synchronization performance between network nodes, and is specifically applied to:
[0052] 1) Industrial wireless communication field: in industrial wireless protocols such as WirelessHART, WIA-PA, the time synchronization accuracy between multiple devices directly affects the timing consistency of data acquisition;
[0053] 2) Industrial Ethernet communication: in real-time communication scenarios of Ethernet protocols such as EtherNet / IP, Profinet, node synchronization error can cause data exchange delay or conflict;
[0054] 3) Fieldbus: in bus systems such as Modbus, CANopen, the time synchronization accuracy of multiple nodes determines the execution synchronization of control commands.
[0055] The application provides a multi-node time synchronization precision measurement method suitable for the above field, and realizes long-time and high-reliability synchronization performance testing.
Claims
1. A method for measuring the time synchronization accuracy between network nodes, characterized in that, Includes the following steps: 1) The multi-channel signal edge detection circuit collects the edge triggering status of the corresponding measured signal; 2) When a trigger signal of a certain channel is detected, the edge timestamp latching module of the corresponding channel latches the edge timestamp of the current channel in combination with the reference time provided by the timer counter. The latched timestamp data is then cached into the cache and timestamp submission module of the corresponding channel. 3) Each cache and timestamp submission module sends a data submission request to the arbitration module, and after receiving the response from the arbitration module, submits the cached data that passed the response to the timestamp queue. 4) The timestamp queue summarizes the timestamp data from multiple channels in the order of receipt.
2. The method for measuring the time synchronization accuracy between network nodes according to claim 1, characterized in that, The latched timestamp data includes the timestamp and the corresponding channel number that triggered the trigger.
3. The method for measuring the time synchronization accuracy between network nodes according to claim 1, characterized in that, The arbitration module responds to scheduling requests according to preset rules, which include scheduling by cyclic priority or scheduling by fixed priority.
4. The method for measuring the time synchronization accuracy between network nodes according to claim 1, characterized in that, If there is data that fails to pass the arbitration module's scheduling request, it will continue to be temporarily stored in the corresponding cache and timestamp submission module, waiting for the next arbitration scheduling.
5. A system for measuring the time synchronization accuracy between network nodes, characterized in that, include: The signal edge detection circuit is used to collect the edge triggering status of the corresponding measured signal. The edge timestamp latching module is used to latch the edge timestamp of the current channel when a trigger signal of a certain channel is detected, in combination with the reference time provided by the timer counter. The latched timestamp data is then stored in the corresponding channel's buffer and timestamp submission module. The caching and timestamp submission module is used to initiate data submission requests to the arbitration module and submit the cached data that has passed the response to the timestamp queue. The arbitration module is used to schedule requests according to preset rules and provide response signals; The timestamp queue is used to uniformly summarize timestamp data from multiple channels according to the order of receipt.