Embedded software data monitoring tool

By introducing data monitoring tools in embedded software, the problem that complex data objects cannot be monitored in real time is solved, real-time monitoring and graphical display of embedded software data is realized, and the efficiency of software debugging and operation is improved.

CN119883810APending Publication Date: 2025-04-25XIAN AVIATION COMPUTING TECH RES INST OF AVIATION IND CORP OF CHINA
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202411957008.7
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-12-29
Publication Date
2025-04-25

AI Technical Summary

Technical Problem

In embedded software development, complex data objects cannot be monitored in real time, making it difficult to analyze and diagnose problems during software debugging and running.

Method used

By introducing a data monitoring tool in the embedded software, the tool includes a monitoring configuration module, a graphical display view, a playback monitoring module and an MMU memory query service, it realizes dynamic collection and real-time monitoring of data related to the target machine device.

Benefits of technology

Real-time monitoring and graphical display of embedded software data is realized, which facilitates developers to analyze data characteristics and realizes post-traceback and playback monitoring by saving process data.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119883810A_ABST
    Figure CN119883810A_ABST
Patent Text Reader

Abstract

The invention belongs to the professional technical field of computer system software, and particularly relates to an embedded software data monitoring tool which is used for analyzing, debugging and monitoring complex data objects in embedded software development. The tool provides a set of display modes including broken line diagrams, histograms, pie diagrams and table forms, and developers are helped to quickly analyze data characteristics. The complex objects refer to variables of types such as char, int, long and bool. The tool is based on a mapping relation from a virtual address space to a physical address space in a memory management unit (MMU), realizes conversion of physical addresses and virtual addresses in different modes of single application and multiple partitions in a shared data area by means of a memory reading interface, and obtains data of a corresponding physical space on a target board by depending on a remote target machine agent. And finally, sending to a host machine end through a network for processing and presenting.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The invention belongs to the technical field of computer system software, and in particular relates to an embedded software data monitoring tool. Background Art

[0002] Current embedded software has put forward higher requirements for reliability, safety and maintainability. In order to meet the requirements of embedded software data analysis and processing, the amount of data monitored and recorded online is increasing. According to incomplete statistics, the number of variables related to airborne system software fault information has reached tens of thousands. Therefore, in order to ensure the safe and stable operation of equipment, the monitoring task of embedded software variables is particularly important.

[0003] Data monitoring tools for embedded system software are an effective way to ensure equipment safety and reduce usage and maintenance costs. Data monitoring tools can record the working status and operating parameters of each subsystem in the system software in real time, and can indirectly realize online monitoring, monitoring backtracking fault diagnosis and indication alarms. In view of the diversity and complexity of data, it is necessary to realize online classification, screening and storage of all working data. At the same time, in order to intuitively display the changing trends of different data, data monitoring tools support display methods including line charts, bar charts, pie charts and tables to help developers quickly analyze data characteristics during program running or debugging. Therefore, embedded system software is increasingly eager for an embedded software data monitoring tool that can monitor online and replay monitoring. Summary of the invention

[0004] In view of this, the present invention provides an embedded software data monitoring tool, which dynamically collects target machine device related data, presents the real-time data of the monitored object of the target machine device to the user, and helps the user analyze the impact of the data change characteristics of the monitored object on the software operation.

[0005] The technical solution of the present invention:

[0006] An embedded software data monitoring tool includes the following functional modules:

[0007] Monitoring configuration module, used to configure ELF files, monitoring variables, variable types, display bases, monitoring frequencies, monitoring object lengths, display formats, target boards, and monitoring data storage directories;

[0008] Graphical display view, supporting users to customize the display format of monitoring results;

[0009] The replay monitoring module is used to open the monitoring results stored locally and trace back the monitoring history;

[0010] MMU memory query service obtains the physical address of the monitored object through MMU mapping, and obtains the corresponding memory data based on the physical address query.

