Communication test positioning method, device and equipment based on real vehicle diagnosis service, and storage medium
By monitoring the communication behavior of real vehicles, automatically determining diagnostic commands and dwell times, and generating stress test reports, the problem of low communication testing efficiency in existing technologies is solved, achieving efficient and accurate communication anomaly localization and improving the stability and security of vehicle communication systems.
Patent Information
- Application Number
- CN202411510678.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-10-28
- Publication Date
- 2026-01-13
- Estimated Expiration
- 2044-10-28
AI Technical Summary
Existing real-vehicle communication testing methods are inefficient, rely on manual operation, and are difficult to conduct large-scale stress tests, resulting in large errors in test results and affecting vehicle performance and safety.
By monitoring the communication behavior of each network segment of the actual vehicle, determining the communication diagnostic commands and diagnostic dwell time, automatically determining the communication stop and recovery status, performing automated stress testing, generating test reports and outputting communication status message characteristic values, and locating communication anomalies and faults.
This improved the accuracy and efficiency of testing, reduced manpower and time investment, lowered testing costs, and ensured the stability and security of vehicle communication systems.
Smart Images

Figure CN119383065B_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of automotive communication control technology, and in particular to communication test positioning methods, devices, equipment and storage media based on real vehicle diagnostic services. Background Technology
[0002] With the continuous upgrading of automotive electronic systems, the reliability requirements of communication systems are becoming increasingly stringent when real vehicles undergo remote over-the-air (OTA) upgrades or other diagnostic services. However, during the R&D phase, some models have experienced occasional anomalies where certain vehicle functions become unusable after a successful OTA upgrade. Therefore, to ensure the integrity and safety of vehicle functions, testing and locating any anomalies that may occur in the vehicle's communication system is an essential task.
[0003] Currently, in existing practices, vehicle communication testing involves sending specific diagnostic commands, such as mute and unmute commands, through diagnostic equipment to monitor and control the communication status. This requires monitoring communication behavior, recording the communication status, and analyzing the data after the test to determine if any communication anomalies exist.
[0004] However, the existing methods for unmuting are incompatible with the remote over-the-air (OTA) download technology upgrade process. The diagnostic commands cannot suppress positive responses in vehicle communication, and the reliance on manually executed diagnostic commands is inefficient and susceptible to human error. This is not only time-consuming and labor-intensive, but also makes it difficult to conduct large-scale stress tests due to the lack of automation. Furthermore, the repeatability and consistency of manual testing are difficult to guarantee, leading to errors in test results and affecting vehicle performance and safety. Therefore, how to more accurately and efficiently test and locate communication anomalies has become an urgent problem to be solved.
[0005] The above content is only used to help understand the technical solution of this application and does not represent an admission that the above content is prior art. Summary of the Invention
[0006] The main purpose of this application is to provide a communication test and location method, device, equipment and storage medium based on real vehicle diagnostic services, aiming to solve the technical problem of how to more accurately and efficiently test and locate communication anomalies.
[0007] To achieve the above objectives, this application proposes a communication test positioning method based on real-vehicle diagnostic services, the method comprising:
[0008] Monitor the communication behavior of each network segment of the actual vehicle to determine the communication diagnostic commands and communication diagnostic dwell time;
[0009] The communication stop status and communication recovery status are determined based on the communication diagnostic command and the communication diagnostic dwell time.
[0010] Based on the communication stop state and the communication recovery state, an automated stress test is performed to generate a test report, and based on the test report, the communication status message feature values are output to locate communication anomalies.
[0011] In one embodiment, the steps of monitoring the communication behavior of each network segment of the actual vehicle and determining the communication diagnostic command and communication diagnostic dwell time include:
[0012] Define diagnostic commands, online handshake commands, diagnostic service commands, switch default session mode diagnostic commands, extend session response dwell time and communication stop duration;
[0013] The communication diagnostic command is determined based on the diagnostic service command and the diagnostic command to switch the default session mode.
[0014] The communication diagnostic dwell time is determined based on the extended session response dwell time and the communication stop duration.
[0015] In one embodiment, the step of determining the communication stop state and the communication recovery state based on the communication diagnostic command and the communication diagnostic dwell time includes:
[0016] Based on the diagnostic service command in the communication diagnostic command and the extended session response dwell time in the communication diagnostic dwell time, the system controls the vehicle to turn off the vehicle recording function, and obtains the dwell time of the function shutdown and the mute command;
[0017] Based on the dwell time of the shutdown function, the mute command, the dwell time of the communication diagnosis, and the communication diagnosis command, the network segment communication status is determined to obtain the communication stop status and the communication recovery status.
[0018] In one embodiment, the step of determining the network segment communication status and obtaining the communication stop status and communication recovery status based on the dwell time of the shutdown function, the mute command, the dwell time of the communication diagnosis, and the communication diagnosis command includes:
[0019] Based on the dwell time of the shutdown function and the mute command, the vehicle is controlled to stop communication to determine the communication stop status;
[0020] Based on the communication stop duration in the communication diagnostic dwell time and the switch default session mode diagnostic command in the communication diagnostic command, the vehicle is controlled to restore communication and determine the communication recovery status.
[0021] In one embodiment, the step of performing automated stress testing based on the communication stop state and the communication recovery state to determine a test report, and outputting communication status message feature values based on the test report to locate communication anomalies includes:
[0022] Obtain the target number of load tests;
[0023] An automated stress test report is generated based on the target number of stress tests, the communication stop status, and the communication recovery status.
[0024] Based on the characteristic values of the communication status messages output in the test report, communication anomalies and faults can be located.
[0025] In one embodiment, the step of determining a test report based on the target number of stress tests, the communication stop status, and the communication recovery status includes:
[0026] Obtain the network segment packet characteristic value and the network segment packet count. The network segment packet characteristic value includes the network segment packet characteristic value before being muted, the network segment packet characteristic value after being muted, and the network segment packet characteristic value after being unmuted. The network segment packet count includes the network segment packet count before being muted, the network segment packet count after being muted, and the network segment packet count after being unmuted.
[0027] The network segment communication status is determined and a test report is obtained based on the network segment message characteristic values before the mute, the network segment message characteristic values after the mute, the network segment message characteristic values after the mute is lifted, the number of network segment messages before the mute, the number of network segment messages after the mute, and the number of network segment messages after the mute is lifted.
[0028] In one embodiment, the step of determining the network segment communication status and obtaining a test report based on the network segment packet characteristic values before the mute, the network segment packet characteristic values after the mute, the network segment packet characteristic values after the mute is lifted, the number of network segment packets before the mute, the number of network segment packets after the mute, and the number of network segment packets after the mute is lifted includes:
[0029] The communication status of the first network segment is determined by comparing the number of network segment packets before and after the mute.
[0030] The communication status of the second network segment is determined by comparing the characteristic values of the network segment messages before the mute is lifted with the characteristic values of the network segment messages after the mute is lifted.
[0031] The network segment communication status is determined based on the first network segment communication status, and a test report is obtained based on the network segment communication status.
[0032] Furthermore, to achieve the above objectives, this application also proposes a communication test positioning device based on real-vehicle diagnostic services, the communication test positioning device based on real-vehicle diagnostic services comprising:
[0033] The determination module is used to monitor the communication behavior of each network segment of the actual vehicle and determine the communication diagnostic commands and communication diagnostic dwell time.
[0034] The processing module is used to determine the communication stop status and the communication recovery status based on the communication diagnostic command and the communication diagnostic dwell time;
[0035] The execution module is used to perform automated stress testing based on the communication stop state and the communication recovery state to determine a test report, and to locate communication anomalies based on the communication status message feature values output by the test report.
[0036] Furthermore, to achieve the above objectives, this application also proposes a communication test and positioning device based on real vehicle diagnostic services. The device includes: a memory, a processor, and a computer program stored in the memory and executable on the processor. The computer program is configured to implement the steps of the communication test and positioning method based on real vehicle diagnostic services as described above.
[0037] In addition, to achieve the above objectives, this application also proposes a storage medium, which is a computer-readable storage medium, on which a computer program is stored, and when the computer program is executed by a processor, it implements the steps of the communication test positioning method based on real vehicle diagnostic services as described above.
[0038] One or more technical solutions proposed in this application have at least the following technical effects:
[0039] This application proposes a communication test localization method based on real-vehicle diagnostic services. It monitors the communication behavior of each network segment of the real vehicle, determines communication diagnostic commands and communication diagnostic dwell times, determines communication stop and recovery states based on the commands and dwell times, performs automated stress testing based on the stop and recovery states to generate test reports, and outputs communication status message feature values based on the test reports to locate communication anomalies. This application automates the monitoring of communication behavior of each network segment of the real vehicle, determines communication diagnostic commands and dwell times to identify stop and recovery states, and executes automated stress testing to generate test reports. It accurately outputs communication status message feature values, efficiently and accurately locating communication anomalies, improving test accuracy, and significantly improving test efficiency through automation, reducing manpower and time investment, and lowering test costs. Attached Figure Description
[0040] The accompanying drawings, which are incorporated in and form part of this specification, illustrate embodiments consistent with this application and, together with the description, serve to explain the principles of this application.
[0041] To more clearly illustrate the technical solutions in the embodiments of this application or the prior art, the drawings used in the description of the embodiments or the prior art will be briefly introduced below. Obviously, for those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0042] Figure 1 This is a flowchart illustrating an embodiment of the communication test positioning method based on real vehicle diagnostic services provided in this application.
[0043] Figure 2 This is a flowchart illustrating Embodiment 2 of the communication test positioning method based on real vehicle diagnostic services in this application.
[0044] Figure 3 A simplified flowchart illustrating the communication test positioning method based on real vehicle diagnostic services provided in this application embodiment;
[0045] Figure 4 This is a schematic diagram of the module structure of the communication test and positioning device based on real vehicle diagnostic services according to an embodiment of this application;
[0046] Figure 5 This is a schematic diagram of the hardware operating environment involved in the communication test positioning method based on real vehicle diagnostic services in the embodiments of this application.
[0047] The purpose, features, and advantages of this application will be further explained in conjunction with the embodiments and with reference to the accompanying drawings. Detailed Implementation
[0048] It should be understood that the specific embodiments described herein are merely illustrative of the technical solutions of this application and are not intended to limit this application.
[0049] To better understand the technical solution of this application, a detailed description will be provided below in conjunction with the accompanying drawings and specific implementation methods.
[0050] The main solution of this application embodiment is: monitoring the communication behavior of each network segment of the actual vehicle, determining the communication diagnostic command and the communication diagnostic dwell time; determining the communication stop state and the communication recovery state based on the communication diagnostic command and the communication diagnostic dwell time; performing automated stress testing based on the communication stop state and the communication recovery state to determine the test report, and locating the communication abnormal fault by outputting the communication status message feature value based on the test report.
[0051] In this embodiment, for ease of description, the following description will focus on identifying communication test positioning devices based on real vehicle diagnostic services.
[0052] Because the existing technology for unblocking speech is incompatible with the remote over-the-air download technology upgrade process, the diagnostic commands cannot suppress positive responses in vehicle communication. Furthermore, the diagnostic commands rely on manual execution, which requires manual operation, is inefficient, and is susceptible to human error. This is not only time-consuming and labor-intensive, but also makes it difficult to conduct large-scale stress tests due to the lack of automation. At the same time, the repeatability and consistency of manual testing are difficult to guarantee, leading to errors in test results, which in turn affect the vehicle's performance and safety.
[0053] This application provides a solution to monitor the communication behavior of each network segment in a real vehicle, determine communication diagnostic commands and communication diagnostic dwell time; determine communication stop status and communication recovery status based on the communication diagnostic commands and communication diagnostic dwell time; perform automated stress testing based on the communication stop status and the communication recovery status to generate a test report, and locate communication anomalies based on the communication status message feature values output from the test report.
[0054] As can be seen from the above embodiments, this application determines the communication stop state and communication recovery state by automatically monitoring the communication behavior of each network segment of the actual vehicle, determining the communication diagnostic command and communication diagnostic dwell time, and performing automated stress testing to generate test reports, accurately outputting the characteristic values of communication status messages, efficiently and accurately locating communication anomalies, improving the accuracy of testing, and significantly improving testing efficiency through automated processes, reducing the input of manpower and time, and lowering testing costs.
[0055] Based on this, embodiments of this application provide a communication test positioning method based on real vehicle diagnostic services, referring to... Figure 1 , Figure 1 This is a flowchart illustrating the first embodiment of the communication test positioning method based on real vehicle diagnostic services in this application.
[0056] In this embodiment, the communication test positioning method based on real vehicle diagnostic services includes steps S10 to S30:
[0057] Step S10: Monitor the communication behavior of each network segment of the actual vehicle, and determine the communication diagnostic commands and communication diagnostic dwell time;
[0058] It should be noted that the communication diagnostic command reflects the characteristics of the command that is expected to perform a specific diagnostic operation, and the communication diagnostic dwell time reflects the characteristics of the length of time to wait for a response after sending the diagnostic command.
[0059] Understandably, by precisely monitoring and controlling the determination of communication diagnostic commands and communication diagnostic dwell time, the behavior of the real vehicle communication system under different operating states can be simulated more accurately. Communication recovery without abnormalities during the communication diagnostic dwell time ensures the stable and reliable operation of the communication system, improves communication efficiency and diagnostic accuracy, and reduces the risk of vehicle function failure due to communication anomalies.
[0060] Additionally, it should be noted that automated stress testing can simulate complex communication scenarios, quickly locate and resolve communication anomalies, thereby improving the stability and reliability of the vehicle's communication system. This ensures that the vehicle can restore normal communication functions after muting and unmuting operations, improving vehicle safety and user experience, reducing human error and inconsistency, lowering testing costs, and improving the repeatability and maintainability of the testing process.
[0061] For ease of understanding, we will take the determination of communication diagnostic commands and communication diagnostic dwell time as an example, where the information acquisition device is the information acquisition module and the storage device is the memory.
[0062] The diagnostic device sends diagnostic commands via function addressing, such as the 10h 83h command sequence. Simultaneously, it sends online handshake commands via function addressing at 2-second intervals, such as the 3Eh 80h command sequence. At this point, it transitions from the default session mode to the extended session mode, determining the extended session response dwell time, such as 100ms. To ensure the vehicle ECU enters and maintains this extended session mode, the diagnostic device sends diagnostic service commands via function addressing, such as the 85h 82h command sequence and the 28h83h 03h command sequence, indicating successful mute. After waiting for the extended session response dwell time, such as 100ms, the diagnostic device sends a diagnostic command via function addressing to switch the default session mode, such as 10h. The 81h command sequence is executed, and the system simultaneously enters the default session mode. In this mode, it is expected that all vehicle ECUs will resume communication, i.e., the mute will be successfully lifted. Based on the diagnostic service command and the default session mode switching diagnostic command, a communication diagnostic command is determined. The communication behavior of the vehicle ECUs is continuously monitored to determine the communication stop duration, such as 5 minutes. It is expected that all ECUs will remain mute without generating error frames. Based on the extended session response dwell time and the communication stop duration, a communication diagnostic dwell time is determined. The information acquisition module determines the communication diagnostic command and the communication diagnostic dwell time, and stores them in the memory. Subsequent processing is then performed based on the communication diagnostic command and the communication diagnostic dwell time.
[0063] In one feasible implementation, step S10 may include steps A11 to A13:
[0064] Step A11: Determine the diagnostic command, online handshake command, diagnostic service command, switch default session mode diagnostic command, extended session response dwell time, and communication stop duration;
[0065] It should be noted that the diagnostic command reflects the characteristics of the system performing basic diagnostic operations, the online handshake command reflects the characteristics of the system establishing and maintaining communication sessions, the diagnostic service command reflects the characteristics of the system performing specific diagnostic services, the switch default session mode diagnostic command reflects the characteristics of the system changing specific diagnostic services, the extended session response dwell time reflects the characteristics of the time the system waits for a response after sending a diagnostic command, and the communication stop duration reflects the characteristics of the length of time the system expects to stop communication after executing certain diagnostic commands.
[0066] Step A12: Determine the communication diagnostic command based on the diagnostic service command and the diagnostic command to switch the default session mode;
[0067] It is understood that the diagnostic service commands correspond to specific diagnostic service IDs and are used to perform complex diagnostic operations. For example, the diagnostic service commands are the 85h 82h command sequence and the 28h 83h 03h command sequence. The 85h 82h command sequence is used to identify faults in the vehicle emission control system or its components, and is also used to disable or clear diagnostic fault codes, i.e., to clear fault codes previously stored in the vehicle ECU. The 28h 83h 03h command sequence is used to control the communication behavior of ECUs in the vehicle network. For example, it can be used to mute or unmute ECUs, i.e., to temporarily stop or resume ECU communication. It is also used to specify the specific operations to be performed under the communication control service, instructing the ECU to enter a special communication state. For example, it can be used to prepare the ECU for software updates or reset operations, instructing the ECU to stop sending all unnecessary communication messages and only send the necessary messages to maintain the current diagnostic session.
[0068] Additionally, it should be noted that the diagnostic command to switch the default session mode allows the system to switch between different session modes. For example, the diagnostic command to switch the default session mode is the 10h 81h command sequence, which is used to control the diagnostic session with the vehicle's electronic control unit (ECU). It can change the session mode to access different levels of diagnostic information and is also used to specify the specific operations to be performed under the diagnostic session control service, such as switching back from the current extended session mode to the default session mode.
[0069] Step A13: Determine the communication diagnostic dwell time based on the extended session response dwell time and the communication stop duration.
[0070] Understandably, in a vehicle's network system, diagnostic commands and response information need to be transmitted between multiple ECUs. Different ECUs require different processing times for diagnostic commands, and the extended session response dwell time must also take this network communication latency into account. Therefore, a reasonable extended session response dwell time needs to be set. If the extended session response dwell time is set too short, the system will incorrectly assume communication failure before the ECU actually responds, leading to unstable or inaccurate diagnostic processes. Conversely, if the extended session response dwell time is too long, it will unnecessarily prolong the diagnostic process. When performing diagnostic silence tests, it is necessary to ensure that all relevant ECUs stop communicating within the same time period. By controlling the duration of this communication stoppage, network communication problems, such as message loss, response delays, or network conflicts, can be detected and diagnosed more accurately.
[0071] Step S20: Determine the communication stop status and communication recovery status based on the communication diagnostic command and the communication diagnostic dwell time;
[0072] It should be noted that the communication stop state reflects the characteristics of the function execution state after the mute command is executed, and the communication resume state reflects the characteristics of the function execution state after the mute command is executed.
[0073] Understandably, after performing diagnostic tests and executing the mute command, it is determined whether communication has stopped. The mute function diagnosis is then performed to determine whether the mute was successful. If the mute is successful, the communication stop status indicates that the entire vehicle ECU has been successfully muteed. If the mute fails, the communication stop status indicates that the mute has failed, which means the ECU has been located. After executing the unmute command, it is determined whether communication has resumed. The unmute function diagnosis is then performed to determine whether the mute has been successfully lifted. If the mute is successfully lifted, the communication resume status indicates that the mute has been successfully lifted, which means the entire vehicle ECU has been successfully unmuteed. If the mute is unlifted, the communication resume status indicates that the mute has failed, which means the ECU has failed to be unmuteed, which means the ECU has been located.
[0074] Additionally, it should be noted that by determining the communication stop state and the communication recovery state, the location of the communication anomaly can be pinpointed, improving the accuracy and safety of diagnostic operations and reducing potential failures caused by communication problems.
[0075] For ease of understanding, we will take the determination of communication stop state and communication resume state as an example, where the information acquisition device is the information acquisition module, the storage device is the memory, and the processing device is the processing module.
[0076] The information acquisition module determines the communication diagnostic command and communication diagnostic dwell time and stores them in the memory. It sends a diagnostic command frame, such as the 10h 83h command sequence, waits for 100ms, and then sends an online handshake command to maintain the session at 2s intervals, such as the 3Eh 80h command sequence. Based on the diagnostic service command in the communication diagnostic command and the extended session response dwell time in the communication diagnostic dwell time, it controls the vehicle to turn off the vehicle recording function, and obtains the shutdown dwell time and mute command. It sends a diagnostic service command to mute, such as the 85h 82h command sequence, waits for 100ms, and controls the vehicle to stop communication based on the shutdown dwell time and the mute command to determine the communication stop state. It sends a diagnostic service command to unmute, such as the 28h 83h 03h diagnostic instruction, and continuously monitors the communication behavior of each network segment for 5 minutes. It sends a diagnostic command to switch the default session mode, such as the 10h 81h command sequence, waits for 100ms, and then stops sending the 3Eh 80h diagnostic session maintenance command, and continuously monitors the communication behavior of each network segment for 30 seconds. Based on the communication stop duration in the communication diagnostic dwell time and the switch default session mode diagnostic command in the communication diagnostic command, the vehicle is controlled to restore communication and determine the communication recovery status.
[0077] In one feasible implementation, step S20 may include steps B11 to B12:
[0078] Step B11: Based on the diagnostic service command in the communication diagnostic command and the extended session response dwell time in the communication diagnostic dwell time, control the vehicle to turn off the vehicle recording function, and obtain the dwell time of the function shutdown and the mute command;
[0079] It should be noted that the "disable function dwell time" reflects the length of time spent waiting after executing the diagnostic command to disable the vehicle recording function, and the "mute command" reflects the characteristic of a command to temporarily stop vehicle communication.
[0080] Understandably, by monitoring the changes in communication status before and after a mute command, the location and cause of communication anomalies during the mute can be accurately identified, effectively locating the communication anomalies. This not only improves the efficiency of fault diagnosis but also reduces the risk of vehicle malfunctions caused by communication problems, thereby enhancing the stability and security of the vehicle communication system.
[0081] Step B12: Based on the dwell time of the shutdown function, the mute command, the dwell time of the communication diagnosis, and the communication diagnosis command, determine the network segment communication status to obtain the communication stop status and the communication recovery status.
[0082] Understandably, by precisely controlling the dwell time of the shutdown function and executing the mute command, there is sufficient time to respond to and complete the expected operation when executing diagnostic commands, thereby avoiding misjudgments caused by insufficient waiting time, providing a stable communication environment, reducing external interference, and improving the accuracy and reliability of testing.
[0083] In one feasible implementation, step B12 may include steps C11 to C12:
[0084] Step C11: Based on the dwell time of the shutdown function and the mute command, control the entire vehicle to stop communication and determine the communication stop status;
[0085] Understandably, by precisely controlling the dwell time of the shutdown function and executing the mute command, communication anomalies during mute can be effectively located, and the location and cause of communication anomalies during mute can be accurately and intelligently identified, thereby improving the efficiency of fault diagnosis and significantly enhancing vehicle performance and user experience.
[0086] Step C12: Based on the communication stop duration in the communication diagnostic dwell time and the switch default session mode diagnostic command in the communication diagnostic command, control the vehicle to restore communication and determine the communication recovery status.
[0087] Understandably, by executing the diagnostic command to switch the default session mode, communication anomalies when the mute is lifted can be effectively located, the location and cause of the communication anomalies can be accurately identified, the efficiency of fault diagnosis can be improved, and vehicle performance and user experience can be significantly enhanced.
[0088] Step S30: Perform automated stress testing based on the communication stop state and the communication recovery state to determine a test report, and locate communication anomalies based on the communication status message feature values output from the test report.
[0089] It should be noted that the test report reflects the characteristics of abnormal communication failure states.
[0090] It is understood that the test report is generated through automated stress testing. Automated testing reduces the repetitiveness and labor intensity of manual testing, improves the efficiency of the testing process, reduces manpower requirements, improves test repeatability, reduces testing costs caused by human error, can simulate more communication scenarios, and can continuously monitor communication behavior, thereby improving the accuracy of test results. In addition, the communication status message feature values included in the test report can quickly identify and locate communication anomalies and faults, thereby shortening the fault diagnosis time.
[0091] For ease of understanding, we will take the test report as an example, where the information acquisition device is the information acquisition module, the storage device is the memory, and the execution device is the execution module.
[0092] A Panel is developed, using Input or Output Box controls to input the number of load tests to be performed, i.e., the target number of load tests, such as 1000. The automated test script obtains the number of load tests to be performed by the Panel to implement the loop load test function. The information acquisition module obtains the target number of load tests, communication stop status, and communication recovery status and stores them in the memory. It also obtains the network segment packet characteristic values and the number of network segment packets. The network segment packet characteristic values include the network segment packet characteristic values before being muted, after being muted, and after being unmuted. The number of network segment packets includes the number of network segment packets before being muted, after being muted, and after being unmuted.
[0093] Obtain the characteristic values and quantity of network segment messages before the mute command, start monitoring of each CAN network segment communication for 5 seconds, use the onmessage* function to store the characteristic value IDs of the CAN messages received by each network segment into the array ALLID_Before[this.can][MsgID_Bef], and count the number of messages Num_ControlBefore[this.can] based on the unique characteristic value IDs of each network segment. Here, the one-dimensional array this.can corresponds to each CAN network segment channel, and the two-dimensional data MsgID_Bef corresponds to the characteristic value IDs of the messages before the mute command (28(h)). Obtain the characteristic values and quantity of network segment messages after the mute command, start monitoring of each CAN network segment communication for 5 minutes after the mute command, and use the onmessage* function. The `message*` function stores CAN messages that are still communicating in each network segment into the array `ControlFail[this.can][MsgID_Fail]`. It then searches the DBC file based on the message's characteristic value ID and outputs the characteristic value ID of the muted message and its associated ECU in the test report. Here, the one-dimensional array `this.can` corresponds to each CAN network segment channel, and the two-dimensional data `MsgID_Fail` corresponds to the characteristic value ID of the muted message. After unmuting, it obtains the characteristic value and quantity of network segment messages. After executing the unmuting command, it starts monitoring communication in each CAN network segment. Using the `on message*` function, it stores the characteristic value ID of the CAN messages received by each network segment into the array `ALLID_After[this.can][MsgID_Aft]`, and counts the message quantity `Num_ControlAfter[this.can]` based on the unique characteristic value IDs of each network segment. Here, the one-dimensional array `this.can` corresponds to each CAN network segment channel, and the two-dimensional data `MsgID_Aft` corresponds to the message ID after unmuting.
[0094] The communication status of the first network segment is determined by comparing the number of network segment packets before and after the ban. The communication status of the second network segment is determined by comparing the feature values of the network segment packets before and after the ban. The network segment communication status is determined based on the first network segment communication status and the first network segment communication status.
[0095] The system sequentially compares the number of messages after unmuting each network segment with the number of messages before muting. If the condition is met (If(Num_ControlAfter[this.can] ≠ Num_ControlAfter[this.can])), communication is considered normal after unmuting. If the condition is met (If(Num_ControlAfter[this.can] != Num_ControlAfter[this.can])), communication is considered abnormal after unmuting, and a second check is performed to determine the specific message to be sent to the ECU. The system then sequentially compares the message characteristic value ID of each network segment after unmuting with the message characteristic value ID of the message before muting. If the condition is met (If(ALLID_After[this.can][MsgID_Aft] ≠ ALLID_Before[this.can][MsgID_Bef])), communication is considered normal after unmuting for that network segment and for that message. If the condition is met (If(ALLID_After[this.can][MsgID_Bef])), communication is considered normal after unmuting for that network segment and for that message. If `gID_Aft` is equal to `ALLID_Before[this.can][MsgID_Bef]`, then it is determined that communication is abnormal after the message in this network segment is unblocked.
[0096] A test report is obtained based on the network segment communication status. Based on the test report, the communication status message feature value is output to locate communication anomalies. The test report outputs the message feature value ID of communication normal or communication anomaly after the mute is lifted to the ECU.
[0097] This application proposes a communication test localization method based on real-vehicle diagnostic services. It monitors the communication behavior of each network segment of the real vehicle, determines communication diagnostic commands and communication diagnostic dwell times, determines communication stop and recovery states based on the commands and dwell times, performs automated stress testing based on the stop and recovery states to generate a test report, and outputs communication status message feature values based on the test report to locate communication anomalies. This solves the technical problem of how to efficiently and accurately locate communication anomalies. Compared to existing technologies, this application significantly improves the accuracy and efficiency of testing by monitoring the communication behavior of each network segment of the real vehicle, determining communication diagnostic commands and dwell times, using an automated testing process to accurately simulate the behavior of the real-vehicle communication system under different operating states, determining communication stop and recovery states, and performing automated stress testing to generate a test report and accurately output communication status message feature values. This enhances the stability and reliability of the communication system, ensures that the vehicle can restore normal communication functions after muting and unmuting operations, and improves vehicle safety and user experience.
[0098] Based on the first embodiment of this application, in the second embodiment of this application, the same or similar content as the first embodiment can be referred to the above description, and will not be repeated hereafter.
[0099] In this embodiment, refer to Figure 2 , Figure 2 This is a flowchart illustrating Embodiment 2 of the communication test positioning method based on real vehicle diagnostic services in this application. Step S30 specifically includes steps S31 to S33:
[0100] Step S31: Obtain the target number of load tests;
[0101] It should be noted that the target number of stress tests reflects the characteristic of setting a specific number of test rounds according to actual needs.
[0102] Understandably, different levels of communication load and stress can be simulated based on the target number of stress tests, allowing the test to be repeated under specific conditions. This makes the test results comparable, enabling a comprehensive evaluation of the communication system's performance under repeated stress and accurately locating occasional communication anomalies.
[0103] For ease of understanding, we will take obtaining the target number of stress tests as an example. The information acquisition device is the information acquisition module, the storage device is the memory, and the execution device is the execution module.
[0104] A Panel is developed, using Input or Output Box controls to input the number of load tests to be performed, i.e., the target number of load tests, such as 1000 times. The automated test script obtains the number of load tests to be performed by the Panel to realize the loop load test function. The information acquisition module obtains the target number of load tests and stores it in the memory, and performs subsequent processing based on the target number of load tests.
[0105] Step S32: Perform automated stress testing and determine a test report based on the target number of stress tests, the communication stop status, and the communication recovery status;
[0106] Understandably, by using automated scripts or programs to repeatedly execute tests based on predetermined communication stop and resume states, long-term communication loads can be simulated. Detailed test reports can be generated based on the data collected during the test to characterize the communication system's performance under stress conditions, thereby capturing abnormal communication behavior.
[0107] For ease of understanding, we will take the test report as an example, where the information acquisition device is the information acquisition module, the storage device is the memory, and the execution device is the execution module.
[0108] A Panel is developed, using Input or Output Box controls to input the number of load tests to be performed, i.e., the target number of load tests, such as 1000. An automated test script obtains the number of load tests performed by the Panel to implement a loop load test function. An information acquisition module obtains the target number of load tests, communication stop status, and communication recovery status and stores them in memory. It also obtains the network segment packet characteristic values and the number of network segment packets. The network segment packet characteristic values include those before, after, and after being muted. The number of network segment packets includes those before, after, and after being muted. The system sequentially compares the number of packets after each network segment is unmuted with the number before being muted. If (Num_ControlAfter[this.can]==Num_Control) is satisfied... If `If(Num_ControlAfter[this.can]!=Num_ControlAfter[this.can])` is satisfied, then communication is considered normal after the mute is lifted. If `If(Num_ControlAfter[this.can]!=Num_ControlAfter[this.can])` is satisfied, then communication is considered abnormal after the mute is lifted, and a second determination is performed to assign a specific message to the ECU. The characteristic value ID of the message after the mute is lifted for each network segment is compared with that before the mute. If `If(ALLID_After[this.can][MsgID_Aft]!=ALLID_Before[this.can][MsgID_Bef])` is satisfied, then communication is considered normal after the mute is lifted for that network segment and that message. If `If(ALLID_After[this.can][MsgID_Aft]!=ALLID_Before[this.can][MsgID_Bef])` is satisfied, then communication is considered abnormal after the mute is lifted for that network segment and that message. A test report is obtained based on the network segment communication status, and subsequent processing is performed based on the test report.
[0109] In one feasible implementation, step S32 may include steps D11 to D12:
[0110] Step D11: Obtain the network segment packet characteristic value and the number of network segment packets. The network segment packet characteristic value includes the network segment packet characteristic value before being muted, the network segment packet characteristic value after being muted, and the network segment packet characteristic value after being unmuted. The number of network segment packets includes the number of network segment packets before being muted, the number of network segment packets after being muted, and the number of network segment packets after being unmuted.
[0111] It should be noted that the network segment packet characteristic value reflects the characteristics of the packet content and attributes, and the network segment packet quantity reflects the characteristics of the total number of packets passing through a specific network segment within a specific time period.
[0112] It is understood that the network segment packet characteristic value can identify the status of the packet, such as whether it is transmitted correctly, whether there is an error, and whether it is delayed, thereby quickly locating communication anomalies and improving the accuracy of fault detection. The number of network segment packets represents the communication activity of the network segment, that is, the frequency of communication events that occur within a specific time period, which can promptly detect and resolve network congestion or other performance problems, thereby optimizing network performance.
[0113] Step D12: Based on the network segment message characteristic values before the mute, the network segment message characteristic values after the mute, the network segment message characteristic values after the mute is lifted, the number of network segment messages before the mute, the number of network segment messages after the mute is lifted, and the number of network segment messages after the mute is lifted, determine the network segment communication status and obtain a test report.
[0114] Understandably, by comparing the characteristic values and quantity of network segment packets, the location and cause of communication anomalies can be accurately identified, thereby generating a test report containing detailed communication status information. This allows for more accurate identification of communication anomalies, improved reliability of test results, rapid fault location, shortened fault handling time, enhanced system stability and security, timely detection and resolution of communication problems, and increased user satisfaction.
[0115] In one feasible implementation, step D12 may include steps E11 to E13:
[0116] Step E11: Compare the number of network segment packets before the mute and the number of network segment packets after the mute to determine the communication status of the first network segment;
[0117] It should be noted that the communication status of the first network segment reflects the characteristics of the change in communication load after the mute.
[0118] Understandably, comparing and analyzing the number of network segment packets can measure communication efficiency. If the number of network segment packets decreases significantly after being muted, it indicates that the muting function is effective. If the number of network segment packets does not decrease after being muted, it indicates that there is a communication problem, such as message filtering failure or communication control commands not being executed correctly.
[0119] Step E12: Compare the characteristic values of the network segment packets before the mute and the characteristic values of the network segment packets after the mute is lifted to determine the communication status of the second network segment;
[0120] It should be noted that the communication status of the second network segment reflects the changes in communication quality after the ban is lifted.
[0121] Understandably, comparative analysis of network segment packet characteristic values can measure the recovery status. If the packet characteristic values are abnormal after the ban is lifted, it indicates abnormal communication behavior or potential system errors.
[0122] Step E13: Determine the network segment communication status based on the first network segment communication status and obtain a test report based on the network segment communication status.
[0123] Understandably, by comprehensively assessing the network segment communication status to locate communication anomalies, ensuring that there is no abnormal communication recovery after communication stops, and that all vehicle ECUs can resume communication, potential problems can be detected and resolved in a timely manner, enhancing the overall stability of the system, shortening fault response time, and enabling the system to quickly return to normal operation.
[0124] Step S33: Locate communication anomalies based on the characteristic values of the communication status message output from the test report.
[0125] Understandably, real-time monitoring of communication status enables the system to detect faults immediately when they occur, improving the accuracy of fault detection. Furthermore, test reports can quickly locate communication anomalies, thus improving fault detection efficiency.
[0126] For ease of understanding, we will take obtaining a test report as an example. The information acquisition device is the information acquisition module, the storage device is the memory, and the execution device is the execution module.
[0127] The information acquisition module obtains the network segment communication status, generates a test report based on the network segment communication status, outputs the communication status message feature value based on the test report to locate communication anomalies, and outputs the communication normal or communication anomaly message feature value ID after the mute is lifted to the ECU.
[0128] This application proposes a communication test localization method based on real-vehicle diagnostic services. The method involves obtaining the target number of stress tests; performing automated stress testing based on the target number of stress tests, the communication stop status, and the communication recovery status to generate a test report; and locating communication anomalies based on the communication status message feature values output from the test report. This solves the technical problem of how to efficiently and accurately perform performance evaluation and fault localization of intermittent communication anomalies based on the generated test report. Compared to existing technologies, this application, by obtaining the target number of stress tests and executing automated stress tests, quickly and accurately simulates different communication load scenarios, collects test data and generates detailed test reports, analyzes the communication status message feature values in the test reports, rapidly identifies and locates communication anomalies, improves system stability and reliability, and simultaneously reduces maintenance costs and improves maintenance efficiency.
[0129] For example, to help understand the implementation process of the communication test positioning method based on real vehicle diagnostic services obtained by combining this embodiment with the above embodiment one, please refer to... Figure 3 , Figure 3 A simplified flowchart of a communication test localization method based on real-vehicle diagnostic services is provided, specifically:
[0130] Referring to Example 1, monitor the communication behavior of each network segment of the actual vehicle, determine the communication diagnostic command and communication diagnostic dwell time; determine the communication stop state and communication recovery state based on the communication diagnostic command and the communication diagnostic dwell time; perform automated stress testing based on the communication stop state and the communication recovery state to determine the test report, and locate communication anomalies based on the communication status message feature values output from the test report. Referring to Example 2, obtain the target number of stress tests; perform automated stress testing based on the target number of stress tests, the communication stop state and the communication recovery state to determine the test report; locate communication anomalies based on the communication status message feature values output from the test report. CANoe monitors all network segments of the actual vehicle, obtains the number of panel stress tests, the vehicle ECU enters extended session mode, the vehicle ECU disables the DTC recording function, the vehicle ECU stops communication, determines the communication stop state, whether the vehicle ECU successfully mutes or fails to mute, the vehicle ECU resumes communication, determines the communication recovery state, whether the vehicle ECU successfully unmutes or fails to unmute, completes the number of stress tests, and outputs the test report results.
[0131] It should be noted that the above examples are only for understanding this application and do not constitute a limitation on the communication test positioning method based on real vehicle diagnostic services in this application. Any simple modifications based on this technical concept are within the protection scope of this application.
[0132] This application also provides a communication test positioning device based on real vehicle diagnostic services. Please refer to [link / reference]. Figure 4 The communication test positioning device based on real vehicle diagnostic services includes:
[0133] Module 10 is used to monitor the communication behavior of each network segment of the actual vehicle and to determine the communication diagnostic commands and communication diagnostic dwell time.
[0134] Processing module 20 is used to determine the communication stop status and communication recovery status based on the communication diagnostic command and the communication diagnostic dwell time;
[0135] The execution module 30 is used to perform automated stress testing based on the communication stop state and the communication recovery state to determine a test report, and to locate communication abnormal faults by outputting communication status message feature values based on the test report.
[0136] The determining module 10 is also used to determine diagnostic commands, online handshake commands, diagnostic service commands, switching default session mode diagnostic commands, extended session response dwell time, and communication stop duration;
[0137] The communication diagnostic command is determined based on the diagnostic service command and the diagnostic command to switch the default session mode.
[0138] The communication diagnostic dwell time is determined based on the extended session response dwell time and the communication stop duration.
[0139] The processing module 20 is also used to control the vehicle to turn off the vehicle recording function based on the diagnostic service command in the communication diagnostic command and the extended session response dwell time in the communication diagnostic dwell time, and to obtain the dwell time of the function shutdown and the mute command;
[0140] Based on the dwell time of the shutdown function, the mute command, the dwell time of the communication diagnosis, and the communication diagnosis command, the network segment communication status is determined to obtain the communication stop status and the communication recovery status.
[0141] The processing module 20 is also used to determine the communication stop status based on the dwell time of the shutdown function and the mute command to control the whole vehicle to stop communication;
[0142] Based on the communication stop duration in the communication diagnostic dwell time and the switch default session mode diagnostic command in the communication diagnostic command, the vehicle is controlled to restore communication and determine the communication recovery status.
[0143] The execution module 30 is also used to obtain the target number of load tests;
[0144] An automated stress test report is generated based on the target number of stress tests, the communication stop status, and the communication recovery status.
[0145] Based on the characteristic values of the communication status messages output in the test report, communication anomalies and faults can be located.
[0146] The execution module 30 is also used to obtain the network segment packet feature value and the number of network segment packets. The network segment packet feature value includes the network segment packet feature value before being muted, the network segment packet feature value after being muted, and the network segment packet feature value after being unmuted. The number of network segment packets includes the number of network segment packets before being muted, the number of network segment packets after being muted, and the number of network segment packets after being unmuted.
[0147] The network segment communication status is determined and a test report is obtained based on the network segment message characteristic values before the mute, the network segment message characteristic values after the mute, the network segment message characteristic values after the mute is lifted, the number of network segment messages before the mute, the number of network segment messages after the mute, and the number of network segment messages after the mute is lifted.
[0148] The execution module 30 is further configured to compare the number of network segment packets before the mute and the number of network segment packets after the mute to determine the communication status of the first network segment;
[0149] The communication status of the second network segment is determined by comparing the characteristic values of the network segment messages before the mute is lifted with the characteristic values of the network segment messages after the mute is lifted.
[0150] The network segment communication status is determined based on the first network segment communication status, and a test report is obtained based on the network segment communication status.
[0151] The communication test and location device based on real-vehicle diagnostic services provided in this application, employing the communication test and location method based on real-vehicle diagnostic services in the above embodiments, can solve the technical problem of how to more accurately and efficiently test and locate communication anomalies. Compared with the prior art, the beneficial effects of the communication test and location device based on real-vehicle diagnostic services provided in this application are the same as those of the communication test and location method based on real-vehicle diagnostic services provided in the above embodiments, and other technical features in the communication test and location device based on real-vehicle diagnostic services are the same as those disclosed in the methods of the above embodiments, and will not be repeated here.
[0152] This application provides a communication test and positioning device based on real vehicle diagnostic services. The communication test and positioning device based on real vehicle diagnostic services includes: at least one processor; and a memory communicatively connected to at least one processor; wherein the memory stores instructions executable by at least one processor, and the instructions are executed by at least one processor to enable at least one processor to execute the communication test and positioning method based on real vehicle diagnostic services in the above embodiment 1.
[0153] The following is for reference. Figure 5 This document illustrates a structural schematic diagram of a communication test and positioning device suitable for implementing vehicle diagnostic services in the embodiments of this application. The communication test and positioning device based on vehicle diagnostic services in the embodiments of this application may include, but is not limited to, mobile terminals such as mobile phones, laptops, digital radio receivers, PDAs (Personal Digital Assistants), PADs (Portable Application Description), PMPs (Portable Media Players), in-vehicle terminals (e.g., in-vehicle navigation terminals), and fixed terminals such as digital TVs and desktop computers. Figure 5 The communication test positioning device based on real vehicle diagnostic services shown is merely an example and should not impose any limitations on the functionality and scope of use of the embodiments of this application.
[0154] like Figure 5As shown, the communication test and positioning device based on vehicle diagnostic services may include a processing unit 1001 (e.g., a central processing unit, a graphics processor, etc.), which can perform various appropriate actions and processes according to a program stored in read-only memory (ROM) 1002 or a program loaded from storage device 1003 into random access memory (RAM) 1004. The RAM 1004 also stores various programs and data required for the operation of the communication test and positioning device based on vehicle diagnostic services. The processing unit 1001, ROM 1002, and RAM 1004 are interconnected via a bus 1005. An input / output (I / O) interface 1006 is also connected to the bus. Typically, the following systems can be connected to I / O interface 1006: input devices 1007 including, for example, touchscreens, touchpads, keyboards, mice, image sensors, microphones, accelerometers, gyroscopes, etc.; output devices 1008 including, for example, liquid crystal displays (LCDs), speakers, vibrators, etc.; storage devices 1003 including, for example, magnetic tapes, hard disks, etc.; and communication devices 1009. Communication device 1009 allows the communication test and positioning equipment based on vehicle diagnostic services to exchange data wirelessly or via wired communication with other devices. Although the figure shows a communication test and positioning equipment based on vehicle diagnostic services with various systems, it should be understood that it is not required to implement or possess all the systems shown. More or fewer systems can be implemented alternatively.
[0155] Specifically, according to the embodiments disclosed in this application, the processes described above with reference to the flowcharts can be implemented as computer software programs. For example, embodiments disclosed in this application include a computer program product comprising a computer program carried on a computer-readable medium, the computer program containing program code for performing the methods shown in the flowcharts. In such embodiments, the computer program can be downloaded and installed from a network via a communication device, or installed from storage device 1003, or installed from ROM 1002. When the computer program is executed by processing device 1001, it performs the functions defined in the methods of the embodiments disclosed in this application.
[0156] The communication test and positioning device based on real-vehicle diagnostic services provided in this application, employing the communication test and positioning method based on real-vehicle diagnostic services in the above embodiments, can solve the technical problem of how to more accurately and efficiently test and locate communication anomalies. Compared with the prior art, the beneficial effects of the communication test and positioning device based on real-vehicle diagnostic services provided in this application are the same as those of the communication test and positioning method based on real-vehicle diagnostic services provided in the above embodiments, and other technical features in this communication test and positioning device based on real-vehicle diagnostic services are the same as those disclosed in the method of the previous embodiment, and will not be repeated here.
[0157] It should be understood that the various parts disclosed in this application can be implemented using hardware, software, firmware, or a combination thereof. In the description of the above embodiments, specific features, structures, materials, or characteristics can be combined in any suitable manner in one or more embodiments or examples.
[0158] The above description is merely a specific embodiment of this application, but the scope of protection of this application is not limited thereto. Any variations or substitutions that can be easily conceived by those skilled in the art within the scope of the technology disclosed in this application should be included within the scope of protection of this application. Therefore, the scope of protection of this application should be determined by the scope of the claims.
[0159] This application provides a computer-readable storage medium having computer-readable program instructions (i.e., a computer program) stored thereon, the computer-readable program instructions being used to execute the communication test positioning method based on real vehicle diagnostic services in the above embodiments.
[0160] The computer-readable storage medium provided in this application may be, for example, a USB flash drive, but is not limited to, electrical, magnetic, optical, electromagnetic, infrared, or semiconductor systems, devices, or any combination thereof. More specific examples of computer-readable storage media may include, but are not limited to: electrical connections having one or more wires, portable computer disks, hard disks, random access memory (RAM), read-only memory (ROM), erasable programmable read-only memory (EPROM or flash memory), optical fiber, portable compact disk read-only memory (CD-ROM), optical storage devices, magnetic storage devices, or any suitable combination thereof. In this embodiment, the computer-readable storage medium may be any tangible medium containing or storing a program that can be used by or in conjunction with an instruction execution system, system, or device. The program code contained on the computer-readable storage medium may be transmitted using any suitable medium, including but not limited to: wires, optical cables, RF (Radio Frequency), etc., or any suitable combination thereof.
[0161] The aforementioned computer-readable storage medium may be included in the communication test and positioning equipment based on the vehicle diagnostic service; or it may exist independently and not be assembled into the communication test and positioning equipment based on the vehicle diagnostic service.
[0162] The aforementioned computer-readable storage medium carries one or more programs. When these programs are executed by a communication test and location device based on vehicle diagnostic services, the communication test and location device based on vehicle diagnostic services: monitors the communication behavior of each network segment of the vehicle, determines communication diagnostic commands and communication diagnostic dwell times; determines communication stop status and communication recovery status based on the communication diagnostic commands and the communication diagnostic dwell times; performs automated stress testing based on the communication stop status and the communication recovery status to determine a test report, and outputs communication status message feature values based on the test report to locate communication anomalies.
[0163] Computer program code for performing the operations of this application can be written in one or more programming languages or a combination thereof, including object-oriented programming languages such as Java, Smalltalk, and C++, and conventional procedural programming languages such as the "C" language or similar programming languages. The program code can be executed entirely on the user's computer, partially on the user's computer, as a standalone software package, partially on the user's computer and partially on a remote computer, or entirely on a remote computer or server. In cases involving remote computers, the remote computer can be connected to the user's computer via any type of network—including a Local Area Network (LAN) or a Wide Area Network (WAN)—or can be connected to an external computer (e.g., via the Internet using an Internet service provider).
[0164] The flowcharts and block diagrams in the accompanying drawings illustrate the architecture, functionality, and operation of possible implementations of systems, methods, and computer program products according to various embodiments of this application. In this regard, each block in a flowchart or block diagram may represent a module, segment, or portion of code containing one or more executable instructions for implementing a specified logical function. It should also be noted that in some alternative implementations, the functions indicated in the blocks may occur in a different order than those indicated in the drawings. For example, two consecutively indicated blocks may actually be executed substantially in parallel, and they may sometimes be executed in reverse order, depending on the functions involved. It should also be noted that each block in the block diagrams and / or flowcharts, and combinations of blocks in the block diagrams and / or flowcharts, can be implemented using a dedicated hardware-based system that performs the specified function or operation, or using a combination of dedicated hardware and computer instructions.
[0165] The modules described in the embodiments of this application can be implemented in software or hardware. The names of the modules do not necessarily limit the functionality of the unit itself.
[0166] The readable storage medium provided in this application is a computer-readable storage medium that stores computer-readable program instructions (i.e., a computer program) for executing the above-described communication test and location method based on real-vehicle diagnostic services. This solves the technical problem of how to more accurately and efficiently test and locate communication anomalies. Compared with the prior art, the beneficial effects of the computer-readable storage medium provided in this application are the same as those of the communication test and location method based on real-vehicle diagnostic services provided in the above embodiments, and will not be repeated here.
[0167] The above description is only a part of the embodiments of this application and does not limit the patent scope of this application. All equivalent structural transformations made under the technical concept of this application and using the contents of the specification and drawings of this application, or direct / indirect applications in other related technical fields, are included in the patent protection scope of this application.
Claims
1. A communication test positioning method based on real vehicle diagnostic services, characterized in that, The method includes: Monitor the communication behavior of each network segment of the actual vehicle to determine the communication diagnostic commands and communication diagnostic dwell time; The communication stop status and communication recovery status are determined based on the communication diagnostic command and the communication diagnostic dwell time. Based on the communication stop state and the communication recovery state, an automated stress test is performed to determine the test report, and based on the test report, the communication status message feature values are output to locate communication anomalies. The steps for monitoring the communication behavior of each network segment of the real vehicle and determining the communication diagnostic commands and communication diagnostic dwell time include: Define diagnostic commands, online handshake commands, diagnostic service commands, switch default session mode diagnostic commands, extend session response dwell time and communication stop duration; The communication diagnostic command is determined based on the diagnostic service command and the diagnostic command to switch the default session mode. The communication diagnostic dwell time is determined based on the extended session response dwell time and the communication stop duration.
2. The method as described in claim 1, characterized in that, The steps for determining the communication stop status and communication recovery status based on the communication diagnostic command and the communication diagnostic dwell time include: Based on the diagnostic service command in the communication diagnostic command and the extended session response dwell time in the communication diagnostic dwell time, the system controls the vehicle to turn off the vehicle recording function, and obtains the dwell time of the function shutdown and the mute command; Based on the dwell time of the shutdown function, the mute command, the dwell time of the communication diagnosis, and the communication diagnosis command, the network segment communication status is determined to obtain the communication stop status and the communication recovery status.
3. The method as described in claim 2, characterized in that, The steps for determining the network segment communication status and obtaining the communication stop status and communication recovery status based on the dwell time of the shutdown function, the mute command, the dwell time of the communication diagnosis, and the communication diagnosis command include: Based on the dwell time of the shutdown function and the mute command, the vehicle is controlled to stop communication to determine the communication stop status; Based on the communication stop duration in the communication diagnostic dwell time and the switch default session mode diagnostic command in the communication diagnostic command, the vehicle is controlled to restore communication and determine the communication recovery status.
4. The method as described in claim 1, characterized in that, The steps of performing automated stress testing based on the communication stop state and the communication recovery state to determine a test report, and outputting communication status message feature values based on the test report to locate communication anomalies include: Obtain the target number of load tests; An automated stress test report is generated based on the target number of stress tests, the communication stop status, and the communication recovery status. Based on the characteristic values of the communication status messages output in the test report, communication anomalies and faults can be located.
5. The method as described in claim 4, characterized in that, The steps for determining the test report through automated stress testing based on the target number of stress tests, the communication stop status, and the communication recovery status include: Obtain the network segment packet characteristic value and the network segment packet count. The network segment packet characteristic value includes the network segment packet characteristic value before being muted, the network segment packet characteristic value after being muted, and the network segment packet characteristic value after being unmuted. The network segment packet count includes the network segment packet count before being muted, the network segment packet count after being muted, and the network segment packet count after being unmuted. The network segment communication status is determined and a test report is obtained based on the network segment message characteristic values before the mute, the network segment message characteristic values after the mute, the network segment message characteristic values after the mute is lifted, the number of network segment messages before the mute, the number of network segment messages after the mute, and the number of network segment messages after the mute is lifted.
6. The method as described in claim 5, characterized in that, The steps for determining the network segment communication status and obtaining the test report based on the network segment message characteristic values before the mute, the network segment message characteristic values after the mute, the network segment message characteristic values after the mute is lifted, the number of network segment messages before the mute, the number of network segment messages after the mute is lifted, and the number of network segment messages after the mute is lifted include: The communication status of the first network segment is determined by comparing the number of network segment packets before and after the mute. The communication status of the second network segment is determined by comparing the characteristic values of the network segment messages before the mute is lifted with the characteristic values of the network segment messages after the mute is lifted. The network segment communication status is determined based on the first network segment communication status, and a test report is obtained based on the network segment communication status.
7. A communication test positioning device based on real vehicle diagnostic services, characterized in that, The device includes: The determination module is used to monitor the communication behavior of each network segment of the actual vehicle and determine the communication diagnostic commands and communication diagnostic dwell time. The processing module is used to determine the communication stop status and the communication recovery status based on the communication diagnostic command and the communication diagnostic dwell time; The execution module is used to perform automated stress testing based on the communication stop state and the communication recovery state to determine a test report, and to output communication status message feature values based on the test report to locate communication abnormal faults; The determining module is also used to determine diagnostic commands, online handshake commands, diagnostic service commands, diagnostic commands for switching default session modes, extended session response dwell time, and communication stop duration; The communication diagnostic command is determined based on the diagnostic service command and the diagnostic command to switch the default session mode. The communication diagnostic dwell time is determined based on the extended session response dwell time and the communication stop duration.
8. A communication test and positioning device based on real-vehicle diagnostic services, characterized in that, The device includes: a memory, a processor, and a computer program stored in the memory and executable on the processor, the computer program being configured to implement the steps of the communication test positioning method based on real vehicle diagnostic services as described in any one of claims 1 to 6.
9. A storage medium, characterized in that, The storage medium is a computer-readable storage medium, and a computer program is stored on the storage medium. When the computer program is executed by a processor, it implements the steps of the communication test and positioning method based on real vehicle diagnostic services as described in any one of claims 1 to 6.
Citation Information
Patent Citations
Whole vehicle CAN network test method and system, electronic equipment and storage medium
CN115314428A
Method, device and equipment for testing vehicle ECU diagnosis based on CAPL and storage medium
CN116088462A