通用测试仪器VISA引擎及常见接口驱动设计
发布时间:2018-05-22 17:19
本文选题:通用测试仪器 + VISA ; 参考:《电子科技大学》2013年硕士论文
【摘要】:虚拟仪器在自动化测试领域中带来的技术革新,使得仪器软件的开发占据越来越重要的地位。VISA(Virtual Instrument Software Architecture),即虚拟仪器软件结构,实现控制计算机与仪器的软件层连接,用于与不同总线接口的仪器进行通讯,被广泛应用于测量工业中测试仪器与上位机的交互。 VISA作为标准I/O库,将对仪器硬件接口的操作进行封装,只向用户开放其可操作的接口函数原型,,且独立于仪器类型、计算机操作系统和具体的编程语言,实现虚拟仪器软件的可互换性及灵活性。本课题研究虚拟仪器软件架构,为通用测试仪器开发具有自主知识产权的VISA库,主要内容有: (1) VISA整体架构的设计。采用分层架构思想,结合经典设计模式,设计VISA平台整体架构,其分层架构将VISA系统按不同功能职责有序组织,以实现低耦合高内聚,提高软件系统的效率及可维护性。采用动态链接库实现VISA的封装,使VISA支持多语言、跨平台使用。 (2) VISA引擎各部分详细设计。包括属性机制、资源管理器和资源解析器的设计与实现。采用静态存储属性不变参数与动态添加属性可变参数相结合的方式完成属性的存储。资源管理器设计链表管理资源,便于扩充接口种类,实现VISA库的向后兼容性。资源解析器结合编译原理,分别实现词法分析、语法分析和正则表达式匹配三个模块,模块间协同合作共同完成资源解析的任务,实现高效、准确的资源查找字符串解析。 (3)常见接口驱动的设计。采用机制与策略分离的思想分层设计驱动,具体驱动分离实现并隐藏,只向用户提供统一接口。按消息基器件和寄存器基器件分类设计接口驱动,包括PXI接口驱动、以太网接口驱动及本地总线接口驱动的实现。 (4)软件的测试。按照不同的通信环境,搭建两种不同的测试平台,根据各模块的用途,综合使用不同软件测试方法制定测试方案,分别完成各模块的测试,再结合VISA整体架构进行综合测试,分析并解决测试中出现的问题。 经过测试,本课题开发的VISA支持跨平台、可重入、多语言和多线程安全,满足设计需求。
[Abstract]:Because of the technological innovation brought by virtual instrument in the field of automatic testing, the development of instrument software occupies a more and more important position. VISAN Virtual Instrument Software Architecture, that is, the structure of virtual instrument software, realizes the software layer connection between computer and instrument. It is used to communicate with instruments with different bus interfaces and is widely used in measuring industry. As the standard I / O library, VISA encapsulates the operation of the hardware interface of the instrument, and only opens its operable interface function prototype to the user, independent of the instrument type, the computer operating system and the specific programming language. The interchangeability and flexibility of virtual instrument software are realized. This paper studies the software architecture of virtual instrument and develops VISA library with independent intellectual property for universal test instrument. The main contents are as follows: 1) the design of the overall VISA architecture. The overall architecture of VISA platform is designed by adopting the idea of layered architecture and the classical design pattern. The layered architecture organizes the VISA system according to different functions and responsibilities in order to achieve low coupling and high cohesion and improve the efficiency and maintainability of the software system. Dynamic Link Library (DLL) is used to encapsulate VISA, which enables VISA to support multi-language and cross-platform use. 2) the detailed design of each part of VISA engine. Including the property mechanism, resource manager and resource parser design and implementation. Static storage of attribute invariant parameters and dynamic addition of variable attribute parameters are used to store attributes. The resource manager designs the linked list to manage the resource, which is convenient to expand the type of interface and realize the backward compatibility of VISA library. Based on the compiling principle, the resource parser implements three modules: lexical analysis, syntax analysis and regular expression matching. The modules cooperate to accomplish the task of resource parsing, and the efficient and accurate resource search string parsing is realized. Design of common interface drivers. The idea of separation of mechanism and policy is used to design the driver, which is implemented and hidden separately, and only provides the user with a unified interface. Interface drivers are designed according to message based devices and register based devices, including PXI interface drivers, Ethernet interface drivers and local bus interface drivers. Software testing. According to different communication environment, two different test platforms are built. According to the use of each module, different software test methods are used to make the test plan. The test of each module is completed separately, and then combined with the overall structure of VISA to conduct comprehensive test. Analyze and resolve the test problems. After testing, the VISA developed in this paper supports cross-platform, reentrant, multi-language and multi-thread security to meet the design requirements.
【学位授予单位】:电子科技大学
【学位级别】:硕士
【学位授予年份】:2013
【分类号】:TP311.53
【参考文献】
相关期刊论文 前8条
1 熊伟,戴果;基于flex和bison的编译器开发[J];兵工自动化;2004年01期
2 刘浩,万昆;基于动态链接库DLL的实时数据库系统研究与开发[J];东北电力学院学报;2005年01期
3 王学伟;张未未;;USB—GPIB控制器VISA函数库的开发及在Visual C++中的应用[J];电测与仪表;2006年11期
4 边海龙;顾亚平;陈光
本文编号:1922952
本文链接:https://www.wllwen.com/falvlunwen/zhishichanquanfa/1922952.html