CN113626294A - Self-checking method and system for robot software - Google Patents

Self-checking method and system for robot software Download PDF

Info

Publication number
CN113626294A
CN113626294A CN202111003097.8A CN202111003097A CN113626294A CN 113626294 A CN113626294 A CN 113626294A CN 202111003097 A CN202111003097 A CN 202111003097A CN 113626294 A CN113626294 A CN 113626294A
Authority
CN
China
Prior art keywords
module
self
program
api
checking
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
Application number
CN202111003097.8A
Other languages
Chinese (zh)
Inventor
曲岩
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Shandong New Generation Information Industry Technology Research Institute Co Ltd
Original Assignee
Shandong New Generation Information Industry Technology Research Institute Co Ltd
Priority date (The priority date 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 date listed.)
Filing date
Publication date
Application filed by Shandong New Generation Information Industry Technology Research Institute Co Ltd filed Critical Shandong New Generation Information Industry Technology Research Institute Co Ltd
Priority to CN202111003097.8A priority Critical patent/CN113626294A/en
Publication of CN113626294A publication Critical patent/CN113626294A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/30Monitoring
    • G06F11/32Monitoring with visual or acoustical indication of the functioning of the machine
    • G06F11/323Visualisation of programs or trace data
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/30Monitoring
    • G06F11/32Monitoring with visual or acoustical indication of the functioning of the machine
    • G06F11/324Display of status information

Abstract

The invention discloses a self-checking method and a self-checking system for robot software, belonging to the field of software application; the method comprises the following specific steps: s1 dividing the software program into modules; s2 defining the dependency relationship between the modules; s3 defines the API provided by the module; s4 developing a self-test program; s5 calls API; s6 executing self-test program after the software is started; the method can check whether the software module service normally operates and quickly checks, and the quality of the module service is determined by detecting the operation condition of the interface and the correctness of the data in the same mode, so that the use experience of a user is improved, and the occurrence of potential safety hazards is avoided.

Description

