A vehicle fault diagnosis method

By designing SQL database files categorized by diagnostic functions, the problem of excessively large or numerous data packets in existing technologies is solved, achieving high efficiency and accuracy in automotive fault diagnosis.

CN116859877BActive Publication Date: 2026-04-24ANHUI AIFKA ELECTRONIC TECH CO LTD +1
View PDF 1 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
ANHUI AIFKA ELECTRONIC TECH CO LTD
Filing Date
2023-05-09
Publication Date
2026-04-24

AI Technical Summary

Technical Problem

In existing automotive fault diagnosis technologies, the simple or excessive classification of data packets leads to excessively large or numerous data packets, affecting the accuracy and speed of diagnosis and resulting in a poor user experience.

Method used

The data packet structure is designed using an SQL database file, categorized by diagnostic function, and the same parts of diagnostic instructions with the same function are extracted and stored in another data packet, thereby reducing the size and number of data packets.

Benefits of technology

It simplifies the data packet structure, reduces loading time, improves diagnostic efficiency, saves storage space, and enhances the accuracy and speed of diagnosis.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN116859877B_ABST
    Figure CN116859877B_ABST
Patent Text Reader

Abstract

The application discloses a vehicle fault diagnosis method and system, and belongs to the technical field of automobile fault diagnosis. In the application, a diagnosis instrument carries out data interaction with an on-board ECU in the form of sending data packets, and sequentially carries out the following operations on the vehicle: reading version information, reading fault codes, confirming fault code components and systems, reading data streams, judging specific problems according to sensor data and actuator states, and testing the vehicle to check occasions where different components and systems have the same data stream. The data packets include ecuinfo data packets, basicinfo data packets, paraminfo data packets, dtcinfo data packets and testinfo data packets, different data packets are classified according to functions, and each data packet has an engine item for distinguishing different diagnosis systems. The application classifies diagnosis functions instead of diagnosis systems, and extracts the same part in the diagnosis instructions of the same function and stores the same part in another data packet, so that the size of the data packet is reduced.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of automotive fault diagnosis technology, and in particular to a vehicle fault diagnosis method and system. Background Technology

[0002] Currently, automobiles have become an indispensable means of transportation for human travel. As automobile performance becomes more and more advanced, their internal structures also become more and more complex, thus placing increasingly higher demands on automobile fault diagnosis.

[0003] In existing technologies, diagnostic instruments are typically used to connect to the vehicle's internal bus. Various diagnostic software is designed to enable communication with the vehicle's ECU. Fault codes of the ECU module in the vehicle are read by sending data packets, and vehicle fault diagnosis is then performed based on the diagnostic instrument and related equipment.

[0004] However, in order to improve the accuracy and speed of diagnosis, various diagnostic software have proposed different data packet structures and packaging methods. This has led to the current data packet classification being too simple, resulting in each data packet being too large and taking too long to load; or the excessive classification resulting in too many data packets.

[0005] On the other hand, various diagnostic software typically uses CSV files, JSON files, SQL database files, and XML files to create the database for the diagnostic software. When creating the database file, it is usually classified according to the diagnostic system, and then the functions under the system are classified. When there are too many diagnostic systems, it also results in too many data packets.

[0006] The excessive size or number of data packets caused by the above factors can affect the accuracy and speed of vehicle fault diagnosis, and impair the user experience of vehicle diagnostic instruments. Summary of the Invention

[0007] 1. The technical problem that the invention aims to solve

[0008] In view of the shortcomings of the prior art, the present invention provides a vehicle fault diagnosis method and system. The present invention designs the data packet structure of the core of the vehicle fault diagnosis process, namely the diagnostic software, and adopts an SQL database file to take advantage of its flexibility and scalability. When designing the SQL database, it does not classify according to the diagnostic system, but according to the diagnostic function. Furthermore, the same part is extracted from the diagnostic instructions with the same function and stored in another data packet to reduce the size and number of data packets.

[0009] 2. Technical Solution

[0010] To achieve the above objectives, the technical solution provided by the present invention is as follows:

[0011] The present invention provides a vehicle fault diagnosis method, the steps of which are as follows:

[0012] Step 1: Connect the diagnostic tool to the vehicle's ECU;

[0013] Step 2: Open the diagnostic software of the diagnostic tool, enter the diagnostic page, select the corresponding vehicle model, and click Start Diagnosis. The diagnostic tool interacts with the vehicle's ECU by sending data packets, and sequentially performs the following operations: reading version information; reading fault codes to identify fault code components and systems; and reading data streams to determine the specific problem based on the data from various sensors and the status of actuators.

[0014] Step 3: Perform motion tests on the vehicle to identify instances where different components and systems have the same data flow;

[0015] Step 4: Repair the fault and clear the fault codes;

[0016] Step 5: Read the fault code again and observe whether the fault has been resolved; otherwise, repeat the operation.

[0017] Furthermore, in step 2, the data packets used by the diagnostic tool to exchange data with the vehicle ECU include ecuinfo, basicinfo, paraminfo, dtcinfo, and testinfo data packets. These data packets are categorized by function, and each data packet contains an "engine" item to distinguish different diagnostic systems.

[0018] Furthermore, the ecuinfo data packet is used to store initialization instructions, and the SID of the read version information and read data stream instructions is stored in the data packet; when entering the diagnostic system, the ecuinfo data packet is read, the corresponding instructions are found according to the engine item, and the initialization instructions for the lower-level machine and the ECU are sent.

[0019] Furthermore, the basicinfo data packet is used to store version-related instructions. Version information is retrieved by sequentially reading the ecuinfo data packet and the basicinfo data packet to form a complete command.

[0020] Furthermore, the SID of the read version information command sent by the diagnostic tool is stored in the basicinfo_command field of the ECUinfo data packet, and the PID of the read version information command is stored in the DID field of the basicinfo data packet. When the ECU responds positively, the diagnostic program calls the basicinfo data packet for analysis and uses the DID as an index to confirm the location.

[0021] Furthermore, the paraminfo data packet is used to store relevant instructions for reading the data stream. By reading the ecuinfo data packet and the paraminfo data packet in sequence, a complete command is formed to read the data stream.

[0022] Furthermore, the SID of the read data stream command sent by the diagnostic tool is stored in the getpara_command field of the ECUinfo data packet, and the PID of the read data stream command sent by the diagnostic tool is stored in the DID field of the paraminfo data packet. When the ECU responds positively, the diagnostic program calls the paraminfo data packet for analysis and uses the PID as an index to analyze the remaining items.

[0023] Furthermore, the fault code reading command is stored in the getdtc_command field of the ecuinfo data packet, and the code library is stored in the dtcinfo data packet.

[0024] Furthermore, the testinfo data packet is used to store action test instructions, including start and end instructions for the action test.

[0025] This invention discloses a vehicle fault diagnosis system, comprising a host computer diagnostic instrument, a slave computer system, and an on-board ECU. The slave computer system includes a wireless communication module, a slave MCU, a drive circuit, and an OBD communication module. The host computer diagnostic instrument connects to the slave computer system via the wireless communication module, and the OBD interface of the slave computer system connects to the on-board ECU via an OBD bus. The host computer diagnostic instrument interacts with the on-board ECU by sending data packets, sequentially performing operations such as reading version information, reading fault codes to identify fault code components and systems, and reading data streams to determine specific problems based on sensor data and actuator status.

[0026] 3. Beneficial effects

[0027] Compared with existing known technologies, the technical solution provided by this invention has the following significant advantages:

[0028] (1) In the process of creating the diagnostic software data package, the present invention adopts the SQL data package format. The SQL database file has the advantages of flexibility and scalability. Furthermore, it adopts a classification method based on diagnostic functions. The number of data packages is determined by the diagnostic functions. That is, it is classified according to initialization functions, reading version information, reading data streams, action tests, etc., which simplifies the data package structure. Moreover, when diagnosing a specific function of a particular vehicle model, it effectively avoids loading other diagnostic function data packages, effectively saves loading time, and improves diagnostic efficiency.

