Data transmission test method of vehicle end equipment and related equipment

By configuring an external tester on the vehicle end device, forming a closed-loop link and generating a simulated data stream, the problem of difficulty in detecting data transmission performance of vehicle end device is solved, and visualization of the internal data transmission process of vehicle end device and the detection efficiency is improved.

CN119766683APending Publication Date: 2025-04-04GREAT WALL MOTOR CO LTD
View PDF 4 Cites 0 Cited by

Patent Information

Application Number
CN202411882433.4
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-12-19
Publication Date
2025-04-04

AI Technical Summary

Technical Problem

It is difficult to detect the data transmission performance of vehicle-side equipment because the detector cannot obtain the data transmission status inside the vehicle-side equipment.

Method used

By configuring the port of the external tester and the port of the vehicle end device, a closed-loop link is formed, a simulation data stream is generated and sent to the vehicle end device, analyzing the data transmission process, and analyzing the test data stream to evaluate the data transmission capability of the vehicle end device.

Benefits of technology

It realizes visualization of the internal data transmission process of vehicle-side equipment, improves the accuracy and efficiency of detection, and can intuitively see the data transmission situation of vehicle-side equipment.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119766683A_ABST
    Figure CN119766683A_ABST
Patent Text Reader

Abstract

The invention provides a testing method for vehicle-end equipment and related equipment, and the method comprises the steps: configuring a port of an external tester and a port of the vehicle-end equipment, so as to enable the port of the external tester and the port of the vehicle-end equipment to form a closed-loop link. And generating a simulation data stream, and sending the simulation data stream to the port of the vehicle-end equipment through the port of the external tester, so that the simulation data stream is transmitted in the vehicle-end equipment, and obtaining a test data stream after the transmission is completed. And receiving the test data flow output by the vehicle-end equipment through the port of the external tester, and completing the test of the vehicle-end equipment. Therefore, the simulation data flow is transmitted among the server, the external tester and the vehicle-end equipment to form a closed loop. Through the test data stream, the detection personnel can visually see the data transmission process in the vehicle end equipment. And the data transmission capability of the vehicle-end equipment can be detected by comparing and analyzing the simulation data stream and the test data stream subsequently.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of vehicle testing technology, and in particular to a data transmission testing method for vehicle-side equipment and related equipment. Background Art

[0002] As vehicles become more intelligent, the data transmission rate in vehicles is also increasing, resulting in a large amount of data flow in the vehicle network, which places high demands on the data transmission capacity of vehicle-side devices. However, since testers cannot obtain the data transmission status inside the vehicle-side device, they cannot determine whether the vehicle-side device has the corresponding data transmission capacity, which brings certain difficulties to the performance testing of vehicle-side devices. Summary of the invention

[0003] In view of this, the purpose of this application is to propose a data transmission test method and related equipment for vehicle-side equipment to solve the problem of difficulty in detecting the data transmission performance of vehicle-side equipment.

[0004] Based on the above purpose, the first aspect of the present application provides a data transmission test method for a vehicle-side device, comprising:

[0005] Configuring a port of an external tester and a port of a vehicle-end device so that a closed-loop link is formed between the port of the external tester and the port of the vehicle-end device;

[0006] Generate a simulation data stream, and send the simulation data stream to the port of the vehicle-end device through the port of the external tester, so that the simulation data stream is transmitted inside the vehicle-end device, and a test data stream is obtained after the transmission is completed;

[0007] The test data stream output by the vehicle-side device is received through the port of the external tester to complete the test of the vehicle-side device.

[0008] Optionally, the port of the external tester includes a first output port and a first input port, and the port of the vehicle-end device includes a second output port and a second input port; configuring the port of the external tester and the port of the vehicle-end device so that a closed-loop link is formed between the port of the external tester and the port of the vehicle-end device, including:

[0009] The first output port is controlled to be connected to the second input port, and the second output port is controlled to be connected to the first input port.

[0010] Optionally, generating a simulation data stream and sending the simulation data stream to a port of the vehicle-side device through a port of the external tester includes:

[0011] Generate a first simulation data stream and a second simulation data stream, wherein the transmission priority of the first simulation data stream is higher than the transmission priority of the second simulation data stream; each data frame in the second simulation data stream is divided into a plurality of fragment frames;

[0012] At a first moment, the second simulation data stream is sent to the port of the vehicle-end device through the port of the external tester, and at a second moment, the first simulation data stream is sent to the port of the vehicle-end device through the port of the external tester; wherein, the first moment is earlier than the second moment, and the time interval between the first moment and the second moment is less than the time required for the second simulation data stream to be transmitted inside the vehicle-end device.

[0013] Optionally, the method further includes:

[0014] The test data stream is parsed to determine whether the test data stream satisfies a preset transmission rule. If not, it is determined that the data transmission of the vehicle-side device is abnormal; wherein the preset transmission rule characterizes the transmission mechanism of the simulation data stream inside the vehicle-side device.

[0015] Optionally, determining whether the test data stream satisfies a preset transmission rule includes:

[0016] In the test data stream, for each data frame in the second simulation data stream, in response to all fragment frames belonging to the data frame being continuously transmitted, it is determined that the test data stream does not satisfy a preset transmission rule.

[0017] Optionally, determining whether the test data stream satisfies a preset transmission rule includes:

[0018] In the test data stream, in response to the presence of a sequence number arrangement error of a fragment frame, it is determined that the test data stream does not satisfy a preset transmission rule.

[0019] Optionally, before sending the simulated data stream to the port of the vehicle-end device through the port of the external tester, the method further includes:

[0020] According to the data transmission speed of the vehicle-side device, the transmission speed of the simulation data stream in the closed-loop link is configured.

[0021] The second aspect of the present application also provides a data transmission test device for a vehicle-side device, comprising:

[0022] A setting module is configured to configure a port of an external tester and a port of a vehicle-end device so as to form a closed-loop link between the port of the external tester and the port of the vehicle-end device;

[0023] A sending module is configured to generate a simulation data stream, and send the simulation data stream to the port of the vehicle-end device through the port of the external tester, so that the simulation data stream is transmitted inside the vehicle-end device, and a test data stream is obtained after the transmission is completed;

[0024] The receiving module is configured to receive the test data stream output by the vehicle-side device through the port of the external tester to complete the test of the vehicle-side device.

[0025] The third aspect of the present application also provides an electronic device, comprising a memory, a processor, and a computer program stored in the memory and executable by the processor, wherein the processor implements the method described in the first aspect when executing the computer program.

[0026] The fourth aspect of the present application also provides a non-transitory computer-readable storage medium, which stores computer instructions, and the computer instructions are used to enable a computer to execute the method described in the first aspect.

[0027] As can be seen from the above, the data transmission test method and related equipment of the vehicle-side device provided by the present application include configuring the port of the external tester and the port of the vehicle-side device so that a closed-loop link is formed between the port of the external tester and the port of the vehicle-side device. After the closed loop is formed, it can be ensured that the data stream can be transmitted between the external tester and the vehicle-side device. At the same time, the data transmission status data of the vehicle-side device can be collected by the external tester. That is, the data transmission process inside the vehicle-side device is visualized. Generate a simulation data stream, and send the simulation data stream to the port of the vehicle-side device through the port of the external tester so that the simulation data stream is transmitted inside the vehicle-side device, and obtain a test data stream after the transmission is completed. Generate a simulation data stream for testing the vehicle-side device on the service side, simulate the data transmission process inside the vehicle-side device through the simulation data stream, and provide support for the data transmission performance test of the vehicle-side device. Receive the test data stream output by the vehicle-side device through the port of the external tester to complete the test of the vehicle-side device. So far, the transmission of the simulation data stream between the service side, the external tester and the vehicle-side device forms a closed loop. Through the test data stream, the inspector can intuitively see the data transmission process inside the vehicle-side device. Subsequently, through the automatic comparison and analysis of the simulation data stream and the test data stream, the data transmission capacity of the vehicle-side device can be tested to improve the accuracy and efficiency of the test. BRIEF DESCRIPTION OF THE DRAWINGS

[0028] In order to more clearly illustrate the technical solutions in the present application or related technologies, the drawings required for use in the embodiments or related technical descriptions are briefly introduced below. Obviously, the drawings described below are only embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without creative work.

[0029] Figure 1 A flow chart of a data transmission test method for a vehicle-side device according to an embodiment of the present application;

[0030] Figure 2 A schematic diagram of the connection between the server, the external tester and the vehicle-side device in an embodiment of the present application;

[0031] Figure 3 A schematic diagram of the OSI seven-layer reference protocol model according to an embodiment of the present application;

[0032] Figure 4 A schematic diagram of the frame structure of an eMAC frame and a pMAC frame according to an embodiment of the present application;

[0033] Figure 5 A schematic diagram of the frame structure of a fragmented frame according to an embodiment of the present application;

[0034] Figure 6 This is a structural schematic diagram of a data transmission test device for a vehicle-side device according to an embodiment of the present application;

[0035] Figure 7 This is a schematic diagram of the hardware structure of an electronic device according to an embodiment of the present application. DETAILED DESCRIPTION

[0036] In order to make the objectives, technical solutions and advantages of the present application more clearly understood, the present application is further described in detail below in combination with specific embodiments and with reference to the accompanying drawings.

[0037] It should be noted that, unless otherwise defined, the technical terms or scientific terms used in the embodiments of the present application should be the usual meanings understood by people with ordinary skills in the field to which the present application belongs. The "first", "second" and similar words used in the embodiments of the present application do not represent any order, quantity or importance, but are only used to distinguish different components. "Including" or "comprising" and similar words mean that the elements or objects appearing in front of the word cover the elements or objects listed after the word and their equivalents, without excluding other elements or objects. "Connect" or "connected" and similar words are not limited to physical or mechanical connections, but can include electrical connections, whether direct or indirect. "Up", "down", "left", "right" and the like are only used to indicate relative positional relationships. When the absolute position of the described object changes, the relative positional relationship may also change accordingly.

[0038] As described in the background technology, with the development of intelligent vehicles, the number of electronic devices in vehicles has gradually increased. The data processing capacity and data processing rate of electronic devices have also gradually increased. When testing the vehicle offline, it is necessary to test the data transmission capacity of the electronic equipment to ensure the normal delivery of the vehicle. However, when testing the data transmission capacity of the electronic equipment, the test personnel cannot intuitively see the data transmission status inside the electronic equipment. The detection of the data transmission performance of the electronic equipment is equivalent to black box detection. Therefore, it is also difficult to determine whether the electronic equipment has the corresponding data transmission capacity.

[0039] In view of this, the present application proposes a data transmission test method for vehicle-side equipment, which realizes a closed loop between the external tester and the vehicle-side equipment by configuring the interface between the external tester and the vehicle-side equipment. By generating and sending a simulated data stream, the simulated data stream is sent to the inside of the vehicle-side equipment for transmission, and then the data transmission method inside the vehicle-side equipment is verified by receiving the test data stream output by the vehicle-side equipment. That is, by converting the black box test into a gray box or even a white box method, the problem of being unable to determine the internal transmission status of the vehicle-side equipment is solved.

[0040] The embodiments of the present application are described in detail below with reference to the accompanying drawings.

[0041] This application proposes a data transmission test method for vehicle-side equipment, which is applied to the server side. Figure 1 , including the following steps:

[0042] Step 102: configure the port of the external tester and the port of the vehicle-end device so as to form a closed-loop link between the port of the external tester and the port of the vehicle-end device.