Self-checking method and system for robot software
Technical Field
The invention discloses a self-checking method and a self-checking system for robot software, and relates to the technical field of software application.
Background
The robot is a product integrating software and hardware, the hardware essentially needs to work by means of software driving, and the software also provides an interaction function with a user, the intelligent capability and the service capability of the robot, so that the software function is very important on the robot. However, the software capability is built in the robot body, and it is difficult to detect whether the software is normally operated or not through vision, and an abnormally operated service may cause the capability of the whole robot to be reduced, even lose control over the robot, reduce the use experience of a user, and possibly bring about potential safety hazards. Therefore, the robot software needs to continuously and automatically detect whether the software is working normally. Therefore, the invention provides a robot software self-checking method.
Disclosure of Invention
Aiming at the problems in the prior art, the invention provides a self-checking method and a system for robot software, and the adopted technical scheme is as follows: a self-checking method for robot software comprises the following specific steps:
s1 dividing the software program into modules;
s2 defining the dependency relationship between the modules;
s3 defines the API provided by the module;
s4 developing a self-test program;
s5 calls API;
s6 executes the self-test procedure after the software is powered on.
The specific steps of the S4 development self-test program are as follows:
s401, developing a self-checking back-end program for simulating and calling an API (application programming interface) use protocol;
s402, developing a self-checking front-end program for displaying a calling result and an exception prompt.
The specific steps of calling the API by the S5 are as follows:
s501, judging the calling condition of the API;
s502, if the API can not be called, calling other APIs of the module to which the API belongs;
the S512API can call through but the returned data is not correct, and the page is prompted by a red warning.
The S522API calls correctly, and prompts are carried out on the page through green.
The specific steps of the S6 executing the self-checking program after the software is booted are as follows:
s601, starting module service by software starting, and executing a self-checking program;
s611, the software starts the starting and restarting module service, and executes the self-checking program;
s612 sets a timing execution or a manual execution self-check program.
A self-checking system for robot software specifically comprises a program dividing module, a relation defining module, an API defining module, a program developing module, an API calling module and a program self-checking module:
a program dividing module: dividing a software program into modules;
the relationship definition module: defining the dependency relationship among the modules;
the API definition module: defining an API provided by the module to the outside;
a program development module: developing a self-checking program;
an API calling module: calling an API;
the program self-checking module: and executing a self-checking program after the software is started.
The program development module specifically comprises a back-end development module and a front-end development module:
a back-end development module: developing a self-checking back-end program for simulating and calling an API (application programming interface) using protocol;
front-end development module: and developing a self-checking front-end program for displaying the calling result and the abnormal prompt.
The API calling module specifically comprises a calling judgment module, a processing module A, a processing module B and a processing module C:
the call-on judging module is used for judging the call-on condition of the API;
a processing module A: if the API can not be called, calling other APIs of the module to which the API belongs;
a processing module B: the API can call through but the returned data is not correct, and the page is prompted by a red warning.
A processing module C: the API calls correctly, and the page is prompted by green.
The program self-checking module specifically comprises a power-on self-checking module, a restart self-checking module and a self-checking setting module:
the power-on self-test module: starting module service when the software is started, and executing a self-checking program;
restarting the self-checking module: the software starts the module service of restarting, carry out the self-checking program;
self-checking sets up the module: setting timing execution or manually executing a self-checking program.
The invention has the beneficial effects that: firstly, dividing a software program into different modules according to service requirements, a deployment mode, decoupling and the like according to S1, then defining the dependency relationship between the modules according to S2, not allowing mutual dependency to occur, combining the two modules into one module if the mutual dependency exists, and then defining an API provided by the module to the outside according to S3, wherein the API is used for calling the module depending on the relationship; then developing a self-checking program according to S4, calling an API according to S5, and finally executing the self-checking program at a software boot interface according to S6;
the method can check whether the software module service normally operates and quickly checks, and the quality of the module service is determined by detecting the operation condition of the interface and the correctness of the data in the same mode, so that the use experience of a user is improved, and the occurrence of potential safety hazards is avoided.
Drawings
In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings needed to be used in the description of the embodiments or the prior art will be briefly introduced below, and it is obvious that the drawings in the following description are some embodiments of the present invention, and for those skilled in the art, other drawings can be obtained according to these drawings without creative efforts.
FIG. 1 is a flow chart of the method of the present invention; fig. 2 is a schematic diagram of the system of the present invention.
Detailed Description
The present invention is further described below in conjunction with the following figures and specific examples so that those skilled in the art may better understand the present invention and practice it, but the examples are not intended to limit the present invention.
The first embodiment is as follows:
a self-checking method for robot software comprises the following specific steps:
s1 dividing the software program into modules;
s2 defining the dependency relationship between the modules;
s3 defines the API provided by the module;
s4 developing a self-test program;
s5 calls API;
s6 executing self-test program after the software is started;
firstly, dividing a software program into different modules according to service requirements, a deployment mode, decoupling and the like according to S1, then defining the dependency relationship between the modules according to S2, not allowing mutual dependency to occur, combining the two modules into one module if the mutual dependency exists, and then defining an API provided by the module to the outside according to S3, wherein the API is used for calling the module depending on the relationship;
then developing a self-checking program according to S4, calling an API according to S5, and finally executing the self-checking program at a software boot interface according to S6;
further, the specific steps of developing the self-test program in S4 are as follows:
s401, developing a self-checking back-end program for simulating and calling an API (application programming interface) use protocol;
s402, developing a self-checking front-end program for displaying a calling result and an abnormal prompt;
further, the specific steps of calling the API in S5 are as follows:
s501, judging the calling condition of the API;
s502, if the API can not be called, calling other APIs of the module to which the API belongs;
the S512API can call through but the returned data is not correct, and the page is prompted by a red warning.
S522, the API is correctly called, and the page is prompted through green;
still further, the specific steps of the S6 executing the self-checking program after the software is turned on are as follows:
s601, starting module service by software starting, and executing a self-checking program;
s611, the software starts the starting and restarting module service, and executes the self-checking program;
s612, setting a timing execution or manual execution self-checking program;
the invention provides a self-checking method for robot software; firstly, dividing robot software into modules, wherein each module is an independent deployment unit, and the modules can have a one-way dependency relationship but cannot be mutually dependent; the modules communicate and process services through the interface API, the relied modules provide the interface API for other relied modules, and the API is not allowed to be deleted or modified and can be added. Writing a self-checking program to call APIs (application program interfaces) among all modules, adopting a blind calling mode aiming at blind communication protocols such as HTTP (hyper text transport protocol), MQTT (maximum transmission data) and the like, judging whether an interface operates correctly or not by simulating transmission parameters and return values, and giving an alarm through a page for calling the blind interface or the interface with the incorrect return value; the whole calling process is recorded in the log, and the API which normally runs but has an error return value can be quickly found in the log, so that whether the software module service normally runs or not is checked, and problems are quickly eliminated; for the relatively independent module which is not referenced, a self-checking interface can be developed independently without providing a called API, the core service but not the secret service in the module is encapsulated into the interface, and the quality of the module service is determined by detecting the operation condition of the interface and the correctness of the data in the same way;
the self-checking program can be automatically executed after all modules are started when the computer is started, can be executed regularly when the modules run, or can be manually triggered to execute; the nature of the self-checking program is an operation and maintenance method, and special attention needs to be paid to the security of the self-checking program, so that the design of API parameters and return values needs to be paid to avoid divulging a secret or causing program security loopholes through the self-checking program.
Example two:
a self-checking system for robot software specifically comprises a program dividing module, a relation defining module, an API defining module, a program developing module, an API calling module and a program self-checking module:
a program dividing module: dividing a software program into modules;
the relationship definition module: defining the dependency relationship among the modules;
the API definition module: defining an API provided by the module to the outside;
a program development module: developing a self-checking program;
an API calling module: calling an API;
the program self-checking module: executing a self-checking program after the software is started;
further, the program development module specifically includes a back-end development module and a front-end development module:
a back-end development module: developing a self-checking back-end program for simulating and calling an API (application programming interface) using protocol;
front-end development module: developing a self-checking front-end program for displaying a calling result and an abnormal prompt;
further, the API calling module specifically includes a call-through judgment module, a processing module a, a processing module B, and a processing module C:
the call-on judging module is used for judging the call-on condition of the API;
a processing module A: if the API can not be called, calling other APIs of the module to which the API belongs;
a processing module B: the API can call through but the returned data is not correct, and the page is prompted by a red warning.
A processing module C: the API is correctly called, and the page is prompted through green;
still further, the program self-checking module specifically includes a power-on self-checking module, a restart self-checking module, and a self-checking setting module:
the power-on self-test module: starting module service when the software is started, and executing a self-checking program;
restarting the self-checking module: the software starts the module service of restarting, carry out the self-checking program;
self-checking sets up the module: setting timing execution or manually executing a self-checking program.
Finally, it should be noted that: the above examples are only intended to illustrate the technical solution of the present invention, but not to limit it; although the present invention has been described in detail with reference to the foregoing embodiments, it will be understood by those of ordinary skill in the art that: the technical solutions described in the foregoing embodiments may still be modified, or some technical features may be equivalently replaced; and such modifications or substitutions do not depart from the spirit and scope of the corresponding technical solutions of the embodiments of the present invention.

