CN1402132A - Method for carrying out instrument module drive of automatic test system - Google Patents

Method for carrying out instrument module drive of automatic test system Download PDF

Info

Publication number
CN1402132A
CN1402132A CN 01132604 CN01132604A CN1402132A CN 1402132 A CN1402132 A CN 1402132A CN 01132604 CN01132604 CN 01132604 CN 01132604 A CN01132604 A CN 01132604A CN 1402132 A CN1402132 A CN 1402132A
Authority
CN
China
Prior art keywords
instrument
interface
test
module
idevice
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.)
Granted
Application number
CN 01132604
Other languages
Chinese (zh)
Other versions
CN1170225C (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.)
Huawei Technologies Co Ltd
Original Assignee
Huawei Technologies 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 Huawei Technologies Co Ltd filed Critical Huawei Technologies Co Ltd
Priority to CNB011326042A priority Critical patent/CN1170225C/en
Publication of CN1402132A publication Critical patent/CN1402132A/en
Application granted granted Critical
Publication of CN1170225C publication Critical patent/CN1170225C/en
Anticipated expiration legal-status Critical
Expired - Fee Related legal-status Critical Current

Links

Images

Landscapes

  • Debugging And Monitoring (AREA)

Abstract

A method for implementing the modular drive of the instrument in an automatic test system includes dividing test program into test program frame layer and test command sequence layer, dividing instrument driver into upper layer driver and lower layer driver, defining basic instrument interface by integrating the functions provided by instrument driver in the interface and setting up its interface pointer, loading instrument drive module by test program to obtain said interface pointer, and accessing the interface. Its advantage is easy exchange of instrument and its driver without need of modifying or recompiling test codes.

Description

