Whole vehicle CAN network interference and data detection method, device and equipment
By collecting and preprocessing the message data of the entire vehicle CAN network, filling in missing data, and detecting based on the interference mode, the problems of low detection efficiency and low accuracy in the prior art are solved, and more efficient and reliable CAN network interference detection is achieved.
Patent Information
- Application Number
- CN202411670175.3
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-11-21
- Publication Date
- 2025-03-07
AI Technical Summary
The existing CAN network interference and data detection methods are inefficient and are susceptible to subjective factors, resulting in low accuracy of detection results.
By collecting message data from the entire vehicle CAN network, preprocessing and data filling, a complete message data set is generated. Then, the message data is interfered with based on the determined interference mode, and the standard message data in the database file is used for dual-channel calculations, data differences are detected, and a detection report is generated.
It improves the accuracy and efficiency of vehicle CAN network interference and data detection, and ensures the reliability and integrity of detection results.
Smart Images

Figure CN119583403A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of network detection technology, and in particular to a vehicle CAN network interference and data detection method, device and equipment. Background Art
[0002] As an efficient serial communication protocol, the CAN network can realize data exchange and collaborative work between various electronic control units (ECUs) inside the car, ensuring that the various functions of the vehicle can operate stably and reliably. In actual application scenarios, the vehicle CAN network faces many challenges. Due to the complexity of the vehicle operating environment, the CAN network may be affected by various external interference factors. For example, electromagnetic interference, power supply fluctuations, electrostatic discharge, etc. may cause errors or instability in data transmission in the CAN network. These interferences will not only affect the performance and safety of the vehicle, but may also cause difficulties and misjudgments in fault diagnosis.
[0003] The existing CAN network interference and data detection methods mainly use manual detection or simple tool-assisted detection. The amount of vehicle CAN network data is huge and complex. Manual detection is not only inefficient, but also easily affected by the subjective factors of the tester, resulting in low accuracy of the test results. Summary of the invention
[0004] The present invention provides a whole vehicle CAN network interference and data detection method, device and equipment to improve the accuracy and efficiency of whole vehicle CAN network interference and data detection.
[0005] In order to solve the above technical problems, an embodiment of the present invention provides a vehicle CAN network interference and data detection method, comprising:
[0006] Collecting message data of the vehicle CAN network, and preprocessing the message data to generate a first message data set;
[0007] Comparing the first message data set with a database file, and filling the first message data set with data based on the comparison result to generate a second message data set;
[0008] Determine an interference pattern, interfere with the message data in the second message data set based on the interference pattern, and obtain an interference result;
[0009] Based on the interference result and the database file, the interfered message is detected, the detection result is obtained, and a detection report is generated.
[0010] The present invention collects message data of the whole vehicle CAN network, compares it with the database file and fills in the data, thereby compensating for missing data and improving the integrity and reliability of the data set; the message data is automatically interfered with based on the interference mode, and dual-channel calculation is performed through the standard message data in the database file and the interfered message data, thereby comparing the data differences, so as to improve the accuracy and efficiency of interference detection of the whole vehicle CAN network.
[0011] Furthermore, before collecting the message data of the vehicle CAN network, it also includes:
[0012] Obtain the database file of the vehicle CAN network, wherein the database file includes CAN message ID, message DLC, message cycle, message source network segment, message target network segment, message cycle count signal start bit, message cycle count signal length, message checksum signal start bit, and message checksum signal length.
[0013] Further, the collecting of message data of the vehicle CAN network and preprocessing of the message data to generate a first message data set includes:
[0014] Collecting message data of each network segment in the vehicle CAN network, wherein the message data includes a message ID;
[0015] Perform ID deduplication processing on the message data to generate first message data.
[0016] Further, the comparing the first message data set with the database file and filling the first message data set with data based on the comparison result to generate the second message data set includes:
[0017] Compare the first message data set with all message IDs in the database file to obtain a comparison result;
[0018] If there is a missing message ID in the first message data set in the comparison result, data filling is performed on the first message data set.
[0019] Further, the filling the first message data set with data includes:
[0020] A whole vehicle simulation is performed on the whole vehicle CAN network to obtain filler message data of the missing message ID, and the filler message data is added to the first message data set.
[0021] Further, the filling the first message data set with data includes:
[0022] Based on the vehicle event triggering mechanism, fill-in message data of the missing message ID is obtained, and the fill-in message data is added to the first message data set.
[0023] Further, the determining the interference pattern, interfering with the message data in the second message data set based on the interference pattern, and obtaining the interference result includes:
[0024] Determine an interference mode, wherein the interference mode includes a sequential interference mode, a specified interference mode, and a network segment interference mode;
[0025] The message data in the second message data set is interfered with based on the interference pattern, an interference result is obtained, and the interference data is recorded.
[0026] Further, the detecting the interfered message based on the interference result and the database file, obtaining the detection result, and generating a detection report includes:
[0027] Based on the interference result, the recovery performance of the interfered message, the recovery performance of the interfered network segment, the performance of the interfered message, the performance of the interfered network segment and the fault code are detected to obtain the detection result;
[0028] Based on the comparison between the detection result and the database file, abnormal data is screened out, and a detection report is generated based on the abnormal data and the interference data.
[0029] In a second aspect, the present invention provides a vehicle CAN network interference and data detection device, including: a collection module, a filling module, an interference module and a monitoring module;
[0030] The acquisition module is used to collect message data of the vehicle CAN network and pre-process the message data to generate a first message data set;
[0031] The filling module is used to compare the first message data set with the database file, and fill the first message data set with data based on the comparison result to generate a second message data set;
[0032] The interference module is used to determine an interference pattern, interfere with the message data in the second message data set based on the interference pattern, and obtain an interference result;
[0033] The monitoring module is used to detect the interfered message based on the interference result and the database file, obtain the detection result, and generate a detection report.
[0034] In a third aspect, the present invention further provides a terminal device, comprising a processor, a memory, and a computer program stored in the memory and configured to be executed by the processor, wherein when the processor executes the computer program, the vehicle CAN network interference and data detection method as described above is implemented. BRIEF DESCRIPTION OF THE DRAWINGS
[0035] Figure 1A flow chart of a vehicle CAN network interference and data detection method provided by an embodiment of the present invention;
[0036] Figure 2 Another flow chart of a vehicle CAN network interference and data detection method provided in an embodiment of the present invention. DETAILED DESCRIPTION
[0037] The specific implementation of the present invention is further described in detail below in conjunction with the accompanying drawings and examples. The following examples are used to illustrate the present invention, but are not intended to limit the scope of the present invention.
[0038] The terms "first" and "second" and the like in the specification, claims and drawings of this application are used to distinguish different objects, rather than to describe a specific order. 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 comprising a series of steps or units is not limited to the listed steps or units, but may optionally include steps or units not listed, or may optionally include other steps or units inherent to these processes, methods, products or devices.
[0039] Reference to "embodiments" herein means that a particular feature, structure, or characteristic described in conjunction with the embodiments may be included in at least one embodiment of the present application. The appearance of the phrase in various locations in the specification does not necessarily refer to the same embodiment, nor is it an independent or alternative embodiment that is mutually exclusive with other embodiments. It is explicitly and implicitly understood by those skilled in the art that the embodiments described herein may be combined with other embodiments.
[0040] Example 1
[0041] See also Figure 1 , Figure 1 The present invention provides a flow chart of a vehicle CAN network interference and data detection method. The present invention provides a vehicle CAN network interference and data detection method, including steps 101 to 104, which are as follows:
[0042] Step 101: collecting message data of the vehicle CAN network, and preprocessing the message data to generate a first message data set;
[0043] In this embodiment, before collecting the message data of the vehicle CAN network, it also includes:
[0044] Obtain the database file of the vehicle CAN network, wherein the database file includes CAN message ID, message DLC, message cycle, message source network segment, message target network segment, message cycle count signal start bit, message cycle count signal length, message checksum signal start bit, and message checksum signal length.
[0045] In this embodiment, a database file of the vehicle CAN network is uploaded based on a preset file format, where the file format is set to a .CSV file: the file definition content includes CAN message ID, message DLC, message cycle, message source network segment, message target network segment, message cycle count signal start bit, message cycle count signal length, message checksum signal start bit, and message checksum signal length.
[0046] In this embodiment, a reference data set is established through a database file, which includes CAN message data under normal working conditions for subsequent comparison and detection. Through the reference data set, abnormal or missing message data can be accurately identified to ensure the accuracy of subsequent detection. At the same time, the establishment of the reference data set provides a quick reference for subsequent data comparison and detection, reducing the time for repeated data processing.
[0047] In this embodiment, the collecting of message data of the vehicle CAN network and preprocessing of the message data to generate a first message data set includes:
[0048] Collecting message data of each network segment in the vehicle CAN network, wherein the message data includes a message ID;
[0049] Perform ID deduplication processing on the message data to generate first message data.
[0050] In this embodiment, the message data of the vehicle CAN network is collected in real time, and preliminary preprocessing is performed to generate a first message data set. Through ID deduplication processing, duplicate data is eliminated to ensure the accuracy of the data set.
[0051] In this embodiment, the time and errors of manual operation are reduced by automating the data collection and preprocessing process.
[0052] Step 102: Comparing the first message data set with a database file, and filling the first message data set with data based on the comparison result to generate a second message data set;
[0053] In this embodiment, the step of comparing the first message data set with a database file and filling the first message data set with data based on the comparison result to generate a second message data set includes:
[0054] Compare the first message data set with all message IDs in the database file to obtain a comparison result;
[0055] If there is a missing message ID in the first message data set in the comparison result, data filling is performed on the first message data set.
[0056] In this embodiment, the message ID in the first message data set is compared with the message ID in the database file to determine whether the first message data set obtained by collecting the entire vehicle CAN network lacks a message ID; if the first message data set is missing a message ID compared to the database file, the first message data set is filled with data.
[0057] In this embodiment, data filling includes simulation filling and event-triggered filling.
[0058] In this embodiment, the step of filling the first message data set with data includes:
[0059] A whole vehicle simulation is performed on the whole vehicle CAN network to obtain filler message data of the missing message ID, and the filler message data is added to the first message data set.
[0060] In this embodiment, a whole vehicle simulation is performed on the whole vehicle CAN network, wherein the simulation message data information is obtained based on a database file.
[0061] In this embodiment, the step of filling the first message data set with data includes:
[0062] Based on the vehicle event triggering mechanism, fill-in message data of the missing message ID is obtained, and the fill-in message data is added to the first message data set.
[0063] When filling data based on the event trigger mechanism, the message data is supplemented by triggering the whole vehicle event. Since some message data may need to receive the actual trigger action before sending the message information, the complete CAN network data can be supplemented by manually operating the vehicle switch or other operations.
[0064] In this embodiment, missing or abnormal message data is identified through data comparison, and the missing data is filled through simulation or vehicle event triggering mechanism to ensure the integrity of the data set. The automated data comparison and filling process reduces the time and cost of manual intervention.
[0065] Step 103: determining an interference pattern, interfering with the message data in the second message data set based on the interference pattern, and obtaining an interference result;
[0066] In this embodiment, the determining the interference pattern, interfering with the message data in the second message data set based on the interference pattern, and obtaining the interference result includes:
[0067] Determine an interference mode, wherein the interference mode includes a sequential interference mode, a specified interference mode, and a network segment interference mode;
[0068] The message data in the second message data set is interfered with based on the interference pattern, an interference result is obtained, and the interference data is recorded.
[0069] In this embodiment, the interference mode includes a sequential interference mode, a specified interference mode and a network segment interference mode. By confirming the interference mode, the message data in the second message data set is interfered based on the interference mode.
[0070] In this embodiment, when the interference mode is the sequential interference mode, all message IDs in the vehicle CAN network are interfered in sequence, so that they appear as error frame types in the network. When the interference mode is the specified interference mode, one or more message IDs for specified interference are input, and the specified message IDs are interfered. When the interference mode is the network segment interference mode, all message IDs of a certain network segment are interfered in sequence.
[0071] In this embodiment, a VH6501 device is used to interfere with a specific message or all CAN messages in a certain network segment.
[0072] In this embodiment, after interference is applied to a message or a network segment, error frames are read back by testing software to see if there are any, and the number of error frames read back is compared with the number of interference applied to determine whether the interference is applied successfully.
[0073] In this embodiment, in the process of applying interference to a message or network segment, the interference trigger bit of the VH6501 device is programmed to be set from IDBase (ID identifier) to AckDe l imiter (answer delimiter) in sequence. When the interference is successfully applied, the interference result is obtained and the interference data is recorded. The interference data includes the interference network segment or the interference message.
[0074] In this embodiment, the actual interference environment is simulated to obtain real interference data, thereby ensuring the accuracy of detection, and the interference simulation process is automated to quickly obtain interference results and shorten the detection time.
[0075] Step 104: Detect the interfered message based on the interference result and the database file, obtain the detection result, and generate a detection report.
[0076] In this embodiment, the detecting the interfered message based on the interference result and the database file, obtaining the detection result, and generating a detection report includes:
[0077] Based on the interference result, the recovery performance of the interfered message, the recovery performance of the interfered network segment, the performance of the interfered message, the performance of the interfered network segment and the fault code are detected to obtain the detection result;
[0078] Based on the comparison between the detection result and the database file, abnormal data is screened out, and a detection report is generated based on the abnormal data and the interference data.
[0079] In this embodiment, after the interference is successfully applied, the recovery performance of the interfered message, the recovery performance of the interfered network segment, the performance of the interfered message, the performance of the interfered network segment and the fault code are detected to obtain the detection results, which include the recovery time of the interfered message or network segment, the ID of the non-interference message during the interference period, the DLC, the source network segment, the target network segment, the period, the message cycle count signal, and the message checksum signal.
[0080] In this embodiment, the detection result is compared with the standard message data content in the benchmark data set defined based on the database file to obtain data differences, and abnormal data is screened out based on the data differences.
[0081] In this embodiment, the interference mode also includes a non-interference mode. In the non-interference mode, there is no need to interfere with the message or network segment. The ID, DLC, source network segment, target network segment, cycle, message cycle count signal, and message checksum signal of the message during normal operation of the vehicle are obtained and compared with the standard message data content in the benchmark data set defined based on the database file to obtain data differences, and abnormal data is filtered out based on the data difference.
[0082] In this embodiment, the fault codes of the vehicle CAN network are read, the fault codes generated by the test are recorded, and the fault codes, interference data and abnormal data are recorded in the report to generate a retrieval report in a txt file / word file.
[0083] In this embodiment, by comparing the interference results with the database files, abnormal data and fault codes are accurately identified, the detection process is automated and the detection report is quickly generated, thereby improving the detection efficiency.
[0084] In this embodiment, the present invention collects message data of the whole vehicle CAN network, compares it with the database file and fills in the data, thereby compensating for missing data and improving the integrity and reliability of the data set; the message data is automatically interfered with based on the interference mode, and dual-channel calculation is performed through the standard message data in the database file and the interfered message data, thereby comparing the data differences to complete the interference detection of the whole vehicle CAN network.
[0085] Please refer to Figure 2 , Figure 2Another flow chart of a vehicle CAN network interference and data detection method provided in an embodiment of the present invention includes steps 1 to 16.
[0086] Step 1: The database file selected and uploaded by the user is a .CSV file: the file definition content includes CAN message ID, message DLC, message cycle, message source network segment, message target network segment, message cycle count signal start bit, message cycle count signal length, message checksum signal start bit, message checksum signal length;
[0087] Step 2: The vehicle message data collection content is mainly the message ID of all network segments of the vehicle CAN network; pre-processing includes ID deduplication;
[0088] Step 3: Compare the preprocessing result of step 2 with the database message ID in step 1 to determine whether the vehicle CAN network lacks a message ID; if the vehicle CAN message is missing from the database, supplement the data and go to step 4; if not, go to step 7;
[0089] Step 4: Determine whether to supplement the message data through simulation; if yes, go to step 5; if no, go to step 6
[0090] Step 5: The simulation message data information comes from the database file in step 1, and then proceed to step 7;
[0091] Step 6: Manually trigger the vehicle event to supplement the message data. Since some message data may need to receive the actual trigger action before sending the message information, the complete CAN network data can be supplemented by manually operating the vehicle switch or other operations, and then go to step 7;
[0092] Step 7: The user selects whether interference is required to verify the vehicle CAN network performance during this test; if yes, proceed to step 8; if no, proceed to step 15;
[0093] Step 8: Determine whether to interfere with all message IDs in the vehicle CAN network in turn so that they appear as error frame types in the network. If yes, proceed to step 12; if no, proceed to step 9;
[0094] Step 9: Determine whether to interfere with one or more specific message IDs, which are input by the user from the test system host computer; if yes, proceed to step 11, if not, proceed to step 10;
[0095] Step 10: Enter the specified network segment to interfere with. In this mode, set the VH6501 device to interfere with all message IDs of a certain network segment in turn, and then go to step 12;
[0096] Decision 11: Enter the message ID of the specified interference and go to step 12;
[0097] Step 12: Interfere with the message or network segment;
[0098] Step 13: Read back whether there are error frames through the test software, and compare the number of error frames read back with the number of interference applied in step 12 to determine whether the interference is successfully applied. If yes, proceed to step 15; if not, proceed to step 14;
[0099] Step 14: Program the VH6501 device interference trigger bits from IDBase (ID identifier) to AckDel imiter (answer delimiter) in sequence. If the interference is successfully applied during this period, the next step of data detection is performed;
[0100] Step 15: ① If interference test is selected in step 7, the data detection content includes the recovery time of the interfered message or network segment, the ID, DLC, source network segment, target network segment, cycle, message cycle count signal, and message checksum signal of the non-interference message during the interference period; ① If no interference test is selected in step 7, the data detection content is the ID, DLC, source network segment, target network segment, cycle, message cycle count signal, and message checksum signal of the message during normal operation of the whole vehicle; the data difference is obtained by comparing the detected message data content with the standard message data content defined in the database of step 1; at the end of the test, the fault code is read by automatically sending a diagnostic instruction, and the fault code generated by the test is recorded.
[0101] Step 16: Generate a test report in txt file / word file, and the vehicle CAN network automatic interference and data detection algorithm process is completed.
[0102] In this embodiment, the definition of the CAN network message in the database file in step 1 is used to calculate the ID, DLC, source network segment, target network segment, cycle, message cycle count signal, and message checksum signal of each frame of the correct message in real time, and compare and analyze the CAN network message collected in the vehicle. Thus, dual-channel calculation is performed through the standard message data in the database file and the interfered message data, so as to compare the data difference, so as to improve the accuracy and efficiency of the interference detection of the vehicle CAN network.
[0103] The embodiment of the present invention also provides a vehicle CAN network interference and data detection device, including: a collection module, a filling module, an interference module and a monitoring module;
[0104] The acquisition module is used to collect message data of the vehicle CAN network and pre-process the message data to generate a first message data set;
[0105] The filling module is used to compare the first message data set with the database file, and fill the first message data set with data based on the comparison result to generate a second message data set;
[0106] The interference module is used to determine an interference pattern, interfere with the message data in the second message data set based on the interference pattern, and obtain an interference result;
[0107] The monitoring module is used to detect the interfered message based on the interference result and the database file, obtain the detection result, and generate a detection report.
[0108] In this embodiment, a database module is also included, which is used to:
[0109] Obtain the database file of the vehicle CAN network, wherein the database file includes CAN message ID, message DLC, message cycle, message source network segment, message target network segment, message cycle count signal start bit, message cycle count signal length, message checksum signal start bit, and message checksum signal length.
[0110] In this embodiment, the acquisition module is used to:
[0111] Collecting message data of each network segment in the vehicle CAN network, wherein the message data includes a message ID;
[0112] Perform ID deduplication processing on the message data to generate first message data.
[0113] In this embodiment, the filling module is used to:
[0114] Compare the first message data set with all message IDs in the database file to obtain a comparison result;
[0115] If there is a missing message ID in the first message data set in the comparison result, data filling is performed on the first message data set.
[0116] In this embodiment, the filling module is used to:
[0117] A whole vehicle simulation is performed on the whole vehicle CAN network to obtain filler message data of the missing message ID, and the filler message data is added to the first message data set.
[0118] In this embodiment, the filling module is used to:
[0119] Based on the vehicle event triggering mechanism, fill-in message data of the missing message ID is obtained, and the fill-in message data is added to the first message data set.
[0120] In this embodiment, the interference module is used to:
[0121] Determine an interference mode, wherein the interference mode includes a sequential interference mode, a specified interference mode, and a network segment interference mode;
[0122] The message data in the second message data set is interfered with based on the interference pattern, an interference result is obtained, and the interference data is recorded.
[0123] In this embodiment, the interference module is used to:
[0124] Based on the interference result, the recovery performance of the interfered message, the recovery performance of the interfered network segment, the performance of the interfered message, the performance of the interfered network segment and the fault code are detected to obtain the detection result;
[0125] Based on the comparison between the detection result and the database file, abnormal data is screened out, and a detection report is generated based on the abnormal data and the interference data.
[0126] In an embodiment of the present invention, a terminal device is also provided, including a processor, a memory, and a computer program stored in the memory and configured to be executed by the processor. When the processor executes the computer program, the above-mentioned vehicle CAN network interference and data detection method is implemented.
[0127] In an embodiment of the present invention, a computer-readable storage medium is also provided, and the computer-readable storage medium includes a stored computer program, wherein when the computer program is running, the device where the computer-readable storage medium is located is controlled to execute the above-mentioned vehicle CAN network interference and data detection method.
[0128] Exemplarily, the computer program may be divided into one or more modules, one or more modules are stored in a memory and executed by a processor to implement the present invention. One or more modules may be a series of computer program instruction segments capable of implementing specific functions, and the instruction segments are used to describe the execution process of the computer program in a terminal device.
[0129] The terminal device may be a computing device such as a desktop computer, a notebook, a PDA, and a cloud server. The terminal device may include, but is not limited to, a processor, a memory, and a display. Those skilled in the art will appreciate that the above components are merely examples of the terminal device and do not constitute a limitation on the terminal device. The terminal device may include more or fewer components than the components, or may combine certain components, or different components. For example, the terminal device may also include input and output devices, network access devices, buses, etc.
[0130] The processor may be a central processing unit (CPU), other general-purpose processors, digital signal processors (DSP), application-specific integrated circuits (ASIC), field-programmable gate arrays (FPGA) or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. A general-purpose processor may be a microprocessor or any conventional processor, etc. The processor is the control center of the terminal device, and uses various interfaces and lines to connect various parts of the entire terminal device.
[0131] The memory can be used to store computer programs and / or modules. The processor realizes various functions of the terminal device by running or executing the computer programs and / or modules stored in the memory, and calling the data stored in the memory. The memory can mainly include a program storage area and a data storage area, wherein the program storage area can store an operating system, an application required for at least one function (such as a sound playback function, a text conversion function, etc.), etc.; the data storage area can store data created according to the use of the mobile phone (such as audio data, text message data, etc.), etc. In addition, the memory can include a high-speed random access memory, and can also include a non-volatile memory, such as a hard disk, a memory, a plug-in hard disk, a smart memory card (Smart Med i aCard, SMC), a secure digital (Secure Digital, SD) card, a flash card (Flash Card), at least one disk storage device, a flash memory device, or other volatile solid-state storage devices.
[0132] Among them, if the module based on the processing of the multi-device access platform is implemented in the form of a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on such an understanding, the present invention implements all or part of the processes in the above-mentioned embodiment method, and can also be completed by instructing the relevant hardware through a computer program. The computer program can be stored in a computer-readable storage medium, and the computer program can implement the steps of the above-mentioned various method embodiments when executed by the processor. Among them, the computer program includes computer program code, and the computer program code can be in source code form, object code form, executable file or some intermediate form. The computer-readable medium may include: any entity or device capable of carrying computer program code, recording medium, U disk, mobile hard disk, disk, optical disk, computer memory, read-only memory (ROM, Read-Only Memory), random access memory (RAM, RandomAccess Memory), electric carrier signal, telecommunication signal and software distribution medium, etc. Ordinary technicians in this field can understand and implement it without paying creative labor.
[0133] The specific embodiments described above further illustrate the purpose, technical solutions and beneficial effects of the present invention. It should be understood that the above description is only a specific embodiment of the present invention and is not intended to limit the scope of protection of the present invention. It is particularly pointed out that for those skilled in the art, any modification, equivalent replacement, improvement, etc. made within the spirit and principle of the present invention should be included in the scope of protection of the present invention.
Claims
1. A vehicle CAN network interference and data detection method, characterized in that: include: Collecting message data of the vehicle CAN network, and preprocessing the message data to generate a first message data set; Comparing the first message data set with a database file, and filling the first message data set with data based on the comparison result to generate a second message data set; Determine an interference pattern, interfere with the message data in the second message data set based on the interference pattern, and obtain an interference result; Based on the interference result and the database file, the interfered message is detected, the detection result is obtained, and a detection report is generated.
2. A vehicle CAN network interference and data detection method as claimed in claim 1, characterized in that: Before collecting the message data of the vehicle CAN network, it also includes: Obtain the database file of the vehicle CAN network, wherein the database file includes CAN message ID, message DLC, message cycle, message source network segment, message target network segment, message cycle count signal start bit, message cycle count signal length, message checksum signal start bit, and message checksum signal length.
3. A vehicle CAN network interference and data detection method as claimed in claim 2, characterized in that: The collecting of message data of the vehicle CAN network and preprocessing of the message data to generate a first message data set includes: Collecting message data of each network segment in the vehicle CAN network, wherein the message data includes a message ID; Perform ID deduplication processing on the message data to generate first message data.
4. A vehicle CAN network interference and data detection method as claimed in claim 3, characterized in that: The step of comparing the first message data set with a database file and filling the first message data set with data based on the comparison result to generate a second message data set includes: Compare the first message data set with all message IDs in the database file to obtain a comparison result; If there is a missing message ID in the first message data set in the comparison result, data filling is performed on the first message data set.
5. A vehicle CAN network interference and data detection method as claimed in claim 4, characterized in that: The step of filling the first message data set with data includes: A whole vehicle simulation is performed on the whole vehicle CAN network to obtain filler message data of the missing message ID, and the filler message data is added to the first message data set.
6. A vehicle CAN network interference and data detection method as claimed in claim 4, characterized in that: The step of filling the first message data set with data includes: Based on the vehicle event triggering mechanism, fill-in message data of the missing message ID is obtained, and the fill-in message data is added to the first message data set.
7. A vehicle CAN network interference and data detection method as claimed in claim 4, characterized in that: The determining the interference pattern, interfering with the message data in the second message data set based on the interference pattern, and obtaining the interference result includes: Determine an interference mode, wherein the interference mode includes a sequential interference mode, a specified interference mode, and a network segment interference mode; The message data in the second message data set is interfered with based on the interference pattern, an interference result is obtained, and the interference data is recorded.
8. A vehicle CAN network interference and data detection method as claimed in claim 7, characterized in that: The detecting the interfered message based on the interference result and the database file, obtaining the detection result, and generating a detection report includes: Based on the interference result, the recovery performance of the interfered message, the recovery performance of the interfered network segment, the performance of the interfered message, the performance of the interfered network segment and the fault code are detected to obtain the detection result; Based on the comparison between the detection result and the database file, abnormal data is screened out, and a detection report is generated based on the abnormal data and the interference data.
9. A vehicle CAN network interference and data detection device, characterized in that: include: Acquisition module, filling module, interference module and monitoring module; The acquisition module is used to collect message data of the vehicle CAN network and pre-process the message data to generate a first message data set; The filling module is used to compare the first message data set with the database file, and fill the first message data set with data based on the comparison result to generate a second message data set; The interference module is used to determine an interference pattern, interfere with the message data in the second message data set based on the interference pattern, and obtain an interference result; The monitoring module is used to detect the interfered message based on the interference result and the database file, obtain the detection result, and generate a detection report.
10. A terminal device, characterized in that: The invention comprises a processor, a memory and a computer program stored in the memory and configured to be executed by the processor. When the processor executes the computer program, a vehicle CAN network interference and data detection method as described in any one of claims 1 to 8 is implemented.