Automobile diagnosis method, system and device
By obtaining the current status of the vehicle, the dynamic configuration target diagnostic service, the problem of static configuration limitations in the existing technology has been solved, and the flexible adaptation and resource optimization of diagnostic services are realized.
Patent Information
- Application Number
- CN202411639986.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-11-18
- Publication Date
- 2025-01-28
- Estimated Expiration
- 2044-11-18
AI Technical Summary
The existing AUTOSAR AP diagnostic components have static configuration limitations in diagnostic service configuration, which cannot adapt to real-time changes in the vehicle, and are difficult to meet changing needs and personalized customization requirements.
By obtaining the current state of the vehicle, the configuration information of the target diagnostic service is dynamically determined, and the diagnostic service is performed according to the configuration information to feedback the diagnostic results.
The dynamic configuration of the diagnostic service can adapt to the real -time changes of the vehicle, improve the diagnostic efficiency and accuracy, and optimize the resource allocation.
Smart Images

Figure CN119126766B_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of diagnostic service technology, and in particular to an automobile diagnostic method, system and device. Background Art
[0002] With the continuous development of automotive electronic technology, the number of electronic control units (ECUs) in modern cars has increased significantly. Each ECU is usually responsible for a specific control function, such as engine management, body control, safety system, etc. In order to ensure the normal operation of the vehicle and quickly locate faults, the automotive diagnostic system came into being. Its main function is to perform diagnostic operations on the ECU, read and clear fault codes, monitor system status, etc.
[0003] In recent years, the introduction of the AUTomotive Open System Architecture (AUTOSAR) Adaptive Platform (AP) has provided new possibilities for realizing flexible, dynamic and efficient in-vehicle systems. AUTOSAR AP supports dynamic configuration and service-oriented communication, but in terms of diagnostic services, the existing AUTOSAR AP diagnostic components still have some limitations: AUTOSAR AP diagnostic service configuration mainly relies on static configuration, and all diagnostic services and parameters are pre-configured when the vehicle leaves the factory. This static configuration method cannot adapt to real-time changes in the vehicle and is difficult to meet changing needs and personalized customization requirements. Summary of the invention
[0004] In order to solve the technical problem that the static configuration of diagnostic services is difficult to adapt to vehicle needs, the present application provides an automobile diagnostic method, system and device.
[0005] In a first aspect, the present application provides a vehicle diagnosis method, comprising:
[0006] In response to an execution request of a target diagnostic service sent by a diagnostic client, obtaining a current state of the vehicle;
[0007] Determining configuration information of the target diagnostic service according to the current state;
[0008] The target diagnostic service is executed according to the configuration information, and the diagnostic result of the target diagnostic service is fed back to the diagnostic client.
[0009] In a second aspect, the present application provides an automobile diagnostic system, comprising: a diagnostic client and at least one electronic controller ECU;
[0010] A diagnostic client, used to send an execution request of a target diagnostic service to a target ECU in at least one ECU;
[0011] The target ECU is used to obtain the current state of the vehicle; determine the configuration information of the target diagnostic service according to the current state; execute the target diagnostic service according to the configuration information; and feed back the diagnostic result of the target diagnostic service to the diagnostic client.
[0012] In a third aspect, the present application provides an automobile diagnostic device, comprising:
[0013] A dynamic configuration management module, configured to obtain a current state of the vehicle in response to an execution request of a target diagnostic service sent by a diagnostic client; and determine configuration information of the target diagnostic service according to the current state;
[0014] A diagnostic service module, used to perform a target diagnostic service according to the configuration information;
[0015] The communication management module is used to feed back the diagnosis result of the target diagnosis service to the diagnosis client.
[0016] The embodiments of the present application have the following technical effects:
[0017] In the embodiment of the present application, the current state of the vehicle is obtained, and the configuration information of the target diagnostic service is determined according to the current state, so that the configuration information of the target diagnostic service is dynamically adjusted according to the current state of the vehicle, so as to realize dynamic configuration of the target diagnostic service with the state of the vehicle, so that the diagnostic service can adapt to the real-time changes of the vehicle, which can not only ensure the diagnostic efficiency and accuracy, but also is conducive to realizing the optimal allocation of resources. BRIEF DESCRIPTION OF THE DRAWINGS
[0018] In order to more clearly illustrate the specific implementation methods of the present application or the technical solutions in the prior art, the drawings required for use in the specific implementation methods or the description of the prior art will be briefly introduced below. Obviously, the drawings described below are some implementation methods of the present application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying any creative work.
[0019] Figure 1 is a schematic diagram of an automobile diagnostic system provided by an embodiment of the present application;
[0020] Figure 2 It is a flow chart of a vehicle diagnostic method provided in an embodiment of the present application;
[0021] Figure 3 is a signaling diagram of another automobile diagnostic method provided in an embodiment of the present application;
[0022] Figure 4 is a structural schematic diagram of an automobile diagnostic device provided in an embodiment of the present application;
[0023] Figure 5 It is a structural schematic diagram of another automobile diagnostic device provided in an embodiment of the present application. DETAILED DESCRIPTION
[0024] In order to make the purpose, technical solution and advantages of the present application clearer, the technical solution of the present application will be described clearly and completely below. Obviously, the described embodiments are only part of the embodiments of the present application, rather than all of the embodiments. Based on the embodiments in the present application, all other embodiments obtained by ordinary technicians in the field without creative work belong to the scope of protection of the present application.
[0025] The embodiment of the present application provides an automobile diagnostic method, which is applicable to the case of diagnosing automobile faults. Optionally, the automobile diagnostic method can be applied to the AUTOSAR AP architecture, or other diagnostic service architectures that can be run on a vehicle. The method provided by the embodiment of the present application is performed by an automobile diagnostic device, which is integrated by hardware and / or software and deployed in an on-board ECU.
[0026] In order to facilitate the introduction of the method provided in this embodiment, the system used by the automobile diagnosis method is first introduced. The system includes a diagnosis client and at least one ECU, including ECUs responsible for different functions such as the engine, transmission, and anti-lock brake system (ABS). Figure 1 , 2 ECUs are shown. The diagnostic client sends an execution request for the target diagnostic service 1 to ECU1, and ECU1 executes the target diagnostic service 1 and feeds back the diagnostic result to the diagnostic client. The diagnostic client sends an execution request for the target diagnostic service 2 to ECU2, and ECU2 executes the target diagnostic service 2 and feeds back the diagnostic result to the diagnostic client. The ECU that receives the target diagnostic service execution request and performs diagnosis can be called the target ECU. The method provided in this embodiment is described below with the target ECU as the execution subject.
[0027] See also Figure 2 The automobile diagnostic method provided in the embodiment of the present application comprises the following steps:
[0028] S110 . Responding to a request for executing a target diagnostic service sent by a diagnostic client, obtaining a current state of the vehicle.
[0029] The target ECU can provide at least one diagnostic service, and the target diagnostic service can be any one of them, such as a transmission fault code reading service.
[0030] In some examples of the present embodiment, the execution request sent by the diagnostic client includes target diagnostic service indication information, such as the name of the target diagnostic service. Through the name, the diagnostic client can indicate to the target ECU which diagnostic service needs to be executed. Those skilled in the art will understand that in some other examples, the target diagnostic service indication information may also be other information, such as a unique identifier of the target diagnostic service.
[0031] After receiving the execution request of the target diagnostic service, the target ECU obtains the current state of the vehicle. The target ECU can determine the current state of the vehicle by obtaining data from the vehicle sensors.
[0032] In some examples, the target ECU is connected to multiple vehicle sensors, including but not limited to at least one of a speed sensor, an engine status sensor, and an on-board network load sensor. These vehicle sensors collect data according to a set collection frequency or based on a specific event (such as a fault). The data acquisition module in the target ECU collects data from the vehicle sensors through an on-board network interface (such as a CAN bus or Ethernet). The data from the vehicle sensors includes but is not limited to at least one of the following: wheel speed, driving speed, acceleration, direction information, engine speed, coolant temperature, data transmission rate, and communication delay. The sensor data needs to ensure low latency and high reliability during the vehicle network transmission process.
[0033] In some examples, because the data collected by the vehicle sensor has more noise and limited accuracy, the target ECU can preprocess the data of the vehicle sensor. The preprocessing operation can include filtering, denoising, and outlier detection. The following is a detailed introduction to each preprocessing.
[0034] Filtering: A low-pass filter algorithm is used for filtering. The basic principle is to smooth the data by reducing the high-frequency components of the signal. It allows low-frequency signals to pass while blocking high-frequency noise. By performing weighted averaging on the data, the low-pass filter smoothes the fluctuations of the signal and retains the main trend of the data. The low-pass filter usually consists of a smoothing factor (α) and a recursive formula, where α determines the weighted ratio of the current value of the data to the previous value. A higher α value makes the current data point have a greater impact on the result, and a lower α value makes the result smoother, but responds slower to sudden changes. In this way, the low-pass filter can effectively remove high-frequency noise and retain the low-frequency components of the data, thereby achieving signal smoothing.
[0035] Denoising: used to remove random noise from sensor data and improve data accuracy; this embodiment identifies and replaces noise data based on the difference between a data point and its neighboring points. In some examples, the difference between each data point and its neighboring points is compared, and the points whose difference exceeds a threshold are replaced with the average value of the neighboring points.
[0036] Outlier detection and processing: Detect and remove outliers in the data, such as extreme values caused by sensor failure, to ensure data quality. This embodiment implements outlier detection and processing by calculating the mean of the data and removing data points that differ from the mean by more than a threshold. In some examples, the mean of the data is calculated, and then data points that deviate from the mean by more than a threshold are removed to remove extreme outliers.
[0037] After preprocessing the data of the vehicle sensor, the target ECU obtains accurate and reliable sensor data, i.e., the preprocessing result. It can be understood by those skilled in the art that the preprocessing process of the sensor data can also be completed by other devices with processing capabilities, which obtain the raw data collected by the vehicle sensor and perform preprocessing, and send the preprocessing result to the target ECU.
[0038] Then, the target ECU can determine the operating state parameters of the vehicle based on the preprocessing results. The operating state parameters can be parsed from the preprocessing results, such as vehicle speed, engine temperature, etc. Then, the target ECU determines the current state of the vehicle based on the operating state parameters.
[0039] Optionally, the current state of the vehicle includes a normal state, a fault state, and a warning state. In some examples, if each operating state parameter is less than a preset warning threshold, the current state is a normal state. If any operating state parameter is greater than or equal to the warning threshold and less than the fault threshold, the current state is a warning state, that is, certain parameters exceed the warning threshold, and attention or preventive measures may be required. If any operating state parameter is greater than or equal to the fault threshold, the current state is a fault state, that is, the vehicle has an equipment failure or a system abnormality; wherein the warning threshold is less than the fault threshold.
[0040] Those skilled in the art should understand that the above three states (normal state, fault state and warning state) are only examples given for the convenience of explanation, and are not the only way to divide the vehicle state. In some other examples, the vehicle may have more or fewer state types than three. In addition, the above state names should not limit the embodiments of the present application. In other situations, "normal state", "fault state" and "warning state" can also be replaced by "first state", "second state" and "third state" respectively.
[0041] S120: Determine configuration information of the target diagnostic service according to the current state.
[0042] Optionally, the configuration information includes at least one of the priority of the target diagnostic service, resource configuration information, and diagnostic parameter configuration information. The process of determining the configuration information includes the following three steps, each of which is described in detail below.
[0043] The first step is to determine the vehicle's diagnostic needs based on its current status.
[0044] Determine whether diagnosis is needed based on the current state of the vehicle, and determine the specific diagnostic needs so that potential problems can be dealt with in a timely manner. If the current state is normal, no further diagnosis is required; if the current state is a fault state, detailed fault diagnosis is required to determine the specific problem; if the current state is a warning state, more data may need to be monitored, or preventive maintenance may be prepared.
[0045] The second step is to determine the priority and resource allocation of each sub-service under the target diagnosis service based on the diagnosis requirements.
[0046] Assume that the target diagnostic service is 0x19 service, which includes sub-services 1901, 1902, 1904 and 1906. Sub-service 1901 is to find the number of faults that match it through the status mask, sub-service 1902 is to find the matching faults in the form of the defined status mask, and sub-service 1904 is to request the snapshot information of the specified fault code (DTC). By finding these data at the time of the fault, the cause of the fault can be analyzed. If the engine temperature rises suddenly and reaches the warning state, sub-service 1901 is called first to read all DTCs to confirm whether there are temperature-related fault codes in the current engine. Then sub-service 1902 is called to track the changes in the fault code status in real time. If the engine temperature exceeds the fault threshold and detailed fault diagnosis is required, sub-service 1904 is called first to request the snapshot information of the specified fault code (DTC) to analyze the cause of the fault in order to solve the fault.
[0047] In this embodiment, the target ECU configures resources for each sub-service according to the priority of each sub-service. Generally, a sub-service with a higher priority will be allocated more resources to improve the diagnostic efficiency of the sub-service with a higher priority. The resources mentioned here include but are not limited to at least one of communication bandwidth, storage space and CPU system resources.
[0048] Step 3: Determine the diagnostic parameter configuration information according to the type of current status.
[0049] In some examples, the diagnostic parameter configuration information includes at least one of a session mode, a sampling frequency, and a diagnostic depth, and the diagnostic parameter configuration information is applied to each sub-service in the aforementioned target diagnostic service.
[0050] In one example, if the current state is a normal state, the target ECU may determine the session mode as a single session mode, the sampling frequency as a first sampling frequency, and the diagnostic depth as a first diagnostic depth; if the current state is a warning state, the session mode may be determined as a continuous session mode, the sampling frequency as a second sampling frequency, and the diagnostic depth as a second diagnostic depth; if the current state is a fault state, the session mode, sampling frequency, and diagnostic depth may be an emergency session mode, a third sampling frequency, and a third diagnostic depth, respectively. Among them, the third sampling frequency> the second sampling frequency> the first sampling frequency, and the third diagnostic depth> the second diagnostic depth> the first diagnostic depth. Among them, the single session mode is suitable for one-time diagnostic tasks, the continuous session mode is suitable for tasks that require long-term monitoring, and the emergency session mode is suitable for tasks that require immediate attention and quick response.
[0051] In one example, if the current state of the vehicle is normal, the session mode is adjusted to single session, the sampling frequency is adjusted to 1, and the diagnostic depth is adjusted to 1. When the vehicle is in normal state, the system only needs to check the status of the vehicle regularly to ensure that everything is within the expected range, so there is no need to collect data frequently or perform in-depth diagnosis. Single session mode means that only one check is required, and the low sampling frequency and shallow diagnostic depth save resources and avoid unnecessary computing overhead. If the current state of the vehicle is warning state, the session mode is adjusted to continuous session, the sampling frequency is adjusted to 5, and the diagnostic depth is adjusted to 2. If the current state is warning state, in order to find potential problems earlier and take measures, it is necessary to increase the frequency of data collection and the depth of diagnosis. Continuous session mode means that the system will continue to monitor the status of the vehicle, a higher sampling frequency can capture more detailed changes, and a deeper diagnostic depth can help locate the problem more accurately. If the current state is a fault state, the session mode is adjusted to emergency session, the sampling frequency is adjusted to 10, and the diagnostic depth is adjusted to 3; when the vehicle has already failed, detailed diagnosis is required immediately to quickly locate the problem and solve it. Emergency session mode means that the system will focus more resources on dealing with current problems. The highest sampling frequency ensures that as much data as possible is obtained, and the deepest diagnostic depth helps to fully understand the cause of the fault and its scope of impact.
[0052] In one example, the target ECU may predefine a function that can implement the mapping of the state to the session mode through a conditional statement. When determining the session mode, the corresponding session mode may be directly returned according to the current state of the vehicle. For example, "single session" is returned for the normal state, "continuous session" is returned for the warning state, and "emergency session" is returned for the fault state. If the current state does not match any of the above, "unknown session" is returned. The target ECU predefines a structure containing two members: sampling frequency and diagnostic depth. The target ECU predefines a function that sets the diagnostic depth and sampling frequency according to the current state of the vehicle. The definition order of the structure and the function is not limited. When determining the diagnostic depth and sampling frequency, the target ECU sets the diagnostic depth and sampling frequency according to the current state of the vehicle by calling the predefined function. In some examples, in the normal state, the sampling frequency is 1 and the diagnostic depth is 1; in the warning state, the sampling frequency is 5 and the diagnostic depth is 2; in the fault state, the sampling frequency is 10 and the diagnostic depth is 3. The function returns the set diagnostic depth and sampling frequency. Optionally, a configuration template is used to generate diagnostic parameter configuration information. First determine the session mode, then determine the diagnostic depth and sampling frequency, and combine these diagnostic parameter configuration information into the configuration template to ensure the standardization, completeness and consistency of the configuration and improve communication efficiency. Through the standardized configuration information determination process, ensure that all necessary information is included, facilitate system integration and expansion, and meet various diagnostic needs.
[0053] Optionally, after determining the configuration information of the target diagnostic service, the target ECU sends the configuration information to the diagnostic client, which synchronizes the received configuration information locally and sends an instruction (which may be referred to as an execution instruction) to execute the target diagnostic service according to the configuration information to the target ECU through the vehicle network, notifying the target ECU to execute the target diagnostic service. The execution instruction includes: the name of the target diagnostic service and the configuration information, etc. The reliability and real-time nature of the message need to be ensured during the sending process. The diagnostic client receives the configuration confirmation message from the target ECU to ensure that the configuration is successful and that the target ECU has correctly received and applied the configuration.
[0054] This embodiment returns the final configuration information to the diagnostic client to ensure that the configuration information between the diagnostic client and the target ECU is consistent, thereby avoiding execution errors or conflicts caused by inconsistent configuration information.
[0055] S130: Execute the target diagnostic service according to the configuration information, and feed back the diagnostic result of the target diagnostic service to the diagnostic client.
[0056] After receiving the execution instruction, the target ECU parses the instruction content and obtains the target diagnostic service name and configuration information. The diagnostic service module corresponding to the target diagnostic service is called to perform diagnostic operations, such as reading sensor data and executing self-test programs. After the diagnostic service module is executed, the diagnostic result is generated and returned to the diagnostic client; the diagnostic result includes detailed information such as diagnostic data and status code.
[0057] In some examples, the target ECU returns the diagnostic results to the diagnostic client module through the communication management module. First, the diagnostic service module passes the diagnostic results to the communication management module and constructs a diagnostic result message, which contains detailed information such as diagnostic data and status code. Then the diagnostic result message is sent back to the diagnostic client module through the vehicle network protocol. After receiving the diagnostic result message, the diagnostic client module parses the message content to obtain the diagnostic result data. The parsed diagnostic result is displayed to the user or further processed.
[0058] This embodiment obtains the current state of the vehicle and determines the configuration information of the target diagnostic service based on the current state, thereby dynamically adjusting the configuration information of the target diagnostic service according to the current state of the vehicle, thereby realizing dynamic configuration of the target diagnostic service with the state of the vehicle, so that the diagnostic service can adapt to the real-time changes of the vehicle, which can not only ensure the diagnostic efficiency and accuracy, but also facilitate the optimal allocation of resources.
[0059] Based on the above embodiment, before responding to the execution request of the target diagnostic service sent by the diagnostic client and obtaining the current status of the vehicle, the automobile diagnostic method provided in this embodiment also includes executing at least one of the following first and second processes. Optionally, the first process is executed first and then the second process.
[0060] The first process is the process of service registration and service discovery between ECUs. Service registration means that ECU broadcasts the diagnostic service information it provides to the vehicle network, so that other ECUs can discover and use these services; service discovery means that after ECU receives the broadcasted diagnostic service information, it registers it in the local diagnostic service database to form a database of available diagnostic services. The second process includes: broadcasting the information of the first diagnostic service provided locally to other ECUs through the first registration information, and receiving the second registration information broadcast by other ECUs, the second registration information contains the information of the second diagnostic service provided by other ECUs; recording the information of the second diagnostic service in the diagnostic service database.
[0061] In some examples, the first registration information includes information about the local diagnostic service provided by the target ECU, which can be referred to as information about the first diagnostic service. After the target ECU is started, it scans the local diagnostic service database to obtain information about all available first diagnostic services. Based on the scanned information about the first diagnostic service, the first registration information is constructed, which includes detailed information such as the service name, interface, and parameters. Then, the first registration information is broadcast to the vehicle network through the vehicle network protocol (such as the SOME / IP-SD protocol) to notify other ECUs of the diagnostic service provided by the ECU. Correspondingly, other ECUs will also scan the local diagnostic service database to obtain information about all available second diagnostic services, construct the second registration information, and broadcast the second registration information to the vehicle network through the vehicle network protocol to notify the target ECU. After receiving the second registration information, the target ECU parses the message content to obtain information about the second diagnostic service such as the service name, interface, and parameters. The information about the second diagnostic service locally supported by the target ECU is recorded in the local diagnostic service database for subsequent diagnostic requests.
[0062] In some cases, the ECU is not fully started or the configuration file is loaded incorrectly, and there will be unavailable local diagnostic services. Each ECU broadcasts all available local diagnostic service information to other ECUs, receives diagnostic service information from other ECUs, selects locally supported diagnostic service information from other ECUs, and updates it to the diagnostic service database, completing the sharing of diagnostic services between ECUs.
[0063] The second process is a process in which a diagnostic client selects a target diagnostic service from a plurality of diagnostic services, including: in response to a diagnostic service discovery request sent by the diagnostic client, feeding back locally provided first diagnostic service set information to the diagnostic client, so that the diagnostic client can select a target diagnostic service from the first diagnostic service set information, wherein the first diagnostic service set information includes information of the locally provided first diagnostic service.
[0064] Optionally, when diagnosis is required, the diagnostic client generates a discovery request for the diagnostic service based on the fault code or the diagnostic command input by the user. The discovery request includes information such as the name of the diagnostic service, parameter requirements, and the priority of the diagnostic service. The fault code is generated autonomously when the vehicle fails; the diagnostic command is actively entered by the operator according to the needs and has nothing to do with whether the vehicle fails. The diagnostic client sends the discovery request to the vehicle network through the vehicle network protocol, broadcasts it to all ECUs, and waits for the ECU's service discovery response. After receiving the discovery request, each ECU (including the target ECU) searches the local diagnostic service database for the diagnostic service that matches the service discovery request, forms the diagnostic service set information, and sends it to the diagnostic client.
[0065] The diagnostic client selects the target diagnostic service and the target ECU supporting the target diagnostic service from the diagnostic service set information sent by all ECUs. Optionally, the diagnostic client obtains the priority of each diagnostic service in the diagnostic service set information and the matching of each diagnostic service with the discovery request; selects the target diagnostic service from the diagnostic service set information according to the priority and matching of each diagnostic service. Selecting the target diagnostic service according to the priority means giving priority to the diagnostic service with the same or higher priority in the discovery request. Selecting the target diagnostic service according to the matching is to ensure that the parameter requirements of the diagnostic service are consistent with the parameters in the discovery request or within the error tolerance range. In some examples, the diagnostic client generates a discovery request for the "engine fault code reading" service based on the engine fault code, requiring the service priority to be "high". Both the engine ECU and the transmission ECU return the diagnostic service set information. The engine fault is more important than the transmission. The diagnostic client requires the diagnostic service of engine fault code reading, and the diagnostic service provided by the engine ECU meets this requirement. Although the transmission diagnostic service provided by the transmission ECU is also related to fault code reading, it does not meet the name condition of "engine" in the request and has a low matching degree. Therefore, the fault code reading diagnostic service (i.e., the target diagnostic service) is selected from the diagnostic service set information provided by the engine ECU. If there are more than two ECUs that can provide fault code reading diagnostic services, the diagnostic client determines the target ECU that supports the target diagnostic service based on the performance of the two or more ECUs. The performance includes at least the response time and the reliability of the data provided.
[0066] The diagnostic client in this embodiment selects a target diagnostic service from the diagnostic service set information according to the priority and matching of each diagnostic service, so as to execute a diagnostic service with a higher priority and a better matching. The target ECU supporting the target diagnostic service is determined according to the performance of more than two ECUs to ensure that the selected target ECU can complete the diagnostic task within the expected time.
[0067] Below, see Figure 3 , a specific embodiment is used to describe in detail the automobile diagnosis method, which is executed collaboratively by the target ECU and the diagnosis client.
[0068] S10: System initialization.
[0069] The system initialization phase is the basis for the entire diagnostic system to start running. This phase mainly includes ECU power-on and initialization, service registration and service discovery.
[0070] ECU power-on and initialization: When the vehicle starts, each ECU is powered on, and self-checking and initialization begins. The initialization process includes loading ECU firmware and operating system, starting the operating system, application program and diagnostic service module, initializing hardware interfaces such as the Controller Area Network (CAN) interface and Ethernet interface to ensure communication with other ECUs. The system initialization phase ensures that the ECU has the ability to run diagnostic services.
[0071] Service registration: After the ECU is started, it broadcasts the information of the first diagnostic service provided locally to other ECUs through the first registration information, and receives the second registration information broadcast by other ECUs;
[0072] Service discovery: The information of the second diagnostic service is recorded in the diagnostic service database to form an available service database for subsequent diagnostic requests.
[0073] S20: The diagnostic client determines a target diagnostic service and a target ECU.
[0074] Assume that there is a problem with the vehicle's engine. The engineer uses the on-board diagnostic device (i.e., the diagnostic client) to connect to the vehicle and wants to read the engine's fault code. There are multiple ECUs inside the vehicle, including ECUs responsible for different functions such as the engine, transmission, and ABS system. When the diagnostic client is ready to start diagnosing the engine, it generates a discovery request for the "Engine Fault Code Reading" service, requiring the service priority to be "high". It is broadcast to all ECUs through the vehicle network, but only the ECU that supports the "Engine Fault Code Reading" service (the ECU is the target ECU in the current scenario) will respond.
[0075] Each ECU will query its own local diagnostic service database. For example, the engine ECU found the "engine fault code reading" service, which supports detailed fault code reading. The transmission can also provide related fault code services, but it is for the transmission, not the engine. Both the engine ECU and the transmission ECU will build diagnostic service set information to inform the diagnostic client which services they have that meet the request. The service returned by the engine ECU is the "detailed engine fault code reading service", and the transmission ECU returns the "transmission fault code reading service".
[0076] The diagnostic client obtains the priority of each diagnostic service in the diagnostic service set information, as well as the matching of each diagnostic service with the discovery request; based on the priority and matching of each diagnostic service, the target diagnostic service is selected from the diagnostic service set information, and finally the fault code reading diagnostic service provided by the engine ECU is selected, and the engine ECU that supports the engine fault code reading diagnostic service is determined as the target ECU. The diagnostic client sends an execution request for the target diagnostic service to the target ECU.
[0077] In some cases, the diagnostic client determines only one target ECU for each target diagnostic service. In other scenarios, the diagnostic client can determine at least two candidate target ECUs for a target diagnostic service. In this case, the diagnostic client can choose to send an execution request for the target diagnostic service to any candidate target ECU. When the target ECU interrupts the target diagnostic service, the diagnostic client can send an execution request for the target diagnostic service to other candidate target ECUs to allow them to continue executing the diagnostic service from the interruption point.
[0078] In some cases, the diagnostic client can discover multiple target diagnostic services (which may have different priorities), and can send execution requests to the corresponding target ECUs in descending order of priority. Each target ECU will generate configuration information and execute subsequent diagnostic services.
[0079] In the embodiment of the present application, by sharing the respective diagnostic services of ECUs, different ECUs can take over each other's tasks when needed, thereby improving the fault tolerance of the system; in addition, after sharing, there may be multiple ECUs to provide the same diagnostic service, so that the diagnostic client can dynamically assign different diagnostic tasks to different ECUs, avoid overloading a single ECU, and improve the operating efficiency of the entire system. It can also dynamically select the most suitable target ECU among multiple ECUs to perform tasks, thereby improving the execution effect of the service.
[0080] S30. Dynamically generate configuration information.
[0081] The target ECU responds to the execution request of the target diagnostic service sent by the diagnostic client, collects the data of the vehicle sensor, determines the current state of the vehicle through the data of the vehicle sensor, determines the configuration information of the target diagnostic service according to the current state, and then returns the configuration information to the diagnostic client. In this embodiment, the configuration information is returned to the diagnostic client to ensure that the configuration information between the diagnostic client and the target ECU is consistent, avoiding execution errors or conflicts caused by inconsistent configuration information.
[0082] S40: The configuration information is sent to the target ECU, and the target ECU executes the target diagnosis service.
[0083] The diagnostic client sends the execution instruction (including configuration information and target diagnostic service indication information, such as the name of the target diagnostic service) to the target ECU through the diagnostic protocol.
[0084] The target ECU receives the configuration information from the diagnostic client, parses and applies the diagnostic configuration. For example, the target ECU adjusts its internal diagnostic logic based on the received session mode, sampling frequency and diagnostic depth. After the target ECU applies the diagnostic configuration, it starts to perform the corresponding diagnostic test. For example, it performs fault detection of engine components based on the configuration information. After the diagnostic test is completed, the target ECU sends the diagnostic results back to the diagnostic client. The diagnostic client determines whether other actions need to be taken based on the results, such as generating a fault report or triggering other diagnostic operations.
[0085] The present application also provides an automobile diagnostic device, which is deployed in the ECU, see Figure 4 , including: a dynamic configuration management module 40, a diagnostic service module 41 and a communication management module 42.
[0086] The dynamic configuration management module 40 is used to obtain the current state of the vehicle in response to the execution request of the target diagnostic service sent by the diagnostic client; and determine the configuration information of the target diagnostic service according to the current state. The diagnostic service module 41 is used to execute the target diagnostic service according to the configuration information. The communication management module 42 is used to feed back the diagnostic result of the target diagnostic service to the diagnostic client. The communication management module 42 is also used to receive the execution request of the target diagnostic service sent by the diagnostic client and send it to the dynamic configuration management module 40.
[0087] Optional, see Figure 5 The system also includes a dynamic service discovery module 43, which is used to broadcast the information of the first diagnostic service provided locally to other ECUs through the first registration information, and receive the second registration information broadcast by other ECUs, wherein the second registration information includes the information of the second diagnostic service provided by other ECUs; and record the information of the second diagnostic service into the diagnostic service database.
[0088] Optionally, the dynamic service discovery module 43 is also used to respond to a diagnostic service discovery request sent by the diagnostic client, and to feedback locally provided first diagnostic service set information to the diagnostic client, so that the diagnostic client can select a target diagnostic service from the first diagnostic service set information, wherein the first diagnostic service set information includes information of the locally provided first diagnostic service.
[0089] Optionally, the dynamic service discovery module 43 is also used to construct a service deregistration message and broadcast it to the vehicle network when the diagnostic service needs to be deregistered, so as to ensure timely updating of the diagnostic service database.
[0090] Optionally, the communication management module 42 is responsible for transmitting various information in the entire device, including registration information, service discovery requests and responses, service execution requests and diagnostic results, etc. The communication management module 42 selects a suitable route according to the information to be transmitted, and forwards the information to the target ECU or diagnostic client to ensure the smooth execution of the diagnostic service.
[0091] The present application also provides an automobile diagnostic system. Figure 1 , including: a diagnostic client and at least one electronic controller ECU. The diagnostic client is used to send an execution request of a target diagnostic service to a target ECU in at least one ECU; the target ECU is used to obtain the current state of the vehicle; determine the configuration information of the target diagnostic service according to the current state; execute the target diagnostic service according to the configuration information; and feed back the diagnostic result of the target diagnostic service to the diagnostic client.
[0092] Optionally, before sending an execution request for a target diagnostic service to a target ECU in at least one ECU, the diagnostic client is further used to: send a discovery request for a diagnostic service to at least one ECU, and receive diagnostic service set information fed back by at least one ECU; select a target diagnostic service from the diagnostic service set information; and determine a target ECU that supports the target diagnostic service based on the performance of more than two ECUs;
[0093] Among them, selecting the target diagnostic service from the diagnostic service set information includes: obtaining the priority of each diagnostic service in the diagnostic service set information, and the matching of each diagnostic service with the discovery request; and selecting the target diagnostic service from the diagnostic service set information according to the priority and matching of each diagnostic service.
[0094] Optionally, the target ECU is used to execute at least one of the first process and the second process before obtaining the current state of the vehicle in response to the execution request of the target diagnostic service sent by the diagnostic client:
[0095] The first process includes: broadcasting information of a first diagnostic service provided locally to other ECUs through first registration information, and receiving second registration information broadcasted by other ECUs, wherein the second registration information includes information of a second diagnostic service provided by other ECUs; and recording the information of the second diagnostic service into a diagnostic service database;
[0096] The second process includes: in response to a diagnostic service discovery request sent by a diagnostic client, feeding back locally provided first diagnostic service set information to the diagnostic client so that the diagnostic client can select a target diagnostic service from the first diagnostic service set information, wherein the first diagnostic service set information includes information of the locally provided first diagnostic service.
[0097] Optionally, when the target ECU obtains the current state of the vehicle in response to the execution request of the target diagnostic service sent by the diagnostic client, it is specifically used to: collect data from vehicle sensors in response to the execution request of the target diagnostic service sent by the diagnostic client; preprocess the data from the vehicle sensors and determine the operating state parameters of the vehicle based on the preprocessing results; and determine the current state of the vehicle based on the operating state parameters.
[0098] Optionally, when the target ECU determines the configuration information of the target diagnostic service based on the current state, it is specifically used to: determine the diagnostic requirements of the vehicle based on the current state; determine the priority and resource allocation of each sub-service under the target diagnostic service based on the diagnostic requirements; determine the diagnostic parameter configuration information based on the type of the current state, and the diagnostic parameter configuration information includes at least one of a session mode, a sampling frequency and a diagnostic depth.
[0099] Optionally, when the target ECU determines the diagnostic parameter configuration information according to the type of the current state, it is specifically used to perform at least one operation: if the current state is the normal state, the session mode is the single session mode, the sampling frequency is the first sampling frequency, and the diagnostic depth is the first diagnostic depth; if the current state is the warning state, the session mode is the continuous session mode, the sampling frequency is the second sampling frequency, and the diagnostic depth is the second diagnostic depth; if the current state is the fault state, the session mode is the emergency session mode, the sampling frequency is the third sampling frequency, and the diagnostic depth is the third diagnostic depth; wherein, the third sampling frequency>the second sampling frequency>the first sampling frequency, and the third diagnostic depth>the second diagnostic depth>the first diagnostic depth.
[0100] The embodiment of the present application obtains the current status of the vehicle in real time, dynamically adjusts the configuration of the target diagnostic service according to the current status of the vehicle, obtains the configuration information of the target diagnostic service, and executes the target diagnostic service according to the configuration information. It can quickly respond to new needs for vehicle diagnosis, adjust the configuration of the diagnostic service according to different states, make the diagnostic service more targeted, improve the accuracy of diagnosis, and improve the performance and efficiency of the diagnostic system under various working conditions.
[0101] It should be noted that the terms used in this application are only for describing specific embodiments, rather than limiting the scope of this application. As shown in the specification of this application, unless the context clearly indicates an exception, the words "one", "a", "a kind of" and / or "the" do not specifically refer to the singular, but may also include the plural. The terms "include", "comprise" or any other variant thereof are intended to cover non-exclusive inclusion, so that the process, method or device including a series of elements includes not only those elements, but also includes other elements not explicitly listed, or also includes elements inherent to such process, method or device. In the absence of more restrictions, the elements defined by the sentence "include one..." do not exclude the presence of other identical elements in the process, method or device including the elements.
[0102] It should also be noted that the terms "center", "up", "down", "left", "right", "vertical", "horizontal", "inside", "outside", etc., indicating the orientation or position relationship, are based on the orientation or position relationship shown in the drawings, and are only for the convenience of describing the present application and simplifying the description, and do not indicate or imply that the device or element referred to must have a specific orientation, be constructed and operated in a specific orientation, and therefore cannot be understood as a limitation on the present application. Unless otherwise clearly specified and limited, the terms "installed", "connected", "connected", etc. should be understood in a broad sense, for example, it can be a fixed connection, a detachable connection, or an integral connection; it can be a mechanical connection or an electrical connection; it can be a direct connection, or it can be an indirect connection through an intermediate medium, or it can be a connection between the two elements. For those of ordinary skill in the art, the specific meanings of the above terms in this application can be understood according to specific circumstances.
[0103] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present application, rather than to limit it. Although the present application has been described in detail with reference to the aforementioned embodiments, those skilled in the art should understand that they can still modify the technical solutions described in the aforementioned embodiments, or replace some or all of the technical features therein with equivalents. However, these modifications or replacements do not deviate the essence of the corresponding technical solutions from the technical solutions of the embodiments of the present application.
Claims
1. A method for diagnosing an automobile, characterized in that: include: In response to an execution request of a target diagnostic service sent by a diagnostic client, a current state of the vehicle is acquired; the types of the current state include a normal state, a warning state, and a fault state; Determining configuration information of the target diagnostic service according to the current state; Execute the target diagnostic service according to the configuration information, and feed back the diagnostic result of the target diagnostic service to the diagnostic client; Determining configuration information of the target diagnostic service according to the current state includes: determining a diagnostic need for the vehicle based on the current state; Determine the priority and resource allocation of each sub-service under the target diagnostic service according to the diagnostic requirements; The diagnostic parameter configuration information is determined according to the type of the current state, and the diagnostic parameter configuration information includes at least one of a session mode, a sampling frequency, and a diagnostic depth.
2. The vehicle diagnostic method according to claim 1, characterized in that: Before obtaining the current state of the vehicle in response to the execution request of the target diagnostic service sent by the diagnostic client, the automobile diagnostic method further includes executing at least one of the first process and the second process: The first process includes: broadcasting information of a first diagnostic service provided locally to other ECUs through first registration information, and receiving second registration information broadcasted by other ECUs, wherein the second registration information includes information of a second diagnostic service provided by the other ECUs; and recording the information of the second diagnostic service into a diagnostic service database; The second process includes: in response to a discovery request for a diagnostic service sent by the diagnostic client, feeding back locally provided first diagnostic service set information to the diagnostic client, so that the diagnostic client can select the target diagnostic service from the first diagnostic service set information, wherein the first diagnostic service set information includes information of the locally provided first diagnostic service.
3. The vehicle diagnostic method according to claim 1, characterized in that: The step of obtaining the current state of the vehicle in response to the execution request of the target diagnostic service sent by the diagnostic client includes: In response to an execution request of a target diagnostic service sent by the diagnostic client, collecting data from vehicle sensors; Preprocessing the data of the vehicle sensor and determining the operating state parameters of the vehicle according to the preprocessing results; The current state of the vehicle is determined based on the operating state parameter.
4. The vehicle diagnostic method according to claim 1, characterized in that: Determining the diagnostic parameter configuration information according to the type of the current state includes at least one of the following operations: If the current state is the normal state, the session mode is a single session mode, the sampling frequency is a first sampling frequency, and the diagnostic depth is a first diagnostic depth; If the current state is the warning state, the session mode is the continuous session mode, the sampling frequency is the second sampling frequency, and the diagnostic depth is the second diagnostic depth; If the current state is the fault state, the session mode is the emergency session mode, the sampling frequency is the third sampling frequency, and the diagnostic depth is the third diagnostic depth; Among them, the third sampling frequency>the second sampling frequency>the first sampling frequency, and the third diagnostic depth>the second diagnostic depth>the first diagnostic depth.
5. An automobile diagnostic system, characterized in that: include: A diagnostic client and at least one electronic control unit ECU; A diagnostic client, used to send an execution request of a target diagnostic service to a target ECU in at least one ECU; The target ECU is used to obtain the current state of the vehicle, the types of the current state include normal state, warning state and fault state; and determine the configuration information of the target diagnostic service according to the current state; Execute the target diagnostic service according to the configuration information; and feeding back the diagnostic result of the target diagnostic service to the diagnostic client; Determining configuration information of the target diagnostic service according to the current state includes: determining a diagnostic need for the vehicle based on the current state; Determine the priority and resource allocation of each sub-service under the target diagnostic service according to the diagnostic requirements; The diagnostic parameter configuration information is determined according to the type of the current state, and the diagnostic parameter configuration information includes at least one of a session mode, a sampling frequency, and a diagnostic depth.
6. The system according to claim 5, characterized in that Before sending a request for executing a target diagnostic service to a target ECU in at least one ECU, the diagnostic client is further configured to: Sending a discovery request for a diagnostic service to the at least one ECU, and receiving diagnostic service set information fed back by the at least one ECU; Selecting a target diagnostic service from the diagnostic service set information; Determining a target ECU supporting the target diagnostic service according to performances of the two or more ECUs; Wherein, selecting a target diagnostic service from the diagnostic service set information includes: Obtaining the priority of each diagnostic service in the diagnostic service set information, and the matching of each diagnostic service with the discovery request; A target diagnostic service is selected from the diagnostic service set information according to the priorities and compatibility of the diagnostic services.
7. An automobile diagnostic device, characterized in that: include: A dynamic configuration management module, configured to obtain a current state of the vehicle in response to an execution request of a target diagnostic service sent by a diagnostic client, wherein the types of the current state include a normal state, a warning state, and a fault state; Determining configuration information of the target diagnostic service according to the current state; Determining configuration information of the target diagnostic service according to the current state includes: determining a diagnostic requirement of the vehicle according to the current state; determining a priority and resource configuration of each sub-service under the target diagnostic service according to the diagnostic requirement; determining diagnostic parameter configuration information according to the type of the current state, the diagnostic parameter configuration information including at least one of a session mode, a sampling frequency, and a diagnostic depth; A diagnostic service module, used to perform a target diagnostic service according to the configuration information; The communication management module is used to feed back the diagnosis result of the target diagnosis service to the diagnosis client.
8. The device according to claim 7, characterized in that Also includes: A dynamic service discovery module is used to broadcast information of a first diagnostic service provided locally to other ECUs through first registration information, and receive second registration information broadcast by other ECUs, wherein the second registration information includes information of a second diagnostic service provided by the other ECUs; and record the information of the second diagnostic service in a diagnostic service database.
Citation Information
Patent Citations
Vehicle remote diagnosis method, electronic equipment and computer readable storage medium
CN118915580A