Performance test method and system for controller of vehicle and vehicle

By introducing a precise time measurement mechanism into the HIL testing system to record and calculate the controller's response time, the problem of neglecting response time measurement in existing technologies is solved. This enables a comprehensive evaluation of controller performance and improves accuracy, ensuring the real-time processing capability and safety of the vehicle controller.

CN120848460APending Publication Date: 2025-10-28FAW JIEFANG AUTOMOTIVE CO
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202511012644.7
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-07-22
Publication Date
2025-10-28

AI Technical Summary

Technical Problem

Existing HIL testing systems in vehicle electronic control system development mainly focus on the functional verification of controllers, while neglecting the consideration of controller real-time performance, especially the accurate measurement of response time. This results in low accuracy of controller performance testing and an inability to fully evaluate its performance in practical applications.

Method used

By introducing a precise time measurement mechanism into the host computer testing system, the sending time of test messages and the receiving time of response messages are recorded, and the response time of the controller is calculated, including taking into account the transmission time of the communication board, to evaluate the real-time processing capability and performance stability of the controller.

Benefits of technology

It enables accurate evaluation of controller performance, improves the accuracy of vehicle controller performance testing, ensures the stability and safety of the controller under real-time operating conditions, and provides data support for performance optimization.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120848460A_ABST
    Figure CN120848460A_ABST
Patent Text Reader

Abstract

The invention discloses a performance test method and system for a controller of a vehicle and the vehicle. The method is applied to an upper computer test system and comprises the steps that at least one test case is obtained in response, a test message corresponding to the test case is sent to a to-be-tested controller of a vehicle, the test case is used for simulating a test environment for carrying out performance test on the to-be-tested controller, and the test message is sent to the to-be-tested controller; the test message is used for representing a to-be-executed target operation of the to-be-tested controller in a test environment; the sending moment of the test message is obtained, the receiving moment of a response message from the to-be-tested controller is obtained, and the response message is used for representing the execution result of the to-be-tested controller executing the target operation in the test environment; based on the sending time and the receiving time, a target performance result of the to-be-tested controller is determined, and the target performance result is used for representing the timeliness degree of executing the target operation by the to-be-tested controller in the test environment. According to the invention, the technical problem of low performance test accuracy of the vehicle controller is solved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of vehicle electronic control technology, and more specifically, to a method, system, and vehicle for testing the performance of a vehicle controller. Background Art

[0002] Currently, Hardware-in-the-Loop (HIL) testing systems occupy a central position in the development of vehicle electronic control systems. Their main task is to verify the functional correctness of the Electronic Control Unit (ECU) through simulated signal interaction, ensuring that hardware components can perform as designed in a simulated operating environment. The HIL testing system generates and sends test messages via host computer software. The ECU under test receives and processes these messages, then returns a response message. By comparing the signal values ​​in the response message with the expected results, the system evaluates the controller's logical functionality and the accuracy of its data processing.

[0003] However, the aforementioned HIL testing methods primarily focus on functional verification, namely the correctness of signal values, while neglecting considerations of the controller's real-time performance, particularly the accurate measurement of the controller's response time. In the field of vehicle electronic control, response time is one of the key indicators for measuring controller performance, directly affecting vehicle safety and driving experience. For example, in scenarios such as emergency braking and active safety system responses, even millisecond-level delays can lead to serious consequences. Therefore, current functional verification methods cannot comprehensively evaluate the controller's performance in practical applications, especially under conditions with extremely high real-time requirements. Consequently, the technical problem of low accuracy in vehicle controller performance testing persists.

[0004] There is currently no effective solution to the technical problem of low accuracy in performance testing of the controllers of the aforementioned vehicles. Summary of the Invention

[0005] This invention provides a method, system, and vehicle for testing the performance of a vehicle controller, in order to at least address the technical problem of low accuracy in testing the performance of vehicle controllers.

[0006] According to one aspect of the present invention, a performance testing method for a vehicle controller is provided. The method is applied to a host computer testing system and may include: in response to acquiring at least one test case, sending a test message corresponding to the test case to the vehicle's controller under test (DUT), wherein the test case is used to simulate a test environment for performance testing of the DUT, and the test message represents a target operation to be performed by the DUT in the test environment; acquiring the sending time of the test message and acquiring the receiving time of a response message from the DUT, wherein the response message represents the execution result of the DUT performing the target operation in the test environment; and determining a target performance result of the DUT based on the sending time and the receiving time, wherein the target performance result represents the timeliness of the DUT performing the target operation in the test environment.

[0007] Optionally, the target performance of the controller under test is determined based on the sending and receiving times, including: determining the response duration of the controller under test based on the sending and receiving times, wherein the response duration is used to represent the time it takes for the controller under test to respond to the test message and send the response message in the test environment; and determining the target performance result based on the response duration.

[0008] Optionally, the controller under test (DUT) is connected to the host computer test system via a communication board. The method may further include: obtaining a first communication duration and a second communication duration of the communication board, wherein the first communication duration represents the duration of the communication board transmitting test messages, and the second communication duration represents the duration of the communication board transmitting response messages; determining the response duration of the DUT based on the sending and receiving times, including: determining a first difference between the sending and receiving times; determining the first difference minus a second difference between the first and second communication durations; and determining the second difference as the response duration.

[0009] Optionally, the method further includes: obtaining the execution count of the current test case in at least one test case; determining the target performance result based on the response time, including: obtaining the response time of the execution count during the execution of the current test case according to the execution count; determining the maximum response time, minimum response time and average response time based on the response time of the execution count; and determining the target performance result corresponding to the current test case based on the maximum response time, minimum response time and average response time.

[0010] Optionally, there are multiple test cases to be executed. Based on the sending and receiving times, the target performance result of the controller under test is determined, including: determining the target performance result based on the sending and receiving times corresponding to the multiple test cases to be executed.

[0011] Optionally, in response to the number of test cases to be executed being multiple, the target performance result is determined based on the sending and receiving times corresponding to the multiple test cases to be executed, including: in response to the number of test cases to be executed being multiple, the average response time corresponding to the multiple test cases to be executed is determined based on the sending and receiving times corresponding to the multiple test cases to be executed; in response to the average response time corresponding to the multiple test cases, there is an abnormal average response time exceeding a preset average response time threshold, and the target performance result is determined under the test environment corresponding to the abnormal average response time as the timeliness of the control device under test performing the target operation, and under the test environment corresponding to the test environment corresponding to the lower than the preset average response time threshold as the timeliness of the control device under test performing the target operation.