[0043] Specifically, the server in this embodiment can be a host computer or a test platform, and the test script can be integrated through the server to test the vehicle-side device. At the same time, the ports of the external tester and the vehicle-side device can also be configured. Among them, the external tester is an Ethernet tester, which is mainly used to evaluate and verify the performance and stability of Ethernet and other network infrastructures. The server is connected to the external tester, and the external tester is connected to the vehicle-side device. The server realizes the closed loop between the external tester and the vehicle-side device by configuring the port of the external tester and the port of the vehicle-side device. In other words, data can be sent and received between the external tester and the vehicle-side device, and data can be sent to the vehicle-side device or received from the vehicle-side device through the external tester. Correspondingly, the vehicle-side device can receive data from the external tester or send data to the external tester. Exemplarily, the vehicle-side device in this embodiment can be an electronic controller (Electronic Control Unit, ECU) of the vehicle.

[0044] Step 104, generate a simulation data stream, and send the simulation data stream to the port of the vehicle-end device through the port of the external tester, so that the simulation data stream is transmitted inside the vehicle-end device, and a test data stream is obtained after the transmission is completed.

[0045] Specifically, the automatic test software is installed on the server in advance. The automatic test software can provide a complete integrated test development and execution environment, which can be used for test script development, compilation, test parameter allocation, test execution, test monitoring, and test report generation. The automatic test software is configured to connect with the data simulation software so that the generated simulation data stream can be automatically sent through the automatic test software. At the same time, the port information of the vehicle-side device is configured in the automatic test software to facilitate the automated testing of the vehicle-side device.

[0046] Generate a simulated data stream through data simulation software, send the simulated data stream to the external tester through automatic test software, and then send the simulated data stream to the port of the vehicle-side device through the port of the external tester. After that, the simulated data stream can be transmitted inside the vehicle-side device. After the transmission is completed, a test data stream is generated. When the data frames of the simulated data stream are transmitted inside the vehicle-side device, they are reassembled in a certain transmission order according to the data transmission protocol to obtain the test data stream.

[0047] In addition, it should be noted that the rate and size of the created simulated data stream must meet the port capacity of the vehicle-side device to ensure that the simulated data stream can flow into the vehicle-side device through the port.

[0048] Step 106: Receive the test data stream output by the vehicle-side device through the port of the external tester to complete the test of the vehicle-side device.

[0049] Specifically, when the simulated data stream is transmitted inside the vehicle-side device, a test data stream is generated. The test data stream flows from the port of the vehicle-side device to the port of the external tester to complete the test data collection process of the vehicle-side device. The test data stream can intuitively present the transmission of the simulated data stream inside the vehicle-side device. For example, the transmission order of each data frame in the simulated data stream can be observed from the test data stream, whether data loss or transmission errors occur during the transmission process, etc.

[0050] Based on the above steps 102 to 106, the vehicle-side device testing method provided in this embodiment is applied to the service end, and the method includes configuring the port of the external tester and the port of the vehicle-side device so that the port of the external tester and the port of the vehicle-side device form a closed loop. After the closed loop is formed, it can be ensured that the data stream can be transmitted between the external tester and the vehicle-side device. At the same time, the data transmission status data of the vehicle-side device can be collected through the external tester. That is, the data transmission process inside the vehicle-side device is visualized. Generate a simulation data stream, and send the simulation data stream to the port of the vehicle-side device through the port of the external tester, so that the simulation data stream is transmitted inside the vehicle-side device, and obtain a test data stream after the transmission is completed. Generate a simulation data stream for testing the vehicle-side device on the service end, simulate the data transmission process inside the vehicle-side device through the simulation data stream, and provide support for the data transmission performance test of the vehicle-side device. Receive the test data stream output by the vehicle-side device through the port of the external tester to complete the collection process of the test data of the vehicle-side device. So far, the transmission of the simulation data stream between the service end, the external tester and the vehicle-side device forms a closed loop. Through the test data stream, the test personnel can intuitively see the data transmission process inside the vehicle-side device. Subsequently, by comparing and analyzing the simulation data stream and the test data stream, the data transmission capability of the vehicle-side device can be tested.

[0051] Before testing the data transmission capability of the vehicle-side device, it is first necessary to ensure that the simulated data stream can be smoothly transmitted between the external tester and the vehicle-side device. Therefore, it is particularly important to form a closed loop of data transmission between the external tester and the vehicle-side device, which is described below through a specific embodiment.

[0052] In some embodiments, the port of the external tester includes a first output port and a first input port, and the port of the vehicle-end device includes a second output port and a second input port; configuring the port of the external tester and the port of the vehicle-end device so that a closed-loop link is formed between the port of the external tester and the port of the vehicle-end device, including:

[0053] The first output port is controlled to be connected to the second input port, and the second output port is controlled to be connected to the first input port.

[0054] Specifically, Figure 2 The figure shows the connection diagram of the server, external tester and vehicle-side equipment. Figure 2As shown, the server is connected to the external tester via Ethernet, and the server and the external tester are configured in the same network segment. The ports of the external tester include a first output port A1 and a first input port A2, and the ports of the vehicle-side device include a second output port B1 and a second input port B2. The first output port A1, the first input port A2, the second output port B1 and the second input port B2 are configured on the server through a shell script so that the four ports form a transmission closed-loop link. The shell script is a program written using the functions of the shell. This program uses a plain text file, writes some shell syntax and instructions in it, and then uses regular expressions, pipeline commands, and data flow redirection functions to achieve the target function.

