Vehicle-end software diagnosis method and device, electronic equipment and storage medium
By receiving the diagnostic SDK from the vehicle application and uploading it to the cloud for diagnosis, the problem of the lack of a unified diagnostic standard for vehicle software is solved, and efficient diagnosis and unified standardization of vehicle software faults are achieved.
Patent Information
- Application Number
- CN202211716315.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-12-29
- Publication Date
- 2026-11-27
- Estimated Expiration
- 2042-12-29
AI Technical Summary
The lack of a unified standard for vehicle software fault diagnosis in the current technology leads to a lack of standardization in the vehicle-side software fault diagnosis process, requiring frequent upgrades of mobile software and lacking a unified standard for fault diagnosis.
By receiving the diagnostic SDK sent by the vehicle-side application, the software error codes are parsed and uploaded to the cloud for diagnosis. The cloud then performs diagnosis based on the error codes and obtains the diagnostic results, thus achieving a unified and standardized diagnosis of faults.
It has achieved a unified diagnostic standard for vehicle software faults, avoiding frequent upgrades to mobile software and improving the efficiency and accuracy of fault diagnosis.
Smart Images

Figure CN116089143B_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of vehicle technology, and in particular to a diagnostic method, apparatus, electronic device, and storage medium for vehicle-side software. Background Technology
[0002] As vehicles become increasingly intelligent, more and more software applications are being used, and the logic processed by these applications is becoming more complex. However, there is no standard for diagnosing software faults in vehicles. The only method available is to diagnose ECUs (Electronic Control Units) through UDS (Unified Diagnostic Services). Therefore, it is essential to develop a software diagnostic standard.
[0003] One related technology provides an intelligent vehicle diagnostic method that establishes a communication connection between a mobile terminal and the vehicle, sends vehicle diagnostic requests, forwards the requests to the control unit, obtains fault information, parses the fault information, and updates control commands. Another proposed method verifies software faults by generating diagnostic related functions and datasets.
[0004] However, when the vehicle-side software malfunctions, the relevant technology requires using a fault diagnosis program on a mobile terminal to determine the fault type of the control unit. Then, it searches the backend server for a matching software upgrade package for the control unit software, downloads it, and sends it to the in-vehicle smart terminal. Only after upgrading the control unit can the previous fault be eliminated. This entire process lacks diagnostic standards, leading to frequent mobile software upgrades. Another issue is the need to generate different diagnostic functions based on different types of datasets, lacking a unified standard for fault diagnosis. Summary of the Invention
[0005] This application provides a diagnostic method, device, electronic device, and storage medium for vehicle-side software to address the lack of a unified standard for fault diagnosis in related technologies and fill the gap in the absence of a standard for vehicle software fault diagnosis.
[0006] A first aspect of this application provides a diagnostic method for vehicle-side software, comprising the following steps: receiving a diagnostic software development kit (SDK) sent by at least one vehicle-side application; parsing the diagnostic SDK to obtain software error codes of the at least one vehicle-side application; sending the software error codes of the at least one vehicle-side application to a target cloud, and receiving diagnostic results of the at least one vehicle-side application sent by the target cloud based on the software error codes of the at least one vehicle-side application, so as to diagnose the at least one vehicle-side application based on the diagnostic results.
[0007] Based on the above-mentioned technical means, this application can solve the problem of the lack of a unified standard for fault diagnosis in related technologies and fill the gap of the lack of software fault diagnosis standards for vehicles.
[0008] Optionally, in some embodiments, the above-described diagnostic method for vehicle-side software further includes: receiving a health management data query instruction from the target cloud for the at least one vehicle-side application; filtering the software application information of the at least one vehicle-side application based on the health management data query instruction, and combining the software application information of the at least one vehicle-side application into a string of a first preset format; and sending the string of the first preset format to the target cloud to monitor whether the at least one vehicle-side application meets preset operating conditions through the target cloud.
[0009] Based on the aforementioned technical means, this application can detect faults using health management data.
[0010] Optionally, in some embodiments, the above-described diagnostic method for vehicle-side software further includes: determining the configuration information to be uploaded for the at least one vehicle-side application; reading the configuration information to be uploaded, combining the configuration information to be uploaded into a string of a second preset format, and sending the string of the second preset format to the target cloud.
[0011] Based on the aforementioned technical means, this application can proactively upload software operation information from the vehicle to facilitate error diagnosis.
[0012] Optionally, in some embodiments, the above-described diagnostic method for vehicle-side software further includes: receiving a configuration file viewing instruction for at least one vehicle-side application sent by a vehicle-side host computer, wherein the configuration file viewing instruction is sent from the target cloud to the vehicle-side host computer; reading the configuration file information of the at least one vehicle-side application based on the configuration file viewing instruction; combining the configuration file information into a string of a third preset format, and sending the string of the third preset format to the target cloud.
[0013] Based on the above technical means, this application can avoid the problem that when multiple users modify the configuration file at the same time, the modification is successful but only the last user's modification takes effect.
[0014] Optionally, in some embodiments, the above-described diagnostic method for vehicle-side software further includes: receiving a Data Distribution Service (DDS) instruction sent by a diagnostic host computer, wherein the DDS instruction is received by the vehicle-side remote control center from the target cloud via Message Queuing Telemetry Transport (MQTT) and then sent to the diagnostic host computer via DDS; based on the DDS instruction, calling the Software Over The Air (SOTA) interface to obtain the vehicle-side application information corresponding to the DDS instruction, and sending the vehicle-side application information corresponding to the DDS instruction to the target cloud.
[0015] Based on the aforementioned technical means, this application can call the software online upgrade (SOTA) interface to obtain the vehicle-side application information corresponding to the information DDS command and upload it to the cloud.
[0016] Optionally, in some embodiments, the software error code includes at least one of the following: error code, error level, error code meaning, timestamp, application name, module name, function name, and remarks.
[0017] Based on the above technical means, the software error codes of this application can provide diagnostic capabilities such as local rolling storage of software application error codes, receiving instructions to pull historical data of software error codes stored locally, actively uploading software application error codes to the cloud and judging and processing them according to set rules, storing software application error codes in the cloud and generating statistical reports periodically.
[0018] A second aspect of this application provides a diagnostic device for vehicle-side software, comprising: a receiving module for receiving a diagnostic software development kit (SDK) sent by at least one vehicle-side application; a parsing module for parsing the diagnostic SDK to obtain software error codes of the at least one vehicle-side application; and a diagnostic module for sending the software error codes of the at least one vehicle-side application to a target cloud, and receiving diagnostic results of the at least one vehicle-side application sent by the target cloud based on the software error codes of the at least one vehicle-side application, so as to diagnose the at least one vehicle-side application based on the diagnostic results.
[0019] Optionally, in some embodiments, the above-described vehicle-side software diagnostic device further includes: a first receiving unit, configured to receive a health management data query instruction for the at least one vehicle-side application sent by the target cloud; a filtering unit, configured to filter the software application information of the at least one vehicle-side application based on the health management data query instruction, and combine the software application information of the at least one vehicle-side application into a string of a first preset format; and a monitoring unit, configured to send the string of the first preset format to the target cloud, so as to monitor whether the at least one vehicle-side application meets preset operating conditions through the target cloud.
[0020] Optionally, in some embodiments, the diagnostic device for vehicle-side software described above further includes: a determining unit, configured to determine the configuration information to be uploaded for the at least one vehicle-side application; and a first reading unit, configured to read the configuration information to be uploaded, combine the configuration information to be uploaded into a string of a second preset format, and send the string of the second preset format to the target cloud.
[0021] Optionally, in some embodiments, the above-described diagnostic device for vehicle-side software further includes: a second receiving unit, configured to receive a configuration file viewing instruction for the at least one vehicle-side application sent by a vehicle-side host computer, wherein the configuration file viewing instruction is sent from the target cloud to the vehicle-side host computer; a second reading unit, configured to read the configuration file information of the at least one vehicle-side application based on the configuration file viewing instruction; and a sending unit, configured to combine the configuration file information into a string of a third preset format and send the string of the third preset format to the target cloud.
[0022] Optionally, in some embodiments, the above-mentioned vehicle-side software diagnostic device further includes: a third receiving unit, configured to receive a Data Distribution Service (DDS) instruction sent by a diagnostic host computer, wherein the DDS instruction is received by the vehicle-side remote control center from the target cloud via Message Queue Telemetry Transmission (MQTT) and then sent to the diagnostic host computer via DDS; and a calling unit, configured to, based on the DDS instruction, call the Software Online Update (SOTA) interface to obtain the vehicle-side application information corresponding to the DDS instruction, and send the vehicle-side application information corresponding to the DDS instruction to the target cloud.
[0023] Optionally, in some embodiments, the software error code includes at least one of the following: error code, error level, error code meaning, timestamp, application name, module name, function name, and remarks.
[0024] A third aspect of this application provides an electronic device, including: a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor executes the program to implement the vehicle-side software diagnostic method as described in the above embodiments.
[0025] A fourth aspect of this application provides a computer-readable storage medium having a computer program stored thereon, which is executed by a processor to implement the diagnostic method for vehicle-side software as described in the above embodiments.
[0026] Therefore, by receiving the diagnostic SDK sent by the vehicle application, parsing it to obtain the software error code, and uploading the vehicle error code to the cloud, the cloud diagnostic center performs diagnosis based on the vehicle error code and obtains the diagnostic results of the vehicle application. This solves the problem of the lack of a unified standard for fault diagnosis in related technologies and fills the gap of the lack of software fault diagnosis standards for vehicles.
[0027] Additional aspects and advantages of this application will be set forth in part in the description which follows, and in part will be obvious from the description, or may be learned by practice of this application. Attached Figure Description
[0028] The above and / or additional aspects and advantages of this application will become apparent and readily understood from the following description of the embodiments taken in conjunction with the accompanying drawings, wherein:
[0029] Figure 1 This is a flowchart of a diagnostic method for vehicle-side software provided according to an embodiment of this application;
[0030] Figure 2 This is a flowchart of a software health data diagnosis method according to a specific embodiment of this application;
[0031] Figure 3 This is a flowchart of the vehicle-side proactive reporting software operation information according to a specific embodiment of this application;
[0032] Figure 4 Here is a flowchart of a cloud-based health filter configuration viewing process according to a specific embodiment of this application;
[0033] Figure 5 A flowchart illustrating the process of issuing instructions for reading software basic information according to a specific embodiment of this application;
[0034] Figure 6 This is a flowchart of a software diagnostic error code provided according to a specific embodiment of this application;
[0035] Figure 7 This is a block diagram of a diagnostic device for vehicle-side software provided according to an embodiment of this application;
[0036] Figure 8 This is a schematic diagram of an electronic device provided according to an embodiment of this application.
[0037] Explanation of reference numerals in the attached figures: 10 - diagnostic device for vehicle-side software, 100 - receiving module, 200 - parsing module, and 300 - diagnostic module. Detailed Implementation
[0038] The embodiments of this application are described in detail below. Examples of these embodiments are shown in the accompanying drawings, wherein the same or similar reference numerals denote the same or similar elements or elements having the same or similar functions throughout. The embodiments described below with reference to the accompanying drawings are exemplary and intended to explain this application, and should not be construed as limiting this application.
[0039] The following description, with reference to the accompanying drawings, outlines a method, apparatus, electronic device, and storage medium for diagnosing vehicle-side software according to embodiments of this application. Addressing the lack of software fault diagnosis standards in the related technologies mentioned in the background section, this application provides a method for diagnosing vehicle-side software. In this method, a diagnostic SDK sent by a vehicle-side application is received, parsed to obtain software error codes, and uploaded to the cloud. A cloud-based diagnostic center then performs a diagnosis based on the vehicle error codes and derives the diagnostic results from the vehicle-side application. This solves the problem of a lack of unified fault diagnosis standards in the related technologies and fills the gap in the lack of software fault diagnosis standards for vehicles.
[0040] Specifically, Figure 1 This is a flowchart illustrating a diagnostic method for vehicle-side software provided in an embodiment of this application.
[0041] like Figure 1 As shown, the diagnostic method for this vehicle-side software includes the following steps:
[0042] In step S101, a diagnostic software development kit (SDK) sent by at least one vehicle-side application is received.
[0043] Specifically, in this embodiment of the application, the diagnostic center can receive at least one diagnostic software development kit (SDK) sent by a vehicle-side application. The communication method between the diagnostic SDK and the diagnostic center is DDS Field, which can be used for intra-domain shared memory communication. The purpose is to control the communication range to be within the kernel. The communication method between the diagnostic SDK and the diagnostic center for sending software error codes can also be DDS.
[0044] It should be noted that, to limit the application software from printing unlimited diagnostic error codes, the following restrictions can be implemented: Calculate a message digest and store it in a cache, with a scheduled cleanup interval, such as 60 seconds. When a message arrives again, perform the digest algorithm again and check if the digest information already exists in the cache. If it exists, do not push the message; otherwise, push the message and add the digest information to the cache. The DDS interface definition is as follows:
[0045] Service: Ntf_SoftDiagnose_SDK;
[0046] Method name: Ntf_Abnormal;
[0047] Communication method: Field;
[0048] Parameter name: errorlnfo;
[0049] Parameter type: SDSDKlnfo. The SDSDKlnfo data structure includes: software ID, error code, error code priority, error code meaning, remarks, timestamp, checksum, module name, and function name.
[0050] In step S102, the diagnostic software development kit (SDK) is parsed to obtain at least one software error code for the vehicle-side application.
[0051] Optionally, in some embodiments, the software error code includes at least one of the following: error code, error level, error code meaning, timestamp, application name, module name, function name, and remarks.
[0052] Understandably, software error codes are used to identify fault data that occurs in software. They are an important diagnostic capability in software fault detection. They mainly provide diagnostic capabilities such as local rolling storage of software application error codes, receiving instructions to pull historical data of software error codes from local storage, proactively uploading software application error codes to the cloud and judging and processing them according to set rules, and storing software application error codes in the cloud and generating statistical reports periodically.
[0053] Specifically, after receiving the information from the diagnostic SDK, the diagnostic center stores the error codes locally, using a tiered storage method based on the application. The implementation is as follows: the diagnostic center starts a thread to receive error codes from each software application; the error codes are then placed into four memory buffers (corresponding to four priorities) according to their priority; four threads in the four memory buffers consume the data and store it in four SQLite files, with each priority level of each software application stored in a separate table.
[0054] The fields for a single table in an SQLITE database are: id, ErrorCode, ErrorLevel, TimeStamp, Describle, Remarks, SourceFile, and Function.
[0055] id: Data type is INTEGER;
[0056] ErrorCode: The data type is INTEGER, and the meaning is error code;
[0057] ErrorLevel: The data type is INTEGER, and the meaning is the error code level;
[0058] TimeStamp: The data type is INTEGER, meaning timestamp;
[0059] Describle: Data type is TEXT, meaning error code description;
[0060] Remarks: The data type is TEXT, and the meaning is remarks information;
[0061] SourceFile: The data type is TEXT, meaning it is an error code file;
[0062] Function: The data type is TEXT, and its meaning is an error code reporting function.
[0063] In step S103, the software error code of at least one vehicle-side application is sent to the target cloud, and the diagnostic results of at least one vehicle-side application sent by the target cloud based on the software error code of at least one vehicle-side application are received, so as to diagnose at least one vehicle-side application based on the diagnostic results.
[0064] Specifically, when errors occur in the software application, they are reported to the cloud in the form of software error codes. For error codes of a severe level, the relevant parties are notified according to the configuration rules. When important data is validated in the software application, the data information of the failed validation is reported to the cloud in the form of error codes. When important logic is validated in the software application, the data information of the failed validation is reported to the cloud in the form of error codes. When important data is embedded in the software application, the embedded data is reported to the cloud in the form of error codes.
[0065] Optionally, in some embodiments, the above-described diagnostic method for vehicle-side software further includes: receiving a health management data query instruction from at least one vehicle-side application sent by a target cloud; filtering the software application information of at least one vehicle-side application based on the health management data query instruction, and combining the software application information of at least one vehicle-side application into a string of a first preset format; and sending the string of the first preset format to the target cloud so as to monitor whether at least one vehicle-side application meets preset operating conditions through the target cloud.
[0066] It should be noted that the diagnostic method of the vehicle-side software in this application mainly consists of fault discovery, i.e., fault investigation. Fault discovery mainly includes two parts: software error codes and software health data.
[0067] Software health data includes process operation information such as memory usage, CPU utilization, and process ID during software operation; the current running status of the software reported by the health module; information on software health channels and function groups reported by the health module; and running information such as the total memory and CPU usage of the current operating system. It is a crucial diagnostic capability in software fault detection, primarily providing the ability to proactively upload software application health data to the cloud and determine whether the current software application is running normally based on basic process information and running status; cloud storage of software application health data and periodic generation of statistical reports; and the ability to view historical information of software application health data.
[0068] Specifically, the software diagnostic software health data solution of this application embodiment consists of four parts: cloud-based instruction reporting of software (including OS) operation information, vehicle-side active reporting of software (including OS) operation information, cloud-based viewing of health filter configuration, and cloud-based modification of health filter configuration.
[0069] The cloud-based system sends commands to report the operating information of the software (including the OS), and consists of a cloud diagnostic instrument, remote control interface, remote control center, diagnostic center, data acquisition module, DDS domain, and health module. For example... Figure 2 As shown, the basic operating steps are as follows:
[0070] S201: The health module sends detection information periodically via DDS Field. This information includes: memory monitoring information (physical memory, virtual memory, memory leaks), CPU (central processing unit) monitoring information (user processes, system processes, waiting for I / O, idle), and application process monitoring information (total number of system processes, number of running processes, number of sleeping processes, number of stopped processes, number of stagnant processes, application status).
[0071] S202: Cloud-based command DDS is issued to view the health management data of a certain software application. The DDS definition is as follows:
[0072]
[0073] S203: Information from the diagnostic center's filtering of corresponding software applications;
[0074] S204; The diagnostic center groups the software application information into a JSON string;
[0075] S205: The diagnostic center reports the JSON string to the data acquisition module;
[0076] S206: The data acquisition module is uploaded to the cloud via MQTT.
[0077] Optionally, in some embodiments, the above-described diagnostic method for vehicle-side software further includes: determining configuration information to be uploaded for at least one vehicle-side application; reading the configuration information to be uploaded, combining the configuration information to be uploaded into a string of a second preset format, and sending the string of the second preset format to the target cloud.
[0078] The second preset format string can be a JSON string.
[0079] Specifically, such as Figure 3 As shown, the vehicle-side proactive reporting software (including the OS) mainly consists of a cloud diagnostic tool, a DDS domain, a diagnostic center, a data acquisition module, and a health module. The basic steps are as follows:
[0080] S301: The health module sends the detection information periodically via the DDS Field;
[0081] S302: The diagnostic center filters applications according to the configuration requirements for cloud migration;
[0082] S303: The diagnostic center will assemble the filtered data that needs to be uploaded into a JSON string;
[0083] S305: The diagnostic center sends a JSON string to the data acquisition module;
[0084] S305: Data acquisition module uploads data to the cloud.
[0085] Optionally, in some embodiments, the above-described diagnostic method for vehicle-side software further includes: receiving a configuration file viewing instruction for at least one vehicle-side application sent by a vehicle-side host computer, wherein the configuration file viewing instruction is sent from a target cloud to the vehicle-side host computer; reading configuration file information of at least one vehicle-side application based on the configuration file viewing instruction; combining the configuration file information into a string of a third preset format, and sending the string of the third preset format to the target cloud.
[0086] The third preset format string can be a JSON string.
[0087] Specifically, the cloud-based health filter configuration in this application embodiment mainly consists of a cloud diagnostic instrument and remote control interface on the cloud, and a remote control center, diagnostic center, and data acquisition module on the vehicle side. For example... Figure 4 As shown, the basic steps are as follows:
[0088] S401: A command sent from the cloud to view the health configuration file of the diagnostic center for a specific domain;
[0089] S402: The vehicle-side host computer receives commands;
[0090] S403: Forward the command to the diagnostic center
[0091] S404: Diagnostic Center reads configuration file;
[0092] S405: Compile the configuration file into a JSON string;
[0093] S406: Report a JSON string along with a uint32 version number to the cloud.
[0094] It should be noted that the purpose of Version data is to prevent multiple users from modifying the configuration file simultaneously, all of which will indicate that the modification was successful, but only the last user's changes will take effect. When the next user views the configuration file, they will not see the content they wanted to modify.
[0095] Optionally, in some embodiments, the above-described diagnostic method for vehicle-side software further includes: receiving a Data Distribution Service (DDS) instruction sent by a diagnostic host computer, wherein the DDS instruction is received by the vehicle-side remote control center from the target cloud via Message Queue Telemetry Transmission (MQTT) and then sent to the diagnostic host computer via DDS; based on the DDS instruction, calling the software online upgrade (SOTA) interface to obtain the vehicle-side application information corresponding to the DDS instruction, and sending the vehicle-side application information corresponding to the DDS instruction to the target cloud.
[0096] Specifically, the cloud-based modification of the health filter configuration in this application embodiment consists of a cloud-based diagnostic instrument and a remote control interface, as well as a vehicle-side remote control center and a diagnostic center.
[0097] The software basic information solution involves reading and issuing commands, which consists of a cloud diagnostic tool, remote control interface, remote control center, diagnostic host computer, diagnostic center, and SOTA module. Vehicle-side software basic information is obtained from the corresponding domain's SOTA, which is provided to the diagnostic center via a DDS interface. For example... Figure 5 As shown, the basic steps are as follows:
[0098] S501: The cloud diagnostic instrument sends MQTT to the vehicle's remote control center via the remote control interface;
[0099] S502: The vehicle-side remote control center sends commands to the diagnostic host computer via DDS;
[0100] S503: The diagnostic host computer sends DDS commands to the diagnostic center of the corresponding application;
[0101] S504: After the diagnostic center calls the SOTA interface to obtain information, it directly returns the data to the cloud.
[0102] To enable those skilled in the art to further understand the diagnostic method of the vehicle-side software in the embodiments of this application, a detailed description is provided below with reference to specific embodiments.
[0103] The diagnostic method for vehicle-side software in this application consists of a diagnostic SDK scheme, a local error code storage scheme, a cloud-based diagnostic error code storage scheme, and historical data retrieval for diagnostic error codes.
[0104] The diagnostic SDK solution consists of various software applications on the vehicle side; the local error code storage solution consists of the vehicle-side diagnostic center and vehicle-side local storage; the cloud-based diagnostic error code solution consists of the cloud diagnostic instrument, KAFKA and TSP on the cloud, and the vehicle-side diagnostic center and data acquisition module; the historical data retrieval of diagnostic error codes consists of the cloud diagnostic instrument and remote control interface on the cloud, and the vehicle-side remote control center, diagnostic center and local storage.
[0105] Specifically, such as Figure 6 As shown, the basic steps of the diagnostic method for vehicle-side software are as follows:
[0106] S601: Each software application generates a diagnostic SDK;
[0107] S602: Each software application sends the SDK to the diagnostic center;
[0108] S603: The diagnostic center received a DDS error code reported by the software application;
[0109] S604: The diagnostic center stores the error codes locally;
[0110] S605: The diagnostic center sends the error code to the data acquisition module via DDS;
[0111] S606: The data acquisition module uploads error codes to the cloud via MQTT;
[0112] S607: The TSP sends the received MQTT to KAFKA; KAFKA forwards it to the cloud diagnostic tool. Historical error code data is stored.
[0113] The Diagnostic Center and Data Acquisition Module (DDS) are defined as follows:
[0114] Service: Enh_DTCData;
[0115] Method name: Ntf_SDERroeCode;
[0116] Communication method: Field;
[0117] Parameter name: errorCode; a
[0118] Parameter type: String.
[0119] It should be noted that the diagnostic method of the vehicle-side software in this application embodiment basically consists of two parts: fault discovery and fault investigation.
[0120] Fault discovery: Fault discovery mainly includes two parts: software error codes and software health data.
[0121] Fault Investigation: Fault investigation mainly includes two parts: basic software information and MCU memory pin data. Basic software information consists of fields such as App1, Type, Version, Architecture, Platform, Maintainer, PackAuthor, PackDate, Description, and Depends. It is one of the diagnostic capabilities in software fault investigation, primarily providing real-time querying of the current basic information of the vehicle's running software applications and the ability to diagnose faults based on this information. It is mainly used in fault investigation; when a software fault occurs, it is recommended to check the basic software information in real time, such as whether the software version number is the expected version number and whether the fault occurrence time corresponds to the software packaging time.
[0122] MCU memory pin data is only used for read operations; for safety reasons, write operations are not actually implemented. It mainly includes data such as the variable value corresponding to the MCU memory address; the level value at the MCU chip pin; and the voltage value at the MCU chip pin. It is also an important diagnostic capability for troubleshooting software applications on the MCU, primarily providing real-time periodic monitoring of changes in the variable value corresponding to the MCU memory address; real-time periodic monitoring of changes in the level value at the MCU chip pin; and real-time periodic monitoring of changes in the voltage value at the MCU chip pin.
[0123] The diagnostic capability is mainly used in scenarios where, after an MCU malfunctions, the fault can be diagnosed by remotely periodically monitoring the variable values corresponding to the MCU memory address and the level and voltage values at the chip pins.
[0124] According to the vehicle-side software diagnostic method proposed in the embodiments of this application, the diagnostic SDK sent by the vehicle-side application is received, parsed to obtain the software error code, and the vehicle error code is uploaded to the cloud. The cloud diagnostic center performs diagnosis based on the vehicle error code and obtains the diagnostic result of the vehicle-side application. This solves the problem of the lack of a unified standard for fault diagnosis in related technologies and fills the gap of the lack of a standard for vehicle software fault diagnosis.
[0125] Next, the diagnostic device for vehicle-side software according to an embodiment of this application is described with reference to the accompanying drawings.
[0126] Figure 7 This is a block diagram of a diagnostic device for vehicle-side software according to an embodiment of this application.
[0127] like Figure 7 As shown, the diagnostic device 10 of the vehicle-side software includes: a receiving module 100, a parsing module 200, and a diagnostic module 300.
[0128] The receiving module 100 is used to receive a diagnostic software development kit (SDK) sent by at least one vehicle-side application; the parsing module 200 is used to parse the diagnostic software development kit (SDK) to obtain the software error codes of at least one vehicle-side application; and the diagnostic module 300 is used to send the software error codes of at least one vehicle-side application to the target cloud, and receive the diagnostic results of at least one vehicle-side application sent by the target cloud based on the software error codes of at least one vehicle-side application, so as to diagnose at least one vehicle-side application based on the diagnostic results.
[0129] Optionally, in some embodiments, the vehicle-side software diagnostic device 10 described above further includes: a first receiving unit, configured to receive a health management data query instruction for at least one vehicle-side application sent by a target cloud; a filtering unit, configured to filter the software application information of at least one vehicle-side application based on the health management data query instruction, and combine the software application information of at least one vehicle-side application into a string of a first preset format; and a monitoring unit, configured to send the string of the first preset format to the target cloud, so as to monitor whether at least one vehicle-side application meets preset operating conditions through the target cloud.
[0130] Optionally, in some embodiments, the diagnostic device 10 for vehicle-side software described above further includes: a determining unit, configured to determine configuration information to be uploaded for at least one vehicle-side application; and a first reading unit, configured to read the configuration information to be uploaded, combine the configuration information to be uploaded into a string of a second preset format, and send the string of the second preset format to the target cloud.
[0131] Optionally, in some embodiments, the vehicle-side software diagnostic device 10 described above further includes: a second receiving unit, configured to receive a configuration file viewing instruction for at least one vehicle-side application sent by a vehicle-side host computer, wherein the configuration file viewing instruction is sent from a target cloud to the vehicle-side host computer; a second reading unit, configured to read configuration file information of at least one vehicle-side application based on the configuration file viewing instruction; and a sending unit, configured to combine the configuration file information into a string of a third preset format and send the string of the third preset format to the target cloud.
[0132] Optionally, in some embodiments, the diagnostic device 10 for vehicle-side software described above further includes: a third receiving unit, configured to receive a Data Distribution Service (DDS) instruction sent by a diagnostic host computer, wherein the DDS instruction is received by the vehicle-side remote control center from the target cloud via Message Queue Telemetry Transmission (MQTT) and then sent to the diagnostic host computer via DDS; and a calling unit, configured to, based on the DDS instruction, call the software online upgrade (SOTA) interface to obtain the vehicle-side application information corresponding to the DDS instruction, and send the vehicle-side application information corresponding to the DDS instruction to the target cloud.
[0133] Optionally, in some embodiments, the software error code includes at least one of the following: error code, error level, error code meaning, timestamp, application name, module name, function name, and remarks.
[0134] It should be noted that the explanation of the aforementioned embodiment of the diagnostic method for vehicle-side software also applies to the diagnostic device for the vehicle-side software in this embodiment, and will not be repeated here.
[0135] The vehicle-side software diagnostic device proposed in the embodiments of this application receives the diagnostic SDK sent by the vehicle-side application, parses it to obtain the software error code, and uploads the vehicle error code to the cloud. The cloud diagnostic center performs diagnosis based on the vehicle error code and obtains the diagnostic result of the vehicle-side application. This solves the problem of the lack of a unified standard for fault diagnosis in related technologies and fills the gap of the lack of a standard for vehicle software fault diagnosis.
[0136] Figure 8 A schematic diagram of the structure of an electronic device provided in an embodiment of this application. The electronic device may include:
[0137] The memory 801, the processor 802, and the computer program stored on the memory 801 and capable of running on the processor 802.
[0138] When the processor 802 executes the program, it implements the diagnostic method of the vehicle-side software provided in the above embodiments.
[0139] Furthermore, electronic devices also include:
[0140] Communication interface 803 is used for communication between memory 801 and processor 802.
[0141] The memory 801 is used to store computer programs that can run on the processor 802.
[0142] The memory 801 may include high-speed RAM (Random Access Memory) memory, and may also include non-volatile memory, such as at least one disk storage.
[0143] If the memory 801, processor 802, and communication interface 803 are implemented independently, then the communication interface 803, memory 801, and processor 802 can be interconnected via a bus to complete communication between them. The bus can be an ISA (Industry Standard Architecture) bus, a PCI (Peripheral Component Interconnect) bus, or an EISA (Extended Industry Standard Architecture) bus, etc. The bus can be divided into address bus, data bus, control bus, etc. For ease of representation, Figure 8 The bus is represented by a single thick line, but this does not mean that there is only one bus or one type of bus.
[0144] Optionally, in a specific implementation, if the memory 801, processor 802, and communication interface 803 are integrated on a single chip, then the memory 801, processor 802, and communication interface 803 can communicate with each other through an internal interface.
[0145] The processor 802 may be a CPU (Central Processing Unit), an ASIC (Application Specific Integrated Circuit), or one or more integrated circuits configured to implement the embodiments of this application.
[0146] This application also provides a computer-readable storage medium storing a computer program thereon, which, when executed by a processor, implements the diagnostic method of the vehicle-side software described above.
[0147] In the description of this specification, the references to terms such as "one embodiment," "some embodiments," "example," "specific example," or "some examples," etc., indicate that a specific feature, structure, material, or characteristic described in connection with that embodiment or example is included in at least one embodiment or example of this application. In this specification, the illustrative expressions of the above terms do not necessarily refer to the same embodiment or example. Furthermore, the specific features, structures, materials, or characteristics described may be combined in any suitable manner in one or more embodiments or examples. Moreover, without contradiction, those skilled in the art can combine and integrate the different embodiments or examples described in this specification, as well as the features of different embodiments or examples.
[0148] Furthermore, the terms "first" and "second" are used for descriptive purposes only and should not be construed as indicating or implying relative importance or implicitly specifying the number of technical features indicated. Thus, a feature defined as "first" or "second" may explicitly or implicitly include at least one of that feature. In the description of this application, "N" means at least two, such as two, three, etc., unless otherwise explicitly specified.
[0149] Any process or method described in the flowchart or otherwise herein can be understood as representing a module, segment, or portion of code comprising one or more N executable instructions for implementing custom logic functions or processes, and the scope of the preferred embodiments of this application includes additional implementations in which functions may be performed not in the order shown or discussed, including substantially simultaneously or in reverse order depending on the functions involved, as should be understood by those skilled in the art to which embodiments of this application pertain.
[0150] It should be understood that the various parts of this application can be implemented using hardware, software, firmware, or a combination thereof. In the above embodiments, the N steps or methods can be implemented using software or firmware stored in memory and executed by a suitable instruction execution system. For example, if implemented in hardware, as in another embodiment, it can be implemented using any one or a combination of the following techniques known in the art: discrete logic circuits having logic gates for implementing logical functions on data signals, application-specific integrated circuits (ASICs) having suitable combinational logic gates, programmable gate arrays (FPGAs), field-programmable gate arrays (FPGAs), etc.
[0151] Those skilled in the art will understand that all or part of the steps of the methods in the above embodiments can be implemented by a program instructing related hardware. The program can be stored in a computer-readable storage medium, and when executed, the program includes one or a combination of the steps of the method embodiments.
[0152] Although embodiments of this application have been shown and described above, it is understood that the above embodiments are exemplary and should not be construed as limiting this application. Those skilled in the art can make changes, modifications, substitutions and variations to the above embodiments within the scope of this application.
Claims
1. A diagnostic method for vehicle-side software, characterized in that, Includes the following steps: The diagnostic center receives at least one diagnostic software development kit (SDK) sent by a vehicle-side application. The communication method between the diagnostic software development kit (SDK) and the diagnostic center is DDS Field. Specifically, DDS Field uses intra-domain shared memory communication, and the communication range is within the DDS kernel. The received message is processed using a digest algorithm, and the corresponding digest information is stored in a cache. When a message is received again, a digest algorithm is used to process the received message and check whether the corresponding digest information already exists in the cache. If it exists, the received message is not pushed; if it does not exist, the received message is pushed and the corresponding digest information is added to the cache. The diagnostic software development kit (SDK) is parsed to obtain the software error codes of the at least one vehicle-side application; the diagnostic center starts a thread to receive the software error codes transmitted by each software application; The software error codes are placed in four memory buffers according to their priority, with each of the four memory buffers corresponding to a different priority level. The data in the four memory buffers is consumed by four threads corresponding to the four memory buffers, and the consumed data is stored in four SQLite files respectively. Each level of each software application stores a separate table in the SQLite file. The system also sends the software error codes of the at least one vehicle-side application to the target cloud and receives the diagnostic results of the at least one vehicle-side application sent by the target cloud based on the software error codes of the at least one vehicle-side application, so as to diagnose the at least one vehicle-side application based on the diagnostic results.
2. The method according to claim 1, characterized in that, Also includes: Receive a health management data query command from the target cloud for at least one vehicle-side application; Based on the health management data query command, the software application information of the at least one vehicle-side application is filtered, and the software application information of the at least one vehicle-side application is combined into a string of a first preset format; The first preset format string is sent to the target cloud so that the target cloud can monitor whether the at least one vehicle-side application meets the preset operating conditions.
3. The method according to claim 1, characterized in that, Also includes: Determine the configuration information to be uploaded for the at least one vehicle-side application; Read the configuration information to be uploaded, combine the configuration information to be uploaded into a string of a second preset format, and send the string of the second preset format to the target cloud.
4. The method according to claim 1, characterized in that, Also includes: Receive a configuration file viewing instruction for at least one vehicle-side application sent by the vehicle-side host computer, wherein the configuration file viewing instruction is sent from the target cloud to the vehicle-side host computer; Based on the configuration file viewing command, read the configuration file information of the at least one vehicle-side application; The configuration file information is combined into a string in a third preset format, and the string in the third preset format is sent to the target cloud.
5. The method according to claim 1, characterized in that, Also includes: The system receives a Data Distribution Service (DDS) instruction from the diagnostic host computer. The DDS instruction is sent to the diagnostic host computer via DDS after the vehicle remote control center receives the Message Queue Telemetry Transmission (MQTT) sent by the target cloud. Based on the DDS command, the software online upgrade (SOTA) interface is invoked to obtain the vehicle application information corresponding to the DDS command, and the vehicle application information corresponding to the DDS command is sent to the target cloud.
6. The method according to any one of claims 1-5, characterized in that, The software error code includes at least one of the following: error code, error level, error code meaning, timestamp, application name, module name, function name, and remarks.
7. A diagnostic device for vehicle-side software, characterized in that, For implementing the method as described in any one of claims 1-6, comprising: The receiving module is used to receive diagnostic software development kit (SDK) sent by at least one vehicle-side application. The parsing module is used to parse the diagnostic software development kit (SDK) to obtain the software error codes of the at least one vehicle-side application; and The diagnostic module is used to send the software error codes of the at least one vehicle-side application to the target cloud, and receive the diagnostic results of the at least one vehicle-side application sent by the target cloud based on the software error codes of the at least one vehicle-side application, so as to diagnose the at least one vehicle-side application based on the diagnostic results.
8. The apparatus according to claim 7, characterized in that, Also includes: The receiving unit is configured to receive a health management data query instruction from the at least one vehicle-side application sent by the target cloud. The filtering unit filters the software application information of the at least one vehicle-side application based on the health management data query instruction, and combines the software application information of the at least one vehicle-side application into a string of a first preset format. The monitoring unit is used to send the string in the first preset format to the target cloud so as to monitor whether the at least one vehicle-side application meets the preset operating conditions through the target cloud.
9. An electronic device, characterized in that, include: A memory, a processor, and a computer program stored in the memory and executable on the processor, the processor executing the program to implement the diagnostic method for vehicle-side software as described in any one of claims 1-6.
10. A computer-readable storage medium having a computer program stored thereon, characterized in that, The program is executed by the processor to implement the diagnostic method for the vehicle-side software as described in any one of claims 1-6.
Citation Information
Patent Citations
SOA-based application service diagnosis architecture and method
CN114265386A
Vehicle MCU remote debugging system and method and storage medium
CN115150431A