[0012] According to another aspect of the present invention, a performance testing method for a vehicle controller is also provided, applied to the controller under test, which may include: in response to receiving a test message corresponding to a test case sent by a host computer testing system, executing the target operation in the test message to obtain an execution result, wherein the test case is used to simulate a test environment for performance testing of the controller under test, and the test message is used to represent the target operation to be executed by the controller under test in the test environment; generating a response message according to the execution result, and sending the response message to the host computer testing system, wherein the response message is used to represent the execution result of the controller under test executing the target operation in the test environment, and the host computer testing system is used to determine the target performance result of the controller under test according to the sending time corresponding to the test message and the receiving time corresponding to the received response message, wherein the target performance result is used to represent the timeliness of the controller under test executing the target operation in the test environment.

[0013] According to another aspect of the present invention, a performance testing system for a vehicle controller is also provided. This performance testing system may include a controller under test (DUT) and a host computer testing system. The host computer testing system is configured to, in response to acquiring at least one test case, send a test message corresponding to the test case to the DUT. The test case is used to simulate a test environment for performance testing of the DUT, and the test message represents the target operation to be performed by the DUT in the test environment. The system also acquires the sending time corresponding to the test message and the receiving time corresponding to the response message from the DUT, where the response message represents the execution result of the target operation performed by the DUT in the test environment. Based on the sending and receiving times, the system determines the target performance result of the DUT, where the target performance result represents the timeliness of the DUT's execution of the target operation in the test environment. The DUT, in response to acquiring the test message, executes the target operation in the test message to obtain the execution result. According to the execution result, the system generates a response message and sends the response message to the host computer testing system.

[0014] Optionally, the performance testing system also includes a communication board, which is used to send test messages to the controller under test and send response messages to the host computer testing system.

[0015] According to another aspect of the present invention, a performance testing apparatus for a vehicle controller is also provided. The apparatus may include: a first sending unit, configured to send a test message corresponding to a test case to a vehicle controller under test in response to acquiring at least one test case, wherein the test case is used to simulate a test environment for performance testing of the controller under test, and the test message represents a target operation to be performed by the controller under test in the test environment; an acquisition unit, configured to acquire the sending time of the test message and the receiving time of a response message from the controller under test, wherein the response message represents the execution result of the controller under test performing the target operation in the test environment; and a determining unit, configured to determine a target performance result of the controller under test based on the sending time and the receiving time, wherein the target performance result represents the timeliness of the controller under test performing the target operation in the test environment.

[0016] According to another aspect of the present invention, a performance testing apparatus for a vehicle controller is also provided. The apparatus may include: an execution unit, configured to execute a target operation in a test message corresponding to a test case sent by a host computer testing system, and obtain an execution result, wherein the test case is used to simulate a test environment for performance testing of the controller under test, and the test message represents the target operation to be executed by the controller under test in the test environment; and a second sending unit, configured to generate a response message according to the execution result and send the response message to the host computer testing system, wherein the response message represents the execution result of the controller under test executing the target operation in the test environment, and the host computer testing system is configured to determine the target performance result of the controller under test based on the sending time corresponding to the test message and the receiving time corresponding to the received response message, wherein the target performance result represents the timeliness of the controller under test executing the target operation in the test environment.

[0017] According to another aspect of the present invention, a computer-readable storage medium is also provided. The computer-readable storage medium includes a stored program, wherein, when the program is executed, it controls the device where the computer-readable storage medium is located to perform a performance testing method for a vehicle controller according to the embodiments of the present invention.

[0018] According to another aspect of the present invention, a processor is also provided. The processor is used to run a program, wherein the program, when running, executes the performance testing method for the vehicle controller according to the embodiments of the present invention.

[0019] According to another aspect of the present invention, a vehicle is also provided. The vehicle includes a memory and a processor, wherein the memory stores an executable program. The processor is used to run the program, wherein the program, when running, executes the performance testing method for the controller of the present invention.

[0020] According to another aspect of the present invention, a computer program product is also provided. This computer program product includes a computer program that, when executed by a processor, implements the performance testing method for the vehicle controller described in the embodiments of this application.

[0021] In this embodiment of the invention, if performance testing of a vehicle controller is required, the vehicle's controller under test (DUT) can be connected to a host computer testing system. If the host computer testing system obtains a test case that triggers a test on the DUT, it can send a test message corresponding to the test case to the DUT. The sending time of the test message and the receiving time of the response message from the DUT are obtained. The target performance result of the DUT is determined by the sending and receiving times. In this embodiment of the invention, a precise time measurement mechanism is introduced in the controller performance test. When executing test cases, the host computer testing system not only focuses on the functional implementation and signal value correctness of the controller, but more importantly, it records and sends the precise time of the test message to the DUT, as well as the exact time of receiving the controller's response message. By using these two precise times, the actual response time of the controller performing the target operation can be calculated, thereby obtaining the controller's true performance index. The above method effectively fills the gap in response time measurement in related HIL tests, enabling the testing system to comprehensively evaluate the controller's real-time processing capability and performance stability, thereby solving the technical problem of low accuracy in vehicle controller performance testing and achieving the technical effect of improving the accuracy of vehicle controller performance testing. Attached Figure Description

[0022] The drawings described herein are used to provide a further understanding of the present invention and constitute a part of this application. The exemplary embodiments of the present invention and their descriptions are used to explain the present invention and do not constitute an improper limitation of the present invention. In the drawings:

[0023] Figure 1 This is a flowchart of a performance testing method for a vehicle controller according to an embodiment of the present invention;

[0024] Figure 2 This is a flowchart of another vehicle controller performance testing method according to an embodiment of the present invention;

[0025] Figure 3 This is a schematic diagram of a controller performance verification system based on in-loop testing according to an embodiment of the present invention;

[0026] Figure 4 This is a schematic diagram of a performance testing system for a vehicle controller according to an embodiment of the present invention;