[0011] Further, the configuration ELF file: the embedded software compiles the source code and generates a binary target code in ELF format and sends it to the target board for debugging or operation, and the monitoring object of the data monitoring tool comes from the configured ELF file;

[0012] Configure monitoring variables: After configuring the ELF file, all variables in the ELF file are listed in the form of disassembly, and the user selects the object he wants to monitor based on the listed variables;

[0013] Select variable type: used to specify the default unit space size monitored by the monitoring tool; variable types include INT32, BOOL, FLOAT, INT64, DOUBLE and CHAR;

[0014] Set the display system: used to set the monitoring display result to binary, decimal or hexadecimal form;

[0015] Setting monitoring frequency: used to set the display frequency of monitoring results to 0.5s, 1s, 2s, 5s or 10s. The monitoring tool also supports manual immediate refresh of monitoring results.

[0016] Setting the monitored object length: used to specify the default unit space size monitored by the monitoring tool; the priority of setting the monitored object length is higher than the variable type selection;

[0017] Select the display format: Provide users with customized choices based on graphical displays;

[0018] Select monitoring target board: Select the target board for program debugging or running to establish a monitoring connection between the target board and the monitoring tool;

[0019] Set the monitoring data storage directory: used to select the storage path of monitoring data on the host side. The monitoring data is stored in XML format for later replay monitoring.

[0020] Furthermore, during the monitoring process, the real-time data of the monitored object is stored in the format of an XML file based on the selected path, where the file name is named after the variable name and the monitoring start time, and the file content includes all configuration items configured by the monitoring configuration module, the monitoring start address and the monitoring results.

[0021] Configuration items include monitoring variable name, variable type, display base, monitoring frequency, monitoring object length and target board name;

[0022] The stored file content also includes the real-time collected data values ​​of the monitored objects, which are recorded in hexadecimal form. In the case of simultaneously recording multiple monitored objects, the real-time collected data values ​​are recorded in layers in the form of XML tree nodes.

[0023] Furthermore, the MMU memory query service establishes an MMU-based space isolation mechanism for applications that the monitored objects depend on; the operating system will allocate available physical space to the application according to the different space requirements of each application, establish a mapping between the physical space and the logical space, and record the space mapping table as private data of domain management; wherein each domain occupies an independent and non-overlapping physical space, and the logical space corresponding to each domain is set according to user needs; the memory size allocated to each application is aligned with the MMU page.

[0024] Furthermore, the monitoring tool implements the conversion between physical addresses and virtual addresses based on the memory mapping relationship of the MMU, forming a reading interface for the monitoring tool to the monitored object, and the reading interface obtains the memory data under the corresponding physical address by calling the operating system kernel.

[0025] Beneficial effects of the present invention:

[0026] The present invention aims at the data monitoring technology of embedded software development, uses a method based on MMU mapping to obtain memory data and graphically display it through processing, solves the problem that complex data objects cannot be monitored in real time during software debugging and operation, and saves the collected process data to facilitate later backtracking and replay of the monitoring process. BRIEF DESCRIPTION OF THE DRAWINGS

[0027] In order to more clearly illustrate the technical solutions of the embodiments of the present disclosure, the drawings required for use in the embodiments will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present disclosure. For ordinary technicians in this field, other drawings can be obtained based on these drawings without creative work.

[0028] Figure 1 : Data monitoring tool module composition;

[0029] Figure 2 : Data monitoring tool execution process. DETAILED DESCRIPTION

[0030] The embodiments of the present disclosure are described in detail below with reference to the accompanying drawings.

[0031] The following describes the embodiments of the present disclosure through specific examples, and those skilled in the art can easily understand other advantages and effects of the present disclosure from the contents disclosed in this specification. Obviously, the described embodiments are only a part of the embodiments of the present disclosure, rather than all of the embodiments. The present disclosure can also be implemented or applied through other different specific embodiments, and the details in this specification can also be modified or changed in various ways based on different viewpoints and applications without departing from the spirit of the present disclosure. It should be noted that the following embodiments and features in the embodiments can be combined with each other without conflict. Based on the embodiments in the present disclosure, all other embodiments obtained by ordinary technicians in the field without making creative work are within the scope of protection of the present disclosure.