[0029] (2) In a diagnostic system, the present invention extracts the SID of the same part in the instructions for reading version information and reading data stream and stores it in a specific data packet. When performing fault diagnosis, only two data packets need to be called in sequence, that is, one diagnostic program. The SID of reading version information and reading data stream is stored only once, which greatly reduces the storage space occupied by the data packet.

[0030] (3) The present invention designs the smallest unit of reading data stream as bit operation, which reduces the operation of the previous character in the data packet and further reduces the space occupied by the data packet. Attached Figure Description

[0031] Figure 1 This is a schematic diagram of the vehicle fault diagnosis process in this invention.

[0032] Figure 2 This is a schematic diagram of the structure of a vehicle fault diagnosis system according to the present invention. Detailed Implementation

[0033] To further understand the content of this invention, a detailed description of the invention will be provided in conjunction with the accompanying drawings and embodiments.

[0034] Example 1

[0035] Combination Figure 1 The process of vehicle fault diagnosis in this embodiment is as follows:

[0036] Step 1: Connect the diagnostic tool to the vehicle's ECU;

[0037] Step 2: Open the diagnostic software of the diagnostic tool, enter the diagnostic page, select the corresponding vehicle model, and click Start Diagnosis. The diagnostic tool interacts with the vehicle's ECU by sending data packets, and sequentially performs the following operations: reading version information; reading fault codes to identify fault code components and systems; and reading data streams to determine the specific problem based on the data from various sensors and the status of actuators.

[0038] Step 3: Perform motion tests on the vehicle to identify instances where different components and systems have the same data flow;

[0039] Step 4: Repair the fault and clear the fault codes;

[0040] Step 5: Read the fault code again and observe whether the fault has been resolved; otherwise, repeat the operation.

[0041] This embodiment designs data packets for data interaction between the diagnostic tool and the vehicle ECU, including ecuinfo, basicinfo, paraminfo, dtcinfo, and testinfo data packets. Because the data packets in this embodiment are categorized by function, each data packet contains an item named "engine," which is used to distinguish different diagnostic systems. Among them:

[0042] The `ecuinfo` data packet stores initialization commands, including the version information and the SID of the data stream read command. Upon entering the diagnostic system, this packet is read, and the corresponding instruction is located based on the `engine` item. Initialization commands for the lower-level machine and ECU are then sent. After normal communication, version information is read by sequentially reading the `ecuinfo` and `basicinfo` data packets to assemble a complete command. Similarly, the data stream is read by sequentially reading the `ecuinfo` and `paraminfo` data packets to assemble a complete command. To read fault codes, only the `ecuinfo` data packet needs to be read to send the fault code read command.

[0043] The `basicinfo` data packet stores version-related information. After a command to read the version information is sent, the ECU responds positively. This data packet analyzes the response command, including confirming the valid start byte, the number of valid data bytes, and the data display method. Finally, the version information name and the display result are combined and displayed on the diagnostic page.

[0044] The paraminfo data packet stores information related to reading the data stream. After sending a command to read the data stream, the ECU responds positively. This data packet analyzes the response command, including confirming the valid start byte, the valid start bits of the valid start byte, and the number of valid start bits. The confirmed value is then used for scaling and offset calculations to obtain the final value. Finally, the data stream name and the final value are combined and displayed on the diagnostic page.

[0045] The dtcinfo data packet is used to store fault code-related information. Sending a command to read fault codes only requires loading the eccuinfo data packet. The ECU responds positively. The dtcinfo data packet analyzes the response command, confirms the valid start byte, fault code byte length, and fault code valid byte length, converts the fault code valid bytes into PBCU codes, and then determines the number of bytes by the difference between the fault code byte length and the fault code valid byte length. This calculation confirms the fault code status. Finally, the fault code's cause, result, impact, PBCU code, and fault code status are combined and output to the diagnostic page.