[0027] Figure 5 This is a schematic diagram of a performance testing device for a vehicle controller according to an embodiment of the present invention;

[0028] Figure 6 This is a schematic diagram of a performance testing device for a vehicle controller according to an embodiment of the present invention. Detailed Implementation

[0029] To enable those skilled in the art to better understand the present invention, the technical solutions of the present invention will be clearly and completely described below with reference to the accompanying drawings of the embodiments of the present invention. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort should fall within the scope of protection of the present invention.

[0030] It should be noted that the terms "first", "second", etc. in the description and claims of the present invention and the above-mentioned drawings are used to distinguish similar objects and are not necessarily used to describe a specific order or sequence. It should be understood that the numbers used in this way can be interchanged where appropriate, so that the embodiments of the present invention described herein can be implemented in an order other than those illustrated or described herein. In addition, the terms "including" and "having" and any variations thereof are intended to cover non-exclusive inclusions. For example, a process, method, system, product or device that includes a series of steps or units is not necessarily limited to those steps or units clearly listed, but may include other steps or units that are not clearly listed or inherent to these processes, methods, products or devices.

[0031] According to an embodiment of the present invention, an embodiment of a performance testing method for a vehicle controller is provided. It should be noted that the steps shown in the flowchart in the accompanying drawings can be executed in a computer system such as a set of computer-executable instructions. Furthermore, although a logical order is shown in the flowchart, in some cases, the steps shown or described may be executed in a different order than that shown here.

[0032] Figure 1 This is a flowchart of a performance testing method for a vehicle controller according to an embodiment of the present invention, such as... Figure 1 As shown, this method, applied to a host computer testing system, may include the following steps:

[0033] Step S102: In response to obtaining at least one test case, send the test message corresponding to the test case to the vehicle's controller under test.

[0034] In the technical solution provided by step S102 of the present invention, the test case is used to simulate the test environment for performance testing of the controller under test, and the test message is used to indicate the target operation to be performed by the controller under test in the test environment.

[0035] Optionally, test cases are used to construct a series of condition combinations that can comprehensively cover all operating environments and scenarios that the controller under test may encounter. They can be used to simulate various input states of the controller in the real environment, including but not limited to normal operation, edge cases or fault injection, so as to evaluate the stability and responsiveness of the controller.

[0036] Optionally, the host computer testing system can be a testing platform located above the controller, which can be a computer, workstation, or other testing equipment, equipped with a complete set of testing software for generating test instructions, monitoring the test process, and collecting test results. The host computer testing system can be host computer testing software. The host computer testing system acts as the command center for controller testing, generating test messages corresponding to test cases, triggering the start of performance testing, and recording the timestamps of sent and received messages to calculate the controller's response time.

[0037] Optionally, the controller under test (DUT) can be the device under test (DUT). The DUT refers to the specific hardware device whose functions and performance need to be evaluated during the testing process; it can be an ECU in a vehicle's electronic control system. The DUT receives test messages sent by the host computer testing system, executes corresponding actions in a simulated test environment according to the operation instructions carried in the messages, and then returns a response message with the execution results.

[0038] Optionally, the test message can be a message instruction issued by the host computer test system to the controller under test (DUT), including control instructions for controlling the DUT to perform target operations in the test environment. The test message is an information packet containing specific instructions and data, generated by the host computer test system based on test cases, used to trigger the DUT to execute predetermined operations. The test message contains various information required for the controller to execute the test cases, including control instructions, data parameters, expected response modes, and timestamps for time measurement. The test message acts as a bridge between the host computer test system and the DUT, not only stimulating the controller's response but also carrying crucial information for subsequent performance analysis, such as the timestamp, which is essential for evaluating the controller's response time.

[0039] In this embodiment, if the host computer testing system obtains the test case, it can send the test message corresponding to the test case to the controller under test.

[0040] Optionally, before the test begins, the host computer testing system can load or select one or more test cases from its database or a preset test environment. These test cases can be carefully designed scenarios aimed at comprehensively testing the behavior and performance of the controller under test (DUT) under different conditions. After selecting test cases, the host computer testing system can generate corresponding test messages. This process involves converting the conditions and instructions in the test cases into a format that the controller can understand. Each test message contains control instructions for controlling the DUT to perform specific operations in a simulated environment, as well as possible input data or parameters. Furthermore, a timestamp of the transmission time can be embedded in the test message.

[0041] Step S104: Obtain the sending time of the test message and the receiving time of the response message from the controller under test.

[0042] In the technical solution provided in step S104 of the present invention, the response message is used to indicate the execution result of the controller under test performing the target operation in the test environment. The sending time can be the timestamp of the message instruction (test message) being sent. The receiving time can be the timestamp recorded by the host computer test software as the time the response message is received.

[0043] In this embodiment, after sending the test message corresponding to the test case to the controller under test, the sending time of the test message and the receiving time of the response message from the controller under test can be obtained.

[0044] Optionally, when the host computer test software prepares to send a test message to the controller under test (DUT), it can record a high-precision timestamp locally on the host computer test system, i.e., the sending time. After the DUT completes the target operation indicated in the test message, it can generate and send a response message to the host computer test system. When the host computer test software receives the response message, it can record a high-precision timestamp, i.e., the receiving time.

[0045] Step S106: Determine the target performance result of the controller under test based on the transmission time and the reception time.

[0046] In the technical solution of step S106 of the present invention, the target performance result is used to represent the timeliness of the controller under test in performing the target operation under the test environment.

[0047] In this embodiment, after obtaining the sending time of the test message and the receiving time of the response message, the target performance result of the controller under test can be determined based on the sending time and the receiving time.

[0048] Optionally, the controller's response time can be calculated based on the sending and receiving times. This response time reflects the total time required for the controller to complete the operation and return the execution result from receiving the instruction. The target performance result aims to evaluate the timeliness of the controller under test in performing the target operation in the test environment, i.e., the speed of the controller's response. By statistically analyzing the response times of multiple test cases, a series of meaningful performance indicators can be derived, including but not limited to minimum response time, maximum response time, average response time, and standard deviation. These performance indicators collectively illustrate the distribution of the controller's response speed under different operating conditions.