[0032] It should be noted that various aspects of the embodiments within the scope of the appended claims are described below. It should be apparent that the aspects described herein can be embodied in a wide variety of forms, and any specific structure and / or function described herein is merely illustrative. Based on the present disclosure, it should be understood by those skilled in the art that an aspect described herein can be implemented independently of any other aspect, and two or more of these aspects can be combined in various ways. For example, any number of aspects described herein can be used to implement the device and / or practice the method. In addition, other structures and / or functionalities other than one or more of the aspects described herein can be used to implement this device and / or practice this method.

[0033] It should also be noted that the illustrations provided in the following embodiments are only schematic illustrations of the basic concept of the present disclosure. The illustrations only show components related to the present disclosure rather than being drawn according to the number, shape and size of components in actual implementation. In actual implementation, the type, quantity and proportion of each component may be changed arbitrarily, and the component layout may also be more complicated.

[0034] Additionally, in the following description, specific details are provided to facilitate a thorough understanding of the examples. However, it will be understood by those skilled in the art that the aspects described may be practiced without these specific details.

[0035] In one embodiment of the present invention, referring to Figure 1 , 2 , an embedded software data monitoring tool is proposed, which includes the following functional modules:

[0036] Monitoring configuration module, used to configure ELF files, monitoring variables, variable types, display bases, monitoring frequencies, monitoring object lengths, display formats, target boards, and monitoring data storage directories;

[0037] Graphical display view, supporting users to customize the display format of monitoring results;

[0038] The replay monitoring module is used to open the monitoring results stored locally and trace back the monitoring history;

[0039] MMU memory query service obtains the physical address of the monitored object through MMU mapping, and obtains the corresponding memory data based on the physical address query.

[0040] In this embodiment, the ELF file is configured: the embedded software compiles the source code and generates a binary target code in the ELF format and sends it to the target board for debugging or operation, and the monitoring object of the data monitoring tool comes from the configured ELF file;

[0041] Configure monitoring variables: After configuring the ELF file, all variables in the ELF file are listed in the form of disassembly, and the user selects the object he wants to monitor based on the listed variables;

[0042] Select variable type: used to specify the default unit space size monitored by the monitoring tool; variable types include INT32, BOOL, FLOAT, INT64, DOUBLE and CHAR;

[0043] Set the display system: used to set the monitoring display result to binary, decimal or hexadecimal form;

[0044] Setting monitoring frequency: used to set the display frequency of monitoring results to 0.5s, 1s, 2s, 5s or 10s. The monitoring tool also supports manual immediate refresh of monitoring results.

[0045] Setting the monitored object length: used to specify the default unit space size monitored by the monitoring tool; the priority of setting the monitored object length is higher than the variable type selection;

[0046] Select the display format: Provide users with customized choices based on graphical displays;

[0047] Select monitoring target board: Select the target board for program debugging or running to establish a monitoring connection between the target board and the monitoring tool;

[0048] Set the monitoring data storage directory: used to select the storage path of monitoring data on the host side. The monitoring data is stored in XML format for later replay monitoring.

[0049] In this embodiment, during the monitoring process, the real-time data of the monitored object is stored in the format of an XML file based on a selected path, where the file name is named after the variable name and the monitoring start time, and the file content includes all configuration items configured by the monitoring configuration module, the monitoring start address and the monitoring results.

[0050] Configuration items include monitoring variable name, variable type, display base, monitoring frequency, monitoring object length and target board name;

[0051] The stored file content also includes the real-time collected data values ​​of the monitored objects, which are recorded in hexadecimal form. In the case of simultaneously recording multiple monitored objects, the real-time collected data values ​​are recorded in layers in the form of XML tree nodes.