[0046] The testinfo data packet is used to store information related to action tests, including start and end commands for the action test.

[0047] Examples of specific applications of the above data packets are as follows:

[0048] Upon entering the diagnostic system, the diagnostic tool will send initialization commands for the lower-level machine and initialization commands for the ECU.

[0049] If the diagnostic tool sends an initialization command to the lower-level ECU and the ECU responds, then the initialization is successful.

[0050] If the diagnostic tool sends an ECU initialization command and the ECU responds, then the initialization is successful.

[0051] Both the lower-level machine and the ECU were successfully initialized, and the diagnostic tool can communicate normally with the vehicle ECU.

[0052] The ecuinfo data packet stores the initialization instructions for the lower-level machine and the initialization instructions for the ECU. The ecuinfo data packet includes the following data items:

[0053] The `bus_type` field indicates the communication bus type, with values ​​ranging from 1 to 2. 1 indicates CAN bus type, and 2 indicates KWP bus type.

[0054] The address field contains the address ID. For the CAN bus, this field contains the address ID sent by the diagnostic tool.

[0055] The corresponding responseaddress field represents the ECU response address ID, where the CAN bus address ID is four bytes; for the KWP bus, the address field stores two bytes of data, the first byte representing the target address of the sent command and the second byte representing the source address of the sent command.

[0056] The Baud field indicates the baud rate during communication, typically 250K or 500K. All of the above are initialization instructions for the lower-level machine.

[0057] The `writediaglog_command` field contains the ECU initialization commands.

[0058] Taking a certain vehicle model as an example, the initialization instructions for the lower-level machine and the ECU are stored in the ECUinfo data packet. The specific storage method is as follows: bus_type is 1, indicating the CAN protocol; address is 000007E0, representing the diagnostic tool's sending address; responseaddress is 000007E8, representing the ECU's sending address; baud is 250, representing the baud rate in Kb / s; writediaglog_command is 22,f8,02, representing the ECU initialization instructions.

[0059] During the process of reading version information from the vehicle's ECU, it is necessary to determine information such as the vehicle's VIN code, production date, and assembly process. This embodiment stores the SID of the command sent by the diagnostic tool in the `basicinfo_command` field of the `ecuinfo` data packet, and the PID of the command in the `DID` field of the `basicinfo` data packet. When the ECU responds positively, the diagnostic program calls the `basicinfo` data packet for analysis, using the DID as an index to confirm the location.

[0060] The basicinfo data packet includes the following data items:

[0061] The `name` field represents the version information name;

[0062] The startbyte field indicates the starting byte.

[0063] The `length` field specifies the number of bytes displayed. The length representation varies depending on the display method. When the version information is displayed in ASCII, the length is the number of bytes displayed. When the version information is displayed in BCD or HEX, the length is twice the number of bytes displayed.

[0064] The encoding field specifies the display mode, including ASCII, BCD, HEX, and other display modes.

[0065] Taking a certain vehicle model as an example, version information data is stored in the ECUInfo and BasicInfo data packets. The method stores the SID (both values ​​are 22) from the command to read the version information in the BasicInfo_Command field of the ECUInfo data packet, and stores the different PID parts of the command in the BasicInfo data packet, for example, f1,92. After the diagnostic tool sends the command, it only needs to read the two data packets. The ECU will definitely respond. The diagnostic tool only needs to call the BasicInfo data packet for analysis, using the PID as an index to determine the remaining parameters, including: name (version information name, in this example, ECU model / hardware model), startbyte (starting byte, in this example, 3), length (length of displayed bytes, in this example, 8), and encoding (display mode, in this example, ASCII display).

[0066] When reading fault codes from an onboard ECU, the codes can point to specific components and provide information about the possible causes of the problem.

[0067] In this embodiment, the fault code reading command is stored in the getdtc_command field of the ecuinfo data packet, and the code library is stored in the dtcinfo data packet.

[0068] By reading the data stream of the vehicle's ECU, and based on the components identified by the fault codes, we can observe the sensor data streams of those components and analyze the specific problems.