[0049] Optionally, if abnormally long or highly fluctuating response times are found under certain test cases, it indicates that the controller may have performance bottlenecks when handling these specific operations. This helps the R&D team to optimize the controller's algorithms, software configuration, or hardware resource allocation in a targeted manner, thereby improving its overall performance. Expected response time thresholds for target operations can be set according to industry standards or product specifications. By comparing the controller's actual response time with the expected response time thresholds, it can be determined whether the controller meets the requirements for real-time processing, ensuring its stability and reliability in complex vehicle environments.

[0050] In this embodiment of the invention, the above method not only quantifies the controller's response speed but also further analyzes its performance stability, which is particularly important for the optimization and fault prevention of vehicle electronic control systems. In particular, as a core component of the vehicle's electronic architecture, the controller's response speed directly affects driving safety and the driving experience; therefore, accurate measurement and analysis of response time is crucial for improving overall vehicle performance. Determining the target performance results also helps engineers understand the differences in controller performance under different test conditions, providing data support for subsequent product iterations and functional upgrades.

[0051] In steps S102 to S106 of this application, if performance testing of the vehicle's controller is required, the vehicle's controller under test (DUT) can be connected to a host computer testing system. If the host computer testing system obtains a test case that triggers a test on the DUT, it can send a test message corresponding to the test case to the DUT. The sending time of the test message and the receiving time of the response message from the DUT are obtained. The target performance result of the DUT is determined using these sending and receiving times. In this embodiment of the invention, a precise time measurement mechanism is introduced in the controller performance test. When executing test cases, the host computer testing system not only focuses on the controller's functional implementation and signal value correctness, but more importantly, it records and sends the precise time of the test message to the DUT, as well as the exact time of receiving the controller's response message. Using these two precise times, the actual response time of the controller performing the target operation can be calculated, thereby obtaining the controller's true performance index. The above method effectively fills the gap in response time measurement in relevant HIL tests, enabling the host computer test system to comprehensively evaluate the real-time processing capability and performance stability of the controller, thereby solving the technical problem of low accuracy in vehicle controller performance testing and achieving the technical effect of improving the accuracy of vehicle controller performance testing.

[0052] The method described in this embodiment will be further described below.

[0053] As an optional embodiment, step S106, determining the target performance of the controller under test based on the sending time and receiving time, includes: determining the response duration of the controller under test based on the sending time and receiving time, wherein the response duration is used to represent the duration for the controller under test to respond to the test message and send a response message in the test environment; and determining the target performance result based on the response duration.

[0054] In this embodiment, during the process of determining the target performance of the controller under test based on the transmission and reception times, the response time of the controller under test can be determined based on the transmission and reception times. Therefore, the target performance result is determined based on the response time.

[0055] Optionally, response duration can be used to represent the time it takes for the controller under test to respond to test messages and send response messages in a test environment. Response duration, also known as response time, refers to the total time consumed from the moment the controller under test receives the test message until it completes its internal processing and generates a response message to send to the host computer test software.

[0056] Optionally, in the development and testing of automotive electronic systems, the controller's response speed is one of the key indicators for measuring its performance. A shorter response time indicates that the controller can process input information and make decisions faster, which is crucial for the safe and efficient operation of the vehicle.

[0057] As an optional embodiment, the controller under test (DUT) is connected to the host computer test system via a communication board. The method may further include: obtaining a first communication duration and a second communication duration of the communication board, wherein the first communication duration represents the duration of the communication board transmitting test messages, and the second communication duration represents the duration of the communication board transmitting response messages; determining the response duration of the DUT based on the sending and receiving times, including: determining a first difference between the sending and receiving times; determining the first difference minus a second difference between the first and second communication durations; and determining the second difference as the response duration.

[0058] In this embodiment, the controller under test (DUT) can be connected to the host computer testing system via a communication board. The first communication duration and the second communication duration of the communication board can be obtained. In determining the response duration of the DUT based on the sending and receiving times, a first difference between the sending and receiving times can be determined. The second difference, obtained by subtracting the first communication duration from the second communication duration, is then determined as the response duration. The first communication duration can represent the duration of the communication board transmitting test messages. The second communication duration can represent the duration of the communication board transmitting response messages.

[0059] Optionally, the communication board acts as a bridge in the HIL test system, responsible for transmitting messages between the host computer test system and the controller under test (DUT). When evaluating controller performance, the transmission time of the communication board is also a significant variable, as it directly affects the total time from when the host computer sends a test message to when it receives a response message. When the host computer test software sends a test message to the DUT, the communication board needs time to encode and transmit the message. The time consumed in this process is called the first communication duration. When the DUT generates a response message and sends it to the host computer via the communication board, it also experiences a delay, which is the second communication duration.

[0060] Optionally, the difference between the sending and receiving times represents the total time from the sending of the test message to the receiving of the response message; this difference is called the first difference. Response duration = First difference - First communication duration - Second communication duration. The above formula ensures that the final calculated response duration only reflects the processing time of the controller under test itself, and does not include the transmission delay of the communication board.

[0061] Optionally, once the response time is determined, the host computer testing software can perform the following operations based on the response time to determine the target performance result: compare the response time with pre-set performance specifications or industry standards to determine whether the controller meets the expected response speed requirements; statistically analyze the response times under multiple test cases to calculate the minimum response time, maximum response time, average response time, and standard deviation to comprehensively evaluate the controller's response performance; and analyze the trend of controller performance evolution over time by tracking changes in response time over a long period, which is very useful for predicting long-term performance degradation or failure risks.

[0062] In this embodiment of the invention, by subtracting the transmission time of the communication board, more accurate controller response time data can be obtained, avoiding performance evaluation bias caused by communication latency. Based on the analysis results of the response time, the R&D team can identify performance bottlenecks and optimize the controller's algorithm, software configuration, or hardware design to improve response speed and overall system performance. Within the framework of HIL testing, by carefully considering and accurately measuring the transmission time of the communication board, the response time of the controller under test can be calculated more accurately, thus yielding more objective and scientific target performance results. The above process enhances the reliability of the test results.

[0063] As an optional embodiment, the method further includes: obtaining the execution count of the current test case in at least one test case; determining the target performance result based on the response time, including: obtaining the response time of the execution count during the execution of the current test case according to the execution count; determining the maximum response time, minimum response time, and average response time based on the response time of the execution count; and determining the target performance result corresponding to the current test case based on the maximum response time, minimum response time, and average response time.