[0052] In this embodiment, the MMU memory query service establishes an MMU-based space isolation mechanism for the applications that the monitored objects depend on; the operating system will allocate available physical space to the applications according to the different space requirements of each application, establish a mapping between the physical space and the logical space, and record the space mapping table as private data of domain management; wherein each domain occupies an independent and non-overlapping physical space, and the logical space corresponding to each domain is set according to the user's needs; the memory size allocated to each application is aligned with the MMU page.

[0053] In this embodiment, the monitoring tool implements the conversion between physical addresses and virtual addresses based on the memory mapping relationship of the MMU, forming a reading interface for the monitoring tool to the monitored object, and the reading interface obtains the memory data under the corresponding physical address by calling the operating system kernel.

[0054] The main functions implemented by this embodiment include:

[0055] (1) Monitoring configuration module

[0056] It is used to configure ELF files, monitoring variables, variable types, display base, monitoring frequency, monitoring object length, display format, target board, monitoring data storage directory and other information.

[0057] Configure ELF file: Embedded software development mainly compiles the source code and generates binary target code in Elf format and sends it to the target board for debugging or running. The object of the data monitoring tool will come from this file;

[0058] Configure monitoring variables: After configuring the ELF file, all variables in the ELF file can be listed in the form of disassembly, and the user can select the object he wants to monitor;

[0059] Select variable type: Selecting variable type is to tell the monitoring tool the default unit space size to monitor. The specific variable types are INT32, BOOL, FLOAT, INT64, DOUBLE, and CHAR.

[0060] Set the display system: You can choose to set it to binary, decimal or hexadecimal according to different data types and data sizes;

[0061] Set monitoring frequency: According to different data characteristics, users can select frequencies of 0.5s, 1s, 2s, 5s, and 10s. To meet different user needs, the monitoring tool supports manual immediate refresh of monitoring data.

[0062] Set the length of the monitored object: Users can specify the default unit space size monitored by the monitoring tool, which has a higher priority than the value set by the variable type;

[0063] Select display format: user-defined display format in graphical display view;

[0064] Select monitoring target board: Select the target board for program debugging or running to establish monitoring connection;

[0065] Set the monitoring data storage directory: Select the storage path of the monitoring data on the host side and store it in XML format to facilitate later replay monitoring.

[0066] (2) Graphical display view

[0067] Supports users to customize and select line charts, bar charts, pie charts, tables and other formats.

[0068] Users can select different display formats based on the characteristics of the monitored object to more intuitively obtain the changing characteristics of the monitored object. For the case of monitoring multiple variable objects at the same time, the four display formats can be distinguished by different colors.

[0069] (3) Replay monitoring module

[0070] Users can open the monitoring results stored locally and trace back the monitoring history.

[0071] During the monitoring process, the real-time data of the monitored object will be stored in the form of an XML file, where the file name is named after the variable name and the monitoring start time. The file content includes some configuration information in module 1, including the monitoring variable name, variable type, display base, monitoring frequency, monitoring object length, target board, and monitoring start address, etc. This information is displayed in a prominent position during replay monitoring, and is used to restore the monitoring scene during graphical display. The file content also includes the real-time collected data value of the monitored object. Considering the storage space occupied by the monitoring data record file, the collected values ​​are recorded in hexadecimal form. For the case of recording multiple monitored objects at the same time, the hierarchical record is used here in the form of XML tree nodes.

[0072] (4)MMU memory query service

[0073] The MMU (Memory Management Unit) memory query service is a background service that provides source data for display to the graphical display module, including communication services between the host and target machines and memory query services on the target machine.

[0074] MMU is one of the basic components of the central processing unit. Through MMU, on the one hand, the mapping of virtual address space to physical address space can be realized, and on the other hand, the corresponding read and write attributes can be added to this mapping relationship. With the support of MMU, the MMU memory query service establishes an MMU-based space isolation mechanism for applications. The operating system will allocate available physical space to each application according to its different space requirements, and establish a mapping between physical space and logical space for it, and use the space mapping table as a private data record for domain management. Each domain has independent and non-overlapping physical space, and its logical space will be set according to user needs. The logical addresses of different domains can be the same or different. The allocated memory size must be MMU page aligned. The specific memory read interface implementation needs to use this mapping relationship to realize the conversion between physical address and virtual address. The memory data under the corresponding physical address is finally obtained by calling the operating system kernel.

