CN101609338A - A kind of method and device to test of embedded device Real-time and Dynamic and localization of fault - Google Patents
A kind of method and device to test of embedded device Real-time and Dynamic and localization of fault Download PDFInfo
- Publication number
- CN101609338A CN101609338A CNA2008101151959A CN200810115195A CN101609338A CN 101609338 A CN101609338 A CN 101609338A CN A2008101151959 A CNA2008101151959 A CN A2008101151959A CN 200810115195 A CN200810115195 A CN 200810115195A CN 101609338 A CN101609338 A CN 101609338A
- Authority
- CN
- China
- Prior art keywords
- function
- embedded device
- instruction
- fault
- compiling
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Pending
Links
Images
Abstract
The invention provides a kind of method and device to test of embedded device Real-time and Dynamic and localization of fault, wherein device comprises: the script load bearing unit, be used to carry function and interfere instruction, the interventional operations predetermined the function setup in the source code of embedded device; The script compile unit is used for interfering compiling of instruction to become the identified documentation of described embedded device the described function of described script load bearing unit; Code pile element built-in system environment compiler, and in the process of carrying out system's compiling generation identified documentation, the machine instruction stake is set in described source code; Performance element is used to carry out described identified documentation.Use this Real-time and Dynamic provided by the invention flexible fast method of test and localization of fault on embedded device, do not needing to recompilate on the source code code base, satisfied engineering technical personnel and interfered the realization fault location, and collected the demand of real-time field monitoring information by certain function.
Description
Technical field
The present invention relates to the embedded device measuring technology, be meant a kind of method and device especially test of embedded device Real-time and Dynamic and localization of fault.
Background technology
In recent years along with embedded device technology constantly develops, for example the embedded device system is huge all the more, the business service that embedded device function and common carrier are provided constantly increases, and the user is for multifunctionality, practicality, the quality and also more and more higher for the requirement of business service of embedded device simultaneously; Also constantly produce simultaneously the embedded device requirement of upgrading fast, thereby in the course of work of embedded device, various bugs and unusual probability increasing appear, and how the location error message of quick and convenient or the testing requirement of response upgrading fast, becoming embedded device manufacturer and operator needs the urgent problem that solves.
In the prior art, in the embedded system field, test and debugging are faced with a lot of difficult problems all the time.Write test case and operation, debugging location wrong (bug) often also needs to expend a large amount of time; Mobile terminal system for example, sometimes do not having under the related commissioning instrument situation, modification or localization of fault need load in to the source code of embedded device after test procedure or the code mostly each time, all need to cause localization of fault and test, upgrading cycle long defective consuming time through loaded down with trivial details processes such as compiling, burning machines.。
Summary of the invention
The purpose of this invention is to provide a kind of method and device, be used for solving prior art, localization of fault and test, upgrading cycle long defective consuming time test of embedded device Real-time and Dynamic and localization of fault.
A kind of device to test of embedded device Real-time and Dynamic and localization of fault, the script load bearing unit is used to carry function and interferes instruction, and described function is interfered the instruction interventional operations predetermined to the function setup in the source code of embedded device; The script compile unit is used for interfering compiling of instruction to become the identified documentation of described embedded device the described function of described script load bearing unit; The code pile element is used for built-in system environment compiler, and carries out in the process of the described identified documentation of system's compiling generation the machine instruction stake being set in described source code in described script compile unit; Performance element is used for carrying out described identified documentation according to described machine instruction stake.
A kind of method to embedded device Real-time and Dynamic test and localization of fault compiles the generation compiling file to the source code of embedded device; Described compiling file and the subsidiary performance element of described embedded device are fired on the described embedded device; Function is set interferes instruction and compiling to generate identified documentation, and the machine instruction stake is set in the described source code; Described embedded device is carried out described identified documentation according to described machine instruction stake.
Use this Real-time and Dynamic provided by the invention flexible fast method of test and localization of fault on embedded device, do not needing to recompilate on the source code code base, satisfied engineering technical personnel and interfered the realization fault location, and collected the demand of real-time field monitoring information by certain function.
Description of drawings
Fig. 1 is a preferred embodiment of the present invention embedded device inner structure synoptic diagram;
Fig. 2 has the embedded device inner structure synoptic diagram of diagnostic engine for the preferred embodiment of the present invention;
Fig. 3 is instruction and response load mode synoptic diagram between preferred embodiment of the present invention server and the diagnostic engine;
Fig. 4 is the workflow synoptic diagram of the preferred embodiment of the present invention.
Embodiment
For making purpose of the present invention, technical characterictic and implementation result clearer, below in conjunction with the accompanying drawings and the specific embodiments technical scheme of the present invention is described in detail.
The embodiment of the invention provides a kind of method and device (Gishow, below refer to this method and device with Gishow) to embedded device Real-time and Dynamic test and localization of fault; Embedded device is by triggering technique and data acquisition technology, the equipment failure that occurs in this built-in equipment operation and the communication process and the service exception of appearance are monitored, and collection in worksite is diagnosed according to this monitoring information by server about the monitoring information of described equipment failure and service exception and send to server.Be specially:
Based on Gishow method or device, the technician adopts a kind of specific program language, for each function that needs in the source code in the embedded device to pay close attention to adds types of functionality, and optionally writing down the on-the-spot real-time information of being concerned about, the embedded device source code does not need the recompility structure to fire simultaneously.As shown in Figure 1, built-in diagnostic engine 101 of this embedded device and memory module 103; Wherein the effect of each module is as follows:
The mode of operation of diagnostic engine 101 comprises at least:
Carry out the preset operation instruction when mode of operation 1. is triggered, collect the embedded device monitoring information and send to server as required according to this operational order.In the mode of operation 1, fault or unusual appearance can trigger diagnostic engine 101 and monitor, and at this moment, do not instruct from the monitoring of server; For instance, fault or have an error code unusually can trigger diagnostic engine 101 with this code and obtain corresponding monitoring information, and send to server.
Mode of operation 2. receives the monitoring instruction from server, and monitoring information is monitored and formed to the equipment failure or the service exception that are occurred in the embedded device course of work, collects the monitoring information of embedded device and sends to server as required.In the mode of operation 2, server sends to diagnostic engine 101 monitoring instructions, and this monitoring instruction comprises a plurality of monitoring tasks that server end issues, and each monitoring task has unique task recognition sign indicating number, and (ID, IDentity), this task ID is specified by server is unified.
Above-mentioned two kinds of mode of operations relate to the mutual of server and embedded device, normally realize with air interface technologies OTA, do not get rid of the possibility of using other technology certainly; Be that example is described with OTA technology commonly used below, as shown in Figure 2, server to the instruction of diagnostic engine 101 transmitting supervisories, is asked diagnostic engine 101 transmitting supervisory information by air interface technologies OTA, and diagnostic engine 101 carries out transmitting supervisory information according to this monitoring instruction.Described OTA is to subscriber identification module (SIM by air interface, Subscriber Identity Module) blocks the technology that telemanagement is carried out in data and application, air interface can adopt WAP (wireless application protocol) (WAP, Wireless Application Protocol), GPRS (GPRS, General Packet Radio Service), CDMA inserts 1X (CDMA1X, CodeDivision Multiple Access 1X) and short message technology.
For realizing goal of the invention, the operation of each function that utilizes Gishow to interfere in the source code in real time in the embedded device to be paid close attention to, locating the fault that occurs in the described source code and unusual, or do test or do for new upgrading and verify easily and survey for the next-generation technology scheme.These functions all can be integrated in the authentication module 102 of embedded device:
Script load bearing unit 1023 is used for the needs according to the user, carries concrete function and interferes instruction, and these functions interfere instruction to make distinct interference setting to each the function behavior in the embedded device system.C language or class C language have been adopted in the exploitation of the source code of embedded device mostly, and therefore preferably, script load bearing unit 1023 should be supported the script definition of C language or class C language at least, and generate the script file of .mlc form.Function in the script load bearing unit 1023 interferes instruction to be modified at any time, makes the behavior change of mobile phone.
Described interference instruction is used for function operation is interfered, and therefore comprised various content: such as the suction parameter of revising function, a new function is carried out in the execution of perhaps replacing this function.Perhaps allow the execution time of this function postpone.Perhaps not carrying out this function reacts with observing system.Perhaps note the environmental information of current function.Perhaps change the rreturn value of function.Perhaps, executive operating system external interface order in specific subprocess, the specific subprocess here can be current function; Wherein in Linux, the operating system external interface is meant Shell, and Shell is used to manage mutual between the external program logical and (SuSE) Linux OS.
The unit is set, is used for after described compilation of source code forms identified documentation,, being placed under the path that sets in advance described identified documentation.
In order to prove absolutely the principle of work of the device to embedded device Real-time and Dynamic test and localization of fault provided by the invention, below select a preferred embodiment that principle of work is described:
Step 401. compiles source code by code pile element 1021 (for example mv_make), compiling file that corresponding application program or system program are generated and subsidiary performance element 104 dynamic base of virtual machine (for example as) burn on the embedded device.
Step 402. is provided with script load bearing unit 1023, that is, write the shell script .mlc that comprises function interference instruction and specify the interference that some function of system is wanted; For example allow certain function return a specific value, to observe the influence of correlative code to the embedded device system.
Step 403. is utilized script compile unit 1022 script compile in the script load bearing unit 1023 to be become the machine code binary file on main frame and is put under the embedded device specific directory.
Related application on the step 404. operation embedded device is checked implementation effect;
Perhaps by the on-the-spot monitoring information of diagnostic engine 101 records.
Step 405. is given server by diagnostic engine 101 transmitting supervisory information.
In the script load bearing unit 1023, the organizational form of script can adopt extensible markup language (XML, EXtensible Markup Language) to realize, so that interfere instruction to carry out concrete diversified definition to used function.
Described server can be a diagnosis server, and this server can be managed by common carrier and/or embedded device manufacturer, and diagnoses according to monitoring information, thereby determines fault type, and based on this instruction that recovers or repair.
Server comprises a unusual and fault diagnosis module, reaches fault management module unusually; Described unusual and fault management module is used for the unusual and device fault information of identification service, and sends instructions to embedded device according to this sign and obtain described service exception and device fault information.
Simultaneously, server is in the type of the fault of determining and recovers or when repairing instruction, the information that the server end basis is collected can generate diagnosis report, and automatic analysis result, analysis result is managed, and be stored in the database.
Use this Real-time and Dynamic provided by the invention flexible fast method of test and localization of fault on embedded device, satisfied engineering technical personnel and interfered by certain function and realize fault location, and collected the demand of real-time field monitoring information; For example, do not needing to recompilate on the source code code base,, just can interfere the function operation of being paid close attention to by the special specification normative language program of design for a so real-time embedded equipment of portable terminal; The problem that can occur in research and development test or upgrading or use embedded device fast positions and verifies; The relevant key code point that can emphasis relates at some traffic failure carries out real-time field notes or intervenes act of execution.
Technical scheme support provided by the invention also can expand to other hardware and software platforms based on senior risc chip (ARM, Advanced RISCMachines) architecture, (SuSE) Linux OS platform.
Should be noted that above embodiment is only unrestricted in order to technical scheme of the present invention to be described, all parameter values can be according to the actual conditions adjustment, and in this rights protection scope.Those of ordinary skill in the art should be appreciated that and can make amendment or be equal to replacement technical scheme of the present invention, and do not break away from the spiritual scope of technical solution of the present invention, and it all should be encompassed in the middle of the claim scope of the present invention.
Claims (10)
1. the device to test of embedded device Real-time and Dynamic and localization of fault is characterized in that,
The script load bearing unit is used to carry function and interferes instruction, and described function is interfered the instruction interventional operations predetermined to the function setup in the source code of embedded device;
The script compile unit is used for interfering compiling of instruction to generate the identified documentation of described embedded device the described function of described script load bearing unit;
The code pile element is built-in with the system environments compiler, and is used for carrying out the process that system's compiling generates described identified documentation in described script compile unit, and the machine instruction stake is set in described source code;
Performance element is used for carrying out described identified documentation according to described machine instruction stake.
2. device according to claim 1 is characterized in that, described device also comprises:
Diagnostic engine is used to write down the field monitoring information that generates when described performance element is carried out described identified documentation, and described field monitoring information is sent to server.
3. device according to claim 1 is characterized in that, described function interferes the set described interventional operations of instruction to comprise at least:
Revise the suction parameter of current described function;
Replace the execution of current described function, move a new function;
Allow the execution time of current described function postpone;
Do not carry out current described function to write down the reaction of described embedded device;
Write down the environmental information of current described function;
Change the rreturn value of current described function;
Perhaps, in predetermined subprocess, call and the order of executive operating system external interface.
4. device according to claim 1 is characterized in that, described system environments compiler comprises: C CompilerTools and class C CompilerTools.
5. device according to claim 3 is characterized in that, described device also comprises:
The unit is set, is used for after described function is interfered compiling of instruction generation identified documentation, described identified documentation being placed under the path that sets in advance of described embedded device.
6. the method to test of embedded device Real-time and Dynamic and localization of fault is characterized in that,
Source code to embedded device compiles the generation compiling file;
Described compiling file and the subsidiary performance element of described embedded device are fired in the described embedded device;
Function is set interferes instruction and compiling to generate identified documentation, the machine instruction stake is set in described source code;
Described embedded device is carried out described identified documentation according to described machine instruction stake.
7. method according to claim 6 is characterized in that, the described function that is provided with interferes instruction and compiling to generate after the identified documentation, also comprises:
Described identified documentation is put under the predetermined path of described embedded device.
8. method according to claim 6 is characterized in that, after the described identified documentation of described execution, also comprises:
Write down the field monitoring information of described embedded device, and described field monitoring information is sent to corresponding server.
9. method according to claim 6 is characterized in that, described function interferes instruction to comprise at least:
Revise the suction parameter of current function;
Replace the execution of current described function, move a new function;
Allow the execution time of current described function postpone;
Do not carry out current described function to write down the reaction of described embedded device;
Write down the environmental information of current described function;
Perhaps, change the rreturn value of current described function.
10. method according to claim 6 is characterized in that, described subsidiary performance element comprises at least:
Support the dynamic link library of C language and the dynamic link library of support class C language.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CNA2008101151959A CN101609338A (en) | 2008-06-18 | 2008-06-18 | A kind of method and device to test of embedded device Real-time and Dynamic and localization of fault |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CNA2008101151959A CN101609338A (en) | 2008-06-18 | 2008-06-18 | A kind of method and device to test of embedded device Real-time and Dynamic and localization of fault |
Publications (1)
Publication Number | Publication Date |
---|---|
CN101609338A true CN101609338A (en) | 2009-12-23 |
Family
ID=41483112
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CNA2008101151959A Pending CN101609338A (en) | 2008-06-18 | 2008-06-18 | A kind of method and device to test of embedded device Real-time and Dynamic and localization of fault |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN101609338A (en) |
Cited By (6)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN101923510A (en) * | 2010-04-13 | 2010-12-22 | 张克东 | Software detection method as well as software detector and software detection system applying same |
CN102158462A (en) * | 2010-02-11 | 2011-08-17 | 希姆通信息技术(上海)有限公司 | Method for repairing remote diagnosis by using 2nd Generation (2G) or 3rd Generation (3G) module |
CN102622299A (en) * | 2010-04-13 | 2012-08-01 | 常州云博软件工程技术有限公司 | Working method of software detection system |
CN102662827A (en) * | 2010-04-13 | 2012-09-12 | 常州云博软件工程技术有限公司 | Software detection method |
CN108519924A (en) * | 2018-03-06 | 2018-09-11 | 许继集团有限公司 | A kind of online Fault Locating Method, system and the device of embedded measure and control device |
CN115658370A (en) * | 2022-11-18 | 2023-01-31 | 辉羲智能科技(上海)有限公司 | Compiler-based real-time detection method for machine learning acceleration chip faults |
-
2008
- 2008-06-18 CN CNA2008101151959A patent/CN101609338A/en active Pending
Cited By (10)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN102158462A (en) * | 2010-02-11 | 2011-08-17 | 希姆通信息技术(上海)有限公司 | Method for repairing remote diagnosis by using 2nd Generation (2G) or 3rd Generation (3G) module |
CN101923510A (en) * | 2010-04-13 | 2010-12-22 | 张克东 | Software detection method as well as software detector and software detection system applying same |
CN101923510B (en) * | 2010-04-13 | 2012-07-04 | 张克东 | Software detection method as well as software detector and software detection system applying same |
CN102622299A (en) * | 2010-04-13 | 2012-08-01 | 常州云博软件工程技术有限公司 | Working method of software detection system |
CN102662827A (en) * | 2010-04-13 | 2012-09-12 | 常州云博软件工程技术有限公司 | Software detection method |
CN102622299B (en) * | 2010-04-13 | 2014-10-01 | 张溟 | Working method of software detection system |
CN102662827B (en) * | 2010-04-13 | 2015-02-04 | 张溟 | Software detection method |
CN108519924A (en) * | 2018-03-06 | 2018-09-11 | 许继集团有限公司 | A kind of online Fault Locating Method, system and the device of embedded measure and control device |
CN108519924B (en) * | 2018-03-06 | 2021-02-05 | 许继集团有限公司 | Online fault positioning method, system and device for embedded measurement and control device |
CN115658370A (en) * | 2022-11-18 | 2023-01-31 | 辉羲智能科技(上海)有限公司 | Compiler-based real-time detection method for machine learning acceleration chip faults |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN105094783B (en) | method and device for testing stability of android application | |
CN101609338A (en) | A kind of method and device to test of embedded device Real-time and Dynamic and localization of fault | |
CN100547562C (en) | The method and system of the unit testing use-case of problem when generation can be reproduced operation automatically | |
CN102880535B (en) | A kind of wireless automatic proving installation for mobile device and method | |
CN100504810C (en) | Embedded system debug method | |
US20050114504A1 (en) | Carrier network capable of conducting remote diagnostics in a mobile handset | |
CN111651366B (en) | SDK test method, device, equipment and storage medium | |
CN108647037A (en) | Automatically dispose method and system based on shell scripts | |
CN101472288A (en) | Mobile terminal, method and server for failure diagnosis | |
EP2025095A2 (en) | Device management in a network | |
CN105912458A (en) | Method and system for dynamically detecting C/C++ memory leak | |
CN103713991A (en) | Method and device for testing application programs on Android devices | |
CN104932973A (en) | Version compatibility test method and apparatus | |
CN103631707A (en) | Method and device for obtaining code coverage rate | |
CN109902005A (en) | A kind of method and system of automatic test | |
CN104731566A (en) | Testing device, method and system for IDE (Integrated Development Environment) | |
CN102968371A (en) | Method and device for testing JAVA API unit component | |
CN104572394A (en) | Process monitoring method and device | |
CN110928777B (en) | Test case processing method, device, equipment and storage medium | |
CN101594627A (en) | A kind of apparatus and method of simulating mobile terminal fault | |
EP3514680B1 (en) | Identification of changes in functional behavior and runtime behavior of a system during maintenance cycles | |
CN113282501A (en) | Block chain testing method and device and electronic equipment | |
CN106713001A (en) | Network inspection method and apparatus | |
CN107122307B (en) | Internet of things execution system | |
CN101267645A (en) | Automatic test method and system for service flow software development of W base station |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
C06 | Publication | ||
PB01 | Publication | ||
C02 | Deemed withdrawal of patent application after publication (patent law 2001) | ||
WD01 | Invention patent application deemed withdrawn after publication |
Open date: 20091223 |