The instrument module of Auto-Test System drives implementation method
Technical field
The present invention relates to field of automatic testing, especially a kind of instrument module of Auto-Test System drives implementation method.
Background technology
In Auto-Test System, test equipment is made up of industrial computer, various testing tool and measured object.The developer's of testing software task is that exploitation code communicates (measured object itself also can be regarded as an instrument, and only this instrument need be verified) with instrument and measured object.But every instrument all has own unique command set to support, like this, the developer of testing software requires a great deal of time the communication protocol and the command set that is based upon on the communication protocol basis at every instrument development low layer.And redaction constantly appears in various instruments, old version stops to sell, when we will duplicate the test macro of exploitation before, have to use new instrument, even use the similar instrument of other manufacturer production, at this moment, we just only develop new code at the instrument after changing again.Equally, for measured object, also always be among the continuous upgrading, so, test macro also will be developed new code again.
So, a kind of programmed instruction standard commands SCPI has just been proposed, this standard commands is that the angle from programmable instrument device message goes out to send and carries out standardizedly, and it is to carry out normalizedly from the angle of command context in other words, does not then do standard in the angle of instrumentation program driver module interface.Like this, though this order to a certain extent standard the form and the content of instrument order, simplified the complexity of instrument programming because the instrument that each manufacturer produces is very different, still be difficult to reach the purpose of instrument exchange on programming mode.
We are divided into test procedure (or being test code), instrument driving or product driving, instrument or three levels of product to the structure of test macro, as shown in Figure 1.Wherein product itself can be regarded as an instrument, so we can be called test procedure, instrument driving and instrument to these three levels.In order to reach the exchange between the instrument, just must reach instrument and drive the realization exchange, be closely to link to each other because instrument drives with instrument itself, can be regarded as one.After we are with concrete instrument and driving replacing thereof, do not need to revise or recompilate test code, system just can finish intended function.Have only in this case, after the instrument upgrading or purchasing the instrument of other producers, we can construct our needed test macro very like a cork, and the developer writes again from the beginning to the end, debugging code and do not want.
Summary of the invention
The instrument module that the purpose of this invention is to provide a kind of Auto-Test System drives implementation method, it can realize the exchange that instrument drives, make that with after concrete instrument and the driving replacing thereof do not need to revise or recompilate test code, system just can finish intended function.
For achieving the above object, solution of the present invention is: a kind of instrument module of Auto-Test System drives implementation method, has at one that test procedure, instrument drive, in the Auto-Test System of instrument,
A, test procedure is divided into two levels: finish basic user interface and integrally-built test procedure ccf layer and instrument and drive the test command sequence layer that communicates; Instrument driven be divided into two levels: the instrument upper strata drive part of communicating by letter with the test code of test procedure is provided, the instrument lower floor drive part with instrument communication is provided;
B, be defined in the underlying instrument interface between test command sequence layer and the instrument upper strata drive part, the various functions that provided be provided instrument be placed in the underlying instrument interface, and set up interface pointer;
C, test procedure load the instrument driver module, obtain the interface pointer of underlying instrument interface, by this interface pointer visit underlying instrument interface, realize the function that instrument drives.
In step b, the order of the basic driver operation of can produce initialization, self check that instrument drives, closing, obtaining system's current state and recent error information is placed in this underlying instrument interface.And the synchronization call function can be set in the underlying instrument interface, be placed in this synchronization call function communicating the operational order that need use between test procedure and the instrument driving.
In step b, we can also add concrete test operation order based on the underlying instrument interface that defines, and drive part defines abstract tool interface system on the upper strata of instrument driver module.
In step b, definition underlying instrument interface and abstract tool interface system are to adopt the document form of .H file to define.
In the present invention, before step c, the instrument driver module can be placed in the dynamic link libraries; In step c, loading the instrument driver module is to take out the instrument driver module to load from dynamic link libraries.
In step c, test procedure is that the load libraries function by Microsoft loads the instrument driver module.
We can define one and create projects module before step c of the present invention, and it can be created needed instrument and drive example, and return the interface pointer of a underlying instrument interface; In step c, test procedure loads after the instrument driver module, calls this establishment projects module, obtains the interface pointer of underlying instrument interface.
Because the present invention has utilized the thought of layering, instrument is driven the hierarchical structure that is divided into upper strata driver module and lower floor's driver module, and the functional interface that has defined the underlying instrument interface and further defined in the above according to concrete instrumental function, the test command sequence only needs this interface document, just can finish coding work, like this, instrument upper strata drive part does not change, when instrument is changed, test code does not need to revise just can finish operate as normal, has realized the exchange that instrument drives, and makes after concrete instrument and the driving replacing thereof, do not need to revise or recompilate test code, system just can finish intended function.
In addition, because the present invention is placed on the instrument driver module in the dynamic link libraries, test procedure directly comes to load the instrument driver module by the load libraries LoadLibrary function of the Microsoft of Microsoft from dynamic link libraries, saved the process that registration table is sought module of searching, improve the travelling speed of software greatly, coding is simple, need not understand the agreement of a lot of complexity.
Because underlying instrument interface of the present invention and the functional interface that expands on this basis are self-defining, its implementation procedure does not rely on the mechanism of the Microsoft of Microsoft, has therefore improved the ubiquity that is suitable for, and helps expanding and developing.
Description of drawings
Fig. 1 is a test macro module of software and hardware structural stratification synoptic diagram.
Fig. 2 is a method flow diagram of the present invention.
Fig. 3 is a test system structure layering synoptic diagram of the present invention.
Embodiment
Fig. 2 is a method flow diagram of the present invention.Can be clear that specific implementation process of the present invention in Fig. 2, each step in this implementation procedure is corresponding with each subhead of our back substantially.
(1) test procedure is divided into two levels: finish basic user interface and integrally-built test procedure ccf layer and instrument and drive the test command sequence layer that communicates; Instrument driven be divided into two levels: the instrument upper strata drive part of communicating by letter with the test code of test procedure is provided, the instrument lower floor drive part with instrument communication is provided.
Can in Fig. 3, be clear that about this part.The top of Fig. 3 is test procedure, this in the introduction of our background technology by the agency of get more clearly.It is divided into two parts: a part is the test procedure framework, finishes basic user interface and one-piece construction, and does not change basically; Another part is the test command sequence, and this part is mainly used to communicate with various testing tools, issues test command, receives instrument and returns next result, and the result is analyzed.The exploitation of test procedure is exactly the exploitation of test command sequence basically.The test procedure framework can be thought the exploitation of the item layer of program development, and the exploitation of test command sequence then is concrete exploitation.
The middle part of Fig. 3 is that instrument drives, and it can further be divided into two parts: a part provides the instrument upper strata drive part of communicating by letter with test code; A part provides the instrument lower floor drive part with concrete instrument communication.We to instrument drive make such level and divide after, will find that as long as instrument upper strata drive part does not change, just can guarantee when instrument is changed, test code does not need modification just can finish operate as normal, the realization plug and play.
We carried in beginning, and test equipment is made up of industrial computer, various testing tool and measured object.Drive about this a part of test procedure and instrument, and their two levels separately, in fact all be level in the software processes of industrial computer inside, not a real physical entity.We adopt the disposal route of this layering, are the first steps that realizes the object of the invention.
(2) we carried in the superincumbent narration, as long as instrument upper strata drive part does not change, just can guarantee when instrument is changed, and test code does not need to revise just can finish operate as normal, realizes plug and play.So, how to guarantee that instrument upper strata drive part does not change? we define a underlying instrument interface IDevice between test command sequence layer and instrument upper strata drive part, the various functions that provided are provided instrument are placed among the underlying instrument interface IDevice, and set up interface pointer.It all is to be undertaken by this interface and other functional interfaces on its basis that the test command sequence layer calls instrument upper strata drive part.By these interfaces, the test command sequence only needs defined each interface document of instrument driver module, by this interface document, just can finish coding work, test command sequence and instrument driver module were bound in the time of running, and when never calling the instrument driving, it is independently that test command sequence and instrument drive, the variation that instrument drives impacts can for the test command of test command sequence, thereby realizes the plug and play of instrument driver module.
Do you how define underlying instrument interface IDevice? the order of the basic driver operation of can produce initialization, self check that instrument drives, closing, obtaining system's current state and recent error information is placed among this underlying instrument interface IDevice.Can also in this underlying instrument interface IDevice, the synchronization call function be set, be placed in this synchronization call function communicating the operational order that to use between test procedure and the instrument driving.
Give one example now.
We are by a underlying instrument interface of such procedure definition Idevice:
At first initialization module provides system more needed initiation parameters;
Module is started working then;
Make module carry out self check, check whether module itself breaks down;
Reset, said process is very similar with the opening computer process in fact;
Module quits work;
The Unload module program;
The title of acquisition module;
The descriptor of acquisition module;
The version information of acquisition module;
Judge whether online;
Obtain system's current state, 0 this equipment of expression is bad; 1 this equipment of expression is normal; Other users can oneself define;
Obtain nearest error message, this is the key that our Auto-Test System is tested automatically with last one;
If submodule is arranged, obtain the number of submodule.In module, some submodules can be set,, also will follow the process same in fact with female module for calling of each submodule;
Obtain the interface of certain submodule.
In this interface, be provided with the synchronization call function:
1) reads function, comprising: the send buffer pointer;
The byte number of desiring to read;
The actual byte number pointer that reads;
Read synchronously.
2) write function, comprising: send buffer zone;
The byte number that desire sends;
The actual byte number pointer that sends;
Synchronous write.
3) function of installation call back function comprises: event code ID is set;
After the generation incident, the event handling call back function;
Call back function is installed.
4) function of unloading call back function comprises: event code ID is set;
After the generation incident, the event handling call back function;
The unloading call back function.
Certainly, in real process, said process all is to carry out with the form of source code.We can copy said process setting.
We can also add concrete test operation order based on the underlying instrument interface IDevice that defines, and drive part defines abstract tool interface system on the upper strata of instrument driver module.Such as we can define SDH tester interface (for example transmission equipment ISdh interface), can be in concrete test operation orders such as this interface definition " jitter test ", " error code testings ", because these functions are functions that the SDH tester all has, so, just can operate all SDH testers by this interface.When the upgrading of SDH tester has increased new test function, then can define tester interface (for example transmission equipment ISdh2 interface) again, driver module for new SDH tester, not only to realize transmission equipment ISdh interface, so that the function of definition before supporting, also to realize transmission equipment ISdh2 interface, be used for supporting the function that tester increases newly.Like this, just can be used for the former test macro that uses old tester to develop very smoothly with new tester.
The interface definition of underlying instrument interface IDevice and abstract tool interface system is the form that adopts the Microsoft definition, and Interface Definition Document adopts the form of .H file.
(3) test procedure loads the instrument driver module, obtains the interface pointer of underlying instrument interface IDevice, by this interface pointer visit underlying instrument interface IDevice, realizes the function that instrument drives.
Before this step, the instrument driver module can be placed in the dynamic link libraries DLL, in the system of Microsoft, the instrument driver software module is both can be placed in the dynamic link libraries to carry out as text, can be used as also that the executable file that has .exe carries out, the speed that the result causes program to carry out descends, and program implementation compares very fast in dynamic link libraries.When this step was carried out, loading the instrument driver module was to take out the instrument driver module to load from dynamic link libraries DLL.
Test procedure is that the load libraries LoadLibrary function by the Microsoft of Microsoft loads the instrument driver module.It is as Microsoft, carries out searching of a very long process and carries out by searching registration table, has greatly saved the execution time of the present invention, has improved efficient of the present invention.About load libraries LoadLibrary function part, be a general purpose function of Microsoft, those skilled in the art are perfectly clear.
Before this step is carried out, can define one and create project CreateObject module, it can be created needed instrument and drive example, and returns the interface pointer of a underlying instrument interface IDevice; In this step, test procedure loads after the instrument driver module, calls this establishment projects module, obtains the interface pointer of underlying instrument interface IDevice.The function of this establishment projects module is exactly that test command for test procedure finds a suitable instrument to drive example, is easy to programming operation for a person skilled in the art.When specifically calling the instrument driver module, can be by certain technical finesse, on the test command sequence, indicate the instrument type that needs, such as the ATM tester, then by the test procedure framework according to current instrument kind of installing, only instrument driver module is loaded in decision, and obtains the underlying instrument interface IDevice of this instrument driver module, it is returned to the test command block use.
In fact lower floor's drive part of instrument driver module is exactly an instrument adapter, with the difference of instrument and difference; The upper strata drive part is then stipulated according to different functions.So in actual applications, test procedure is handled just to resemble abstract instrument and equipment such as ATM tester and drives, and the order that test procedure issues converts the order that particular instrument can be discerned to by lower floor's driving interface.By such hierarchy, the interchange issues between just can process instrumentation.