[0075] The above is only a specific implementation of the present disclosure, but the protection scope of the present disclosure is not limited thereto. Any changes or substitutions that can be easily thought of by a person skilled in the art within the technical scope disclosed in the present disclosure should be included in the protection scope of the present disclosure. Therefore, the protection scope of the present disclosure should be based on the protection scope of the claims.

Claims

1. An embedded software data monitoring tool, characterized in that: Includes the following functional modules: Monitoring configuration module, used to configure ELF files, monitoring variables, variable types, display bases, monitoring frequencies, monitoring object lengths, display formats, target boards, and monitoring data storage directories; Graphical display view, supporting users to customize the display format of monitoring results; The replay monitoring module is used to open the monitoring results stored locally and trace back the monitoring history; MMU memory query service obtains the physical address of the monitored object through MMU mapping, and obtains the corresponding memory data based on the physical address query.

2. The embedded software data monitoring tool according to claim 1, characterized in that: Described configuration ELF file: Described embedded software compiles source code and generates binary target code in ELF format and sends it to target board for debugging or running. The monitoring object of data monitoring tool comes from the configured ELF file; Configure monitoring variables: After configuring the ELF file, all variables in the ELF file are listed in the form of disassembly, and the user selects the object he wants to monitor based on the listed variables; Select variable type: used to specify the default unit space size monitored by the monitoring tool; variable types include INT32, BOOL, FLOAT, INT64, DOUBLE and CHAR; Set the display system: used to set the monitoring display result to binary, decimal or hexadecimal form; Setting monitoring frequency: used to set the display frequency of monitoring results to 0.5s, 1s, 2s, 5s or 10s. The monitoring tool also supports manual immediate refresh of monitoring results. Setting the monitored object length: used to specify the default unit space size monitored by the monitoring tool; the priority of setting the monitored object length is higher than the variable type selection; Select the display format: Provide users with customized choices based on graphical displays; Select monitoring target board: Select the target board for program debugging or running to establish a monitoring connection between the target board and the monitoring tool; Set the monitoring data storage directory: used to select the storage path of monitoring data on the host side. The monitoring data is stored in XML format for later replay monitoring.

3. The embedded software data monitoring tool according to claim 2, characterized in that: During the monitoring process, the real-time data of the monitored object is stored in the format of an XML file based on the selected path. The file name is named after the variable name and the monitoring start time. The file content includes all configuration items configured by the monitoring configuration module, the monitoring start address and the monitoring results. Configuration items include monitoring variable name, variable type, display base, monitoring frequency, monitoring object length and target board name; The stored file content also includes the real-time collected data values ​​of the monitored objects, which are recorded in hexadecimal form. In the case of simultaneously recording multiple monitored objects, the real-time collected data values ​​are recorded in layers in the form of XML tree nodes.

4. The embedded software data monitoring tool according to claim 3, characterized in that: The MMU memory query service establishes an MMU-based space isolation mechanism for applications that the monitored object depends on; the operating system will allocate available physical space to the application according to the different space requirements of each application, establish a mapping between physical space and logical space, and record the space mapping table as private data of domain management; wherein each domain occupies an independent and non-overlapping physical space, and the logical space corresponding to each domain is set according to user needs; the memory size allocated to each application is aligned with the MMU page.

5. The embedded software data monitoring tool according to claim 4, characterized in that: The monitoring tool realizes the conversion between physical address and virtual address based on the memory mapping relationship of MMU, and forms a reading interface of the monitoring tool to the monitored object. The reading interface obtains the memory data under the corresponding physical address by calling the operating system kernel.