[0064] In this embodiment, the execution count of the current test case in at least one test case can be obtained. The current test case can be executed according to the execution count, the response time of the execution count can be obtained, and the maximum response time, minimum response time and average response time can be determined based on the response time of the execution count. The target performance result corresponding to the current test case can be determined through the above three response times.

[0065] Optionally, in HIL testing, to ensure the comprehensiveness and reliability of the evaluation, the same test case can be executed multiple times, i.e., the execution count. This helps to collect response time data of the controller under repeated operations under the same conditions, providing sufficient samples for subsequent statistical analysis.

[0066] Optionally, the host computer testing software will repeatedly send the same test case message to the controller under test according to a predetermined number of executions, and record the sending and receiving times each time. For each test, the response time is calculated based on the sending and receiving times, and the transmission delay of the communication board is subtracted to obtain the precise response time of the controller in processing the test case.

[0067] Optionally, identify the longest response time (maximum response time) among the response times of each execution. This represents the controller's response latency in the worst-case scenario and is crucial for predicting the system's behavior under extreme conditions. Identify the shortest response time (minimum response time). This reflects the controller's response speed and can serve as an indicator of the system's performance potential. Calculate the average response time for each execution (average response time). The average response time is the typical response time of the controller when executing this test case and is a key metric for evaluating its general performance.

[0068] Optionally, by comparing the maximum and minimum response times, the response time fluctuation range of the controller under the same test cases can be evaluated to determine its performance stability. The average response time is compared with a preset performance level or industry standard to assess the controller's performance level. If abnormally large response times are found, possible failure modes and their impact on overall system performance can be analyzed, allowing for preventative measures to be taken. Based on the statistical results, the R&D team can identify performance bottlenecks and guide the optimization direction of the controller design, such as algorithm optimization, hardware upgrades, or software debugging.

[0069] In this embodiment of the invention, by determining the performance results based on multiple executions of statistical data, it is possible not only to evaluate the basic response speed of the controller but also to conduct in-depth analysis of its performance stability and reliability. This method is particularly suitable for identifying and resolving performance degradation issues that may occur in the controller under extreme or specific conditions. In HIL testing, by executing the same test case multiple times and statistically analyzing the response time, the controller's performance can be evaluated more comprehensively, potential problem areas can be identified, and performance optimization can be guided. This method combines statistics and engineering practice, ensuring the accuracy of the test results and the scientific rigor of the evaluation.

[0070] As an optional implementation, there are multiple test cases to be executed. Step S106, based on the sending time and receiving time, determines the target performance result of the controller under test, including: determining the target performance result based on the sending time and receiving time corresponding to the multiple test cases to be executed.

[0071] In this embodiment, if there are multiple test cases to be executed, the target performance result of the controller under test can be determined based on the sending and receiving times corresponding to the multiple test cases to be executed.

[0072] Optionally, in HIL testing, multiple test cases can be designed to comprehensively evaluate the performance of the controller under test. Each test case aims to simulate the controller's working state under different operating conditions or scenarios, including but not limited to various driving conditions, load conditions, and communication environments. By testing with multiple test cases, response time data of the controller under various conditions can be collected, thereby enabling a comprehensive performance evaluation.

[0073] Optionally, for each test case, the host computer testing software records the sending and receiving times during its execution, thereby calculating the controller's response time under that test case. The execution of each test case is independent, meaning that each test case will be executed multiple times to collect sufficient data for statistical analysis. For each test case, the response times from multiple executions are analyzed to calculate the maximum response time, minimum response time, average response time, and possible standard deviation, in order to evaluate the controller's performance under that specific operating condition.

[0074] Optionally, after collecting and analyzing the response times of each test case, the response times of each test case will be further integrated to determine the overall target performance result: comparing the average response times under different test cases can identify which operating conditions have the greatest impact on the controller's response speed, helping to pinpoint performance bottlenecks. By integrating the response time data of each test case, the performance trend of the controller under different operating conditions can be analyzed to determine whether its performance fluctuates with changes in operating conditions and whether such fluctuations are within an acceptable range. The performance results under each test case will be compared with industry standards or product specifications to ensure that the controller meets performance requirements under various operating conditions. If the maximum response time is significantly higher in some test cases than in others, it may indicate that the controller's performance under these operating conditions is negatively affected by specific factors, requiring further investigation and optimization.

[0075] In this embodiment of the invention, performance evaluation of the controller under test (DUT) is more comprehensive and accurate by using response time data from multiple test cases. This method not only identifies and quantifies the controller's performance under various specific operating conditions but also captures the trend of its performance changing with operating conditions, thus providing multi-dimensional insights for the optimization of automotive electronic control systems. Determining the target performance result of the controller based on response time data from multiple test cases within the HIL testing framework is a rigorous and meticulous process. It not only requires the host computer testing system to accurately record the timestamp of each test operation but also relies on subsequent data analysis and performance evaluation. The above method ensures the reliability and objectivity of the evaluation results.

[0076] As an optional embodiment, in response to the number of test cases to be executed being multiple, step S106 involves determining the target performance result based on the sending and receiving times corresponding to the multiple test cases to be executed, including: in response to the number of test cases to be executed being multiple, determining the average response time corresponding to each of the multiple test cases based on the sending and receiving times corresponding to the multiple test cases to be executed; in response to the existence of an abnormal average response time exceeding a preset average response time threshold among the average response times corresponding to the multiple test cases, determining that under the test environment corresponding to the abnormal average response time, the target performance result is the timeliness of the control device under test performing the target operation, and under the test environment corresponding to the test environment corresponding to the lower than the preset average response time threshold, the timeliness of the control device under test performing the target operation.

[0077] In this embodiment, in the HIL testing scenario, there are multiple test cases to be executed, each representing the controller's working state under a specific operating condition or operation. For these test cases, the host computer's testing software records their transmission and reception times, thereby calculating the response time of each test case.

