A test method for AS6802 protocol consistency
The tester simulates PCF frame operation, uses the time counter and test table to judge the consistency of the AS6802 protocol, which solves the problem of network synchronization of multi-manufacturers and realizes accurate testing without hardware changes.
Patent Information
- Application Number
- CN202310396521.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2023-04-13
- Publication Date
- 2025-08-12
- Estimated Expiration
- 2043-04-13
AI Technical Summary
How to test whether the time-triggered Ethernet device complies with the AS6802 protocol before forming a network, especially if the network contains multiple manufacturers' devices, it is extremely difficult to troubleshoot.
A test method for the consistency of the AS6802 protocol is provided. The tester obtains the test table, parses and compares the operation type, operation window and operation time point of the PCF frame, simulates the behavior of sending and receiving PCF frames, and uses the local time counter to determine the time point to achieve protocol consistency judgment.
Various tests can be completed without changing the hardware circuit. The test time can trigger the state machine jump of Ethernet devices. It has flexibility and accuracy, and is suitable for network synchronization testing of multi-manufacturers.
Smart Images

Figure CN116389327B_ABST
Abstract
Description
Technical Field
[0001] The present invention belongs to the field of communication technology, and in particular relates to a method for testing the consistency of the AS6802 protocol. Background Art
[0002] With the rapid development of distributed systems, the best-effort, event-triggered transmission mechanisms of traditional Ethernet are no longer able to meet the real-time, deterministic, secure, and fault-tolerant communication requirements of these systems. Time-triggered Ethernet (TTE) combines time-triggered technology, enabling real-time and fault-tolerant networks, with Ethernet's high bandwidth and flexible networking capabilities. It is widely used in aerospace, autonomous driving, telecommunications, and other fields.
[0003] The key to Time-Triggered Ethernet (TTE) technology is the AS6802 time synchronization protocol. The AS6802 protocol establishes a new, highly accurate and fault-tolerant synchronization technology, enabling low-latency, low-jitter, and highly accurate clock synchronization. AS6802 time synchronization introduces a global time reference for devices in the network and, through fault-tolerance, ensures the determinism, reliability, and security of TTE.
[0004] Time-triggered Ethernet technology has broad application prospects in aviation, aerospace, and military industries, and many domestic research institutes have already developed their own time-triggered Ethernet equipment. The AS6802 protocol, as a key technology for time-triggered Ethernet, requires proper network synchronization. In practice, a network may include time-triggered Ethernet equipment from multiple manufacturers. Manufacturers may not fully adhere to the AS6802 protocol standards during development, resulting in network synchronization issues. Due to the complex state machine of the AS6802 protocol, the numerous network devices, and the complex topology, troubleshooting anomalies is extremely difficult.
[0005] It can be seen that how to test whether time-triggered Ethernet devices comply with the AS6802 protocol before networking is established is an urgent problem to be solved by those skilled in the art. Summary of the Invention
[0006] To address the aforementioned issues in the prior art, the present invention provides a method for testing AS6802 protocol conformance. The technical issues addressed by the present invention are achieved through the following technical solutions:
[0007] The present invention provides a method for testing the consistency of the AS6802 protocol, which is applied to a tester. The method comprises:
[0008] Obtaining a test table through a data interface, the test table including test contents corresponding to a plurality of protocol control frames, the test contents including at least an operation type, an operation window, and an operation time point of each PCF frame, the operation type including sending or receiving;
[0009] When receiving the start test instruction, the local time counter starts timing and reads the current test content corresponding to the current PCF frame in the test table;
[0010] Based on the current test content, if the operation type of the current PCF frame is reception, opening a PCF frame reception window at the operation time point corresponding to the current PCF frame;
[0011] After receiving the PCF frame to be tested sent by the device under test, the PCF frame to be tested is parsed and the parsed content is compared with the test content of the current PCF frame to obtain a test result.
[0012] In one embodiment of the present invention, before the step of receiving the start test instruction, the method further includes:
[0013] Writing the test table into a random access memory RAM;
[0014] When a test start instruction is received, the local time counter starts timing and reads the current test content corresponding to the current PCF frame in the test table, including:
[0015] When the start test instruction is received, the local time counter starts timing and reads the current test content corresponding to the current PCF frame in the test table from the RAM.
[0016] In one embodiment of the present invention, based on the current test content, if the operation type of the current PCF frame is reception, the step of opening a PCF frame reception window at the operation time point corresponding to the current PCF frame includes:
[0017] Determine the operation type, operation window, and operation time point of the current PCF frame based on the current test content;
[0018] If the operation type of the current PCF frame is reception, the PCF frame reception window is opened when the count value of the time counter is equal to the operation time point of the current PCF frame.
[0019] In one embodiment of the present invention, the PCF frame receiving window takes the operation time point of the current PCF frame as its center and the operation window of the current PCF frame as its width.
[0020] In one embodiment of the present invention, upon receiving the start test instruction, after the step of starting the local time counter to time and reading the current test content corresponding to the current PCF frame in the test table, the method further includes:
[0021] Determine the operation type, operation window, and operation time point of the current PCF frame based on the current test content;
[0022] If the operation type of the current PCF frame is sending, then when the count value of the time counter is equal to the operation time point of the current PCF frame, the current PCF frame is sent to the device under test.
[0023] In one embodiment of the present invention, the test content also includes the destination MAC address, source MAC address, Ethernet frame type, integration period, member vector, synchronization priority, synchronization domain, synchronization frame type, transparent clock, frame sequence, whether it is the last frame and comparison enable field of each PCF frame.
[0024] In one embodiment of the present invention, after receiving a PCF frame to be tested sent by a device under test, parsing the PCF frame to be tested and comparing the parsed content with the test content of the current PCF frame to obtain a test result includes:
[0025] Receive the PCF frame to be tested sent by the device under test;
[0026] Parsing the PCF frame to be tested to obtain the destination MAC address, source MAC address, Ethernet frame type, integration period, member vector, synchronization priority, synchronization domain, synchronization frame type and transparent clock of the PCF frame to be tested;
[0027] Obtaining the destination MAC address, source MAC address, Ethernet frame type, integration period, member vector, synchronization priority, synchronization domain, synchronization frame type and transparent clock of the current PCF frame from the current test content;
[0028] According to the comparison enable field of the current PCF frame, at least one of the destination MAC address, source MAC address, Ethernet frame type, integration period, member vector, synchronization priority, synchronization domain, synchronization frame type and transparent clock of the PCF frame to be tested is compared with the corresponding items of the destination MAC address, source MAC address, Ethernet frame type, integration period, member vector, synchronization priority, synchronization domain, synchronization frame type and transparent clock of the current PCF frame to obtain a detection consistency test result.
[0029] In one embodiment of the present invention, if the consistency test result is correct and the current PCF frame is not the last frame, the next PCF frame is used as the current frame, and the process returns to the step of reading the current test content corresponding to the current PCF frame in the test table.
[0030] Compared with the prior art, the present invention has the following beneficial effects:
[0031] (1) The present invention provides a method for testing the conformance of the AS6802 protocol. The operations during the test are determined by a test table, and various tests can be completed without changing the hardware circuit. Since the state machine jump of the AS6802 protocol is complex, the present invention can also test the state machine jump of the time-triggered Ethernet device under abnormal conditions.
[0032] (2) The present invention can simulate the SM (Synchronous Master) to test the CM (Compression Master), and can also simulate the CM to complete the test of the SM.
[0033] (3) The present invention can flexibly adjust whether to test the PCF frame field through the comparison enable bit. For example, when the destination MAC address has a corresponding comparison enable bit, if the comparison enable bit is 1, it is necessary to determine whether the destination MAC address is the same. Conversely, if the comparison enable bit is 0, it is no longer necessary to determine whether the destination MAC address is the same. Even if the destination MAC is not the same, it has no effect. The above method can ignore the destination MAC address, source MAC address, synchronization domain and synchronization priority of the PCF frame, and has extremely strong flexibility.
[0034] The present invention will be further described in detail below with reference to the accompanying drawings and embodiments. BRIEF DESCRIPTION OF THE DRAWINGS
[0035] Figure 1 This is a schematic diagram of a method for testing AS6802 protocol conformance provided by an embodiment of the present invention;
[0036] Figure 2 This is a flow chart of a method for testing AS6802 protocol conformance provided by an embodiment of the present invention;
[0037] Figure 3 This is another schematic diagram of a method for testing AS6802 protocol conformance provided by an embodiment of the present invention;
[0038] Figure 4 This is a schematic diagram of a test table provided by an embodiment of the present invention. DETAILED DESCRIPTION
[0039] The present invention will be further described in detail below with reference to specific examples, but the embodiments of the present invention are not limited thereto.
[0040] Figure 1This is a schematic diagram of a method for testing AS6802 protocol conformance provided by an embodiment of the present invention. Figure 2 This is a flow chart of a method for testing AS6802 protocol consistency provided by an embodiment of the present invention. The present invention provides a method for testing AS6802 protocol consistency, which is applied to a tester and includes:
[0041] S1. Obtain a test table through a data interface. The test table includes test contents corresponding to multiple protocol control frames. The test contents include at least the operation type, operation window, and operation time point of each PCF frame. The operation type includes sending or receiving.
[0042] S2. When the start test instruction is received, the local time counter starts timing and reads the current test content corresponding to the current PCF frame in the test table;
[0043] S3. Based on the current test content, if the operation type of the current PCF frame is receive, then open the PCF frame receive window at the operation time point corresponding to the current PCF frame;
[0044] S4. After receiving the PCF frame to be tested sent by the device under test, the PCF frame to be tested is parsed and the parsed content is compared with the test content of the current PCF frame to obtain a test result.
[0045] Specifically, when performing AS6802 protocol conformance testing on a time-triggered Ethernet device, this embodiment simulates the behavior of the synchronization component sending and receiving PCF frames through the content of the test table. The time points of receiving and sending PCF frames are both determined by the local time counter. The content and time points of the received PCF frames to be tested are then compared to determine whether the time-triggered Ethernet device complies with the content specified in the AS6802 protocol.
[0046] Optionally, before receiving the step of starting the test instruction, the method further includes:
[0047] The test table is written into the random access memory RAM.
[0048] In this embodiment, the tester receives a test table through a data interface. Exemplarily, the test table includes the contents of PCF frames exchanged during the cold start process of the AS6802 protocol, such as the cs (Coldstart) frame, the ca (Coldstart Acknowledge) frame, and the IN (Integration) frame.
[0049] In the above step S2, when the start test instruction is received, the local time counter starts timing and reads the current test content corresponding to the current PCF frame in the test table, including:
[0050] When the start test instruction is received, the local time counter starts timing and reads the current test content corresponding to the current PCF frame in the test table from the RAM.
[0051] Figure 3 FIG. 1 is another schematic diagram of a method for testing the consistency of the AS6802 protocol provided by an embodiment of the present invention. Figure 3 As shown, in the above step S3, based on the current test content, if the operation type of the current PCF frame is reception, the step of opening the PCF frame reception window at the operation time point corresponding to the current PCF frame includes:
[0052] Based on the current test content, determine the operation type, operation window and operation time point of the current PCF frame;
[0053] If the operation type of the current PCF frame is reception, the PCF frame reception window is opened when the count value of the time counter is equal to the operation time point of the current PCF frame.
[0054] In this embodiment, the PCF frame receiving window takes the operation time point of the current PCF frame as its center and the operation window of the current PCF frame as its width.
[0055] Please continue to see Figure 3 , after receiving the start test instruction, the local time counter starts timing and reads the current test content corresponding to the current PCF frame in the test table, it also includes:
[0056] Based on the current test content, determine the operation type, operation window and operation time point of the current PCF frame;
[0057] If the operation type of the current PCF frame is sending, then when the count value of the time counter is equal to the operation time point of the current PCF frame, the current PCF frame is sent to the device under test.
[0058] In this embodiment, the test content also includes the destination MAC address, source MAC address, Ethernet frame type, integration period, member vector, synchronization priority, synchronization domain, synchronization frame type, transparent clock, frame sequence, whether it is the last frame, and comparison enable field of each PCF frame.
[0059] Furthermore, after receiving the PCF frame to be tested, the tester first buffers the PCF frame to be tested into the FIFO, then reads out the PCF frame data to be tested buffered in the FIFO, analyzes the content of the frame and completes the curing function.
[0060] In the above step S4, after receiving the PCF frame to be tested sent by the device under test, the step of parsing the PCF frame to be tested and comparing the parsed content with the test content of the current PCF frame to obtain the test result includes:
[0061] Receive the PCF frame to be tested sent by the device under test;
[0062] Parse the PCF frame to be tested and obtain the destination MAC address, source MAC address, Ethernet frame type, integration period, member vector, synchronization priority, synchronization domain, synchronization frame type and transparent clock of the PCF frame to be tested;
[0063] Obtain the destination MAC address, source MAC address, Ethernet frame type, integration period, member vector, synchronization priority, synchronization domain, synchronization frame type, and transparent clock of the current PCF frame from the current test content;
[0064] According to the comparison enable field of the current PCF frame, at least one of the destination MAC address, source MAC address, Ethernet frame type, integration period, member vector, synchronization priority, synchronization domain, synchronization frame type and transparent clock of the PCF frame to be tested is compared with the corresponding items of the destination MAC address, source MAC address, Ethernet frame type, integration period, member vector, synchronization priority, synchronization domain, synchronization frame type and transparent clock of the current PCF frame to obtain a detection consistency test result.
[0065] In this embodiment, if the consistency test result is correct and the current PCF frame is not the last frame, the next PCF frame is used as the current frame, and the process returns to the step of reading the current test content corresponding to the current PCF frame in the test table.
[0066] The following further illustrates the AS6802 protocol conformance testing method provided by the present invention by taking the test contents including CS frames, CA frames, and IN frames in the test table as an example.
[0067] Specifically, after the tester starts the test, the local time counter starts timing. The first test content in the test table is to send a CS frame, so the CS frame is sent at the specified time point; the second test content in the test table is to receive a CS frame, so the receiving window is opened at the specified time point, and after the received PCF frame is solidified, the received PCF frame content is compared with the content specified in the test table. If the test result is correct and it is not the last frame, the test operation is continued on the next frame; further, the third test content in the test table is to send a CA frame, so the tester sends a CA frame at the specified time point; the fourth test content in the test table is to receive a CA frame, so the test The tester opens the receiving window at the specified time point, and after solidifying the received PCF frame, compares the content of the received PCF frame with the content specified in the test table. Similarly, if the test result is correct and it is not the last frame, the test operation continues; the fifth test content in the test table is to send an IN frame, so the tester sends an IN frame at the specified time point; the sixth test content in the test table is to receive an IN frame, so the tester opens the receiving window at the specified time point, solidifies the received PCF frame, and compares the content of the received PCF frame with the content specified in the test table. If the test result is correct and it is the last frame, the test success result is reported and the test ends.
[0068] It can be seen from the above embodiments that the beneficial effects of the present invention are:
[0069] (1) The present invention provides a method for testing the conformance of the AS6802 protocol. The operations during the test are determined by a test table, and various tests can be completed without changing the hardware circuit. Since the state machine jump of the AS6802 protocol is complex, the present invention can also test the state machine jump of the time-triggered Ethernet device under abnormal conditions.
[0070] (2) The present invention can simulate SM to test CM, and can also simulate CM to complete the test of SM.
[0071] (3) The present invention can flexibly adjust whether to test the PCF frame field through the comparison enable bit. For example, when the destination MAC address has a corresponding comparison enable bit, if the comparison enable bit is 1, it is necessary to determine whether the destination MAC address is the same. Conversely, if the comparison enable bit is 0, it is no longer necessary to determine whether the destination MAC address is the same. Even if the destination MAC is not the same, it has no effect. The above method can ignore the destination MAC address, source MAC address, synchronization domain and synchronization priority of the PCF frame, and has extremely strong flexibility.
[0072] In the description of the present invention, the terms "first" and "second" are used for descriptive purposes only and should not be understood to indicate or imply relative importance or implicitly specify the number of the technical features indicated. Therefore, a feature specified as "first" or "second" may explicitly or implicitly include one or more of the features. In the description of the present invention, "plurality" means two or more, unless otherwise specifically defined.
[0073] In the description of this specification, the reference terms "one embodiment", "some embodiments", "example", "specific example", or "some examples" mean that the specific features, structures, materials, or characteristics described in conjunction with the embodiment or example are included in at least one embodiment or example of the present invention. In this specification, the schematic representations of the above terms do not necessarily refer to the same embodiment or example. Moreover, the specific features, structures, materials, or characteristics described can be combined in any appropriate manner in any one or more embodiments or examples. In addition, those skilled in the art can combine and combine different embodiments or examples described in this specification.
[0074] Although the present application is described herein in conjunction with various embodiments, in the process of implementing the claimed application, those skilled in the art can understand and implement other variations of the disclosed embodiments by reviewing the drawings, the disclosure, and the appended claims.
[0075] The above is a further detailed description of the present invention in conjunction with specific preferred embodiments, and the specific implementation of the present invention should not be considered to be limited to these descriptions. For those skilled in the art of the present invention, without departing from the concept of the present invention, several simple deductions or substitutions can be made, which should be considered to fall within the scope of protection of the present invention.
Claims
1. A method for testing AS6802 protocol consistency, characterized in that: Applied to a tester, the method comprises: Obtaining a test table through a data interface, the test table including test contents corresponding to a plurality of protocol control PCF frames, the test contents including at least an operation type, an operation window, and an operation time point of each PCF frame, the operation type including sending or receiving; When receiving the start test instruction, the local time counter starts timing and reads the current test content corresponding to the current PCF frame in the test table; Based on the current test content, if the operation type of the current PCF frame is reception, opening a PCF frame reception window at the operation time point corresponding to the current PCF frame; After receiving the PCF frame to be tested sent by the device under test, parsing the PCF frame to be tested and comparing the parsed content with the test content of the current PCF frame to obtain a test result; Before receiving the step of starting the test instruction, the method further includes: writing the test table into a random access memory RAM; When a start test instruction is received, the local time counter starts timing and reads the current test content corresponding to the current PCF frame in the test table, including: when a start test instruction is received, the local time counter starts timing and reads the current test content corresponding to the current PCF frame in the test table from the RAM; Based on the current test content, if the operation type of the current PCF frame is reception, the step of opening a PCF frame reception window at the operation time point corresponding to the current PCF frame includes: Determine, based on the current test content, an operation type, an operation window, and an operation time point of the current PCF frame; if the operation type of the current PCF frame is reception, then open a PCF frame reception window when the count value of the time counter is equal to the operation time point of the current PCF frame; The PCF frame receiving window takes the operation time point of the current PCF frame as its center and the operation window of the current PCF frame as its width.
2. The method for testing AS6802 protocol consistency according to claim 1, wherein: After receiving the start test instruction, the local time counter starts timing and reads the current test content corresponding to the current PCF frame in the test table, the method further includes: Determine the operation type, operation window, and operation time point of the current PCF frame based on the current test content; If the operation type of the current PCF frame is sending, then when the count value of the time counter is equal to the operation time point of the current PCF frame, the current PCF frame is sent to the device under test.
3. The method for testing AS6802 protocol consistency according to claim 1, wherein: The test content also includes the destination MAC address, source MAC address, Ethernet frame type, integration period, member vector, synchronization priority, synchronization domain, synchronization frame type, transparent clock, frame sequence, whether it is the last frame and comparison enable field of each PCF frame.
4. The method for testing AS6802 protocol consistency according to claim 3, wherein: After receiving the PCF frame to be tested sent by the device under test, the step of parsing the PCF frame to be tested and comparing the parsed content with the test content of the current PCF frame to obtain a test result includes: Receive the PCF frame to be tested sent by the device under test; Parsing the PCF frame to be tested to obtain the destination MAC address, source MAC address, Ethernet frame type, integration period, member vector, synchronization priority, synchronization domain, synchronization frame type and transparent clock of the PCF frame to be tested; Obtaining the destination MAC address, source MAC address, Ethernet frame type, integration period, member vector, synchronization priority, synchronization domain, synchronization frame type and transparent clock of the current PCF frame from the current test content; According to the comparison enable field of the current PCF frame, at least one of the destination MAC address, source MAC address, Ethernet frame type, integration period, member vector, synchronization priority, synchronization domain, synchronization frame type and transparent clock of the PCF frame to be tested is compared with the corresponding items of the destination MAC address, source MAC address, Ethernet frame type, integration period, member vector, synchronization priority, synchronization domain, synchronization frame type and transparent clock of the current PCF frame to obtain a detection consistency test result.
5. The method for testing the consistency of the AS6802 protocol according to claim 4, wherein: If the consistency test result is correct and the current PCF frame is not the last frame, the next PCF frame is used as the current frame, and the process returns to the step of reading the current test content corresponding to the current PCF frame in the test table.