CN105446882B - The method of testing of family expenses and similar applications electrical equipment software evaluation Black-box Testing system - Google Patents

The method of testing of family expenses and similar applications electrical equipment software evaluation Black-box Testing system Download PDF

Info

Publication number
CN105446882B
CN105446882B CN201510868968.0A CN201510868968A CN105446882B CN 105446882 B CN105446882 B CN 105446882B CN 201510868968 A CN201510868968 A CN 201510868968A CN 105446882 B CN105446882 B CN 105446882B
Authority
CN
China
Prior art keywords
detected
input
program
control device
subtest
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.)
Active
Application number
CN201510868968.0A
Other languages
Chinese (zh)
Other versions
CN105446882A (en
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.)
Hefei General Electromechanical Products Testing Institute Co Ltd
Hefei General Machinery Research Institute Co Ltd
Original Assignee
Hefei General Machinery Product Inspect Institute Co Ltd
Hefei General Machinery 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 Hefei General Machinery Product Inspect Institute Co Ltd, Hefei General Machinery Research Institute Co Ltd filed Critical Hefei General Machinery Product Inspect Institute Co Ltd
Priority to CN201510868968.0A priority Critical patent/CN105446882B/en
Publication of CN105446882A publication Critical patent/CN105446882A/en
Application granted granted Critical
Publication of CN105446882B publication Critical patent/CN105446882B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/36Preventing errors by testing or debugging software
    • G06F11/3668Software testing

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Computer Hardware Design (AREA)
  • Quality & Reliability (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Test And Diagnosis Of Digital Computers (AREA)

Abstract

The present invention relates to a kind of family expenses and the method for testing of similar applications electrical equipment software evaluation Black-box Testing system.This Black-box Testing system includes computer testing unit, subtest unit and detected controller unit, pass through emulator two-way communication link between computer testing unit and detected controller unit, two-way communication link between the computer testing unit and subtest unit, two-way communication link between the subtest unit and detected controller unit.Method of testing in the present invention includes software and is implanted into failure and hardware implantation two kinds of method of testings of failure.This test system does not need enterprise to provide corresponding source program code, has prevented the risk that software is divulged a secret, security is good;This test system can be automatically performed test process, and testing efficiency is high, and test result is true, accurate, and the versatility and uniformity of test are preferable.

Description

The method of testing of family expenses and similar applications electrical equipment software evaluation Black-box Testing system
Technical field
The invention belongs to computer software assessment technology field, more particularly to a kind of family expenses and similar applications electrical equipment software is commented Estimate the method for testing of Black-box Testing system.
Background technology
According to existing software evaluation standard requirement, current testing agency assesses test generally using white for fail-safe software The mode of box test, white-box testing is a kind of system detection method for test data being incorporated into program, the i.e. group to controller Part such as register, clock, reservoir, input and output periphery etc. are examined, detected.Current software test uses white-box testing side Formula is primarily present following shortcoming:
1st, because different household appliances may use different controllers, identical household appliances may use different controls Device processed, same controller are it is also possible that write software with different language, therefore the repeatability of software evaluation is poor, often Secondary assessment all equivalent to customized, wastes substantial amounts of time, man power and material, this is that enterprise and testing agency are all difficult to bear 's.
In addition, the controller of Some Enterprises is development & production abroad, for evaluation process, if software security is tested White-box testing all is used, generally requires to arrange software developer abroad to be tested, testing cost is very high.
2nd, white-box testing requires that enterprise provides core source program code and core data, could allow testing staff to source program Enter Mobile state and static check is tested and examines whether related measure software works.And this way may be to enterprise due to presence Industry brings the potential risk that kernel software and technology are divulged a secret, and allows enterprise very to worry and worry, so that enterprise and detection machine It is difficult to coordinate between structure.
3rd, the professional of software evaluation need of work, but software control is microcosmic behavior, its software logic is present Diversified combination, its program function and hardware mechanism brought close, also vary, it is contemplated that the component of controller Working condition, such as register, clock, reservoir, input and output periphery whether can break down, it may occur that what failure.Cause This analysis to software, to set and check be a highly difficult and complicated job.This is accomplished by the system engineer, hard of specialty Part engineer and software engineer, even if but it is professional again, for being examined with artificial mode after all Look into, cannot guarantee that all softwares all meet the requirements of the standard, the measure method provided is all very appropriate, suitable, effective.
4th, the standard that household electrical appliances software evaluation is related to is more and complicated, including electric, electronics, software, both including the whole of household electrical appliances Machine safety standard, also including part-subassemble standard;Should the universal standard requirement, also to consider particular criteria requirement.So multi-standard In, the overwhelming majority only requires no method, this test mode used to inspection personnel in checking process and test knot The judgement of fruit causes certain difficulty.Different inspection personnel may also can be caused, different understandings are had, can be caused different Result of determination, may bring unnecessary trouble to enterprise.
The content of the invention
The invention aims to overcome above-mentioned the deficiencies in the prior art, there is provided a kind of family expenses and similar applications electrical equipment The method of testing of software evaluation Black-box Testing system, the method for testing of this test system does not need enterprise to provide corresponding source program Code, has prevented the risk that software is divulged a secret, and security is good.
To achieve the above object, present invention employs following technical measures:
A kind of method of testing of family expenses and similar applications electrical equipment software evaluation Black-box Testing system, Black-box Testing system includes Computer testing unit, subtest unit and detected controller unit, computer testing unit and detected controller By emulator two-way communication link between unit, two-way communication connects between the computer testing unit and subtest unit Connect, two-way communication link between the subtest unit and detected controller unit;
It is preferred that, the computer testing unit includes following part:
Test control device, the machine code program required for receiving detected controller unit operation, is additionally operable to connect The trial and error data message inputted from input/output unit is received, test control device leads to the machine code program received successively Cross data and fault input device, emulator communication device, emulator are sent to tested observing and controlling in detected controller unit In device processed, test control device and by the trial and error data information memory received into data storage device;The testing and control Device also constitutes two-way communication link with subtest communication device;
Data and fault input device, receive the trial and error data message that sends of test control device, and by trial and error data Information is sent to emulator communication device, is sent while emulator communication device to be transmitted to the trial and error feedback data information come to survey Try control device;
Data storage device, with test control device two-way communication link, sends for storing self-test control device Trial and error data message and trial and error feedback data information;
Subtest communication device, and subtest unit two-way communication link, in test control device and auxiliary Information is transmitted between test cell;
Emulator communication device, and emulator two-way communication link, in data and fault input device and emulator Between transmit information;
Input/output unit, for inputting trial and error data message into test control device, and receives test control device The trial and error feedback data information that transmission comes.
The subtest unit includes following part:
Subtest microprocessor, and the subtest communication device two-way communication link, for receiving testing and control The instruction and data information that device is sent by subtest communication device, and by the instruction and data message transport received extremely It is detected controller unit;The subtest microprocessor is also by the hardware status information of the detected controller unit received Sent with processing data through subtest communication device to test control device;
Output control circuit, its input is connected with the output end of the subtest microprocessor, and output end is with being detected The input for surveying controller unit is connected, for detected controller unit be forwarded from instruction that test control device sends and Data message;
Input capture circuit, its input is connected with the output end of the detected controller unit, output end and auxiliary The input for testing microprocessor is connected, for by the hardware status information and processing data of the detected controller unit received Sent through subtest communication device to test control device;
Two-way communication link between communication control circuit, with subtest microprocessor, the letter of the communication control circuit The connection of number output end is detected the signal input part of controller unit.
The detected controller unit includes following part:
Be detected controller, and emulator two-way communication link, be detected the input of controller also with input circuit Output end is connected, and the output end for being detected controller is connected with the input of output circuit;For storing the machine code program And the program set according to machine code program is run;
Input circuit, its input is connected with the output end of the output control circuit, for receiving circuit abnormal information;
Output circuit, its output end is connected with the input of the input capture circuit, for receiving and forwarding what is received It is detected the hardware status information of controller unit.
The software implantation fault test flow of this method of testing is as follows:
S1, the machine code program using test control device, the first test of download needs, then by machine code program successively Transmit and be stored in detected controller unit by data and fault input device, emulator communication device, emulator It is detected in controller;
S2, the software project to be detected using input/output unit selection machine code program, then in software item to be detected Inputted in mesh detection method program entry address, safeguard measure program entry address, the start-stop address of software project to be detected and Trial and error data message, above-mentioned input information is stored in the data storage device by test control device;
S3, operation are detected the machine code program in controller, while test control device passes sequentially through data and failure Input unit, emulator communication device, emulator monitoring and the operation of control machine coded program, when machine code program runs to inspection During the entry address of survey measure program, the trial and error data message in data storage device is passed sequentially through data by test control device And fault input device, emulator communication device, emulator write according to the start-stop address of the software project to be detected and are detected In the software project to be detected for surveying controller, test control device record is detected controller before write-in trial and error data message And the operation information during the whole service after write-in trial and error data message;
S4, the test control device judge whether the course of work for being detected controller accords with according to the operation information Close setting program;
The operation information and judged result are exported to form survey by S5, the test control device by input/output unit Trial record.
It is preferred that, the detected controller unit also includes communication controler, and the signal of the detected controller is defeated Go out end to be connected with the signal input part of the communication controler, the signal input part connection communication control of the detected controller The signal output part of circuit, the signal output part connection communication of the communication controler controls the signal input part of circuit.
It is preferred that, in step S3, when machine code program runs to the entrance of detection method program, test control device control Machine code program single step run processed, i.e. machine code program often run a step, and test control device is by data storage device Trial and error data message writes the software project to be detected for being detected controller according to the start-stop address of the software project to be detected In, it is ensured that the trial and error data message of write-in will not be changed before detection method program is compared judgement, until machine code journey Sort run jumps to safeguard measure program or machine code program is run to the outlet of detection method program.
Further, in step S3, the machine code program circular flow in each circular flow cycle, works as machine When coded program runs to the entrance of detection method program, the equal control machine coded program single step run of test control device.
The hardware implantation fault test flow of this method of testing is as follows:
S1, the machine code program using test control device, the first test of download needs, then by machine code program successively Transmit and be stored in detected controller unit by data and fault input device, emulator communication device, emulator It is detected in controller;
S2, the item of hardware to be detected using input/output unit selection machine code program, the item of hardware to be detected At least include numeral I/O detection projects, detection method program entry address, safeguard measure are inputted in digital I/O detection projects Program entry address, the passage for controlling abnormal circuit, the input information are stored in the data storage by test control device In device;
S3, operation are detected the machine code program in controller, while test control device passes sequentially through data and failure Input unit, emulator communication device, emulator monitoring and the operation of control machine coded program, when machine code program runs to inspection During the entrance of survey measure program, the passage and switch letter of control abnormal circuit of the test control device in data storage device Breath, sends control command by subtest communication device and gives subtest microprocessor, the subtest microprocessor according to It is secondary to open the corresponding circuit abnormality being detected in controller unit by the output control circuit, the input circuit and set Put;Test control device record is detected whole fortune of the controller before abnormal circuit setting and after abnormal circuit setting Operation information during row;
S4, the test control device judge whether the course of work for being detected controller accords with according to the operation information Close setting program;
The operation information and judged result are exported to form survey by S5, the test control device by input/output unit Trial record.
Item of hardware to be detected in step S2 also includes communication data detection project, the test of communication data detection project Step is as follows:
S21, input in communication data detection project detection method program entry address, safeguard measure program entry Location, the passage and trial and error communication data information for switching communicating circuit, the input information are stored in institute by test control device State in data storage device;
S22, operation are detected the machine code program in controller, while test control device passes sequentially through data and failure Input unit, emulator communication device, emulator monitoring and the operation of control machine coded program, when machine code program runs to inspection During the entrance of survey measure program, input information of the test control device in data storage device is communicated by subtest Device sends control command and gives subtest microprocessor, and the subtest microprocessor is opened by the communication control circuit The passage of the switching communicating circuit in detected controller unit is opened, subtest microprocessor is caught by communication controller circuit The communication data between detected controller and the communication controler in detected controller unit is grasped, the subtest is micro- The communication data received is added the trial and error communication data information and obtains mixing trial and error data, subtest microprocessor by processor Device sends the mixing trial and error data to tested controller;It is logical in abnormal circuit that test control device record is detected controller The operation information during whole service before road is set and after the setting of abnormal circuit passage;
S23, the test control device judge whether the course of work for being detected controller accords with according to the operation information Close setting program;
S24, the test control device export the operation information and judged result by input/output unit to be formed Test record.
The beneficial effects of the present invention are:
1), the Black-box Testing system in the present invention does not need enterprise to provide corresponding source program code, thoroughly solves house Electric enterprise, to the worry of Software Intellectual Property Rights, is also the developing direction of future secure software evaluation test.
2), the method for testing efficiency high of the Black-box Testing system in the present invention, hand inspection source is not needed when checking test Program code, but be automatically performed by computer testing unit and subtest unit, so that the volume of testing staff and source program Cheng Yuyan, the program thread of programming personnel, controller species are not directly dependent upon, favorable repeatability, can be testing agency, enterprise Industry saves substantial amounts of time and efforts.
3), Security of test is good, because enterprise no longer needs to provide the source program code of household appliances controller, but will Executable program file after compilation of source code is downloaded or burning enters in controller, will be equipped with controller and is supplied to testing agency, By information material of the testing staff according to offer, tested automatically by test system.Enterprise can be with without worrying due to open source Risk that what program code was brought divulge a secret.
4), ease for use is good, and because test system is automatically performed the fault-injection inspection to controller, inspection personnel need not Source program code inspection is opened again, and the block analysis, software inspection, setting to controller are completed by computer system, so right The inspection workload demand of inspection personnel reduces, it is specialized require that degree can be reduced, flase drop looks into that probability is almost nil, inspection As a result can directly it print.
5), uniformity is good, because test system is according to standard organizational system, and testing staff is unified to survey according to job instruction clause Examination, the judgement for test case and test result is then automatically performed by test system, therefore will not be because of tester to mark Standard understands different, causes the inconsistent appearance of test result.
6), the method for testing in the present invention is implanted into failure and hardware implantation two kinds of test modes of failure using software, not only Comprehensive test of the item of hardware of software project to controller to be detected can be realized, and test is comprehensive, and test result is true It is real accurate.
Brief description of the drawings
Fig. 1 is schematic diagram of the invention;
Fig. 2 is implanted into the flow chart of failure for the software mode of the present invention;
Fig. 3 is implanted into the flow chart of the port test of failure for the hardware mode of the present invention;
Fig. 4 is implanted into the flow chart of the communication test of failure for the hardware mode of the present invention.
Reference implication in figure is as follows:
10-computer testing unit 11-test control device, 12-data storage device
13-data and fault input device 14-subtest communicator
15-emulator communication device 16-input/output unit, 20-subtest unit
21-subtest microprocessor 22-output control circuit, 23-input capture circuit
24-communication control circuit 30-be detected controller unit
31-it is detected controller 32-input circuit, 33-output circuit
34-communication controler, 40-emulator
Embodiment
Below in conjunction with the accompanying drawing in the embodiment of the present invention, the technical scheme in the embodiment of the present invention is carried out clear, complete Site preparation is described, it is clear that described embodiment is only a part of embodiment of the invention, rather than whole embodiments.It is based on Embodiment in the present invention, it is every other that those of ordinary skill in the art are obtained under the premise of creative work is not made Embodiment, belongs to the scope of protection of the invention.
As shown in figure 1, black in the method for testing of a kind of family expenses and similar applications electrical equipment software evaluation Black-box Testing system Box test system includes computer testing unit 10, subtest unit 20, is detected controller unit 30 and emulator 40.
The computer testing unit 10 includes test control device 11, data storage device 12, data and failure input Device 13, subtest communication device 14, emulator communication device 15 and input/output unit 16, the test control device 11 It is bi-directionally connected respectively with data and fault input device 13, subtest communication device 14, data storage device 12, the test The output end of control device 11 is connected by communication interface with the printer in input/output unit 16, and testing staff can pass through Human-computer interaction interface in input/output unit 16 inputs corresponding information and checks testing result;Data and failure the input dress Two-way communication link between 13 and emulator communication device 15 is put, the emulator communication device 15 passes through communication interface and emulation The two-way communication link of device 40, the subtest communication device 14 is bi-directionally connected by communication interface with subtest unit 20.
The subtest unit 20 includes subtest microprocessor 21, output control circuit 22, input capture circuit 23 and communication control circuit 24, the subtest microprocessor 21 connects with the two-way communication of subtest communication device 14 Connect;The output end of the subtest microprocessor 21 with the input of output control circuit 22 with being connected, output control circuit 22 output end is connected with the input of detected controller unit 30;The input of the input capture circuit 23 and the quilt Detect that the output end of controller unit 30 is connected, output end is connected with the input of subtest microprocessor 21;The communication Control circuit 24 and the two-way communication link of subtest microprocessor 21.
The detected controller unit 30 includes being detected controller 31, input circuit 32, output circuit 33 and communication Controller 34, the detected controller 31 and the two-way communication link of emulator 40, be detected the input of controller 31 also with The output end of input circuit 32 is connected, and the output end for being detected controller 31 is connected with the input of output circuit 33;The quilt The signal output part of detection controller 31 is connected with the signal input part of the communication controler 34, the detected controller 31 Signal input part connection communication control the signal output part of circuit 24, the signal output part connection of the communication controler 34 is logical The signal input part of letter control circuit 24.
The present invention has two kinds of implantation fault testing methods, and one of which is that software is implanted into fault testing method, another Fault testing method is implanted into for hardware, its testing procedure is illustrated separately below:
1. it is implanted into fault testing method for software
S1, the machine code using input/output unit 16 and test control device 11, first download or reception needs test Program, then passes sequentially through data by machine code program and fault input device 13, emulator communication device 15, emulator 40 is passed Send and be stored in the detected controller 31 in detected controller unit 30;
S2, the software project to be detected using the selection machine code program of input/output unit 16, then in software to be detected Detection method program entry address, safeguard measure program entry address, the start-stop address of software project to be detected are inputted in project With trial and error data message, above-mentioned input information is stored in the data storage device 12 by test control device 11;
S3, operation be detected controller 31 in machine code program, while test control device 11 pass sequentially through data and Fault input device 13, emulator communication device 15, the monitoring of emulator 40 and the operation of control machine coded program, when machine code journey Sort run to detection method program entrance when, test control device 11 by the trial and error data message in data storage device 12 according to It is secondary by data and fault input device 13, emulator communication device 15, emulator 40 according to the software project to be detected The write-in of start-stop address is detected in the software project to be detected of controller 31, and the record of test control device 11 is detected controller 31 The operation information during whole service before write-in trial and error data message and after write-in trial and error data message;
Special instruction, when machine code program runs to the entrance of detection method program, test control device 11 is controlled Machine code program single step run processed, i.e. machine code program often run a step, and test control device 11 is by data storage device 12 In trial and error data message according to the software project to be detected start-stop address write be detected controller 31 it is to be detected soft In part project, it is ensured that the trial and error data message of write-in will not be changed before detection method program is compared judgement, until machine The operation of device coded program jumps to safeguard measure program or machine code program is run to the outlet of detection method program.
S4, the test control device 11 judge that the course of work for being detected controller 31 is according to the operation information It is no to meet setting program;
The operation information and judged result are exported shape by S5, the test control device 11 by input/output unit 16 Into test record.
2. it is implanted into fault testing method for hardware
Item of hardware includes PERCOM peripheral communication part, input and output peripheral components, detection means and comparator part, conventional collection Into block part, certainly, there is no PERCOM peripheral communication part in some tested controller units, that can not just do the inspection of PERCOM peripheral communication part The test of survey project.
2.1 for the input and output periphery in hardware, detection means and comparator, custom integrated circuit part
S1, the machine code using input/output unit 16 and test control device 11, first download or reception needs test Program, then passes sequentially through data by machine code program and fault input device 13, emulator communication device 15, emulator 40 is passed Send and be stored in the detected controller 31 in detected controller unit 30;
S2, using input/output unit 16 select to be detected the input and output periphery of controller 31, detection means and compare Detection project in device, custom integrated circuit part, detection method program entry address, protection are inputted in the detection project and is arranged Apply program entry address, control the passage of abnormal circuit, the input information is stored in the data by test control device 11 In storage device 12;
S3, operation be detected controller 31 in machine code program, while test control device 11 pass sequentially through data and Fault input device 13, emulator communication device 15, the monitoring of emulator 40 and the operation of control machine coded program, when machine code journey Sort run to detection method program entrance when, control abnormal circuit of the test control device 11 in data storage device 12 Channel information, control command is sent to subtest microprocessor 21 by subtest communication device 14, the auxiliary is surveyed Examination microprocessor 21 passes sequentially through the output control circuit 22, the input circuit 32 and opened in detected controller unit 30 Related circuit extremely set;Test control device 11 record be detected controller 31 abnormal circuit passage setting before and The operation information during whole service after the setting of abnormal circuit passage;
S4, the test control device 11 judge that the course of work for being detected controller 31 is according to the operation information It is no to meet setting program;
The operation information and judged result are exported shape by S5, the test control device 11 by input/output unit 16 Into test record.
2.2 for the PERCOM peripheral communication part in hardware
S1, the machine code using input/output unit 16 and test control device 11, first download or reception needs test Program, then passes sequentially through data by machine code program and fault input device 13, emulator communication device 15, emulator 40 is passed Send and be stored in the detected controller 31 in detected controller unit 30;
S2, using input/output unit 16 select machine code program PERCOM peripheral communication part in detection project, in the inspection Inputted in survey project detection method program entry address, safeguard measure program entry address, the passage for switching communicating circuit and Trial and error communication data information, the input information is stored in the data storage device 12 by test control device 11;
S3, operation be detected controller 31 in machine code program, while test control device 11 pass sequentially through data and Fault input device 13, emulator communication device 15, the monitoring of emulator 40 and the operation of control machine coded program, when machine code journey Sort run to detection method program entrance when, input information of the test control device 11 in data storage device 12, lead to Cross subtest communication device 14 and send control command to subtest microprocessor 21, the subtest microprocessor 21 leads to Cross the passage that the communication control circuit 24 opens the switching communicating circuit being detected in controller unit 30, the micro- place of subtest Reason device 21 captures detected controller 31 and Control on Communication in detected controller unit 30 by communication control circuit 24 The communication data received is added the trial and error communication data by the communication data between device 34, the subtest microprocessor 21 Information obtains mixing trial and error data, and subtest microprocessor 21 sends the mixing trial and error data to tested controller 31; The record of test control device 11 is detected controller 31 before the setting of abnormal circuit passage and abnormal circuit passage sets it The operation information during whole service afterwards;
S4, the test control device 11 judge that the course of work for being detected controller 31 is according to the operation information It is no to meet setting program;
The operation information and judged result are exported shape by S5, the test control device 11 by input/output unit 16 Into test record.
As a rule, the data storage device 12 in the computer testing unit 10, altogether to 9 component items of controller Visual inspection is surveyed, respectively CPU, interrupt processing and execution item, clock, reservoir, internal data paths, PERCOM peripheral communication Item, the peripheral item of input/output, detection means and comparator, conventional integrated package, these components are respectively provided with again, can not Change reservoir, variable reservoir item, E2PROM, program counter, interrupt processing and execution item, clock, outside are logical Preceding 1-7 in letter data, numeral I/O etc., this 9 components are detected by way of software implantation failure, then 2 Item then needs to be detected by way of hardware is implanted into failure.This 9 components can be checked by human-computer interaction interface, and Carry out being implanted into corresponding trial and error data message by test control device 11 or the configuration of mistake is set.
The method that failure and hardware implantation failure are implanted into software below by specific embodiment is illustrated respectively.
The software of embodiment 1 is implanted into fault test
The present embodiment is examined by variable reservoir detection project in detection part to the variable reservoir of washing machine controller Illustrated exemplified by survey item.
As shown in Fig. 2
1) the computer testing unit 10 of test software will be installed and detected controller list is connected to by emulator 40 Detected controller 31 in member 30.
2) in the human-computer interaction interface of computer testing unit 10, the machine of production is downloaded by input/output unit 16 Code, is clicked on " downloading ", and opening needs the machine code downloaded to be tested program, clicks on " opening ", if test program into Work(is downloaded in controller, and system shows " download success ", otherwise shows " failed download ", can be recorded in detection record Download time, download filename;This process namely machine code is passed sequentially through test control device 11 into data and failure is defeated Enter device 13, emulator communication device 15, emulator 40 to download in controller.
3) click on, select " detection project " in the check box on the column of detection project one, " variable storage is selected in the present embodiment Device ", is clicked on " variable reservoir ", ejection " variable reservoir detection " the configuration page, according to the data of enterprise, fills in corresponding Detection method program entry address, safeguard measure program entry address, need detect variable reservoir start-stop address and Trial and error data message, " fault category " for selecting variable reservoir to occur is clicked on " preservation ", and the configuration is stored in data storage In device 12.
4) machine code program being detected in controller 31 brings into operation, according to the operation instruction of detected controller 31 Book, opens equipment and enters dehydration mode, is detected the load output of controller 31, and human-computer interaction interface display output state starts Detection program, test control device 11 passes sequentially through data and fault input device 13, emulator communication device 15, emulator 40 The operation of simultaneously control machine coded program is monitored, when machine code program runs to the entrance of detection method program, testing and control dress Put 11 control machine coded program single step runs, i.e. machine code program and often run a step, the equal called data of test control device 11 is deposited Configured trial and error data message in storage device 12, is sent in data and fault input device 13, is filled by data and failure input Put 13 pairs of trial and error data messages and carry out logic control and processing, and emulator communication device is given by the trial and error data transfer after processing 15, these data are converted into emulation command by emulator communication device 15, then these emulation commands are converted into communication data, are led to Cross USB interface to communicate with emulator 40, the variable reservoir area of controller is sent to by emulator 40, and detect as required The start-stop address of variable reservoir writes variable reservoir area;After trial and error data message writes variable reservoir area, machine Coded program is continued to run with;Test control device 11 monitors the operation of simultaneously control machine coded program always, until machine code program fortune Row jumps to the entrance of safeguard measure software to the outlet of detection method software or machine code program;When machine code program operation To after the entrance of the outlet of detection method software or safeguard measure software, test control device 11, which just discharges, to be monitored, machine code journey Sequence also just exits single step run state.
For the inspection measure software of cyclic check, machine code program meeting circular flow is soft until being again introduced into detection method Part, repeats the operation of the above.
In above process, controller feedback information is divided into two parts, and a part passes to emulator by emulator 40 and led to Device 15 is interrogated, then enters test control device 11 by data and fault input device 13, another part is by input capture circuit Microprocessor 21 is passed to, then enters test control device 11 by subtest communication device 14, by test control device 11 It is stored in data storage device 12 and is shown on human-computer interaction interface, test result is printed by input/output unit 16;It is described Feedback information both includes the operation information of machine code program, and the output protection also performed including being detected controller 31 is acted (such as Close all outputs or close dehydration electric motor output or Program reset) information, test control device 11 passes through above-mentioned feedback information Judge whether this is detected the measure method and measure program of controller 31 qualified.
5) detection progress and detection record have corresponding display, when test passes through, and detection record has corresponding display, During test crash, detection record also has corresponding display, when test passes through, and detected controller load output state, which can be shown, to be set Standby to close, detection record and output state can be stored or print by exporting test record as test record.
The hardware of embodiment 2 is implanted into fault test
The present embodiment is detected by the digital I/O detection projects in detection part to the door switch circuit of washing machine controller Exemplified by illustrate.
As shown in figure 3,
1) the computer testing unit 10 of test software will be installed and detected controller list is connected to by emulator 40 Detection controller 31 in member 30.
2) in the human-computer interaction interface of computer testing unit 10, the machine of production is downloaded by input/output unit 16 Code, is clicked on " downloading ", and opening needs the machine code downloaded to be test program, is clicked on " opening ", if test program is Download in controller, system shows " download success ", otherwise show " failed download ", can be recorded in detection record Load time, download filename;The machine code is passed sequentially through data and failure input by this process namely test control device 11 Device 13, emulator communication device 15, emulator 40 are downloaded in controller.
3) click on, select " detection project " in the check box on the column of detection project one, selection numeral I/O inspections in the present embodiment Survey, following information is configured to the digital I/O detection projects for needing to detect:The entry address of inspection measure software, safeguard measure are soft The entry address of part, the passage for controlling abnormal circuit, are clicked on " preservation ", and the configuration information is stored in data storage device 12.
4) machine code program being detected in controller 31 brings into operation, according to the operation instruction of detected controller 31 Book, opens equipment operation dehydration mode, is detected the load output of controller 31, and display device output state starts detection program, Test control device 11 passes sequentially through data and fault input device 13, emulator communication device 15, emulator 40 are monitored and controlled The operation of machine code program processed, when machine code program runs to the entrance of detection method program, the basis of test control device 11 Configuration information in human-computer interaction interface, sends control command by subtest communication device 14 and gives subtest microprocessor 21, subtest microprocessor 21 passes sequentially through output control circuit 22, the open circuit of input circuit 32 and sets abnormal passage, i.e., To have in the input circuit of the door switch of tested controller 31 and be arranged to abnormal all the way, such as high level input signal, another all the way It is arranged to low imput all the way;During the detected rolling inspection measure software of controller 31, test control device 11 monitoring always and the operation of control machine coded program, until machine code program runs to outlet or the machine of detection method software Device coded program jumps to the entrance of safeguard measure software;When the outlet or protection that machine code program runs to detection method software are arranged After the entrance for applying software, test control device 11, which just discharges, to be monitored.
For the inspection measure software of cyclic check, machine code program meeting circular flow is soft until being again introduced into detection method Part, repeats the operation of the above.
In above process, subtest microprocessor 21 is detected controller by the real-time capture of input capture circuit 23 The status information (as closed dehydration electric motor output) of 31 output circuit, subtest microprocessor 21 and by the state captured Information passes to test control device 11 by subtest communication device 14, while emulator 40 is by the survey of detected controller 31 Information is tried to pass to test control device by emulator communication device 15, then by data and fault input device 13 and (such as enter Enter measure defence program or Program reset), data storage device 12 is stored in and in human-computer interaction interface by test control device 11 Upper display, test result is printed by input/output unit 16;Test control device 11 judges the quilt by above-mentioned status information Detect whether the measure method and measure program of controller 31 are qualified.
5) detection progress and detection record have corresponding display, when test passes through, and detection record has corresponding display, During test crash, detection record also has corresponding display, when test passes through, and detected controller load output state, which can be shown, to be set Standby to close, detection record and output state can be stored or print by exporting test record as test record.
The hardware of embodiment 3 is implanted into fault test
Communication of the present embodiment by the Data Detection project of the PERCOM peripheral communication in detection part to washing machine controller is examined Illustrated exemplified by survey.
As shown in figure 3,
1) the computer testing unit 10 for being provided with test software is connected to detected controller unit by emulator 40 Detected controller 31 in 30.
2) in the human-computer interaction interface of computer testing unit 10, the machine of production is downloaded by input/output unit 16 Code, is clicked on " downloading ", and opening needs the machine code downloaded to be test program, is clicked on " opening ", if test program is Download in controller, system shows " download success ", otherwise show " failed download ", can be recorded in detection record Load time, download filename;The machine code is passed sequentially through data and failure input by this process namely test control device 11 Device 13, emulator communication device 15, emulator 40 are downloaded in controller.
3) click on, select " detection project " in the check box on the column of detection project one, PERCOM peripheral communication is selected in the present embodiment Middle Data Detection, the following information of Data Detection project configuration in the PERCOM peripheral communication to needing detection:The entrance of inspection measure software Address, the entry address of safeguard measure software, the passage for controlling abnormal circuit, are clicked on " preservation ", and the configuration information is stored in number According in storage device 12.
4) machine code program being detected in controller 31 brings into operation, according to the operation instruction of detected controller 31 Book, opens equipment operation dehydration mode, is detected the load of controller 31 and exports, display device output state, at the same time, test Control device 11 passes sequentially through data and fault input device 13, emulator communication device 15, the monitoring of emulator 40 and control machine The operation of device coded program, when machine code program runs to the entrance of detection method program, test control device 11 is according to man-machine Configuration information in interactive interface, control command is sent to subtest microprocessor 21 by subtest communication device 14, Subtest microprocessor 21 opens the passage of switching telecommunication circuit, and real-time capture is detected controller 31 and communication controler 34 Between communication data, and by the communication data captured add human-computer interaction interface set trial and error data message, Ran Houyi It is secondary that detected controller is sent to by subtest communication device 14, subtest microprocessor 21, communication control circuit 24 31;During the detected rolling inspection measure software of controller 31, test control device 11 is monitored and control machine code journey always The operation of sequence, until machine code program run to the outlet of detection method software or machine code program to jump to safeguard measure soft The entrance of part;After machine code program runs to the entrance of outlet safeguard measure software of detection method software, testing and control dress Put 11 just release monitoring.
For the inspection measure software of cyclic check, machine code program meeting circular flow is soft until being again introduced into detection method Part, repeats the operation of the above.
In above process, subtest microprocessor 21 is detected controller by the real-time capture of input capture circuit 23 The status information (such as dehydration electric motor stops output) of 31 output circuit, subtest microprocessor 21 believes the state captured Breath passes to test control device 11 by subtest communication device 14, while emulator 40 is by the test of detected controller 31 Information passes to test control device (as entered by emulator communication device 15, then by data and fault input device 13 Measure defence program or Program reset), data storage device 12 is stored in and on human-computer interaction interface by test control device 11 It has been shown that, test result is printed by input/output unit 16;Test control device 11 judges that this is detected by above-mentioned status information Whether the measure method and measure program for surveying controller 31 are qualified.
5) detection progress and detection record have corresponding display, when test passes through, and detection record has corresponding display, During test crash, detection record also has corresponding display, when test passes through, and the controller load being captured stops output, detection Record and output state can be stored or print by exporting test record as test record.

Claims (6)

1. the method for testing of a kind of family expenses and similar applications electrical equipment software evaluation Black-box Testing system, it is characterised in that:Black box is surveyed Test system includes computer testing unit (10), subtest unit (20) and detected controller unit (30), computer By emulator (40) two-way communication link between test cell (10) and detected controller unit (30), the computer is surveyed Try two-way communication link between unit (10) and subtest unit (20), the subtest unit (20) and detected control Two-way communication link between device unit (30);
The computer testing unit (10) includes following part:
Test control device (11), the machine code program required for receiving detected controller unit (30) operation, is also used In the trial and error data message for being received from input/output unit (16) input, test control device (11) is by the machine received Coded program passes sequentially through data and fault input device (13), emulator communication device (15), emulator (40) be sent to it is tested Survey in the detected controller (31) in controller unit (30), test control device (11) simultaneously believes the trial and error data received Breath is stored into data storage device (12);The test control device (11) is also constituted with subtest communication device (14) Two-way communication link;
Data and fault input device (13), receive test control device (11) trial and error data message for sending, and by trial and error Data message is sent to emulator communication device (15), while emulator communication device (15) is transmitted into the trial and error feedback data of coming Information is sent to test control device (11);
Data storage device (12), and test control device (11) two-way communication link, for storing self-test control device (11) the trial and error data message and trial and error feedback data information sent;
Subtest communication device (14), and subtest unit (20) two-way communication link, in test control device (11) information is transmitted between subtest unit (20);
Emulator communication device (15), and emulator (40) two-way communication link, in data and fault input device (13) Information is transmitted between emulator (40);
Input/output unit (16), for the input trial and error data message into test control device (11), and receives testing and control The trial and error feedback data information that device (11) transmission comes;
The subtest unit (20) includes following part:
Subtest microprocessor (21), with subtest communication device (14) two-way communication link, is tested for receiving The instruction and data information that control device (11) is sent by subtest communication device (14), and by the instruction sum received It is believed that breath transfers to detected controller unit (30);The subtest microprocessor (21) is also by the detected control received The hardware status information and processing data of device unit (30) are sent to test control device through subtest communication device (14) (11);
Output control circuit (22), its input is connected with the output end of the subtest microprocessor (21), output end with The input for being detected controller unit (30) is connected, for being forwarded from test control device to detected controller unit (30) (11) the instruction and data information sent;
Input capture circuit (23), its input is connected with the output end of the detected controller unit (30), output end with The input of subtest microprocessor (21) is connected, for the hardware state letter for the detected controller unit (30) that will be received Breath and processing data are sent to test control device (11) through subtest communication device (14);
Two-way communication link between communication control circuit (24), with subtest microprocessor (21), the communication control circuit (24) signal output part connection is detected the signal input part of controller unit (30);
The detected controller unit (30) includes following part:
Be detected controller (31), and emulator (40) two-way communication link, be detected the input of controller (31) also with it is defeated The output end for entering circuit (32) is connected, and the output end for being detected controller (31) is connected with the input of output circuit (33);With Run in the program stored the machine code program and set according to machine code program;
Input circuit (32), its input is connected with the output end of the output control circuit (22), abnormal for receiving circuit Information;
Output circuit (33), its output end is connected with the input of the input capture circuit (23), for receiving and forwarding receipts The hardware status information of the detected controller unit (30) arrived;
The software implantation fault test flow of this method of testing is as follows:
S1, the machine code program using test control device (11), the first test of download needs, then by machine code program successively Transmitted by data and fault input device (13), emulator communication device (15), emulator (40) and be stored in tested observing and controlling In detected controller (31) in device unit (30) processed;
S2, the software project to be detected using input/output unit (16) selection machine code program, then in software item to be detected Inputted in mesh detection method program entry address, safeguard measure program entry address, the start-stop address of software project to be detected and Trial and error data message, above-mentioned input information is stored in the data storage device (12) by test control device (11);
S3, operation be detected controller (31) in machine code program, while test control device (11) pass sequentially through data and Fault input device (13), emulator communication device (15), emulator (40) monitoring and the operation of control machine coded program, work as machine When device coded program runs to the entry address of detection method program, test control device (11) is by data storage device (12) Trial and error data message pass sequentially through data and fault input device (13), emulator communication device (15), emulator (40) according to The start-stop address write-in of the software project to be detected is detected in the software project to be detected of controller (31), testing and control dress Put the detected controller (31) of (11) record whole before write-in trial and error data message and after write-in trial and error data message Operation information in individual running;
S4, the test control device (11) judge that the course of work for being detected controller (31) is according to the operation information It is no to meet setting program;
The operation information and judged result are exported shape by S5, the test control device (11) by input/output unit (16) Into test record.
2. the method for testing of family expenses as claimed in claim 1 and similar applications electrical equipment software evaluation Black-box Testing system, it is special Levy and be:The detected controller unit (30) also includes communication controler (34), the letter of the detected controller (31) Number output end is connected with the signal input part of the communication controler (34), the signal input part of the detected controller (31) The signal output part of connection communication control circuit (24), the signal output part connection communication control electricity of the communication controler (34) The signal input part on road (24).
3. the method for testing of family expenses as claimed in claim 1 and similar applications electrical equipment software evaluation Black-box Testing system, it is special Levy and be:In step S3, when machine code program runs to the entrance of detection method program, test control device (11) control machine Device coded program single step run, i.e. machine code program often run a step, and test control device (11) is by data storage device (12) In trial and error data message according to the software project to be detected start-stop address write be detected controller (31) it is to be detected In software project, it is ensured that the trial and error data message of write-in will not be changed before detection method program is compared judgement, until Machine code program operation jumps to safeguard measure program or machine code program is run to the outlet of detection method program.
4. the method for testing of family expenses as claimed in claim 3 and similar applications electrical equipment software evaluation Black-box Testing system, it is special Levy and be:In step S3, the machine code program circular flow, in each circular flow cycle, when machine code program operation To detection method program entrance when, test control device (11) control machine coded program single step run.
5. the method for testing of family expenses as claimed in claim 1 or 2 and similar applications electrical equipment software evaluation Black-box Testing system, its It is characterised by that the hardware implantation fault test flow of this method of testing is as follows:
Carry out the step S1 operations;
The item of hardware to be detected of machine code program is selected using input/output unit (16), the item of hardware to be detected is at least Including digital I/O detection projects, detection method program entry address, safeguard measure program are inputted in digital I/O detection projects Entry address, the passage for controlling abnormal circuit, the input information are stored in the data storage by test control device (11) In device (12);
Operation is detected the machine code program in controller (31), while test control device (11) passes sequentially through data and failure Input unit (13), emulator communication device (15), emulator (40) monitoring and the operation of control machine coded program, work as machine code When program runs to the entrance of detection method program, control of the test control device (11) in data storage device (12) is different The passage and switching information of normal circuit, send control command by subtest communication device (14) and give subtest microprocessor (21), the subtest microprocessor (21) passes sequentially through the output control circuit (22), the input circuit (32) and opened The corresponding circuit abnormality opened in detected controller unit (30) is set;Test control device (11) record is detected controller (31) operation information during the whole service before abnormal circuit setting and after abnormal circuit setting;
Carry out the step S4 operations;
Carry out the step S5 operations.
6. the method for testing of family expenses as claimed in claim 5 and similar applications electrical equipment software evaluation Black-box Testing system, it is special Levy and be:Item of hardware to be detected in step S2 also includes communication data detection project, the test of communication data detection project Step is as follows:
S21, in communication data detection project input detection method program entry address, safeguard measure program entry address, cut The passage and trial and error communication data information of communicating circuit are changed, the input information is stored in described by test control device (11) In data storage device (12);
S22, operation be detected controller (31) in machine code program, while test control device (11) pass sequentially through data and Fault input device (13), emulator communication device (15), emulator (40) monitoring and the operation of control machine coded program, work as machine When device coded program runs to the entrance of detection method program, test control device (11) is defeated in data storage device (12) Enter information, sending control command by subtest communication device (14) gives subtest microprocessor (21), and the auxiliary is surveyed Try microprocessor (21) and the switching being detected in controller unit (30) communication electricity is opened by the communication control circuit (24) The passage on road, subtest microprocessor (21) captures detected controller unit (30) by communication controller circuit (24) In detected controller (31) and communication controler (34) between communication data, the subtest microprocessor (21) will The communication data received adds the trial and error communication data information and obtains mixing trial and error data, and subtest microprocessor (21) will The mixing trial and error data are sent to tested controller (31);Test control device (11) record is detected controller (31) different The operation information during whole service before normal circuit path is set and after the setting of abnormal circuit passage;
S23, the test control device (11) judge that the course of work for being detected controller (31) is according to the operation information It is no to meet setting program;
S24, the test control device (11) export the operation information and judged result by input/output unit (16) Form test record.
CN201510868968.0A 2015-11-27 2015-11-27 The method of testing of family expenses and similar applications electrical equipment software evaluation Black-box Testing system Active CN105446882B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201510868968.0A CN105446882B (en) 2015-11-27 2015-11-27 The method of testing of family expenses and similar applications electrical equipment software evaluation Black-box Testing system

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201510868968.0A CN105446882B (en) 2015-11-27 2015-11-27 The method of testing of family expenses and similar applications electrical equipment software evaluation Black-box Testing system

Publications (2)

Publication Number Publication Date
CN105446882A CN105446882A (en) 2016-03-30
CN105446882B true CN105446882B (en) 2017-11-07

Family

ID=55557111

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201510868968.0A Active CN105446882B (en) 2015-11-27 2015-11-27 The method of testing of family expenses and similar applications electrical equipment software evaluation Black-box Testing system

Country Status (1)

Country Link
CN (1) CN105446882B (en)

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110674028A (en) * 2019-08-20 2020-01-10 华为技术有限公司 Fault injection method and device and business service system thereof
CN110826292B (en) * 2019-11-08 2023-07-04 航天柏克(广东)科技有限公司 Digital control visual graphical auxiliary analysis method

Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US6571389B1 (en) * 1999-04-27 2003-05-27 International Business Machines Corporation System and method for improving the manageability and usability of a Java environment
CN102629229A (en) * 2012-03-02 2012-08-08 南京大学 Co-diversified random testing (CAT) method

Patent Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US6571389B1 (en) * 1999-04-27 2003-05-27 International Business Machines Corporation System and method for improving the manageability and usability of a Java environment
CN102629229A (en) * 2012-03-02 2012-08-08 南京大学 Co-diversified random testing (CAT) method

Non-Patent Citations (2)

* Cited by examiner, † Cited by third party
Title
Automated Conformance Testing of Java Virtual Machines;Andrea Calvagna 等;《2013 Seventh International COnference on Complex,Intelligent,and Software Intensive Systems》;20131231;第547-552页 *
软件黑河测试的方法与实践;万年红 等;《计算机工程》;20001231;第26卷(第12期);第91-93页 *

Also Published As

Publication number Publication date
CN105446882A (en) 2016-03-30

Similar Documents

Publication Publication Date Title
CN108155619B (en) Protective relaying device multi-core CPU embedded system handles method and platform
CN106597947A (en) Substation equipment test method and system, server and tester
CN105652852B (en) A kind of Inspection and monitoring system of high voltage transducer power unit and its mainboard
CN107368408A (en) A kind of software fault towards interface injects automated testing method
CN109324601A (en) The test platform of robot controller or control system based on hardware in loop
CN102590730A (en) Modularized open PCBA (Printed Circuit Board Assembly) functional circuit test platform, system and method
CN103368795A (en) Automatic feeding, testing and sorting system and operation method thereof
CN103761185B (en) A kind of automatization test system and method
Kormann et al. Automated test case generation approach for PLC control software exception handling using fault injection
CN107608291A (en) A kind of intelligent substation application function linkage rule verification method and system
CN106980576B (en) A kind of built-in system software debugging system based on run time verification technology
CN110297470A (en) A kind of rail traffic battery data that lightweight is cross-platform monitoring host computer platform
CN109194491A (en) A kind of password evaluation and test pilot system and password evaluate and test test method
CN105446882B (en) The method of testing of family expenses and similar applications electrical equipment software evaluation Black-box Testing system
CN106646186A (en) Batch testing method and batch testing system for chips
CN111736064A (en) Multi-type signal online test method and system for PCB
CN109901554A (en) A kind of host computer execution method based on UDS diagnosis
CN113253700A (en) Hardware-in-loop closed-loop test method and system for battery management system
CN105468526B (en) Family expenses and similar applications electrical equipment software evaluation Black-box Testing system
CN105093096B (en) A kind of FPGA test device
CN106291329A (en) A kind of have the automatic test system detecting and joining the distant function of a terminal three
CN202421442U (en) Modularized open PCBA (Printed Circuit Board Assembly) functional circuit test (FCT) platform
CN112416676A (en) Testing tool applied to testing chip
CN205139905U (en) Domestic and similar usage electrical apparatus software aassessment black box test system
CN113691669B (en) Android mobile phone APP control vehicle full-process test analysis system and method

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant
CP01 Change in the name or title of a patent holder

Address after: 230031 No. 888 Changjiang West Road, Shushan District, Anhui, Hefei

Patentee after: HEFEI GENERAL MACHINERY RESEARCH INSTITUTE Co.,Ltd.

Patentee after: Hefei General Electromechanical Products Testing Institute Co., Ltd

Address before: 230031 No. 888 Changjiang West Road, Shushan District, Anhui, Hefei

Patentee before: HEFEI GENERAL MACHINERY Research Institute

Patentee before: Hefei General Electromechanical Products Testing Institute Co., Ltd

CP01 Change in the name or title of a patent holder