[0078] Optionally, for each test case, the execution is repeated multiple times, and the response time is recorded each time. Statistical analysis is performed on the response times from multiple runs to calculate the average response time for that test case. The above steps aim to obtain the typical response speed of the controller under specific test conditions. By calculating the average response time for each test case, the randomness and uncertainty in a single test can be eliminated, providing a more stable and reliable performance metric.

[0079] Optionally, the preset average response time threshold is a reference value set based on controller design specifications, industry standards, or system performance requirements, used to determine whether the controller's response speed meets expectations. If the average response time of a test case is lower than the preset threshold, it indicates that the controller's timely execution of the target operation in this test environment meets or exceeds expectations, and its performance is good. Conversely, if the average response time of a test case exceeds the preset threshold, it may mean that there is a bottleneck in the controller's performance in this test environment, and the timely execution of the target operation is lower than expected, requiring further performance optimization or troubleshooting.

[0080] Optionally, the average response time of each test case can be compared with a preset threshold to identify abnormal average response times. This helps identify under which specific operating conditions or operations the controller performs poorly. Based on the comparison between abnormal and normal average response times, the host computer testing software can integrate the overall performance of the controller throughout the testing process, including the distribution of stability, reliability, and response speed. The test environment and operations corresponding to abnormal average response times can serve as a preliminary location for performance bottlenecks, helping engineers to deeply analyze potential problems in controller design or system configuration.

[0081] In this embodiment of the invention, by comparing the average response time of multiple test cases with a preset threshold, the performance of the controller under different test environments can be precisely identified, ensuring that it meets the preset performance standards under various operating conditions. The above method not only provides a comprehensive performance evaluation framework but also offers clear directions for performance optimization and fault detection.

[0082] Figure 2 This is a flowchart of another vehicle controller performance testing method according to an embodiment of the present invention, such as... Figure 2 As shown, this method, applied to the controller under test, may include the following steps:

[0083] Step S202: In response to receiving the test message corresponding to the test case sent by the host computer test system, the target operation in the test message is executed to obtain the execution result.

[0084] In the technical solution provided by step S202 of the present invention, the test case is used to simulate the test environment for performance testing of the controller under test, and the test message is used to indicate the target operation to be performed by the controller under test in the test environment.

[0085] In this embodiment, the controller under test (DUT) receives test messages sent by the host computer via a communication board. The test messages contain specific instructions or data to simulate various inputs the controller might encounter in a real driving environment. The controller's internal software or firmware parses the received test messages to identify the target operation instructions, which are prerequisites for executing the operation. The controller identifies the target operation from the parsed test messages. If the test case involves verifying a specific algorithm, the controller will run the corresponding algorithm to process the data or instructions in the message.

[0086] Optionally, after the target operation is completed, the controller can generate an execution result, which may be the output after data processing, feedback information after status update, or a response signal to a specific instruction. The execution result is then returned to the host computer test system via the communication board for the test software to record and analyze.

[0087] Step S204: Based on the execution result, generate a response message and send the response message to the host computer test system.

[0088] In the technical solution provided in step S204 of the present invention, the response message is used to indicate the execution result of the controller under test performing the target operation in the test environment. The host computer test system is used to determine the target performance result of the controller under test according to the sending time corresponding to the test message and the receiving time corresponding to the received response message. The target performance result is used to indicate the timeliness of the controller under test performing the target operation in the test environment.

[0089] In this embodiment, the software or firmware inside the controller under test analyzes and interprets the execution results to determine the information that needs to be included in the response message. For example, if the execution result indicates that a specific function has been successfully implemented, the response message should include confirmation information and possible response parameters. The execution result can contain various types of data, such as numerical values, status information, or error codes. The controller needs to format this data into a message format suitable for communication, ensuring the integrity and accuracy of the information. Based on the information from the execution result, the controller constructs the response message. This typically includes selecting an appropriate message protocol, filling in the response data, and possibly generating checksums or sequence numbers to ensure reliable communication. The controller prepares to send the response message, including possible communication interface configurations and signal modulation, to ensure a stable communication connection with the host computer test system.

[0090] Optionally, the controller sends response messages to the host computer testing system via the communication board according to preset communication protocols and logic. This requires the controller to have good communication management and scheduling capabilities to adapt to the communication needs of different testing scenarios. Under some communication protocols, the controller may need to wait for an acknowledgment response from the host computer after sending a message to ensure that the message is successfully delivered and correctly interpreted.

[0091] In steps S202 to S204 of this application, in response to receiving the test message corresponding to the test case sent by the host computer testing system, the target operation in the test message is executed to obtain the execution result; according to the execution result, a response message is generated and sent to the host computer testing system. This solves the technical problem of low accuracy in vehicle controller performance testing and achieves the technical effect of improving the accuracy of vehicle controller performance testing.

[0092] The technical solutions of the embodiments of the present invention will be illustrated below with reference to preferred embodiments.

[0093] Currently, the basic principle of HIL testing is to virtually simulate the various signals required by the controller using HIL testing equipment, while simultaneously acquiring the various signals emitted by the controller, thereby performing hardware-in-the-loop testing. Today, HIL testing has become a crucial part of the vehicle's electronic and electrical development process, reducing vehicle testing cycles, increasing coverage of extreme operating conditions, and enhancing OEMs' confidence in the quality of their products. With the continuous development of HIL testing technology, major domestic OEMs in the commercial vehicle sector have acquired HIL testing capabilities.

[0094] In related technologies, HIL (Hardware-In-the-Loop) testing systems are used to test functionality, while host computer testing software focuses on verifying the correctness of signal values ​​and cannot perform performance testing on controller response time. According to the functional safety definition, faults can be divided into two categories: system faults and random faults. The former can only be eliminated by changing the manufacturing process, operating procedures, documentation design, or other related factors. The latter are unpredictable faults that occur during the hardware's lifecycle. Based on probability distribution, these faults may be caused by permanent or temporary environmental disturbances, or by the frequency of the clock signal affecting the controller's performance. Therefore, testing the controller's millisecond-level response time is necessary. Consequently, the technical problem of low accuracy in vehicle controller performance testing remains.