Claims (8)

1. A self-checking method for robot software is characterized by comprising the following specific steps:
s1 dividing the software program into modules;
s2 defining the dependency relationship between the modules;
s3 defines the API provided by the module;
s4 developing a self-test program;
s5 calls API;
s6 executes the self-test procedure after the software is powered on.
2. The method as claimed in claim 1, wherein the step of developing the self-test program of S4 comprises:
s401, developing a self-checking back-end program for simulating and calling an API (application programming interface) use protocol;
s402, developing a self-checking front-end program for displaying a calling result and an exception prompt.
3. The method of claim 2, wherein the step of calling the API in S5 comprises the following steps:
s501, judging the calling condition of the API;
s502, if the API can not be called, calling other APIs of the module to which the API belongs;
the S512API can call through but the returned data is not correct, and the page is prompted by a red warning.
The S522API calls correctly, and prompts are carried out on the page through green.
4. The method as claimed in claim 3, wherein the step of executing the self-test procedure after the software is booted in the step of S6 is as follows:
s601, starting module service by software starting, and executing a self-checking program;
s611, the software starts the starting and restarting module service, and executes the self-checking program;
s612 sets a timing execution or a manual execution self-check program.
5. A self-checking system for robot software is characterized by specifically comprising a program dividing module, a relation defining module, an API defining module, a program developing module, an API calling module and a program self-checking module:
a program dividing module: dividing a software program into modules;
the relationship definition module: defining the dependency relationship among the modules;
the API definition module: defining an API provided by the module to the outside;
a program development module: developing a self-checking program;
an API calling module: calling an API;
the program self-checking module: and executing a self-checking program after the software is started.
6. The system of claim 5, wherein the program development modules specifically include a back-end development module and a front-end development module:
a back-end development module: developing a self-checking back-end program for simulating and calling an API (application programming interface) using protocol;
front-end development module: and developing a self-checking front-end program for displaying the calling result and the abnormal prompt.
7. The system of claim 6, wherein the API call module specifically includes a call-in determination module, a processing module a, a processing module B, and a processing module C:
the call-on judging module is used for judging the call-on condition of the API;
a processing module A: if the API can not be called, calling other APIs of the module to which the API belongs;
a processing module B: the API can call through but the returned data is not correct, and the page is prompted by a red warning.
A processing module C: the API calls correctly, and the page is prompted by green.
8. The system as claimed in claim 7, wherein the program self-test module specifically includes a power-on self-test module, a restart self-test module, and a self-test setting module:
the power-on self-test module: starting module service when the software is started, and executing a self-checking program;
restarting the self-checking module: the software starts the module service of restarting, carry out the self-checking program;
self-checking sets up the module: setting timing execution or manually executing a self-checking program.
CN202111003097.8A 2021-08-30 2021-08-30 Self-checking method and system for robot software Pending CN113626294A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202111003097.8A CN113626294A (en) 2021-08-30 2021-08-30 Self-checking method and system for robot software

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202111003097.8A CN113626294A (en) 2021-08-30 2021-08-30 Self-checking method and system for robot software

