A method and system for adaptive diagnosis of motor vehicle OBD protocol
By providing an adaptive diagnostic method for OBD protocols suitable for motor vehicles, identifying and analyzing multiple OBD protocols, the problem that existing systems cannot achieve multi-protocol fusion analysis is solved, and efficient emission data acquisition and unified processing is achieved, which improves the Monitor efficiency and reduce costs.
Patent Information
- Application Number
- CN202210311602.3
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-03-28
- Publication Date
- 2025-02-11
- Estimated Expiration
- 2042-03-28
AI Technical Summary
The existing OBD protocol analysis system can only support one specific protocol standard and cannot implement multi-protocol fusion analysis, resulting in some automobile emission data being unable to be obtained, affecting data statistics and supervision efficiency.
An adaptive diagnostic method for OBD protocols for motor vehicles is provided, and the fusion analysis of multiple protocols is achieved by identifying and analyzing the OBD protocols of motor vehicles, including SAEJ1939, ISO-15765 and ISO-27145.
It is possible to obtain emission data of all motor vehicles through one system and process emission data in a unified manner, greatly improving the efficiency of exhaust emission monitoring and reducing monitoring costs.
Smart Images

Figure CN114721350B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of automotive electronic technology, and in particular to an OBD protocol adaptive diagnosis method and system applicable to motor vehicles. Background Art
[0002] As people's awareness of environmental protection continues to increase, the requirements of automobile energy conservation, emission reduction and low-carbon development have received great attention from local governments. Through the OBD diagnostic method of the CAN bus, the relevant data of automobile emissions can be read to reduce environmental pollution and improve air quality standards. Products based on the above technology have become increasingly popular in the market.
[0003] At present, the diagnostic protocols related to automobile OBD emissions include SAEJ1939 (diesel), ISO-15765 (passenger cars, active reading), ISO-27145 (diesel and passenger cars), etc. However, most of the products that analyze SAEJ1939, ISO-15765, and ISO-27145 protocols on the market are independent products, and there is no corresponding integration, which makes it impossible to obtain some automobile emission data (such as national and local emission standards related to vehicle speed and rotation speed, and energy-saving and emission reduction data detected by nitrogen oxide sensors), which cannot play a good role in data statistics and supervision.
[0004] Traditional OBD protocol parsing systems can only support one specific protocol standard and cannot adapt to different protocols. Considering that there are many protocols used in motor vehicle OBD on the market, it is necessary to parse more vehicle model data and adapt to more motor vehicle diagnostic protocols. However, existing independent products cannot achieve this. Summary of the invention
[0005] The purpose of the present invention is to provide a method and system for adaptive diagnosis of motor vehicle OBD protocols, so as to solve the technical problem that existing protocol analysis technologies or products are often independent and cannot achieve multi-protocol fusion analysis. The preferred technical solutions among the many technical solutions provided by the present invention can produce many technical effects as described below.
[0006] To achieve the above object, the present invention provides the following technical solutions:
[0007] The present invention provides an adaptive diagnostic method for an OBD protocol of a motor vehicle, which integrates the diagnosis and analysis of multiple OBD protocols, and can determine and analyze the OBD protocol of the current motor vehicle, and includes the following steps:
[0008] S10, confirming the baud rate of the motor vehicle;
[0009] S20, receiving a message from the motor vehicle under the premise of confirming the baud rate;
[0010] S30: Whether the message is received; if so, execute step S40; otherwise, execute S50;
[0011] S40, identifying the type of CAN-ID in the message, and confirming the OBD protocol of the motor vehicle according to the type of CAN-ID;
[0012] S50: Confirm the OBD protocol of the motor vehicle through functional addressing.
[0013] Furthermore, step S10 includes the following steps:
[0014] S100, setting a default baud rate, and receiving a message from the motor vehicle;
[0015] S101: Is the message received? If yes, execute step S102; otherwise, execute step S103;
[0016] S102, the baud rate of the message obtained by the motor vehicle is the default baud rate, and step S20 is executed;
[0017] S103, setting the default baud rate as the switching baud rate, and receiving a message from the motor vehicle;
[0018] S104: Is the message received? If yes, execute step S105; otherwise, execute step S50;
[0019] S105. The baud rate of the message obtained by the motor vehicle is the switching baud rate, and step S20 is executed.
[0020] Furthermore, the default baud rate is 250 Kbps.
[0021] Furthermore, the switching baud rate is 500 Kbps.
[0022] Furthermore, the OBD protocol of the motor vehicle includes SAEJ1939, ISO-15765 and ISO-27145; the type of the CAN-ID includes a standard frame and an extended frame.
[0023] Further, step S40 includes the following steps:
[0024] S400, identifying the type of CAN-ID in the message;
[0025] S401: Is the type the standard frame? If yes, execute step S402; otherwise, execute step S403;
[0026] S402: The OBD protocol of the motor vehicle is ISO-15765 or ISO-27145; execute step S50;
[0027] S403, parsing the message of the motor vehicle;
[0028] S404: Is there any parsed data? If yes, execute step S405; otherwise, execute step S50;
[0029] S405. The OBD protocol of the motor vehicle is SAEJ1939, and this diagnosis is ended.
[0030] Furthermore, the functional addressing includes standard frame functional addressing corresponding to the standard frame and extended frame functional addressing corresponding to the extended frame.
[0031] Further, step S50 includes the following steps:
[0032] S500, when the type of the CAN-ID is a standard frame, using standard frame function addressing to send ISO-27145 and ISO-15765 type diagnostic instructions respectively;
[0033] Or, when the type of the CAN-ID is an extended frame, the extended frame function addressing is used to send ISO-27145 and ISO-15765 type diagnostic instructions respectively;
[0034] S501: Is a response received? If yes, execute step S502; otherwise, execute step S503;
[0035] S502: If a response of ISO-27145 is received, the OBD protocol of the motor vehicle is ISO-27145; or, if a response of ISO-15765 is received, the OBD protocol of the motor vehicle is ISO-15765; this diagnosis ends;
[0036] S503: The OBD protocol of the motor vehicle is SAEJ1939; this diagnosis ends.
[0037] According to another aspect of the present invention, there is also provided an OBD protocol adaptive diagnostic system for motor vehicles, which is based on the above-mentioned OBD protocol adaptive diagnostic method for motor vehicles and includes an ECU, and an OBD and protocol fusion diagnostic module connected to the ECU; the ECU is used to confirm the communication baud rate of the motor vehicle, and obtain the message of the motor vehicle at a determined baud rate, and send a diagnostic instruction to the OBD when the message cannot be received; under the control of the ECU, the protocol fusion diagnostic module is used to receive and parse the OBD protocol of the motor vehicle confirmed by the ECU, and transmit the parsed data to the ECU; the OBD protocols of the motor vehicle to be confirmed include SAEJ1939, ISO-15765 and ISO-27145.
[0038] Furthermore, the OBD protocol adaptive diagnostic system for motor vehicles also includes a monitoring platform communicatively connected to the ECU; the protocol fusion diagnostic module parses the confirmed OBD protocol of the motor vehicle, and the vehicle status and emission data of the motor vehicle after parsing are sent to the monitoring platform via the ECU.
[0039] Implementing one of the above technical solutions of the present invention has the following advantages or beneficial effects:
[0040] The present invention provides a set of unified adaptation automobile OBD diagnostic protocol processes, which integrates the original independent OBD protocol diagnosis into a unified diagnostic process, and realizes that the emission data of all motor vehicles can be obtained through one system, and the emission data can be processed uniformly, which greatly improves the efficiency of exhaust emission monitoring and reduces the monitoring cost. Therefore, the present invention has strong adaptability, high diagnostic efficiency, can greatly reduce the cost of OBD protocol diagnosis, and has a wide range of market promotion value. BRIEF DESCRIPTION OF THE DRAWINGS
[0041] In order to more clearly illustrate the technical solutions of the embodiments of the present invention, the following briefly introduces the drawings required for use in the description of the embodiments. It is obvious that the drawings described below are only some embodiments of the present invention. For those skilled in the art, other drawings can be obtained based on these drawings without creative work. In the drawings:
[0042] Figure 1 It is a flow chart of a method for adaptive diagnosis of an OBD protocol for a motor vehicle according to an embodiment of the present invention;
[0043] Figure 2 is a flow chart of step S10 in a motor vehicle OBD protocol adaptive diagnosis method according to an embodiment of the present invention;
[0044] Figure 3 is a flow chart of step S40 in a motor vehicle OBD protocol adaptive diagnosis method according to an embodiment of the present invention;
[0045] Figure 4 is a flow chart of step S50 in a motor vehicle OBD protocol adaptive diagnosis method according to an embodiment of the present invention;
[0046] Figure 5 It is a structural diagram of an OBD protocol adaptive diagnostic system for motor vehicles according to an embodiment of the present invention.
[0047] 1. ECU; 2. OBD; 3. Protocol fusion diagnostic module; 4. Monitoring platform. DETAILED DESCRIPTION
[0048] In order to make the purpose, technical solutions and advantages of the present invention clearer, the various exemplary embodiments to be described below will refer to the corresponding drawings, which constitute a part of the exemplary embodiments, wherein various exemplary embodiments that may be used to implement the present invention are described. Unless otherwise indicated, the same numbers in different drawings represent the same or similar elements. The implementation methods described in the following exemplary embodiments do not represent all implementation methods consistent with the present disclosure. It should be understood that they are only examples of processes, methods, devices, etc. that are consistent with some aspects of the present disclosure as detailed in the attached claims, and other embodiments may also be used, or the embodiments listed herein may be modified in structure and function without departing from the scope and essence of the present invention.
[0049] In the description of the present invention, it should be understood that the terms "center", "longitudinal", "lateral", etc. indicate the orientation or positional relationship based on the drawings, which is only for the convenience of describing the present invention and simplifying the description, rather than indicating or implying that the elements referred to must have a specific orientation, be constructed and operated in a specific orientation. The terms "first", "second", etc. are only used for descriptive purposes, and cannot be understood as indicating or implying relative importance or implicitly indicating the number of technical features indicated. The term "multiple" means two or more. The terms "connected" and "connected" should be understood in a broad sense, for example, it can be a fixed connection, a detachable connection, an integral connection, a mechanical connection, an electrical connection, a communication connection, a direct connection, an indirect connection through an intermediate medium, and can be the internal connection of two elements or the interaction relationship between two elements. The term "and / or" includes any and all combinations of one or more related listed items. For those of ordinary skill in the art, the specific meanings of the above terms in the present invention can be understood according to the specific circumstances.
[0050] In order to illustrate the technical solution of the present invention, a specific embodiment is used below for description, and only the parts related to the embodiment of the present invention are shown.
[0051] Embodiment 1:
[0052] like Figure 1-4 As shown, the present invention provides an adaptive diagnosis method for the OBD protocol of a motor vehicle, which integrates the diagnosis and analysis of multiple OBD protocols, and can determine and analyze the OBD protocol of the current motor vehicle, including the following steps:
[0053] S10, confirming the baud rate of the motor vehicle. Specifically, this step includes the following steps:
[0054] S100, set the default baud rate, and receive messages from motor vehicles. In this embodiment, the default baud rate is set to 250Kbps. It should be noted that the message content includes the motor vehicle CAN diagnostic identifier (CAN-ID), the protocol frame part, and the vehicle data frame part. Among them, the protocol frame part includes the protocols SAEJ1939 (for diesel vehicles), ISO-15765 (for cars), and ISO-27145 (common to diesel vehicles and cars). The vehicle data includes vehicle status data, such as frame number, equipment name, vehicle speed, engine speed, and emission data, etc. The emission data includes the content of nitrogen oxides obtained from the nitrogen oxide sensor;
[0055] S101: Is the message received? If yes, go to step S102; otherwise, go to step S103;
[0056] S102, the baud rate of the message obtained by the motor vehicle is the default baud rate, and step S20 is executed;
[0057] S103, setting the default baud rate to the switching baud rate, and receiving the message from the motor vehicle. In this embodiment, the switching baud rate is 500 Kbps;
[0058] S104: Is the message received? If yes, go to step S105; otherwise, go to step S50;
[0059] S105. The baud rate of the message obtained by the motor vehicle is the switched baud rate, and step S20 is executed.
[0060] S20, receiving a message from the motor vehicle under the premise of confirming the baud rate;
[0061] S30: Is the message received? If yes, execute step S40; otherwise, execute S50;
[0062] S40, identify the type of CAN-ID in the message, and confirm the OBD protocol of the motor vehicle according to the type of CAN-ID. Specifically, the types of CAN-ID include standard frame and extended frame. The OBD protocol corresponding to the standard frame is ISO-15765 or ISO-27145; while the extended frame needs to continue to filter the protocol, and it can be confirmed from the analysis of the received message which of the three protocols it is. Specifically:
[0063] S400, identifying the type of CAN-ID in the message. Generally, after receiving the above message, the ECU (see Embodiment 2) can directly identify the type of CAN-ID (standard frame or extended frame) from the relevant fields of the message;
[0064] S401: Is the type a standard frame? If yes, go to step S402; otherwise, go to step S403;
[0065] S402, the OBD protocol of the motor vehicle is ISO-15765 or ISO-27145; execute step S50. In this step, the type of CAN-ID is a standard frame, and the following step S500 is executed to respectively send ISO-27145 and ISO-15765 type diagnostic instructions using standard frame function addressing, and then specifically confirm whether the protocol is ISO-15765 or ISO-27145;
[0066] S403, parsing the message of the motor vehicle. This step is implemented by the protocol fusion diagnosis module in the second embodiment, and the parsing result will be transmitted to the ECU mentioned above, and then the ECU will determine whether there is parsed data;
[0067] S404: Is there any parsed data? If yes, execute step S405; otherwise, execute step S50;
[0068] S405. The OBD protocol of the motor vehicle is SAEJ1939. This diagnosis is completed.
[0069] S50. Confirm the OBD protocol of the motor vehicle through functional addressing. If the above steps do not allow data to be parsed from the received message or if no message is received at all, functional addressing is required to confirm the OBD protocol of the motor vehicle. Specifically, functional addressing includes standard frame functional addressing corresponding to the standard frame (such as addressing identifier: 0x7DF) and extended frame functional addressing corresponding to the extended frame (such as addressing identifier: 0x18DB00xx), and the OBD protocol of the motor vehicle is determined through the addressing response. Further steps are:
[0070] When the type of S500 and CAN-ID is standard frame, the standard frame function addressing is used to send ISO-27145 and ISO-15765 type diagnostic instructions respectively;
[0071] Or, when the CAN-ID type is an extended frame, the extended frame function addressing is used to send ISO-27145 and ISO-15765 type diagnostic instructions respectively;
[0072] S501, whether a response is received; if so, execute step S502; otherwise, execute step S503. Specifically, the ECU sends ISO-27145 diagnostic instructions and ISO-15765 diagnostic instructions to the car's OBD respectively. Since the message contents of ISO-27145 and ISO-15765 are different, if the current motor vehicle supports the ISO-27145 protocol, the ECU will receive a positive response from the ISO-27145 protocol. If this protocol is not supported, the OBD will not generate any response. The same is true for ISO-15765;
[0073] S502: If a response of ISO-27145 is received, the OBD protocol of the motor vehicle is ISO-27145; or, if a response of ISO-15765 is received, the OBD protocol of the motor vehicle is ISO-15765; this diagnosis ends;
[0074] S503: The OBD protocol of the motor vehicle is SAEJ1939; this diagnosis is completed.
[0075] In summary, this embodiment provides a set of unified adaptation automobile OBD diagnostic protocol processes, which integrates the original independent OBD protocol diagnosis into a unified diagnostic process, and realizes that the emission data of all motor vehicles can be obtained through one system, and the emission data can be processed uniformly, which greatly improves the efficiency of exhaust emission monitoring and reduces the monitoring cost. Therefore, the present invention has strong adaptability, high diagnostic efficiency, can greatly reduce the cost of OBD protocol diagnosis, and has a wide range of market promotion value.
[0076] Embodiment 2:
[0077] The present invention also provides an OBD protocol adaptive diagnosis system for motor vehicles, which is based on the OBD protocol adaptive diagnosis method for motor vehicles described in Example 1, and includes ECU 1, OBD 2 and protocol fusion diagnosis module 3 connected to ECU 1. Specifically, ECU 1 is used to confirm the communication baud rate of the motor vehicle, and obtain the message of the motor vehicle at the determined baud rate, the message (including the OBD protocol to be confirmed, vehicle status and emission data), and send a diagnostic instruction to OBD 2 when the message cannot be received; under the control of ECU 1, the protocol fusion diagnosis module 3 is used to receive and parse the OBD protocol confirmed by ECU1, and transmit the parsed data (vehicle status and emission data) to ECU 1. Among them, the OBD protocols to be confirmed include SAEJ1939, ISO-15765 and ISO-27145.
[0078] Furthermore, the OBD protocol adaptive diagnostic system for motor vehicles of this embodiment also includes a monitoring platform 4 that is communicatively connected to the ECU 1. The protocol fusion diagnostic module 3 parses the confirmed OBD protocol of the motor vehicle, and the vehicle status and emission data of the motor vehicle after parsing are sent to the monitoring platform 4 (such as the exhaust gas environmental monitoring management platform, vehicle exhaust gas monitoring platform, etc. developed by the state or locality) through the ECU 1, so that the monitoring platform 4 can scientifically supervise and manage the exhaust gas emissions in the vehicle.
[0079] In this embodiment, the SAEJ1939, ISO-15765, and ISO-27145 protocol parsing of the motor vehicle is implemented by one ECU, and the ECU is used to communicate with the CAN bus of the whole vehicle, and the vehicle status and emission (see Example 1) related information are obtained through OBD. This system saves the number of integrated IC chips of the motor vehicle millimeter wave radar system, optimizes the system structure, unifies the information transmission with the vehicle end, is stable and reliable, and saves system costs.
[0080] The above description is only the preferred embodiment of the present invention. It is known to those skilled in the art that various changes or equivalent substitutions may be made to these features and embodiments without departing from the spirit and scope of the present invention. In addition, under the teachings of the present invention, these features and embodiments may be modified to adapt to specific circumstances and materials without departing from the spirit and scope of the present invention. Therefore, the present invention is not limited to the specific embodiments disclosed herein, and all embodiments falling within the scope of the claims of this application belong to the protection scope of the present invention.
Claims
1. A method for adaptive diagnosis of motor vehicle OBD protocol, characterized in that: It integrates the diagnosis and analysis of multiple OBD protocols, and can determine and analyze the OBD protocol of the current motor vehicle, including the following steps: S10, confirming the baud rate of the motor vehicle; S20, receiving a message from the motor vehicle under the premise of confirming the baud rate; S30: Whether the message is received; If yes, execute step S40; Otherwise, execute S50; S40, identifying the type of CAN-ID in the message, and confirming the OBD protocol of the motor vehicle according to the type of CAN-ID; S50, confirming the OBD protocol of the motor vehicle through functional addressing; The OBD protocols of the motor vehicle include SAEJ1939, ISO-15765 and ISO-27145; the types of the CAN-ID include standard frames and extended frames; Step S40 includes the following steps: S400, identifying the type of CAN-ID in the message; S401: Is the type the standard frame? If yes, execute step S402; Otherwise, execute step S403; S402: The OBD protocol of the motor vehicle is ISO-15765 or ISO-27145; execute step S50; S403, parsing the message of the motor vehicle; S404: Is there any parsed data? If yes, execute step S405; Otherwise, execute step S50; S405. The OBD protocol of the motor vehicle is SAEJ1939, and this diagnosis is ended.
2. The OBD protocol adaptive diagnosis method for motor vehicles according to claim 1, characterized in that: Step S10 includes the following steps: S100, setting a default baud rate, and receiving a message from the motor vehicle; S101: Is the message received? If yes, go to step S102; otherwise, go to step S103; S102, the baud rate of the message obtained by the motor vehicle is the default baud rate, and step S20 is executed; S103, setting the default baud rate as the switching baud rate, and receiving a message from the motor vehicle; S104: Whether the message is received; If yes, execute step S105; otherwise, execute step S50; S105. The baud rate of the message obtained by the motor vehicle is the switching baud rate, and step S20 is executed.
3. The OBD protocol adaptive diagnosis method for motor vehicles according to claim 2, characterized in that: The default baud rate is 250 Kbps.
4. The OBD protocol adaptive diagnosis method for motor vehicles according to claim 2, characterized in that: The switching baud rate is 500 Kbps.
5. The OBD protocol adaptive diagnosis method for motor vehicles according to claim 1, characterized in that: The functional addressing includes standard frame functional addressing corresponding to the standard frame and extended frame functional addressing corresponding to the extended frame.
6. The OBD protocol adaptive diagnosis method for motor vehicles according to claim 5, characterized in that: Step S50 includes the following steps: S500, when the type of the CAN-ID is a standard frame, using standard frame function addressing to send ISO-27145 and ISO-15765 type diagnostic instructions respectively; Or, when the type of the CAN-ID is an extended frame, the extended frame function addressing is used to send ISO-27145 and ISO-15765 type diagnostic instructions respectively; S501: Is a response received? If yes, execute step S502; otherwise, execute step S503; S502: If a response of ISO-27145 is received, the OBD protocol of the motor vehicle is ISO-27145; or, if a response of ISO-15765 is received, the OBD protocol of the motor vehicle is ISO-15765; this diagnosis ends; S503: The OBD protocol of the motor vehicle is SAEJ1939; this diagnosis ends.
7. An OBD protocol adaptive diagnostic system for motor vehicles, characterized in that: Based on the OBD protocol adaptive diagnosis method applicable to motor vehicles according to any one of claims 1 to 6, it includes an ECU, and an OBD and protocol fusion diagnosis module connected to the ECU; The ECU is used to confirm the communication baud rate of the motor vehicle, obtain the message of the motor vehicle at the determined baud rate, and send a diagnostic instruction to the OBD when the message cannot be received; under the control of the ECU, the protocol fusion diagnosis module is used to receive and parse the OBD protocol of the motor vehicle confirmed by the ECU, and transmit the parsed data to the ECU; The OBD protocols of the motor vehicle to be confirmed include SAEJ1939, ISO-15765 and ISO-27145.
8. The OBD protocol adaptive diagnostic system for motor vehicles according to claim 7, characterized in that: Also included is a monitoring platform communicatively connected to the ECU; The protocol fusion diagnosis module parses the confirmed OBD protocol of the motor vehicle, and the vehicle status and emission data of the motor vehicle after parsing are sent to the monitoring platform through the ECU.
Citation Information
Patent Citations
Method and system for automatically identifying CAN communication baud rate of vehicle ECU
CN111224837A
Systems and methods for accessing vehicle communications bus information for an application processor
US9734119B1