[0095] However, this invention proposes a controller performance verification method based on in-loop testing. If performance testing of a vehicle's controller is required, the controller under test (DUT) can be connected to a host computer testing system. If the host computer testing system obtains a test case that triggers testing on the DUT, it can send a test message corresponding to the test case to the DUT. The sending time of the test message and the receiving time of the response message from the DUT are obtained. The target performance result of the DUT is determined using these sending and receiving times. In this invention, a precise time measurement mechanism is introduced into the controller performance testing. When executing test cases, the host computer testing system not only focuses on the controller's functional implementation and signal value correctness, but more importantly, it records and records the precise time of sending the test message to the DUT, as well as the exact time of receiving the controller's response message. Using these two precise times, the actual response time of the controller performing the target operation can be calculated, thereby obtaining the controller's true performance indicators. The above method effectively fills the gap in response time measurement in relevant HIL tests, enabling the host computer test system to comprehensively evaluate the real-time processing capability and performance stability of the controller, thereby solving the technical problem of low accuracy in vehicle controller performance testing and achieving the technical effect of improving the accuracy of vehicle controller performance testing.

[0096] The embodiments of the present invention will be further described below.

[0097] Figure 3 This is a schematic diagram of a controller performance verification system based on in-loop testing according to an embodiment of the present invention, as shown below. Figure 3 As shown, the performance verification system may include host computer test software 301, communication board 302, and controller under test 303. The host computer test software 301 may include an upload response time statistics module 3011 and a command issuance time statistics module 3012.

[0098] Optionally, the host computer test software 301 simulates the test environment required by the controller under test 303. When executing a test case, the instruction issuance time statistics module 3012 in the host computer test software 301 records the timestamp of the instruction issuance message and sends the instruction to the controller under test 303 through the communication board 302. After receiving the instruction, the controller under test sends a corresponding response message and uploads the response message to the host computer test software 301 through the communication board 302. The upload response time statistics module 3011 in the host computer test software 301 records the timestamp of the received response message. The difference between the two timestamps minus the response time of the two communication boards is the response time of the controller under test.

[0099] Optionally, the host computer testing software 301 executes the same test case multiple times, and statistically analyzes the response time of the controller under test 303 after receiving the same instruction each time, measuring and statistically analyzing the maximum response time, minimum response time, and average response time. Alternatively, the host computer testing software 301 executes different test cases multiple times, statistically analyzing the average response time of the controller under test 303 after receiving different instructions, facilitating comparative analysis and helping users pinpoint the controller's performance bottlenecks.

[0100] Figure 4 This is a schematic diagram of a performance testing system for a vehicle controller according to an embodiment of the present invention, as shown below. Figure 4 As shown, the vehicle controller performance testing system 400 may include a controller under test (DUT) 402 and a host computer testing system 404. The DUT 402, in response to receiving a test message, executes the target operation in the test message and obtains the execution result; according to the execution result, it generates a response message and sends the response message to the host computer testing system. The host computer testing system, in response to receiving at least one test case, sends a test message corresponding to the test case to the DUT; obtains the sending time corresponding to the test message and the receiving time corresponding to the response message from the DUT; and determines the target performance result of the DUT based on the sending and receiving times.

[0101] Optionally, the performance testing system also includes a communication board 406, which is used to send test messages to the controller under test and send response messages to the host computer testing system.

[0102] According to embodiments of the present invention, a performance testing apparatus for a vehicle controller is also provided. It should be noted that this performance testing apparatus for a vehicle controller can be used to perform the performance testing method for a vehicle controller described in the above embodiments.

[0103] Figure 5 This is a schematic diagram of a performance testing device for a vehicle controller according to an embodiment of the present invention. Figure 5 As shown, the performance testing device 500 for the vehicle controller may include: a first sending unit 502, an acquisition unit 504, and a determination unit 506.

[0104] The first sending unit 502 is used to send a test message corresponding to the test case to the vehicle's controller under test in response to acquiring at least one test case.

[0105] The acquisition unit 504 is used to acquire the sending time of the test message and the receiving time of the response message from the controller under test.

[0106] The determination unit 506 is used to determine the target performance result of the controller under test based on the transmission time and the reception time.

[0107] In this embodiment of the invention, the first sending unit 502, in response to acquiring at least one test case, sends a test message corresponding to the test case to the vehicle's controller under test. The acquiring unit 504 is used to acquire the sending time of the test message and the receiving time of the response message from the controller under test. The determining unit 506 determines the target performance result of the controller under test based on the sending and receiving times, thereby solving the technical problem of low accuracy in vehicle controller performance testing and achieving the technical effect of improving the accuracy of vehicle controller performance testing.

[0108] Figure 6 This is a schematic diagram of a performance testing device for a vehicle controller according to an embodiment of the present invention. Figure 6 As shown, the performance testing device 600 for the vehicle controller may include: an execution unit 602 and a second sending unit 604.

[0109] The execution unit 602 is used to respond to the test message corresponding to the test case sent by the host computer test system, execute the target operation in the test message, and obtain the execution result.

[0110] The second sending unit 604 is used to generate a response message according to the execution result and send the response message to the host computer test system.

[0111] In this embodiment of the invention, the execution unit 602, in response to receiving the test message corresponding to the test case sent by the host computer testing system, executes the target operation in the test message to obtain the execution result. The second sending unit 604 then generates a response message according to the execution result and sends the response message to the host computer testing system, thereby solving the technical problem of low accuracy in vehicle controller performance testing and achieving the technical effect of improving the accuracy of vehicle controller performance testing.

[0112] According to an embodiment of the present invention, a computer-readable storage medium is also provided, the storage medium including a stored program, wherein the program executes the performance testing method for the vehicle controller in the above embodiments.

[0113] According to an embodiment of the present invention, a processor is also provided for running a program, wherein the program executes the performance testing method for the vehicle controller in the above embodiments.

[0114] Embodiments of this application also provide a computer program product. Optionally, in this embodiment, the computer program product may include a computer program that, when executed by a processor, implements the performance testing method for the vehicle controller described in the embodiments of this application.

[0115] In the above embodiments of the present invention, the description of each embodiment has its own focus. For parts that are not described in detail in a certain embodiment, reference can be made to the relevant descriptions of other embodiments.

[0116] In the several embodiments provided in this application, it should be understood that the disclosed technical content can be implemented in other ways. Among them, the device embodiments described above are only schematic. For example, the division of the units can be a logical function division. In actual implementation, there may be other division methods, such as multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the mutual coupling or direct coupling or communication connection shown or discussed can be through some interfaces, indirect coupling or communication connection of units or modules, which can be electrical or other forms.