Publications (1)

Publication Number Publication Date
CN113626294A true CN113626294A (en) 2021-11-09

Family

ID=78388343

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202111003097.8A Pending CN113626294A (en) 2021-08-30 2021-08-30 Self-checking method and system for robot software

Country Status (1)

Country Link
CN (1) CN113626294A (en)

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20080307387A1 (en) * 2006-12-05 2008-12-11 Seok Jin Yoon Software development apparatus and method for providing performance prediction
US20090132860A1 (en) * 2007-11-21 2009-05-21 Inventec Corporation System and method for rapidly diagnosing bugs of system software
CN109783295A (en) * 2017-11-10 2019-05-21 中国电子科技集团公司第四十一研究所 Test macro self-test method for producing software and device based on configuration

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20080307387A1 (en) * 2006-12-05 2008-12-11 Seok Jin Yoon Software development apparatus and method for providing performance prediction
US20090132860A1 (en) * 2007-11-21 2009-05-21 Inventec Corporation System and method for rapidly diagnosing bugs of system software
CN109783295A (en) * 2017-11-10 2019-05-21 中国电子科技集团公司第四十一研究所 Test macro self-test method for producing software and device based on configuration

Similar Documents

Publication Publication Date Title
EP3432140B1 (en) Android-based pop-up prompt method and device
US8001429B2 (en) Method and system for automated handling of errors in execution of system management flows consisting of system management tasks
US20230393944A1 (en) Method and apparatus for data interaction between server bios and bmc, and device
WO2014013499A1 (en) System and method for operating system agnostic hardware validation
US20070129860A1 (en) Vehicle Service Equipment Interface Drivers
CN108021791B (en) Data protection method and device
WO2012031474A1 (en) Method and device for starting up terminal equipment
CN113626294A (en) Self-checking method and system for robot software
US20050033952A1 (en) Dynamic scheduling of diagnostic tests to be performed during a system boot process
JP2001056772A (en) Fault monitoring system
CN108241510B (en) Display card switching method
KR102438148B1 (en) Abnormality detection apparatus, system and method for detecting abnormality of embedded computing module
CN113821265B (en) Operating system control method and device, computer mainboard and readable storage medium
CN115658152A (en) Firmware upgrading method, firmware, electronic device and computer readable storage medium
CN109656768A (en) A kind of test method for checking CPU IEER
CN106227615B (en) The stuck method and system of precautionary process in program start-up course
CN113190491B (en) Serial port information display method, system and medium
CN105808467B (en) A method of managing computer power supply using self-defined ACPI
CN115061871A (en) Computer performance test method, device and medium
CN115014828A (en) Automated device testing method and related device
CA2607435A1 (en) Software process monitor
US20230078692A1 (en) Systems and methods for narrowing the scope of a problem when a modem is bricked
CN106201825A (en) A kind of intelligent back vision mirror running state monitoring method and system
CN111221554A (en) DSP circuit structure, DSP online program upgrading method and device
CN113760577B (en) Dynamic connection answering device, processing method, control device and storage medium

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination