Embedded software fault anchor point positioning analysis method, device, equipment and medium

By adding fault assertion and anchor positioning technology in the embedded software compilation stage, dynamic fault code tables are generated, and time-consuming problem of embedded software failure detection is solved, and the full process of automated fault analysis is realized, reducing the workload of maintenance personnel.

CN114398198BActive Publication Date: 2025-08-19CASCO SIGNAL LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202111568972.7
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2021-12-21
Publication Date
2025-08-19
Estimated Expiration
2041-12-21

AI Technical Summary

Technical Problem

The existing embedded software fault detection and positioning analysis process is time-consuming and difficult to locate specific causes. Special tools are expensive and have high training requirements, so maintenance personnel workload is required.

Method used

In the software compilation stage, add fault assertions, generate dynamic fault code tables, use anchor points to locate the location of the fault, and query the cause of the fault through auxiliary tools to eliminate the impact of the fault.

Benefits of technology

It realizes the automation of the entire process from fault point generation to fault analysis, reduces manual intervention, improves fault handling efficiency, and reduces labor costs.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN114398198B_ABST
    Figure CN114398198B_ABST
Patent Text Reader

Abstract

The present invention relates to a method, device, equipment, and medium for analyzing embedded software fault anchor point positioning. This method utilizes anchor point positioning to proactively add fault assertions during the software compilation phase, generating a dynamic fault code table. When a fault occurs, the fault location is located by backtracking the anchor points. Simultaneously, auxiliary tools are used to query the cause of the fault and eliminate its impact. The device includes a configuration module, a loading module, a monitoring module, a downloading module, and an analysis module, each of which can operate independently. The configuration module, loading module, monitoring module, downloading module, and analysis module are each connected to a system maintenance station. Compared to existing technologies, this method has the advantages of significantly reducing the workload of maintenance personnel.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to a fault detection technology for embedded software, and in particular to a method, device, equipment and medium for locating and analyzing a fault anchor point of an embedded software. Background Art

[0002] During the development, use, and maintenance phases of embedded software, difficult faults often require detection, location, and analysis. Fault detection typically addresses two questions: "Where does the fault occur?" and "Why does this fault occur?" To address the first question, device vendors rely on print statements or LED status indicators to indicate the application's execution location. For the second, they often rely on register display windows to observe variable information and processor memory contents. These debugging and maintenance tasks are time-consuming and difficult to pinpoint.

[0003] Many industry vendors therefore offer dedicated debuggers or supporting analysis tools, such as log analysis and memory retrieval tools. These tools are often expensive, and even after investing significant capital, subsequent personnel training is still quite demanding. Therefore, how to analyze potential faults in real time and address them accordingly, while minimizing manual intervention, has become a technical challenge that needs to be addressed. Summary of the Invention

[0004] The purpose of the present invention is to overcome the defects of the above-mentioned prior art and provide an embedded software fault anchor point positioning and analysis method, device, equipment and medium that significantly reduces the workload of maintenance personnel.

[0005] The purpose of the present invention can be achieved by the following technical solutions:

[0006] According to a first aspect of the present invention, a method for anchor point location analysis of embedded software faults is provided. The method utilizes anchor point location to proactively add fault assertions during the software compilation phase to generate a dynamic fault code table. When a fault occurs, the location of the fault is located by backtracking the anchor points. At the same time, auxiliary tools are used to query the cause of the fault and eliminate its impact.

[0007] As a preferred technical solution, the method comprises the following steps:

[0008] Step S1, start the fault anchor point location analysis device and set the fault point search keyword in the configuration module;

[0009] Step S2: setting corresponding information of each type or each fault in the configuration module;

[0010] Step S3, starting the loading module, retrieving the code anchor point pile after loading the code, and automatically inserting the set fault anchor point into the code;

[0011] Step S4, loading the module-related software compilation tool, and the software compilation tool generates a fault list according to the fault keywords;

[0012] Step S5: When the embedded software is running, the monitoring module automatically matches keywords to the relevant information; when a downtime or abnormal information is thrown, the fault point is located according to the anchor point, and the preset processing measures are combined to quickly process it; and the download module is started to automatically download the log and memory dump information.

[0013] Step S6: The download module converts the downloaded log into text and archives it, which can be uploaded to the remote maintenance station. The downloaded memory information is sent to the analysis module.

[0014] In step S7, the analysis module analyzes the downloaded memory information, queries task information, stack information, key variable information, and message queue, and finds the key points of the problem in combination with the fault list.

[0015] As a preferred technical solution, the anchor point is a hyperlink technology used to dynamically jump between the same page or multiple pages.

[0016] As a preferred technical solution, the corresponding information in step S2 adopts the anchor point style "ID+name+description" and is attached with the response measures for each fault, and is associated with the maintenance manual.

[0017] As a preferred technical solution, the relevant information in step S5 includes log information and maintenance print information.

[0018] According to the second aspect of the present invention, a device for the embedded software fault anchor point positioning and analysis method is provided, which includes a configuration module, a loading module, a monitoring module, a download module and an analysis module, each of which can work independently, and the configuration module, loading module, monitoring module, download module and analysis module are respectively connected to the system maintenance station.

[0019] As a preferred technical solution, the configuration module is used to set code fault identification points and quote the maintenance manual to allow maintenance personnel to describe the fault details.

[0020] As a preferred technical solution, the loading module is used to insert fault anchors into the imported embedded code, and the associated compilation tool automatically generates a fault list during the software compilation process.

[0021] As a preferred technical solution, the monitoring module is used to monitor maintenance information of software downtime or exception throwing during software operation, and locate fault list information using anchor points.

[0022] As a preferred technical solution, the download module is used to download software maintenance logs and memory dump information after a fault occurs, so that maintenance personnel can further analyze the cause of the fault.

[0023] As a preferred technical solution, the analysis module is used to track the memory dump information after the fault occurs, and find out the parameter variable information when the fault occurs, so as to find out the specific cause of the fault.

[0024] According to a third aspect of the present invention, an electronic device is provided, comprising a memory and a processor, wherein a computer program is stored in the memory, and the processor implements the method when executing the program.

[0025] According to a fourth aspect of the present invention, a computer-readable storage medium is provided, on which a computer program is stored, and when the program is executed by a processor, the method described above is implemented.

[0026] Compared with the prior art, the present invention has the following advantages:

[0027] 1) This invention connects the entire fault handling process, from software fault point generation -> monitoring -> analysis -> archiving. It can be reused in embedded systems in various fields and has strong versatility.

[0028] 2) The present invention designs keyword matching through logs and maintenance print information. Through anchor point positioning technology, possible faults can be analyzed in real time and handled accordingly, reducing manual intervention, improving fault handling efficiency and reducing labor costs.

[0029] 3) The device of the present invention can be designed as an independent component of a maintenance station or distributed and deployed to multiple maintenance stations, with deployment and operation flexibility. BRIEF DESCRIPTION OF THE DRAWINGS

[0030] Figure 1 It is the workflow diagram of the method of the present invention;

[0031] Figure 2 Schematic diagram of the structure of the device of the present invention. DETAILED DESCRIPTION

[0032] The following will clearly and completely describe the technical solutions in the embodiments of the present invention in conjunction with the accompanying drawings. Obviously, the described embodiments are part of the embodiments of the present invention, not all of them. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without making creative efforts should fall within the scope of protection of the present invention.

[0033] The present invention provides an embedded software fault anchor point location and analysis device and method. "Anchor points" are a common hyperlink technology used to enable jumps between the same or multiple pages. Using anchor point location, fault assertions are proactively added during the software compilation phase to generate a dynamic fault code table. When a fault occurs, the location of the fault is located by backtracking to the anchor points. Furthermore, auxiliary tools can be used to determine the cause of the fault and mitigate its impact.

[0034] like Figure 1 As shown, a method for locating and analyzing an embedded software fault anchor point includes the following steps:

[0035] Step 1: After the fault anchor point location analysis device is started, the user sets a special string to identify the fault point in the configuration module, such as "POINT_NULL_ERROR", "PARAM_RANGE_ERROR", etc.

[0036] Step 2: Set each fault message in the configuration module using the anchor format "ID + Name + Location + Description + Fault Response." For example, "E001, POINT_NULL_ERROR, Null Pointer Exception, Module Replacement and Repair." The fault response can be referenced from the maintenance manual.

[0037] Step 3: Enable the loading module, import the required software code h, and insert the fault anchor point set in step 2 into the code according to the identification symbol in step 1;

[0038] In step 4, the loading module can be linked to the system compilation tool i. When compiling the software image, the fault trigger point is automatically located based on the anchor point position, and this information is used as additional anchor point information. For example, "E001, POINT_NULL_ERROR, Null Pointer Exception, Module Replacement and Repair, Test1.c123 line." The entire project file is searched in the same way to generate a fault list.

[0039] In steps 5 and 6, the monitoring module is enabled during software operation to continuously monitor operational maintenance information. Keyword matching is automatically performed on log information, maintenance printouts, and other information. When a downtime or abnormality message is generated, the fault point is located based on the anchor point.

[0040] Step 7: According to the fault list, handle it according to the preset treatment measures.

[0041] Step 8: Start the download module to automatically download the maintenance log and memory dump information. The maintenance log can be uploaded to a remote maintenance station for backup.

[0042] In step 9, the maintenance personnel start the analysis module, record the system operation status according to the log, and analyze the memory dump information to determine the cause of the fault.

[0043] Step 10: Record the analysis report in the analysis module. The report can also be uploaded to the remote maintenance station for backup.

[0044] The above is an introduction to a method embodiment. The following further illustrates the solution of the present invention through an apparatus embodiment.

[0045] like Figure 2 Figure 1 shows an embedded software fault anchor point location and analysis device. The device includes a configuration module a, a loading module b, a monitoring module c, a download module d, and an analysis module e. These modules can operate independently and are connected via an Ethernet switch f. Configuration module a is connected to the maintenance manual g via a dialog box. Loading module b is connected to the software code h via a dialog box and to the compilation tool i via a control. Monitoring module c is connected to the maintenance information i via a control.

[0046] 1. Configure module a:

[0047] Configuration module a is used to set the code fault identification point and quote the maintenance manual to allow maintenance personnel to describe the fault details.

[0048] 2. Loading module b:

[0049] The loading module b is used to insert fault anchor points into the imported embedded code, and the associated compilation tool automatically generates a fault list during the software compilation process.

[0050] 3. Monitoring module c:

[0051] The monitoring module c is used to monitor the maintenance information of software downtime or exception throwing during software operation, and use anchor points to locate the fault list information.

[0052] 4. Download module d:

[0053] Download Module d can download software maintenance logs and memory dump information after a fault occurs. This module can be used by maintenance personnel to further analyze the cause of the fault. This module can also back up maintenance logs to the system maintenance console k.

[0054] 5. Analysis module e:

[0055] After a fault occurs, the analysis module e can track the memory dump information and find the parameter variable information at the time of the fault, so as to find the specific cause of the fault. This module can also generate a fault analysis report and send it to the system maintenance station k.

[0056] This device utilizes anchor point positioning to generate a code table for potential faults during the R&D phase, even during the software compilation phase. When a fault occurs, anchor point positioning pinpoints the fault location, allowing for rapid resolution based on the defined handling method. It also provides log and memory dump analysis capabilities to identify and analyze the root cause of the fault, and generates reports that can be uploaded to the maintenance desk in real time. This significantly reduces maintenance personnel's workload and enables a comprehensive process from R&D to maintenance.

[0057] Those skilled in the art can clearly understand that, for the convenience and brevity of description, the specific working process of the described module can refer to the corresponding process in the aforementioned method embodiment, and will not be repeated here.

[0058] The electronic device of the present invention includes a central processing unit (CPU), which can perform various appropriate actions and processes according to computer program instructions stored in a read-only memory (ROM) or loaded from a storage unit into a random access memory (RAM). In the RAM, various programs and data required for device operation can also be stored. The CPU, ROM, and RAM are connected to each other via a bus. An input / output (I / O) interface is also connected to the bus.

[0059] Many components in a device are connected to the I / O interface, including: input units, such as a keyboard and mouse; output units, such as various types of displays and speakers; storage units, such as magnetic disks and optical disks; and communication units, such as network cards, modems, and wireless communication transceivers. The communication unit allows the device to exchange information / data with other devices via computer networks such as the Internet and / or various telecommunication networks.

[0060] The processing unit performs the various methods and processes described above, such as steps 1 to 10 of the method. For example, in some embodiments, steps 1 to 10 of the method may be implemented as a computer software program, which is tangibly contained in a machine-readable medium, such as a storage unit. In some embodiments, part or all of the computer program may be loaded and / or installed on the device via a ROM and / or a communication unit. When the computer program is loaded into the RAM and executed by the CPU, one or more of steps 1 to 10 of the method described above may be performed. Alternatively, in other embodiments, the CPU may be configured to execute steps 1 to 10 of the method by any other appropriate means (e.g., by means of firmware).

[0061] The functions described above herein may be performed, at least in part, by one or more hardware logic components. For example, and without limitation, exemplary types of hardware logic components that may be used include: field programmable gate arrays (FPGAs), application specific integrated circuits (ASICs), application specific standard products (ASSPs), systems on chip (SOCs), complex programmable logic devices (CPLDs), and the like.

[0062] The program code for implementing the method of the present invention can be written in any combination of one or more programming languages. Such program code can be provided to a processor or controller of a general-purpose computer, a special-purpose computer, or other programmable data processing device so that when the program code is executed by the processor or controller, the functions / operations specified in the flow chart and / or block diagram are implemented. The program code can be executed entirely on the machine, partially on the machine, as a stand-alone software package, partially on the machine and partially on a remote machine, or entirely on a remote machine or server.