[0055] from Figure 2 It can be seen from the data flow that the simulation data stream flows from the first output port A1 to the second input port B2. After the internal transmission of the vehicle-side device is completed, a test data stream is generated, and the test data stream is output through the second output port B1. The test data stream flows to the first input port A2. In this way, a closed-loop data transmission channel is formed between the external tester and the vehicle-side device. Afterwards, the service end obtains the test data stream from the external tester and parses the test data stream to evaluate the data transmission capability of the vehicle-side device. Through the method of this embodiment, a data transmission channel between the external tester and the vehicle-side device can be established, providing a communication link for the transmission of the simulation data stream and the test data stream, assisting in the visualization of the test data stream, and providing convenience for the detection process of the detection personnel.

[0056] After configuring the external tester and the vehicle-side device to form a closed-loop link, when sending the simulated data stream to the vehicle-side device, it is also necessary to configure the transmission speed of the data transmission link so that it can match the transmission capacity of the vehicle-side device and smoothly transmit data within the closed-loop link. This is specifically explained in the following embodiment.

[0057] In some embodiments, before sending the simulated data stream to the port of the vehicle-side device through the port of the external tester, the method further includes: configuring the transmission speed of the simulated data stream in the closed-loop link according to the data transmission speed of the vehicle-side device.

[0058] Specifically, before sending the simulated data stream, it is also necessary to determine the data transmission speed of the vehicle-side device, and determine the transmission speed of the simulated data stream according to the data transmission speed of the vehicle-side device, that is, determine the transmission speed of the data transmission link. If the data transmission speed of the vehicle-side device does not match the transmission speed of the simulated data stream, the vehicle-side device may not be able to receive the simulated data stream, and subsequent data transmission performance testing cannot be performed. Therefore, the method provided in this embodiment can ensure that the vehicle-side device can send and receive the simulated data stream in a timely manner, and provide support for the smooth transmission of subsequent simulated data.

[0059] In the field of Ethernet communication, TSN (Time-Sensitive Networking) is a family of protocols that achieve deterministic minimum latency in non-deterministic Ethernet. It is a set of protocol standards developed by IEEE 802.1. It provides a common time-sensitive mechanism for the data link layer of the Ethernet protocol, and provides determinism and reliability for standard Ethernet to ensure real-time, deterministic and reliable data transmission, thereby improving data transmission efficiency. Global precise clock synchronization is established based on the IEEE802.1AS standard. Based on the IEEE802.1Qbv standard, the global time axis is divided into multiple time periods, and each clock period is divided into multiple continuous time slices. In each time slice with the same number, only data frames of the same type can be transmitted. In this way, data streams of various traffic levels are scheduled for transmission to avoid transmission conflicts.

[0060] The IEEE802.1Qbu and IEEE802.3br standards define frame preemption technology, which aims to reduce data flow delay while maximizing the effective bandwidth of the data link. Frame preemption technology belongs to the MAC sublayer of the data link layer in the OSI seven-layer reference protocol. Figure 3 Figure 1 shows a schematic diagram of the OSI seven-layer reference protocol model. Figure 3 As shown in the figure, the OSI seven-layer reference protocol model includes the application layer, presentation layer, session layer, transport layer, network layer, data link layer and physical layer. The frame preemption technology can be summarized as two independent data channels between the high layer and the MAC sublayer, which transmit time-sensitive frames and preemptible frames with lower priority respectively. The time-sensitive frames are framed into data frames in the mPacket frame format through the eMAC (express MAC) of the MAC sublayer, and the preemptible frames are framed into mPacket frames through the pMAC (Preemptable MAC). All mPacket frames exchange data with the physical layer through the only media independent interface between the data link layer and the physical layer. pMAC can be preempted by eMAC, and pMAC waits for eMAC data transmission to complete before transmitting data.

[0061] The application of the frame preemption mechanism can improve bandwidth utilization and ensure the real-time and reliability of data. When applied on the vehicle side, it can allow higher priority data to be transmitted first between various devices on the vehicle side, improving the overall data processing performance of the vehicle.

[0062] However, since the Ethernet data transmission rate is very fast, a large amount of data flow will be generated in the network instantly, and the processing mechanism inside the vehicle-side device cannot be observed. Therefore, when testing the vehicle-side device, it is impossible to determine whether the vehicle-side device has correctly executed the frame preemption mechanism, which brings certain difficulties to the testing of the vehicle-side device. The aforementioned embodiments of the present application realize the detection of the data transmission situation inside the vehicle-side device. If it is necessary to detect the execution of the frame preemption mechanism during the data transmission process of the vehicle-side device, it is also necessary to further configure the simulation data flow to construct a simulation data flow that can meet the test requirements, which is explained below through specific embodiments.

[0063] In some embodiments, generating a simulation data stream and sending the simulation data stream to a port of the vehicle-side device through a port of the external tester includes:

[0064] Generate a first simulation data stream and a second simulation data stream, wherein the transmission priority of the first simulation data stream is higher than the transmission priority of the second simulation data stream; each data frame in the second simulation data stream is divided into a plurality of fragment frames;

[0065] At a first moment, the second simulation data stream is sent to the port of the vehicle-end device through the port of the external tester, and at a second moment, the first simulation data stream is sent to the port of the vehicle-end device through the port of the external tester; wherein, the first moment is earlier than the second moment, and the time interval between the first moment and the second moment is less than the time required for the second simulation data stream to be transmitted inside the vehicle-end device.

[0066] Specifically, in the frame preemption mechanism, data streams with high priority are transmitted first. Therefore, when constructing a simulation data stream, two data streams with different priorities need to be constructed. In this embodiment, a first simulation data stream with high priority and a second simulation data stream with low priority are generated by data simulation software. The second simulation data stream with low priority is sent to the vehicle-side device at a first moment, and the first simulation data stream with high priority is sent to the vehicle-side device at a second moment thereafter. By sending the two simulation data streams at intervals, it is possible to test whether the vehicle-side device can achieve the interruption of the second simulation data stream with low priority by the first simulation data stream with high priority during transmission. Before the transmission of the second simulation data stream is completed, it is necessary to ensure that the first simulation data stream can reach the vehicle-side device. Therefore, the time interval between the first moment and the second moment is less than the transmission time required for the second simulation data stream inside the vehicle-side device.

[0067] Exemplarily, the first simulation data stream is an express frame, and the second simulation data stream is a preemptible frame. The configuration codes of the first simulation data stream and the second simulation data stream are as follows:

[0068] Configure Test stream1(express frame)

[0069] Set priority = 6

[0070] Set frame length of stream=256B

[0071] Set rate of stream=1Frame / sec

[0072] Configure Test stream 2(preemptible frame)

[0073] Set priority = 0

[0074] Divided into 5 fragmented frames

[0075] Frame length is 100 / 200 / 300 / 400 / 500B

[0076] Set rate of stream=1Frame / sec

[0077] From the above code, we can know that when configuring the first simulated data stream (Test stream 1), the priority of the first simulated data stream is 6, the frame length is 256B, and the frame transmission rate is 1 frame / second. When configuring the second simulated data stream (Test stream 2), the priority of the second simulated data stream is 0, and each data frame of the second simulated data stream is divided into 5 fragmented frames, and the frame length of each fragmented frame is 100B / 200B / 300B / 400B / 500B, and the frame transmission rate is 1 frame / second.

[0078] The automatic test software on the server side will automatically send the first simulation data stream and the second simulation data stream to the port of the vehicle-side device. After the data transmission is completed, the transmission results of the first simulation data stream and the second simulation data stream, that is, the test data stream, will be received.

[0079] It should be noted that before sending the first simulation data stream and the second simulation data stream to the vehicle-side device, the frame preemption function of the vehicle-side device port needs to be activated first. The activation method of the frame preemption function can be realized through an activation instruction, specifically, sending an activation instruction to the vehicle-side device through the server to enable the vehicle-side device to turn on the frame preemption function.

[0080] The method of this embodiment constructs two simulation data streams with different priorities and sends them out at different times to achieve differentiation of the arrival time at the vehicle-side device, thus providing the possibility for testing the frame preemption function of the vehicle-side device.

[0081] After the server collects the test data stream through the external tester, it can also analyze the test data stream to determine the transmission status of the simulated data stream by the vehicle-side device, which is explained below through a specific embodiment.

[0082] In some embodiments, the method further includes: parsing the test data stream to determine whether the test data stream satisfies a preset transmission rule, and if not, determining that the data transmission of the vehicle-side device is abnormal; wherein the preset transmission rule characterizes the transmission mechanism of the simulation data stream within the vehicle-side device.

[0083] Specifically, the preset transmission rules in this embodiment may be transmission rules corresponding to the frame preemption mechanism. For example, under the frame preemption mechanism, when the vehicle-side device is transmitting the first fragment frame of one of the data frames of the second simulation data stream, if the vehicle-side device receives the first simulation data stream, after the transmission of the first fragment frame is completed, the transmission of the second simulation data stream is suspended, and the transmission of the first simulation data stream is started. Only after the transmission of the first simulation data stream is completed can the next fragment frame of the second simulation data stream be transmitted. In other words, each time a data frame of the first simulation data stream is received, the transmission of the data frame of the second simulation data stream is immediately interrupted until all the data frames of the first simulation data stream are transmitted, and then the transmission of the data frames of the second simulation data stream is continued.

[0084] When detecting the test data stream, if it is found that the transmission mode of the first simulation data stream and the second simulation data stream does not meet the preset transmission rules, it can be determined that the data transmission of the vehicle-end device is abnormal and the vehicle-end device has not passed the test.

[0085] The server uses network packet analysis software when testing the test data stream. The function of the network packet analysis software is to intercept network data and display the most detailed network packet information as possible. The network packet analysis software can parse the specific fields of each data frame in the test data stream to determine whether each data frame or fragment frame belongs to the first simulation data stream or the second simulation data stream, and determine the frame sequence number of each fragment frame. In this way, it is possible to analyze and determine whether the vehicle-side device transmits the first simulation data stream and the second simulation data stream according to the frame preemption mechanism, and whether the order of transmission is correct. Through the method of this embodiment, the corresponding preset transmission rules can be determined for the data transmission function to be tested of the vehicle-side device, so as to accurately determine whether there is a transmission anomaly in the vehicle-side device, and provide convenience for the detection process of the detection personnel.

[0086] Furthermore, when detecting whether a test data stream satisfies a preset transmission rule, a detection method may include: in the test data stream, for each data frame in the second simulation data stream, in response to all fragmented frames belonging to the data frame being transmitted continuously, determining that the test data stream does not satisfy the preset transmission rule.

[0087] Specifically, continuing the above example, the first simulated data stream is an eMAC frame, and the second simulated data stream is a pMAC frame. The frame structures of the eMAC frame and the pMAC frame are different. Figure 4 A schematic diagram of the frame structure of an eMAC frame and a pMAC frame is shown. Figure 4 The left side shows the frame structure of the eMAC frame. Figure 4 The right side shows the frame structure of a pMAC frame that has not been divided into fragmented frames. The Preamble in the frame structure is the preamble code, which usually occupies 7 bytes. SMD (Start mPacket Delimiter) indicates whether the mPacke contains a fast packet, the beginning of a preemptible packet (initial fragment or complete packet), or any continuous fragments. SMD-E represents the eMAC frame, and SMD-Sx represents the pMAC frame, occupying one byte. MAC DA represents the destination MAC address, occupying 6 bytes, and MAC SA represents the source MAC address, occupying 6 bytes. Ethertype represents the type, occupying two bytes, Data represents the data payload, and FCS is the checksum, occupying 4 bytes.

[0088] When the data frame of the second simulation data stream is divided into a plurality of slice frames, each slice frame also has a corresponding frame structure. Figure 5 A schematic diagram of the frame structure of a slice frame is shown. Figure 5 The left figure in the figure shows the first frame of the fragment frame, that is, the first fragment frame. The frame structure is basically the same as the pMAC frame, the difference is that the check code is MCRC. Figure 4The figure in the middle position represents the intermediate frame of the fragmented frame, the difference is that the field SMD-Sx (Start Fragment) is replaced by the field SMD-Cx (Continuation Fragment). The field Frag Count represents the frame count, which occupies one byte. The sequence number of the current fragmented frame can be represented by Frag Count. For example, if the data in the test data stream includes SMD:0x2a[SMD-C3]Frag Count:0x4c[#1], it means that the current fragmented frame is an intermediate frame, and the sequence number of the intermediate frame is 1, which is the first intermediate frame. If the data in the test data stream includes SMD:0x2a[SMD-C3]Frag Count:0xb3[#3], it means that the current fragmented frame is an intermediate frame, and the sequence number of the intermediate frame is 3, which is the third intermediate frame. Figure 5 The right figure in the figure shows the last frame in the fragment frame. Different from the middle frame, the check code is FCS.

[0089] Through the fields in the above frame structure, it can be determined whether the current data frame is a pMAC frame or an eMAC frame, and whether it is a fragmented frame and the sequence number of the fragmented frame. According to the transmission rules of the frame preemption mechanism, the eMAC frame will interrupt the transmission of the pMAC frame. Therefore, if all the fragmented frames corresponding to each data frame in the second simulation data stream are continuously transmitted, it means that the second simulation data stream is not interrupted by the first simulation data stream, that is, the data transmission inside the vehicle-side device does not implement the frame preemption mechanism. It can be determined that the test data stream does not meet the preset transmission rules, the vehicle-side device has not passed the test, and the test personnel need to perform further maintenance or debugging on the vehicle-side device. The method of this embodiment provides a method for testing whether the vehicle-side device can transmit data according to the frame preemption mechanism, realizes the automated testing of the vehicle-side device, and can generate a test report through the automatic testing software and feedback to the test personnel, reducing the workload of the test personnel.

[0090] In another embodiment of the present application, the detection method for detecting whether a test data stream satisfies a preset transmission rule may further include: in the test data stream, in response to a sequence number arrangement error of a fragment frame, determining that the test data stream does not satisfy the preset transmission rule.

[0091] Specifically, through Figure 5The Frag Count field in the frame structure of the fragmented frame can determine the sequence number of the fragmented frame. If the vehicle-side device can transmit the simulated data stream normally, the sequence numbers of the fragmented frames in the test data stream should be arranged in sequence. Even if the transmission is interrupted, there will be no transmission sequence error when the transmission is resumed. For example, the transmission sequence number arrangement of the intermediate frames of the test data stream should be [#1][#2][#3][#4]. An eMAC frame can be inserted between any two intermediate frames, but it does not affect the arrangement order from small to large. However, if the transmission sequence number arrangement of the intermediate frames is wrong, such as [#1][#3][#4][#2], it means that the fragmented frames are not arranged according to the frame sequence number, and the test data stream does not meet the preset transmission rules. The vehicle-side device did not pass the test, and the inspection personnel need to further maintain or debug the vehicle-side device.

[0092] This embodiment provides a method for testing whether the vehicle-side device can transmit data according to the frame preemption mechanism. Even if a high-priority simulation data stream interrupts the transmission process of a low-priority simulation data stream, if an error occurs in the fragmented frame transmission of the low-priority simulation data stream, it also indicates that the vehicle-side device has not successfully executed the frame preemption function.

[0093] It should be noted that the method of the embodiment of the present application can be performed by a single device, such as a computer or server. The method of this embodiment can also be applied to a distributed scenario and completed by multiple devices cooperating with each other. In the case of such a distributed scenario, one of the multiple devices can only perform one or more steps in the method of the embodiment of the present application, and the multiple devices will interact with each other to complete the described method.

[0094] It should be noted that the above describes some embodiments of the present application. Other embodiments are within the scope of the appended claims. In some cases, the actions or steps recorded in the claims can be performed in an order different from that in the above embodiments and still achieve the desired results. In addition, the processes depicted in the accompanying drawings do not necessarily require the specific order or continuous order shown to achieve the desired results. In some embodiments, multitasking and parallel processing are also possible or may be advantageous.

[0095] Based on the same inventive concept, corresponding to any of the above-mentioned embodiment methods, the present application also provides a data transmission test device for a vehicle-side device.

[0096] refer to Figure 6 , the data transmission test device of the vehicle-side device comprises:

[0097] A setting module 602 is configured to configure a port of an external tester and a port of a vehicle-end device so that a closed-loop link is formed between the port of the external tester and the port of the vehicle-end device;

[0098] The sending module 604 is configured to generate a simulation data stream, and send the simulation data stream to the port of the vehicle-end device through the port of the external tester, so that the simulation data stream is transmitted inside the vehicle-end device;

[0099] The receiving module 606 is configured to receive the test data stream output by the vehicle-side device through the port of the external tester to complete the test of the vehicle-side device; wherein the test data stream includes the simulation data stream.

[0100] In some embodiments, the port of the external tester includes a first output port and a first input port, and the port of the vehicle-side device includes a second output port and a second input port; the setting module 602 is configured to control the first output port to be connected to the second input port, and control the second output port to be connected to the first input port.

[0101] In some embodiments, the sending module 604 is configured to generate a first simulation data stream and a second simulation data stream, wherein the transmission priority of the first simulation data stream is higher than the transmission priority of the second simulation data stream; each data frame in the second simulation data stream is divided into a plurality of fragment frames;

[0102] At a first moment, the second simulation data stream is sent to the port of the vehicle-end device through the port of the external tester, and at a second moment, the first simulation data stream is sent to the port of the vehicle-end device through the port of the external tester; wherein, the first moment is earlier than the second moment, and the time interval between the first moment and the second moment is less than the time required for the second simulation data stream to be transmitted inside the vehicle-end device.

[0103] In some embodiments, it also includes a parsing module, which is configured to parse the test data stream to determine whether the test data stream satisfies a preset transmission rule. If not, it is determined that the data transmission of the vehicle-side device is abnormal; wherein the preset transmission rule characterizes the transmission mechanism of the simulation data stream inside the vehicle-side device.

[0104] In some embodiments, the parsing module is further configured to, in the test data stream, for each data frame in the second simulation data stream, determine that the test data stream does not meet the preset transmission rule in response to all fragmented frames belonging to the data frame being transmitted continuously.

[0105] In some embodiments, the parsing module is further configured to determine that the test data stream does not meet a preset transmission rule in response to a sequence number arrangement error of a fragment frame in the test data stream.

[0106] In some embodiments, before the simulated data stream is sent to the port of the vehicle-end device through the port of the external tester, a configuration module is also included, which is configured to configure the transmission speed of the simulated data stream in the closed-loop link according to the data transmission speed of the vehicle-end device.

[0107] For the convenience of description, the above device is described in terms of functions divided into various modules. Of course, when implementing the present application, the functions of each module can be implemented in the same or multiple software and / or hardware.

[0108] The device of the above embodiment is used to implement the data transmission test method of the corresponding vehicle-side device in any of the above embodiments, and has the beneficial effects of the corresponding method embodiment, which will not be repeated here.

[0109] Based on the same inventive concept, corresponding to any of the above-mentioned embodiment methods, the present application also provides an electronic device, including a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein when the processor executes the program, the data transmission test method for the vehicle-side device described in any of the above embodiments is implemented.

[0110] Figure 7 A more specific schematic diagram of the hardware structure of an electronic device provided in this embodiment is shown, and the device may include: a processor 1010, a memory 1020, an input / output interface 1030, a communication interface 1040, and a bus 1050. The processor 1010, the memory 1020, the input / output interface 1030, and the communication interface 1040 are connected to each other through the bus 1050 in the device.

[0111] The processor 1010 can be implemented by a general-purpose CPU (Central Processing Unit), a microprocessor, an application-specific integrated circuit (ASIC), or one or more integrated circuits, and is used to execute relevant programs to implement the technical solutions provided in the embodiments of this specification.

[0112] The memory 1020 may be implemented in the form of ROM (Read Only Memory), RAM (Random Access Memory), static storage device, dynamic storage device, etc. The memory 1020 may store an operating system and other application programs. When the technical solutions provided in the embodiments of this specification are implemented by software or firmware, the relevant program codes are stored in the memory 1020 and are called and executed by the processor 1010.

[0113] The input / output interface 1030 is used to connect the input / output module to realize information input and output. The input / output module can be configured in the device as a component (not shown in the figure), or it can be externally connected to the device to provide corresponding functions. The input device may include a keyboard, a mouse, a touch screen, a microphone, various sensors, etc., and the output device may include a display, a speaker, a vibrator, an indicator light, etc.

[0114] The communication interface 1040 is used to connect a communication module (not shown) to realize communication interaction between the device and other devices. The communication module can realize communication through a wired mode (such as USB, network cable, etc.) or a wireless mode (such as mobile network, WIFI, Bluetooth, etc.).

[0115] The bus 1050 includes a path that transmits information between the various components of the device (eg, the processor 1010, the memory 1020, the input / output interface 1030, and the communication interface 1040).

[0116] It should be noted that, although the above device only shows the processor 1010, the memory 1020, the input / output interface 1030, the communication interface 1040 and the bus 1050, in the specific implementation process, the device may also include other components necessary for normal operation. In addition, it can be understood by those skilled in the art that the above device may also only include the components necessary for implementing the embodiments of the present specification, and does not necessarily include all the components shown in the figure.

[0117] The electronic device of the above-mentioned embodiment is used to implement the data transmission test method of the corresponding vehicle-side device in any of the above-mentioned embodiments, and has the beneficial effects of the corresponding method embodiment, which will not be repeated here.

[0118] Based on the same inventive concept, corresponding to any of the above-mentioned embodiment methods, the present application also provides a non-transitory computer-readable storage medium, wherein the non-transitory computer-readable storage medium stores computer instructions, and the computer instructions are used to enable the computer to execute the data transmission test method of the vehicle-side device as described in any of the above embodiments.

[0119] The computer-readable medium of this embodiment includes permanent and non-permanent, removable and non-removable media, and information storage can be implemented by any method or technology. Information can be computer-readable instructions, data structures, modules of programs, or other data. Examples of computer storage media include, but are not limited to, phase change memory (PRAM), static random access memory (SRAM), dynamic random access memory (DRAM), other types of random access memory (RAM), read-only memory (ROM), electrically erasable programmable read-only memory (EEPROM), flash memory or other memory technology, read-only compact disk read-only memory (CD-ROM), digital versatile disk (DVD) or other optical storage, magnetic cassettes, magnetic tape magnetic disk storage or other magnetic storage devices or any other non-transmission media that can be used to store information that can be accessed by a computing device.

[0120] The computer instructions stored in the storage medium of the above embodiment are used to enable the computer to execute the data transmission test method of the vehicle-side device as described in any of the above embodiments, and have the beneficial effects of the corresponding method embodiments, which will not be repeated here.

[0121] Based on the same concept, corresponding to any of the above-mentioned embodiment methods, the present application also provides a computer program product, including computer program instructions. When the computer program instructions are run on a computer, the computer executes the method described in any of the above embodiments, which has the beneficial effects of the corresponding method embodiments and will not be repeated here.

[0122] A person skilled in the art should understand that the discussion of any of the above embodiments is merely illustrative and is not intended to imply that the scope of the present application is limited to these examples. In line with the concept of the present application, the technical features in the above embodiments or different embodiments may be combined, the steps may be implemented in any order, and there are many other variations of the different aspects of the embodiments of the present application as described above, which are not provided in detail for the sake of simplicity.

[0123] In addition, to simplify the description and discussion, and in order not to make the embodiments of the present application difficult to understand, the known power supply / ground connection with the integrated circuit (IC) chip and other components may or may not be shown in the provided drawings. In addition, the device can be shown in the form of a block diagram to avoid making the embodiments of the present application difficult to understand, and this also takes into account the fact that the details of the implementation of these block diagram devices are highly dependent on the platform to be implemented in the embodiments of the present application (that is, these details should be fully within the scope of understanding of those skilled in the art). In the case of elaborating specific details (e.g., circuits) to describe exemplary embodiments of the present application, it is obvious to those skilled in the art that the embodiments of the present application can be implemented without these specific details or when these specific details are changed. Therefore, these descriptions should be considered to be illustrative rather than restrictive.

[0124] Although the present application has been described in conjunction with specific embodiments of the present application, many replacements, modifications and variations of these embodiments will be apparent to those skilled in the art from the foregoing description. For example, other memory architectures (e.g., dynamic RAM (DRAM)) may use the embodiments discussed.

[0125] The embodiments of the present application are intended to cover all such substitutions, modifications and variations that fall within the broad scope of the present application. Therefore, any omissions, modifications, equivalent substitutions, improvements, etc. made within the spirit and principles of the embodiments of the present application should be included in the protection scope of the present application.

Claims

1. A data transmission test method for a vehicle-side device, characterized in that: include: Configuring a port of an external tester and a port of a vehicle-end device so that a closed-loop link is formed between the port of the external tester and the port of the vehicle-end device; Generate a simulation data stream, and send the simulation data stream to the port of the vehicle-end device through the port of the external tester, so that the simulation data stream is transmitted inside the vehicle-end device, and a test data stream is obtained after the transmission is completed; The test data stream output by the vehicle-side device is received through the port of the external tester to complete the test of the vehicle-side device.

2. The method according to claim 1, characterized in that The port of the external tester includes a first output port and a first input port, and the port of the vehicle-end device includes a second output port and a second input port; configuring the port of the external tester and the port of the vehicle-end device so that a closed-loop link is formed between the port of the external tester and the port of the vehicle-end device, including: The first output port is controlled to be connected to the second input port, and the second output port is controlled to be connected to the first input port.

3. The method according to claim 1, characterized in that The generating of the simulation data stream and sending the simulation data stream to the port of the vehicle-end device through the port of the external tester includes: Generate a first simulation data stream and a second simulation data stream, wherein the transmission priority of the first simulation data stream is higher than the transmission priority of the second simulation data stream; each data frame in the second simulation data stream is divided into a plurality of fragment frames; At a first moment, the second simulation data stream is sent to the port of the vehicle-end device through the port of the external tester, and at a second moment, the first simulation data stream is sent to the port of the vehicle-end device through the port of the external tester; wherein, the first moment is earlier than the second moment, and the time interval between the first moment and the second moment is less than the time required for the second simulation data stream to be transmitted inside the vehicle-end device.

4. The method according to claim 3, characterized in that The method further comprises: The test data stream is parsed to determine whether the test data stream satisfies a preset transmission rule. If not, it is determined that the data transmission of the vehicle-side device is abnormal; wherein the preset transmission rule characterizes the transmission mechanism of the simulation data stream inside the vehicle-side device.

5. The method according to claim 4, characterized in that The determining whether the test data stream satisfies a preset transmission rule includes: In the test data stream, for each data frame in the second simulation data stream, in response to all fragment frames belonging to the data frame being continuously transmitted, it is determined that the test data stream does not satisfy a preset transmission rule.

6. The method according to claim 4, characterized in that The determining whether the test data stream satisfies a preset transmission rule includes: In the test data stream, in response to the presence of a sequence number arrangement error of a fragment frame, it is determined that the test data stream does not satisfy a preset transmission rule.

7. The method according to claim 1, characterized in that Before sending the simulated data stream to the port of the vehicle-end device through the port of the external tester, the method further includes: According to the data transmission speed of the vehicle-side device, the transmission speed of the simulation data stream in the closed-loop link is configured.

8. A data transmission test device for vehicle-side equipment, characterized in that: include: A setting module is configured to configure a port of an external tester and a port of a vehicle-end device so as to form a closed-loop link between the port of the external tester and the port of the vehicle-end device; A sending module, configured to generate a simulation data stream, and send the simulation data stream to the port of the vehicle-end device through the port of the external tester, so that the simulation data stream is transmitted inside the vehicle-end device; The receiving module is configured to receive the test data stream output by the vehicle-side device through the port of the external tester to complete the test of the vehicle-side device; wherein the test data stream includes the simulation data stream.

9. An electronic device comprising a memory, a processor, and a computer program stored in the memory and running on the processor, characterized in that: When the processor executes the program, the method according to any one of claims 1 to 7 is implemented.

10. A non-transitory computer-readable storage medium storing computer instructions, characterized in that: The computer instructions are used to enable a computer to execute the method according to any one of claims 1 to 7.

Citation Information

Patent Citations

  • Vehicle-mounted high-speed network test system and method

    CN110995547A

  • Automatic test system and method, electronic equipment and storage medium

    CN115437351A

  • Testing device for frame preemption function

    CN116346678A

  • Method for secure transmission of safety critical function data between diagnosis tester and control device in control system in vehicle, involves synchronizing keys, and initiating access to client during coincidence of keys

    DE102012209445A1