Claims (8)

1, a kind of instrument module of Auto-Test System drives implementation method, has at one that test procedure, instrument drive, in the Auto-Test System of instrument,
A, test procedure is divided into two levels: finish basic user interface and integrally-built test procedure ccf layer and instrument and drive the test command sequence layer that communicates; Instrument driven be divided into two levels: the instrument upper strata drive part of communicating by letter with the test code of test procedure is provided, the instrument lower floor drive part with instrument communication is provided;
B, be defined in the underlying instrument interface (IDevice) between test command sequence layer and the instrument upper strata drive part, the various functions that provided be provided instrument be placed in the underlying instrument interface (IDevice), and set up interface pointer;
C, test procedure load the instrument driver module, obtain the interface pointer of underlying instrument interface (IDevice), by this interface pointer visit underlying instrument interface (IDevice), realize the function that instrument drives.
2, the instrument module of Auto-Test System according to claim 1 drives implementation method, it is characterized in that: in step b, the order of the basic driver operation of can produce initialization, self check that instrument drives, closing, obtaining system's current state and recent error information is placed in this underlying instrument interface (IDevice).
3, the instrument module of Auto-Test System according to claim 1 and 2 drives implementation method, it is characterized in that: in step b, in underlying instrument interface (IDevice), the synchronization call function is set, is placed in this synchronization call function communicating the operational order that to use between test procedure and the instrument driving.
4, the instrument module of Auto-Test System according to claim 3 drives implementation method, it is characterized in that: in step b, based on the underlying instrument interface (IDevice) that defines, add concrete test operation order, drive part defines abstract tool interface system on the upper strata of instrument driver module.
5, the instrument module of Auto-Test System according to claim 4 drives implementation method, it is characterized in that: in step b, definition underlying instrument interface (IDevice) and abstract tool interface system are to adopt the document form of .H file to define.
6, the instrument module of Auto-Test System according to claim 1 drives implementation method, it is characterized in that: before step c, the instrument driver module is placed on dynamic link libraries (DLL) lining; In step c, loading the instrument driver module is to take out the instrument driver module to load from dynamic link libraries (DLL).
7, the instrument module according to claim 1 or 6 described Auto-Test Systems drives implementation method, it is characterized in that: in step c, test procedure is to load the instrument driver module by the load libraries of Microsoft (Microsoft) (LoadLibrary) function.
8, the instrument module according to claim 1 or 6 described Auto-Test Systems drives implementation method, it is characterized in that: before step c, define an establishment project (CreateObject) module, it can be created needed instrument and drive example, and returns the interface pointer of a underlying instrument interface (IDevice); In step c, test procedure loads after the instrument driver module, calls this establishment project (CreateObject) module, obtains the interface pointer of underlying instrument interface (IDevice).
CNB011326042A 2001-08-28 2001-08-28 Method for carrying out instrument module drive of automatic test system Expired - Fee Related CN1170225C (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CNB011326042A CN1170225C (en) 2001-08-28 2001-08-28 Method for carrying out instrument module drive of automatic test system

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CNB011326042A CN1170225C (en) 2001-08-28 2001-08-28 Method for carrying out instrument module drive of automatic test system

Publications (2)

Publication Number Publication Date
CN1402132A true CN1402132A (en) 2003-03-12
CN1170225C CN1170225C (en) 2004-10-06

Family

ID=4671485

Family Applications (1)

Application Number Title Priority Date Filing Date
CNB011326042A Expired - Fee Related CN1170225C (en) 2001-08-28 2001-08-28 Method for carrying out instrument module drive of automatic test system

Country Status (1)

Country Link
CN (1) CN1170225C (en)

Cited By (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN100349134C (en) * 2005-03-28 2007-11-14 华为技术有限公司 Method and system for testing drive software
CN100456252C (en) * 2004-02-25 2009-01-28 三星电子株式会社 Method of testing open services gateway initiative service platform and test tool using the method
CN101404651B (en) * 2008-11-12 2011-08-17 武汉虹信通信技术有限责任公司 Method for compatibility of automatic test system with different instrument communication bus
CN102508781A (en) * 2004-09-14 2012-06-20 科威尔公司 Debug in a multicore architecture
CN104298501A (en) * 2014-08-26 2015-01-21 中国直升机设计研究所 Drive design method of automatic test equipment instrument
US9038070B2 (en) 2004-09-14 2015-05-19 Synopsys, Inc. Debug in a multicore architecture
CN116436541A (en) * 2023-06-12 2023-07-14 西安弘捷电子技术有限公司 Multichannel TR (transmitter/receiver) component test instrument management method and system

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101799506B (en) * 2010-04-21 2012-05-30 广州市广晟微电子有限公司 Chip test method, device and system based on script control

Cited By (13)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN100456252C (en) * 2004-02-25 2009-01-28 三星电子株式会社 Method of testing open services gateway initiative service platform and test tool using the method
US9038070B2 (en) 2004-09-14 2015-05-19 Synopsys, Inc. Debug in a multicore architecture
CN102508781A (en) * 2004-09-14 2012-06-20 科威尔公司 Debug in a multicore architecture
CN102521137A (en) * 2004-09-14 2012-06-27 科威尔公司 Debug in multicore architecture
US9038076B2 (en) 2004-09-14 2015-05-19 Synopsys, Inc. Debug in a multicore architecture
US9129050B2 (en) 2004-09-14 2015-09-08 Synopys, Inc. Debug in a multicore architecture
CN102508781B (en) * 2004-09-14 2015-10-14 斯诺普西斯公司 Debugging in multicore architecture
CN102521137B (en) * 2004-09-14 2015-10-28 斯诺普西斯公司 Debugging in multicore architecture
US9830241B2 (en) 2004-09-14 2017-11-28 Synopsys, Inc. Debug in a multicore architecture
CN100349134C (en) * 2005-03-28 2007-11-14 华为技术有限公司 Method and system for testing drive software
CN101404651B (en) * 2008-11-12 2011-08-17 武汉虹信通信技术有限责任公司 Method for compatibility of automatic test system with different instrument communication bus
CN104298501A (en) * 2014-08-26 2015-01-21 中国直升机设计研究所 Drive design method of automatic test equipment instrument
CN116436541A (en) * 2023-06-12 2023-07-14 西安弘捷电子技术有限公司 Multichannel TR (transmitter/receiver) component test instrument management method and system

Also Published As

Publication number Publication date
CN1170225C (en) 2004-10-06

Similar Documents

Publication Publication Date Title
EP1445693B1 (en) System and method for building and configuring cross-platform applications
CA2290086C (en) Method for loading a java application program
US6971093B1 (en) Techniques for maintaining compatibility of a software core module and an interacting module
CN1248116C (en) General purpose testing arrangement for embedded module and subsystem based on host machine platform
US8037467B2 (en) Single stream processing with multi-version support of application operating environments
CN1885264A (en) Software package constructing method and system for embedded system
CN102279765A (en) Pre-compiling hosted managed code
CN1170225C (en) Method for carrying out instrument module drive of automatic test system
CN1455348A (en) Incremental duplication of source document and its bag on networked resources
CN111338657B (en) Template-based palm parameter batch configuration method
CN1641601A (en) Software unit measuring method
EP0631229A2 (en) Method and system of storing and restoring object persistent attribute data
CN1945531A (en) Design method of inter-operation system
CN112181432A (en) System for realizing bundle modular packaging processing in ReactNative framework
EP1445694A2 (en) Modularization for J2ME platform implementation
CN1167012C (en) Test system for information equipment and test method
CN100337198C (en) A mobile communications device application processing system
CN1945527A (en) SERVER edition code generation system capable of realizing code reutilizization
CN102736905A (en) Method for dynamically replacing field in classes
CN1805582A (en) Method of testing with integrated test tools
CN1848093A (en) Method for debugging high configuration and power supply interface module in basic inputting and outputting system
US20050081166A1 (en) System and method facilitating automated navigation for user interface(s)
CN1154922C (en) Expandable automatic test platform
CN1971509A (en) Method to realize binary compatibility operation by component software system based on equipment interface
CN101059758A (en) Screen transition program generating method and device

Legal Events

Date Code Title Description
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
C06 Publication
PB01 Publication
C14 Grant of patent or utility model
GR01 Patent grant
DD01 Delivery of document by public notice

Addressee: Huawei Technology Co Ltd

Document name: Notification to Pay the Fees

DD01 Delivery of document by public notice
DD01 Delivery of document by public notice

Addressee: Huawei Technologies Co., Ltd.

Document name: Notification of Termination of Patent Right

CF01 Termination of patent right due to non-payment of annual fee
CF01 Termination of patent right due to non-payment of annual fee

Granted publication date: 20041006

Termination date: 20160828