[0063] In the context of the present invention, machine-readable medium can be a tangible medium that can contain or store a program for use with an instruction execution system, device or equipment or used in combination with an instruction execution system, device or equipment. Machine-readable medium can be a machine-readable signal medium or a machine-readable storage medium. Machine-readable medium can include, but is not limited to, electronic, magnetic, optical, electromagnetic, infrared or semiconductor systems, devices or equipment, or any suitable combination of the foregoing. More specific examples of machine-readable storage media can include electrical connections based on one or more lines, portable computer disks, hard disks, random access memories (RAM), read-only memories (ROM), erasable programmable read-only memories (EPROM or flash memory), optical fibers, portable compact disk read-only memories (CD-ROM), optical storage devices, magnetic storage devices, or any suitable combination of the foregoing.

[0064] The above description is merely a specific embodiment of the present invention, but the scope of protection of the present invention is not limited thereto. Any person skilled in the art can easily conceive of various equivalent modifications or substitutions within the technical scope disclosed in the present invention, and such modifications or substitutions are intended to be within the scope of protection of the present invention. Therefore, the scope of protection of the present invention shall be subject to the scope of protection of the claims.

Claims

1. A method for locating and analyzing embedded software fault anchor points, characterized in that: This method uses anchor point positioning to proactively add fault assertions during the software compilation phase to generate a dynamic fault code table. When a fault occurs, the location of the fault is located by backtracking the anchor points. At the same time, auxiliary tools are used to query the cause of the fault and eliminate its impact. The method comprises the following steps: Step S1, start the fault anchor point location analysis device and set the fault point search keyword in the configuration module; Step S2: setting corresponding information of each type or each fault in the configuration module; Step S3, starting the loading module, retrieving the code anchor point pile after loading the code, and automatically inserting the set fault anchor point into the code; Step S4, loading the module-related software compilation tool, and the software compilation tool generates a fault list according to the fault keywords; Step S5: During the operation of the embedded software, the monitoring module automatically matches keywords to the relevant information; when a downtime or abnormal information is thrown, the fault point is located according to the anchor point and quickly processed in combination with the preset processing measures; and the download module is started to automatically download the log and memory dump information; Step S6: The download module converts the downloaded log into text and archives it, which can be uploaded to the remote maintenance station. The downloaded memory information is sent to the analysis module. Step S7: The analysis module analyzes the downloaded memory information, queries task information, stack information, key variable information, and message queue, and finds the key points of the problem in combination with the fault list; The anchor point is a hyperlink technology used to dynamically jump between the same page or multiple pages.

2. The method for locating and analyzing an embedded software fault anchor point according to claim 1, characterized in that: The corresponding information in step S2 adopts the anchor point format "ID+name+description" and is attached with the response measures for each fault, and is associated with the maintenance manual.

3. The method for locating and analyzing an embedded software fault anchor point according to claim 1, characterized in that: The relevant information in step S5 includes log information and maintenance print information.

4. A device for the embedded software fault anchor point location analysis method according to claim 1, characterized in that: The device comprises a configuration module, a loading module, a monitoring module, a downloading module and an analysis module, each of which can work independently. The configuration module, loading module, monitoring module, downloading module and analysis module are respectively connected to a system maintenance platform.

5. The device according to claim 4, characterized in that The configuration module is used to set the code fault identification point and refer to the maintenance manual to allow maintenance personnel to describe the fault details.

6. The device according to claim 4, characterized in that The loading module is used to insert fault anchor points into the imported embedded code, and the associated compilation tool automatically generates a fault list during the software compilation process.

7. The device according to claim 4, characterized in that The monitoring module is used to monitor maintenance information of software downtime or exception throwing during software operation, and locate fault list information using anchor points.

8. The device according to claim 4, characterized in that The download module is used to download software maintenance logs and memory dump information after a fault occurs, so that maintenance personnel can further analyze the cause of the fault.

9. The device according to claim 4, characterized in that The analysis module is used to track the memory dump information after a fault occurs, and find out the parameter variable information when the fault occurs, so as to find out the specific cause of the fault.

10. An electronic device comprising a memory and a processor, wherein a computer program is stored in the memory, wherein: When the processor executes the program, the method according to any one of claims 1 to 3 is implemented.

11. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the program is executed by a processor, the method according to any one of claims 1 to 3 is implemented.

Citation Information

Patent Citations

  • Devices, systems, and methods regarding a plc system fault

    CN101523317A

  • Photovoltaic panel fault spot detection and identification method and system

    CN109525194A