[0069] This embodiment stores the SID of the read data stream command sent by the diagnostic tool in the getpara_command field of the ECUinfo data packet, and the PID of the command sent by the diagnostic tool in the DID field of the paraminfo data packet. The ECU responds positively, and the remaining fields are analyzed using the PID as an index.

[0070] The `name` field represents the name of the data stream.

[0071] The startbyte field indicates the starting byte.

[0072] The startbit field indicates the starting bit position of the table.

[0073] The Bitnum field indicates the number of valid bits;

[0074] The Bitseq item indicates the calculation method, with options ranging from 1 to 2. 1 indicates unsigned computation, and 2 indicates signed computation.

[0075] Item B is the data *b read from the control bit, and its principle conforms to the rules of addition, subtraction, multiplication, and division.

[0076] Item C is the data read from the control bit + c, and its principle conforms to the rules of addition, subtraction, multiplication, and division.

[0077] The Minvalue field represents the minimum value that the data stream can display.

[0078] The `maxvalue_` field specifies the maximum value that the data stream can display.

[0079] The Content field contains the options for the switch quantities in the data stream.

[0080] Taking a certain vehicle model as an example, data stream data is stored in the `ecuinfo` and `paraminfo` data packets. Commands with the same SID for reading the data stream are stored in the `getpara_command` field of the `ecuinfo` data packet (e.g., 22). Different PIDs are stored in the `DID` field of the `paraminfo` data packet, using this as an index (e.g., 10,6a in this example). When the diagnostic tool sends a command, it only needs to call the `ecuinfo` and `paraminfo` data packets, and the ECU will definitely respond. Further analysis of the `paraminfo` data packet, using the PID as an index, determines the remaining parameters, including: the `name` field (data stream name, in this example, pressure control valve setpoint); the `startbyte` field (starting byte, 4 in this example); the `startbit` field (starting bit, 1 in this example, the starting bit in the starting byte; the responding byte converted to binary, with the highest bit being 1, sorted sequentially to the right, and the lowest bit being 8); the `Bitnum` field (number of valid bits, 28 in this example, three half-bytes); the `Bitseq` field (calculation method, 2 in this example); and the `B` field (data read from the control bit *b, 0.01 in this example). Item C is the data read from the control bit plus c, which is 0 in this example. Item Minvalue is the minimum value that the data stream can display, which is -32768000 in this example. Item maxvalue is the maximum value that the data stream can display, which is 32768000 in this example.

[0081] In this example, the effective bytes in the reply command are 3 0.5 bytes. Compared to other software designs that use & followed by 0fffffff to remove the highest half-byte data, this design uses bits as the smallest unit of calculation. It only requires confirming the starting byte, the starting bit, and the number of effective bits. By adopting this design, the high half-byte of the fourth byte is not processed, thus avoiding & calculation and further reducing the space occupied by the data packet.

[0082] When performing motion tests on a vehicle, the same data stream may involve multiple different systems. Motion testing helps eliminate faulty components and reduces unnecessary disassembly. Motion test commands are stored in a Testinfo data packet.

[0083] When clearing fault codes from an onboard ECU, if a fault is found after reading the fault codes, the error codes are usually recorded in the vehicle's diagnostic system. After repairs, the codes are cleared first, then read again to observe whether the fault is resolved. In this embodiment, the clear code command is stored in the `cleardtc_command` field of the `ecuinfo` data packet.

[0084] Example 2

[0085] Combination Figure 2This embodiment of a vehicle fault diagnosis system includes a host computer diagnostic instrument, a lower-level system, and an on-board ECU. The lower-level system includes a wireless communication module, a lower-level MCU, a drive circuit, and an OBD communication module. The wireless communication module is a Bluetooth module. The host computer diagnostic instrument is connected to the Bluetooth module of the lower-level system through the Bluetooth module. The OBD interface of the lower-level system is connected to the on-board ECU through the OBD bus.