[0117] The units described as separate components may or may not be physically separate, and the components shown as units may or may not be physical units, that is, they may be located in one place or distributed across multiple units. Some or all of the units may be selected according to actual needs to achieve the purpose of the present embodiment.

[0118] In addition, the functional units in the various embodiments of the present invention may be integrated into a single processing unit, each unit may exist physically separately, or two or more units may be integrated into a single unit. The aforementioned integrated units may be implemented in the form of hardware or software functional units.

[0119] If the integrated unit is implemented as a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present invention, in essence, or the part that contributes to the prior art, or all or part of the technical solution, can be embodied in the form of a software product. This computer software product is stored in a storage medium and includes several instructions to cause a computer device (which may be a personal computer, server, or network device, etc.) to execute all or part of the steps of the methods described in the various embodiments of the present invention. The aforementioned storage medium includes various media capable of storing program code, such as USB flash drives, read-only memory (ROM), random access memory (RAM), portable hard drives, magnetic disks, or optical disks.

[0120] The above is only a preferred embodiment of the present invention. It should be pointed out that for ordinary technicians in this technical field, several improvements and modifications can be made without departing from the principles of the present invention. These improvements and modifications should also be regarded as the scope of protection of the present invention.

Claims

1. A performance testing method for a vehicle controller, characterized in that, The method, applied to a host computer testing system, includes: In response to acquiring at least one test case, a test message corresponding to the test case is sent to the vehicle's controller under test, wherein the test case is used to simulate a test environment for performance testing of the controller under test, and the test message is used to indicate the target operation to be performed by the controller under test in the test environment; The sending time of the test message is obtained, and the receiving time of the response message from the controller under test is obtained, wherein the response message is used to indicate the execution result of the controller under test performing the target operation in the test environment; Based on the transmission time and the reception time, the target performance result of the controller under test is determined, wherein the target performance result is used to represent the timeliness of the controller under test in performing the target operation in the test environment.

2. The method according to claim 1, characterized in that, Determining the target performance of the controller under test based on the transmission time and the reception time includes: Based on the sending time and the receiving time, the response duration of the controller under test is determined, wherein the response duration is used to represent the duration for the controller under test to respond to the test message and send the response message in the test environment; The target performance result is determined based on the response time.

3. The method according to claim 2, characterized in that, The controller under test is connected to the host computer test system via a communication board, and the method further includes: Obtain the first communication duration and the second communication duration of the communication board, wherein the first communication duration is used to represent the duration of the communication board transmitting the test message, and the second communication duration is used to represent the duration of the communication board transmitting the response message; Based on the transmission time and the reception time, the response duration of the controller under test is determined, including: Determine a first difference between the sending time and the receiving time; Determine the first difference minus the second difference between the first communication duration and the second communication duration; The second difference is then determined as the response duration.

4. The method according to claim 2, characterized in that, The method further includes: Obtain the number of times the current test case is executed in at least one of the aforementioned test cases; Determining the target performance result based on the response duration includes: obtaining the response duration of the execution count during the execution of the current test case according to the execution count; Based on the response time of the number of executions, determine the maximum response time, minimum response time, and average response time; Based on the maximum response time, the minimum response time, and the average response time, the target performance result corresponding to the current test case is determined.

5. The method according to claim 1, characterized in that, The number of test cases to be executed is multiple. Based on the sending time and the receiving time, the target performance result of the controller under test is determined, including: The target performance result is determined based on the sending time and receiving time corresponding to the multiple test cases to be executed.

6. The method according to claim 5, characterized in that, In response to the existence of multiple test cases to be executed, the target performance result is determined based on the sending time and receiving time corresponding to the multiple test cases to be executed, including: In response to the fact that there are multiple test cases to be executed, the average response time corresponding to the multiple test cases to be executed is determined based on the sending time and the receiving time corresponding to the multiple test cases to be executed respectively. If, in response to an abnormal average response time exceeding a preset average response time threshold among the average response times corresponding to multiple test cases, the target performance result under the test environment corresponding to the abnormal average response time is determined to be the timeliness of the control device under test executing the target operation, which is lower than the timeliness of the control device under test executing the target operation under the test environment corresponding to the preset average response time threshold.

7. A performance testing method for a vehicle controller, characterized in that, Applied to a controller under test, the method includes: In response to receiving a test message corresponding to a test case sent by the host computer testing system, the target operation in the test message is executed to obtain the execution result. The test case is used to simulate a test environment for performance testing of the controller under test, and the test message is used to represent the target operation to be executed by the controller under test in the test environment. According to the execution result, a response message is generated and sent to the host computer test system. The response message indicates the execution result of the controller under test performing the target operation in the test environment. The host computer test system determines the target performance result of the controller under test based on the sending time corresponding to the test message and the receiving time corresponding to the received response message. The target performance result indicates the timeliness of the controller under test performing the target operation in the test environment.

8. A performance testing system for a vehicle controller, characterized in that, The performance testing system includes the vehicle's controller under test (DUT) and a host computer testing system, among which... The host computer testing system is configured to, in response to acquiring at least one test case, send a test message corresponding to the test case to the controller under test (DUT), wherein the test case is used to simulate a test environment for performance testing of the DUT, and the test message represents the target operation to be performed by the DUT in the test environment; acquire the sending time corresponding to the test message and acquire the receiving time corresponding to the response message from the DUT, wherein the response message represents the execution result of the DUT performing the target operation in the test environment; and determine the target performance result of the DUT based on the sending time and the receiving time, wherein the target performance result represents the timeliness of the DUT performing the target operation in the test environment. The controller under test is configured to, in response to receiving the test message, execute the target operation in the test message to obtain the execution result; generate the response message according to the execution result, and send the response message to the host computer test system.

9. The system according to claim 8, characterized in that, The performance testing system also includes a communication board, wherein... The communication board is used to send the test message to the controller under test and the response message to the host computer test system.

10. A vehicle, characterized in that, include: Memory, which stores executable programs; A processor for running the program, wherein the program, when running, performs the method according to any one of claims 1 to 7.