Automatic reporting method, device and related equipment for vehicle diagnostic logs
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2026-06-24
- Publication Date
- 2026-08-14
AI Technical Summary
[0005]有鉴于此,本发明实施例提供一种车辆诊断日志自动上报方法、装置及相关设备,以解决现有技术中诊断失败时日志手动反馈步骤繁琐、易出错、效率低的问题
[0040]基于上述本发明实施例提供的一种车辆诊断日志自动上报方法、装置及相关设备,适用于诊断仪。向车辆电子控制单元发送诊断请求;接收车辆电子控制单元返回的诊断响应;若诊断响应为否定响应,则解析否定响应,得到对应的服务标识,并累计服务标识相应的否定响应次数;若累计的否定响应次数达到服务标识对应的预设触发阈值,则收集当前诊断会话的日志信息并上传至服务器。通过自动识别诊断否定响应及其服务标识,并根据服务标识所属反馈等级对应的触发阈值自动触发日志收集上传,实现用户无感知的自动化反馈,提升反馈效率与数据准确性;同时兼容多种通信协议,适用场景广,支持开发人员基于自动上报数据快速复现问题、发布更新,持续提升诊断仪软件质量。
Smart Images

Figure CN122569331A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of automotive electronics and fault diagnosis technology, and in particular to a method, device and related equipment for automatic reporting of vehicle diagnostic logs. Background Technology
[0002] With the increasing complexity of automotive Electronic Control Units (ECUs), diagnostic tools, as crucial tools for vehicle troubleshooting, are widely used in after-sales repair and development testing. When a diagnostic tool fails to perform a diagnostic function, current technology typically employs manual intervention to collect fault information. Specifically, the customer needs to manually enter the problem type, problem description, and the mobile phone number of the person providing feedback on the diagnostic tool's application interface, and manually select the corresponding log file from local storage. After the device is connected to the internet, an upload operation is performed, sending the data to the company's server. Developers then download these log files from the server to their local environment for subsequent problem reproduction and root cause analysis.
[0003] However, this operation mode based on manual form filling and log selection has obvious shortcomings: First, the entire process requires customers to perform multiple steps, which is cumbersome and time-consuming, especially in scenarios where diagnostic failures occur frequently or batch testing occurs, resulting in low efficiency; Second, manually filling in descriptive information and selecting log files is prone to human errors, such as missing information, inaccurate descriptions, or selecting the wrong logs, making it difficult for developers to accurately locate the problem; Third, this process requires a high degree of cooperation and operational proficiency from the customer, resulting in a poor user experience.
[0004] Therefore, simplifying the fault log reporting process and improving the accuracy and efficiency of data collection are urgent technical problems to be solved in the current development of diagnostic tools. Summary of the Invention
[0005] In view of this, embodiments of the present invention provide a method, apparatus and related equipment for automatic reporting of vehicle diagnostic logs, in order to solve the problems of cumbersome, error-prone and inefficient manual log feedback steps when diagnostic failure occurs in the prior art.
[0006] To achieve the above objectives, the embodiments of the present invention provide the following technical solutions:
[0007] The first aspect of this invention discloses a method for automatically reporting vehicle diagnostic logs, applicable to diagnostic instruments, the method comprising:
[0008] Send a diagnostic request to the vehicle's electronic control unit;
[0009] Receive the diagnostic response returned by the vehicle electronic control unit based on the diagnostic request;
[0010] If the diagnostic response is a negative response, then the negative response is parsed to obtain the service identifier corresponding to the negative response, and the number of negative responses corresponding to the service identifier is accumulated;
[0011] Determine whether the cumulative number of negative responses has reached the preset trigger threshold corresponding to the service identifier;
[0012] If the condition is met, the log information of the current diagnostic session is collected and uploaded to the server.
[0013] Preferably, parsing the negative response to obtain the service identifier corresponding to the negative response includes:
[0014] Identify the negative response identifier in the negative response;
[0015] Extract the first byte following the negative response identifier as the service identifier.
[0016] Preferably, before determining whether the cumulative number of negative responses has reached the preset trigger threshold corresponding to the service identifier, the method further includes:
[0017] Based on the feedback level to which the service identifier belongs, query the preset trigger threshold corresponding to the feedback level; wherein, different feedback levels correspond to different preset trigger thresholds.
[0018] Preferably, the step of querying the preset trigger threshold corresponding to the feedback level based on the feedback level to which the service identifier belongs includes:
[0019] If the feedback level to which the service identifier belongs is the normal feedback level, then the preset trigger threshold corresponding to the feedback level is 3 times;
[0020] If the feedback level to which the service identifier belongs is medium, then the preset trigger threshold corresponding to the feedback level is 2 times.
[0021] If the feedback level to which the service identifier belongs is a high feedback level, then the preset trigger threshold corresponding to the feedback level is 1 time.
[0022] Preferably, the collection of log information for the current diagnostic session includes:
[0023] Obtain the vehicle identification number, vehicle model, and currently executed function menu name, as well as the original data frame recording the negative response;
[0024] The vehicle identification number, the vehicle model, the function menu name, and the raw data frame are integrated into the log information of the current diagnostic session.
[0025] Preferably, before uploading the log information to the server, the method further includes:
[0026] Check the current network connection status;
[0027] If a network connection is detected, the log information is uploaded to the server;
[0028] If no network connection is detected, the log information is stored locally, and the process returns to the step of detecting the current network connection status.
[0029] A second aspect of this invention discloses an automatic vehicle diagnostic log reporting device, applicable to diagnostic instruments, the device comprising:
[0030] The transmitting unit is used to send diagnostic requests to the vehicle's electronic control unit;
[0031] A receiving unit is configured to receive a diagnostic response returned by the vehicle electronic control unit based on the diagnostic request;
[0032] The parsing unit is configured to, if the diagnostic response is a negative response, parse the negative response to obtain the service identifier corresponding to the negative response, and accumulate the number of negative responses corresponding to the service identifier;
[0033] The judgment unit is used to determine whether the cumulative number of negative responses has reached the preset trigger threshold corresponding to the service identifier;
[0034] An upload unit is used to collect log information of the current diagnostic session and upload the log information to the server if the condition is met.
[0035] Preferably, the parsing unit includes:
[0036] The identification module is used to identify the negative response identifier in the negative response;
[0037] The extraction module is used to extract the first byte after the negative response identifier as the service identifier.
[0038] The third aspect of the present invention discloses a computer-readable storage medium having a computer program stored thereon, wherein the computer program, when executed by a processor, implements the automatic reporting method for vehicle diagnostic logs disclosed in the first aspect of the present invention.
[0039] The fourth aspect of this invention discloses an electronic device, including a memory, a processor, and a computer program stored in the memory, wherein the processor executes the computer program to implement the automatic reporting method for vehicle diagnostic logs disclosed in the first aspect of this invention.
[0040] The present invention provides an automatic vehicle diagnostic log reporting method, apparatus, and related equipment, applicable to diagnostic instruments. The method involves sending a diagnostic request to the vehicle's electronic control unit (ECU); receiving a diagnostic response from the ECU; parsing a negative response to obtain its corresponding service identifier and accumulating the number of negative responses corresponding to that service identifier; and collecting and uploading the log information of the current diagnostic session to a server if the accumulated number of negative responses reaches a preset trigger threshold corresponding to the service identifier. By automatically identifying the diagnostic negative response and its service identifier, and automatically triggering log collection and uploading based on the trigger threshold corresponding to the feedback level of the service identifier, the invention achieves seamless automated feedback for the user, improving feedback efficiency and data accuracy. It is also compatible with multiple communication protocols, has a wide range of applications, and supports developers in quickly reproducing problems and releasing updates based on automatically reported data, continuously improving the quality of the diagnostic instrument software. Attached Figure Description
[0041] To more clearly illustrate the technical solutions in the embodiments of the present invention or the prior art, the drawings used in the description of the embodiments or the prior art will be briefly introduced below. Obviously, the drawings described below are only embodiments of the present invention. For those skilled in the art, other drawings can be obtained based on the provided drawings without creative effort.
[0042] Figure 1 A flowchart of a method for automatically reporting vehicle diagnostic logs provided in an embodiment of the present invention;
[0043] Figure 2 A flowchart of the hierarchical triggering mechanism provided in an embodiment of the present invention;
[0044] Figure 3 This is a structural block diagram of a vehicle diagnostic log automatic reporting device provided in an embodiment of the present invention;
[0045] Figure 4 This is a schematic diagram of the structure of an electronic device provided in an embodiment of the present invention. Detailed Implementation
[0046] The technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.
[0047] In this application, the terms "comprising," "including," or any other variations thereof are intended to cover a non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements includes not only those elements but also other elements not expressly listed, or elements inherent to such a process, method, article, or apparatus. Without further limitation, an element defined by the phrase "comprising one..." does not exclude the presence of other identical elements in the process, method, article, or apparatus that includes said element.
[0048] As the background technology shows, existing diagnostic instrument log reporting requires customers to manually fill in problem information and select local log upload, which has the drawbacks of being cumbersome to operate, prone to human error, and demanding on customers, resulting in a poor user experience and affecting the efficiency of problem localization.
[0049] Therefore, embodiments of the present invention provide a method, apparatus, and related equipment for automatically reporting vehicle diagnostic logs, applicable to diagnostic instruments. The method involves sending a diagnostic request to the vehicle's electronic control unit (ECU); receiving a diagnostic response from the ECU; if the diagnostic response is negative, parsing the negative response to obtain the corresponding service identifier, and accumulating the number of negative responses corresponding to the service identifier; if the accumulated number of negative responses reaches a preset trigger threshold corresponding to the service identifier, collecting the log information of the current diagnostic session and uploading it to a server. By automatically identifying diagnostic negative responses and their service identifiers, and automatically triggering log collection and uploading according to the trigger threshold corresponding to the feedback level of the service identifier, user-unobtrusive automated feedback is achieved, improving feedback efficiency and data accuracy; it is also compatible with multiple communication protocols, has a wide range of applicable scenarios, and supports developers in quickly reproducing problems and releasing updates based on automatically reported data, continuously improving the quality of diagnostic instrument software.
[0050] See Figure 1 The diagram illustrates a flowchart of an automatic vehicle diagnostic log reporting method provided by an embodiment of the present invention. This method is applied to a diagnostic instrument and includes:
[0051] It should be noted that common data communication protocols used for communication between diagnostic tools and automobiles include Keyword Protocol 2000 (KWP2000), Controller Area Network (CAN), and Diagnostic over Internet Protocol (DoIP). This embodiment uses the CAN protocol as an example, which is compatible with ISO 14229 Unified Diagnostic Services (UDS) and ISO 15765-2 CAN Transport Protocol (CAN-TP), enabling segmented transmission and reassembly of long messages, and adapting to the interaction of 8-byte single-frame and multi-frame diagnostic messages.
[0052] Step S101: Send a diagnostic request to the vehicle's electronic control unit.
[0053] In the specific implementation of step S101, the diagnostic tool sends a diagnostic request to the vehicle's electronic control unit (ECU).
[0054] It should be noted that the diagnostic request includes a Service Identifier (SID), and the diagnostic request follows the UDS protocol format.
[0055] Step S102: Receive the diagnostic response returned by the vehicle electronic control unit based on the diagnostic request.
[0056] In the specific implementation of step S102, the diagnostic instrument receives the diagnostic response returned by the vehicle's electronic control unit based on the diagnostic request.
[0057] It should be noted that, according to the UDS protocol, a positive response (positive response) is formatted as 0x40 + request SID + parameters, indicating that the diagnostic request was executed successfully; a negative response (negative response) is formatted as 0x7F + request SID + negative response code (NRC), indicating that the diagnostic request was executed unsuccessfully.
[0058] Understandably, NRC is used to identify the reason for failure, such as 0x11 Service not supported, 0x22 Condition not met, 0x31 Request out of bounds, 0x33 Security access denied, etc.
[0059] For example, for Service ID 14 (clear fault code information), the diagnostic tool sends the data "14 00 00" to the vehicle. The vehicle's electronic control unit returns a positive response "54 00 00" indicating that the function was executed successfully, and a negative response "7F 14 22" indicating that the function was executed failed.
[0060] Step S103: If the diagnostic response is a negative response, then parse the negative response to obtain the service identifier corresponding to the negative response, and accumulate the number of negative responses corresponding to the service identifier.
[0061] In the specific implementation of step S103, if the diagnostic response is a negative response, the negative response identifier in the negative response is identified; the first byte after the negative response identifier is extracted as the service identifier, and the number of negative responses corresponding to the service identifier is accumulated.
[0062] It should be noted that a negative response means that the first byte of the response data is 0x7F.
[0063] For example, for the negative response "7F 14 22", the extracted service identifier is 0x14. Subsequently, the number of negative responses corresponding to this service identifier 0x14 is accumulated. Each time a negative response with the same service identifier is received, the count is incremented by 1.
[0064] It should be added that different service identifiers are pre-classified into different feedback levels. In actual application, based on the feedback level to which the service identifier belongs, the preset trigger threshold corresponding to that feedback level is queried; different feedback levels correspond to different preset trigger thresholds.
[0065] Combination Figure 2 As shown, if the feedback level of the service identifier is the normal feedback level, then the preset trigger threshold for the feedback level is 3 times.
[0066] For example, the normal feedback level includes Service ID 0x19 (Read fault code information), whose core diagnostic function is to read the current fault code, historical fault code, fault code status and environmental snapshot data; 0x14 (Clear diagnostic information), whose core diagnostic function is to perform a code clearing operation to clear fault codes, freeze frames and other diagnostic data stored in the ECU; and 0x22 (Read data via data ID), whose core diagnostic function is to read sensor data streams, ECU version, vehicle configuration parameters and other data.
[0067] These service IDs perform basic diagnostic functions, such as reading codes, clearing codes, and reading data streams. The corresponding preset trigger threshold is 3 times. That is, when the cumulative negative response of the same service ID reaches 3 times, automatic feedback is triggered.
[0068] Combination Figure 2As shown, if the feedback level of the service identifier is medium, the preset trigger threshold for the feedback level is 2 times.
[0069] For example, medium feedback levels include Service ID 0x2E (writing data via data ID), whose core diagnostic function is writing calibration parameters, configuration information, and vehicle personalization settings; 0x2F (input / output control), whose core diagnostic function is performing action tests and forcibly driving actuators (such as relays, motors, and lights); and 0x31 (routine program control), whose core diagnostic function is triggering routine operations such as ECU self-test, sensor calibration, and component function tests.
[0070] These service IDs perform special diagnostic functions, such as writing data to the ECU, performing action tests, and triggering ECU self-tests. The preset trigger threshold is 2 times. That is, when the number of negative responses from the same service ID reaches 2 times, automatic feedback is triggered.
[0071] Combination Figure 2 If the service identifier belongs to a high feedback level, the preset trigger threshold for that feedback level is 1 time.
[0072] For example, the high-level feedback includes service ID 0x34 (Request Download), whose core diagnostic function is to initiate an ECU software / data download request, specify the target memory address, data length and format, and establish a data transmission channel to prepare for subsequent flashing and program upgrades; 0x36 (Transmit Data), whose core diagnostic function is to transmit large amounts of information such as ECU upgrade firmware and calibration data in blocks based on the transmission channel established by 0x34, supporting continuous data block transmission and ensuring data transmission integrity; and 0x37 (Request Exit Transmission), whose core diagnostic function is to terminate the data transmission session established by 0x34 / 0x36, release the memory channel, verify the transmission results, complete the data download / flashing process, and restore the ECU to its normal diagnostic state.
[0073] These service IDs perform advanced flashing functions, rewriting vehicle data for purposes such as ECU software upgrades and calibration data writing. The corresponding preset trigger threshold is 1 time. That is, when the cumulative negative response for the same service ID reaches 1 time, automatic feedback is triggered.
[0074] Understandably, a threshold for the number of log reports was set to avoid excessive load on the backend server due to frequent diagnostic log reporting, while also ensuring the rational utilization of storage resources. This threshold aims to balance system performance with the needs of problem diagnosis. In practical applications, this threshold can be flexibly adjusted based on server load, storage capacity, and the actual needs of problem diagnosis to ensure efficient system operation and proper data storage.
[0075] Step S104: Determine whether the cumulative number of negative responses has reached the preset trigger threshold corresponding to the service identifier.
[0076] In the specific implementation of step S104, the current cumulative number of negative responses is compared with the preset trigger threshold corresponding to the feedback level of the service identifier. If the cumulative number of negative responses reaches the preset trigger threshold corresponding to the service identifier, then step S105 is executed; if the cumulative number of negative responses does not reach the preset trigger threshold corresponding to the service identifier, then subsequent diagnostic responses are monitored.
[0077] Step S105: If the condition is met, collect the log information of the current diagnostic session and upload the log information to the server.
[0078] In the specific implementation step S105, if the cumulative number of negative responses reaches the preset trigger threshold corresponding to the service identifier, the log information of the current diagnostic session is collected, including: obtaining the Vehicle Identification Number (VIN), vehicle model, and currently executed function menu name, as well as the original data frame recording the negative response; the VIN, vehicle model, function menu name, and original data frame are integrated into the log information of the current diagnostic session. Then, the log information is fed back.
[0079] In some specific embodiments, the content fed back to the server also includes, but is not limited to, information such as the name of the diagnostic instrument's function menu, so that development engineers can simulate and reproduce the problem.
[0080] In practical applications, before uploading log information to the server, the process includes: detecting the current network connection status; if a network connection is detected, the log information is uploaded to the server; if a network connection is detected, the log information is stored locally, and the system returns to continue detecting the current network connection status, automatically uploading it when a network connection is established.
[0081] Understandably, after the log information is uploaded to the backend server, an alarm mechanism will be triggered first, and a dedicated team of diagnostic engineers will follow up and handle it in real time: First, the uploaded logs are cleaned and verified, and basic information such as the corresponding vehicle's VIN code, model configuration, hardware version, and production batch is associated to reconstruct the complete triggering scenario of the fault. Then, the cause of the error is located through reproduction testing, message comparison, and root cause analysis model. If it is an ECU firmware defect, a repair solution is output and a corresponding firmware update package is released. If it is a logic problem of the diagnostic tool itself, the diagnostic tool version is iterated. Finally, the repair solution is automatically pushed to the corresponding vehicle or diagnostic equipment to complete the problem loop. At the same time, the fault cases are also accumulated in the knowledge base to provide support for the rapid location of similar problems in the future.
[0082] It should be noted that the fully closed-loop automatic feedback mechanism designed in this embodiment of the invention is not limited to the CAN bus communication scenario used in the embodiment. It is also compatible with other mainstream vehicle data communication protocols, including but not limited to KWP2000 (commonly known as the K protocol) commonly used in vehicle diagnostics, the Ethernet-based DoIP diagnostic protocol, and diagnostic scenarios corresponding to vehicle bus communication protocols such as LIN and FlexRay. For different protocols, only minor adaptation adjustments are needed to the underlying log collection and message parsing. The complete process logic of automatic upload triggering, background analysis, and repair solution push at the upper layer can be fully reused, which can cover the diagnostic needs of different vehicle types such as passenger cars, commercial vehicles, and intelligent connected vehicles, significantly reducing the adaptation and development costs for multi-protocol and multi-vehicle scenarios.
[0083] In this embodiment of the invention, by automatically identifying diagnostic negative responses and their service identifiers, and automatically accumulating the number of triggers, collecting and uploading trigger logs according to the trigger threshold corresponding to the feedback level of the service identifier, automated feedback without the user's awareness is achieved, significantly improving feedback efficiency and data accuracy. At the same time, the hierarchical triggering mechanism ensures timely reporting when critical operations fail, while effectively reducing server load and storage pressure. In addition, the network detection and local temporary storage mechanism for resuming transmission after network outages ensures that logs are not lost, and it is compatible with multiple communication protocols such as CAN, K, and DoIP, making it widely applicable. Developers can quickly reproduce problems and release software updates in a timely manner based on the automatically reported vehicle VIN code, model, function menu name, and original negative response data frame, thereby continuously improving the software quality and reliability of the diagnostic instrument.
[0084] Corresponding to the automatic reporting method for vehicle diagnostic logs provided in the above embodiments of the present invention, see also... Figure 3 The diagram shows a structural block diagram of an automatic vehicle diagnostic log reporting device provided in an embodiment of the present invention.
[0085] The device includes: a sending unit 301, a receiving unit 302, a parsing unit 303, a judging unit 304, and an uploading unit 305.
[0086] The sending unit 301 is used to send a diagnostic request to the vehicle's electronic control unit.
[0087] The receiving unit 302 is used to receive the diagnostic response returned by the vehicle electronic control unit based on the diagnostic request.
[0088] The parsing unit 303 is used to parse the negative response if the diagnostic response is a negative response, obtain the service identifier corresponding to the negative response, and accumulate the number of negative responses corresponding to the service identifier.
[0089] The judgment unit 304 is used to determine whether the cumulative number of negative responses has reached the preset trigger threshold corresponding to the service identifier.
[0090] Upload unit 305 is used to collect the log information of the current diagnostic session and upload the log information to the server if the condition is met.
[0091] In this embodiment of the invention, by automatically identifying diagnostic negative responses and their service identifiers, and automatically accumulating the number of triggers, collecting and uploading trigger logs according to the trigger threshold corresponding to the feedback level of the service identifier, automated feedback without the user's awareness is achieved, significantly improving feedback efficiency and data accuracy. At the same time, the hierarchical triggering mechanism ensures timely reporting when critical operations fail, while effectively reducing server load and storage pressure. In addition, the network detection and local temporary storage mechanism for resuming transmission after network outages ensures that logs are not lost, and it is compatible with multiple communication protocols such as CAN, K, and DoIP, making it widely applicable. Developers can quickly reproduce problems and release software updates in a timely manner based on the automatically reported vehicle VIN code, model, function menu name, and original negative response data frame, thereby continuously improving the software quality and reliability of the diagnostic instrument.
[0092] Combination Figure 3 The content shown is parsing unit 303, which includes: recognition module and extraction module.
[0093] The identification module is used to identify the negative response identifier in the negative response.
[0094] The extraction module is used to extract the first byte after the negative response identifier as the service identifier.
[0095] Combination Figure 3 The device also includes a query unit, which queries a preset trigger threshold corresponding to the feedback level based on the feedback level to which the service identifier belongs; wherein different feedback levels correspond to different preset trigger thresholds.
[0096] Combination Figure 3 The displayed content, query unit, includes: normal level module, medium level module and high level module.
[0097] The normal level module is used to set the preset trigger threshold of 3 times if the feedback level to which the service identifier belongs is normal feedback level.
[0098] The medium-level module is used to set the preset trigger threshold to 2 times if the feedback level to which the service identifier belongs is medium.
[0099] The advanced level module is used to set the preset trigger threshold to 1 time if the feedback level to which the service identifier belongs is advanced.
[0100] Combination Figure 3 The content shown, upload unit 305, includes: acquisition module and integration module.
[0101] The acquisition module is used to acquire the vehicle identification number, vehicle model, and name of the currently executed function menu, as well as the raw data frame that records the negative response.
[0102] The integration module is used to integrate vehicle identification numbers, vehicle models and function menu names, as well as raw data frames, into log information for the current diagnostic session.
[0103] Combination Figure 3 As shown, the device also includes: a monitoring unit, a network uploading unit, and a storage unit.
[0104] The monitoring unit is used to detect the current network connection status.
[0105] The network upload unit is used to upload log information to the server if a network connection is detected.
[0106] The storage unit is used to store log information locally if no network connection is detected, and then return it to the execution monitoring unit.
[0107] Another embodiment of this application provides an electronic device, such as... Figure 4 As shown, it includes: memory 401 and processor 402.
[0108] Among them, memory 401 is used to store computer programs.
[0109] The processor 402 is used to execute a computer program, which, when executed, is specifically used to implement a vehicle diagnostic log automatic reporting method as provided in any of the above embodiments.
[0110] The electronic devices mentioned in this article can be servers, PCs, tablets, mobile phones, ECUs (Electronic Control Units), VCUs (Vehicle Control Units), MCUs (Micro Controller Units), HCUs (Hybrid Control Units), etc.
[0111] Another embodiment of this application provides a computer-readable storage medium for storing a computer program, which, when executed by a processor, is used to implement a vehicle diagnostic log automatic reporting method as provided in any of the above embodiments.
[0112] Computer-readable storage media include both permanent and non-permanent, removable and non-removable media that can store information by any method or technology. Information can be computer-readable instructions, data structures, program modules, or other data. Examples of computer storage media include, but are not limited to, phase-change memory (PRAM), static random access memory (SRAM), dynamic random access memory (DRAM), other types of random access memory (RAM), read-only memory (ROM), electrically erasable programmable read-only memory (EEPROM), flash memory or other memory technologies, CD-ROM, digital versatile optical disc (DVD) or other optical storage, magnetic tape, magnetic tape, disk storage or other magnetic storage devices, or any other non-transferable medium that can be used to store information accessible by a computing device. As defined herein, computer-readable media does not include transient computer-readable media, such as modulated data signals and carrier waves.
[0113] The various embodiments in this specification are described in a progressive manner. Similar or identical parts between embodiments can be referred to mutually. Each embodiment focuses on describing the differences from other embodiments. In particular, for system or system embodiments, since they are basically similar to method embodiments, the description is relatively simple, and relevant parts can be referred to the descriptions in the method embodiments. The systems and system embodiments described above are merely illustrative. The units described as separate components may or may not be physically separate. The components shown as units may or may not be physical units; that is, they may be located in one place or distributed across multiple network units. Some or all of the modules can be selected to achieve the purpose of this embodiment according to actual needs. Those skilled in the art can understand and implement this without creative effort.
[0114] Those skilled in the art will further recognize that the units and algorithm steps of the various examples described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, computer software, or a combination of both. To clearly illustrate the interchangeability of hardware and software, the components and steps of the various examples have been generally described in terms of functionality in the foregoing description. Whether these functions are implemented in hardware or software depends on the specific application and design constraints of the technical solution. Those skilled in the art can use different methods to implement the described functions for each specific application, but such implementations should not be considered beyond the scope of this invention.
[0115] The above description of the disclosed embodiments enables those skilled in the art to make or use the invention. Various modifications to these embodiments will be readily apparent to those skilled in the art, and the general principles defined herein may be implemented in other embodiments without departing from the scope of the invention. Therefore, the invention is not to be limited to the embodiments shown herein, but is to be accorded the widest scope consistent with the principles and novel features disclosed herein.
Claims
1. A method for automatically reporting vehicle diagnostic logs, characterized in that, Applicable to diagnostic instruments, the method includes: Send a diagnostic request to the vehicle's electronic control unit; Receive the diagnostic response returned by the vehicle electronic control unit based on the diagnostic request; If the diagnostic response is a negative response, then the negative response is parsed to obtain the service identifier corresponding to the negative response, and the number of negative responses corresponding to the service identifier is accumulated; Determine whether the cumulative number of negative responses has reached the preset trigger threshold corresponding to the service identifier; If this is achieved, the log information of the current diagnostic session is collected and uploaded to the server.
2. The method according to claim 1, characterized in that, The process of parsing the negative response to obtain the service identifier corresponding to the negative response includes: Identify the negative response identifier in the negative response; Extract the first byte following the negative response identifier as the service identifier.
3. The method according to claim 1, characterized in that, Before determining whether the cumulative number of negative responses has reached the preset trigger threshold corresponding to the service identifier, the method further includes: Based on the feedback level to which the service identifier belongs, query the preset trigger threshold corresponding to the feedback level; wherein, different feedback levels correspond to different preset trigger thresholds.
4. The method according to claim 3, characterized in that, The step of querying the preset trigger threshold corresponding to the feedback level based on the feedback level to which the service identifier belongs includes: If the feedback level to which the service identifier belongs is the normal feedback level, then the preset trigger threshold corresponding to the feedback level is 3 times; If the feedback level to which the service identifier belongs is medium, then the preset trigger threshold corresponding to the feedback level is 2 times. If the feedback level to which the service identifier belongs is a high feedback level, then the preset trigger threshold corresponding to the feedback level is 1 time.
5. The method according to claim 1, characterized in that, The collection of log information for the current diagnostic session includes: Obtain the vehicle identification number, vehicle model, and currently executed function menu name, as well as the original data frame recording the negative response; The vehicle identification number, the vehicle model, the function menu name, and the raw data frame are integrated into the log information of the current diagnostic session.
6. The method according to claim 1, characterized in that, Before uploading the log information to the server, the process also includes: Check the current network connection status; If a network connection is detected, the log information is uploaded to the server; If no network connection is detected, the log information is stored locally, and the process returns to the step of detecting the current network connection status.
7. A vehicle diagnostic log automatic reporting device, characterized in that, Suitable for diagnostic instruments, the device includes: The transmitting unit is used to send diagnostic requests to the vehicle's electronic control unit; A receiving unit is configured to receive a diagnostic response returned by the vehicle electronic control unit based on the diagnostic request; The parsing unit is configured to, if the diagnostic response is a negative response, parse the negative response to obtain the service identifier corresponding to the negative response, and accumulate the number of negative responses corresponding to the service identifier; The judgment unit is used to determine whether the cumulative number of negative responses has reached the preset trigger threshold corresponding to the service identifier; An upload unit is used to collect log information of the current diagnostic session and upload the log information to the server if the condition is met.
8. The apparatus according to claim 7, characterized in that, The parsing unit includes: The identification module is used to identify the negative response identifier in the negative response; The extraction module is used to extract the first byte after the negative response identifier as the service identifier.
9. A computer-readable storage medium having a computer program stored thereon, characterized in that, When the computer program is executed by the processor, it implements the automatic reporting method for vehicle diagnostic logs as described in any one of claims 1 to 6.
10. An electronic device comprising a memory, a processor, and a computer program stored in the memory, characterized in that, The processor executes the computer program to implement the automatic reporting method for vehicle diagnostic logs as described in any one of claims 1 to 6.