[0086] The aforementioned host computer diagnostic instrument interacts with the vehicle ECU by sending data packets, and sequentially performs operations such as reading version information, reading fault codes to identify fault code components and systems, and reading data streams to determine specific problems based on sensor data and actuator status.

[0087] The data packets used by the diagnostic tool to interact with the vehicle's ECU include ecuinfo, basicinfo, paraminfo, dtcinfo, and testinfo data packets, as described in Example 1.

[0088] The present invention and its embodiments have been described above illustratively. This description is not restrictive, and the figures shown are only one embodiment of the present invention; the actual structure is not limited thereto. Therefore, if those skilled in the art are inspired by this description and design similar structures and embodiments without departing from the spirit of the present invention, such designs should fall within the protection scope of the present invention.

Claims

1. A vehicle fault diagnosis method, characterized in that, The steps are as follows: Step 1: Connect the diagnostic tool to the vehicle's ECU; Step 2: Open the diagnostic software on the diagnostic tool, enter the diagnostic page, select the corresponding vehicle model, and click "Start Diagnosis." The diagnostic tool interacts with the vehicle's ECU by sending data packets, sequentially performing operations such as reading version information, reading fault codes to identify faulty components and systems, and reading data streams to determine specific problems based on sensor data and actuator status. The data packets used by the diagnostic tool to interact with the vehicle's ECU include ecuinfo, basicinfo, paraminfo, dtcinfo, and testinfo data packets. Different data packets are categorized by function, and each data packet contains an "engine" item to distinguish different diagnostic systems. The ecuinfo data packet is used to store initialization instructions, and the version information and the SID of the data stream reading instruction are stored in the data packet. When entering the diagnostic system, the ecuinfo data packet is read, the corresponding instruction is found according to the engine item, and the initialization instructions for the lower-level machine and the ECU are sent. The basicinfo data packet is used to store version-related instructions. Version information is retrieved by sequentially reading the ecuinfo data packet and the basicinfo data packet to form a complete command. The paraminfo data packet is used to store relevant instructions for reading the data stream. By reading the ecuinfo data packet and the paraminfo data packet in sequence, a complete command is formed to read the data stream. The dtcinfo data packet is used to store fault code related information. Sending a command to read fault codes requires loading the eccuinfo data packet. The ECU responds positively. The dtcinfo data packet analyzes the response command, confirms the valid start byte, fault code byte length, and fault code valid byte length, converts the fault code valid bytes into PBCU codes, and then confirms the number of bytes by the difference between the fault code byte length and the fault code valid byte length. The fault code status is then confirmed by calculation. Finally, the fault cause, result, impact, PBCU code, and fault code status are combined and output to the diagnostic page. The testinfo data packet is used to store action test instructions, including start and end instructions for the action test; Step 3: Perform motion tests on the vehicle to identify instances where different components and systems have the same data flow; Step 4: Repair the fault and clear the fault codes; Step 5: Read the fault code again and observe whether the fault has been resolved; otherwise, repeat the operation.

2. The vehicle fault diagnosis method according to claim 1, characterized in that: The SID of the read version information command sent by the diagnostic tool is stored in the basicinfo_command field of the ECUinfo data packet, and the PID of the read version information command is stored in the DID field of the basicinfo data packet. The ECU responds positively, and the diagnostic program calls the basicinfo data packet for analysis, using the DID as an index to confirm the location.

3. The vehicle fault diagnosis method according to claim 2, characterized in that: The SID of the read data stream command sent by the diagnostic tool is stored in the getpara_command field of the ECUinfo data packet, and the PID of the read data stream command sent by the diagnostic tool is stored in the DID field of the paraminfo data packet. The ECU responds positively, the diagnostic program calls the paraminfo data packet for analysis, and uses the PID as an index to analyze the remaining items.

4. The vehicle fault diagnosis method according to claim 3, characterized in that: The command to read fault codes is stored in the getdtc_command field of the ecuinfo data packet, and the code library is stored in the dtcinfo data packet.

Citation Information

Patent Citations

  • Automobile remote diagnosis system and method based on cloud platform

    CN114640662A