基于USB2.0的图像采集卡的设计与实现
详细信息    本馆镜像全文|  推荐本文 |  |   获取CNKI官网全文
摘要
随着多媒体技术发展,数字图像的采集和处理已经成为许多应用系统的核心和基础。本文阐述了基于USB(Universal Serial Bus)接口的图像采集卡的设计、制作及软件的编写过程。本卡将用于在基于红外热图像分析的电路板检测系统中,采集红外热像仪输出的图像数据。
     现在市面上的数字图像采集卡价格昂贵,且大多使用PCI(Peripheral Component Interconnect)接口,使用不方便。本文研制的图像采集卡使用了较新且较普遍的USB接口,具有极强的易用性和便携性,且能够实现与红外热像仪的良好匹配。将USB接口的图像采集卡与红外热像仪集成为一体在国内还未见报道。
     论文从图像采集的意义和本课题的应用背景出发,阐述了图像采集系统的组成,分析了各部分的性能需要,比较了现有的计算机总线技术及可编程逻辑技术,提出了一种基于计算机USB2.0总线接口,应用FPGA进行逻辑控制的方案。
     USB2.0接口有很多突出的优点:即插即用,连接方便,传输速度快,兼容性强。它已经在诸多设备中得到了非常广泛的应用。FPGA的使用大大简化了逻辑控制电路的设计,并且由于体积小、速度快及可编程性强等诸多优点,它已经渐渐成为数字逻辑设计的首选。
     论文从硬件系统设计和软件设计两大方面详细阐述了其开发方法和实现过程。在硬件电路设计方面,本论文分模块介绍了各部分电路的时钟电源设计、接口设计,说明了FPGA(Field Programmable Gate Array)的启动配置模式和重要信号引脚的连接设计,分析并选择了Slave FIFO模式为USB芯片和FPGA之间的接口模式。系统软件设计分为三个大部分进行:固件程序、驱动程序和上层应用程序。固件程序部分重点介绍了软件流程和USB芯片的中断系统。Windows下WDM(Win32 Driver Model)驱动程序是功能的提供者,操作系统才是过程的管理者。因此驱动程序部分在介绍了WDM的层次结构基础上,分析了驱动程序被调用流程,及关键函数的设计方法。应用设计主要关注了图像数据的格式转换及显示方式。
     经过设计、制作和调试,本图像采集卡已经开发完成,完全满足预定目标。该卡的研制成功,为基于红外图像分析的电路板检测系统的小型化、实用化奠定了坚实的技术基础。
With the development of multimedia technology, the digital image acquisition and processing have become the core and foundation of a lot of application system. In this paper, the design, fabrication and software programming of an image acquisition card which is based on USB2.0 interface are presented. This card will be used for acquiring image data exported by infrared camera in PCB diagnosis system which is based on thermal images processing.
     The commercially available digital image acquisition cards are expensive, and usually connected through PCI interface, which is not convenient to use. The card we develop can be connected through USB interface providing great convenience to use and take around, and can make a good match with our infrared camera. Interiorly it hasn't been reported to integrate image acquisition card which is based on USB interface with infrared camera.
     In this dissertation, beginning from the significance of image acquisition and the application background, the modules of the image acquisition system are presented, the capability requiring of every module is analyzed, the existing computer bus technology and programmable logic technology are compared, a scheme is brought forward which uses USB2.0 as the bus interface and uses FPGA to control the logic.
     The USB2.0 interface has a lot of advantages, including Plug and Play, connecting convenience, high-speed transportation and strong compatibility. It has been widely used in many devices. By using FPGA, the design of logic-control circuit has been significantly simplified, and because of the advantages such as small size, high speed and programmability, FPGA has become the top option in digital logic design.
     In this dissertation, the method and implementation process of both hardware system and software design are presented. In aspect of hardware circuit, the design of the clock, power and interface is introduced; the start-up configuration modes and the significant signal pins connections are explained; the Slave FIFO interface mode between USB chip and FPGA chip is chosen after analyzing. System software design is composed of three parts: firmware, driver and application. In the part of firmware, software flow and the interrupt system are put emphasis on. Under Windows, the WDM (Win32 Driver Model) driver is the provider of functions, and the operating system is in charge of the process. So after the hierarchy of WDM is introduced, the sequence of function calls and the design method of key functions are analyzed. In Application design, the format conversion and the display usage are focused on.
     After design, fabrication and debugging, the image acquisition card has been completed, and the anticipated goal has been achieved. It has provided a firm technical basis for miniaturization and practicality of the PCB diagnosis system which is based on thermal image processing.
引文
[1] 沈兰荪.高速数据采集系统的原理与应用.北京人民邮电出版,1995
    [2] 程开富.CCD图像传感器的市场与发展.国外电子元器件,2000,7:4
    [3] 蔡.AD/DA与DC-DC变换器的技术发展.电子产品世界,2005,3
    [4] 于宗光,魏敬和,王国章.SoC和FPGA技术未来的发展趋势.电子与封装,2006,3
    [5] Xilinx.Virtex-5 User Guide.Xilinx Inc,2006
    [6] 王成儒,李英伟.USB2.0原理与工程开发.北京:国防工业出版社,2004
    [7] 范超.TIP检测仪热像数据采集卡的设计与实现:[硕士学位论文],成都:电子科技大学,2005
    [8] 韩振雷.数字分量视频的取样结构及其码率计算.中国有线电视,2006,24
    [9] 黄传铭.基于USB2.0接口技术的医学视频图像采集系统的研制:[硕士学位论文],成都:电子科技大学,2005
    [10] 于晓琳.SAA7111A在实时图像采集系统中的应用.电子产品世界,2005,1:97
    [11] 肖儿良.SAA7111A在图像多媒体中的应用.视频电路,1999,7:79
    [12] 黄正谨.CPLD系统设计技术入门与应用.北京:电子工业出版社,2002
    [13] 孙航.Xilinx可编程逻辑器件的高级应用与设计技巧.北京:电子工业出版社,2004
    [14] 冯寿廷.FPGA/SOPC开发简明教程.http://www.21control.com
    [15] Jan Axelson. USB Complete. USA, Lakeview Research LLC,2005
    [16] 边海龙.USB2.0设备的设计与开发.北京:人民邮电出版社,2004
    [17] 武安河.Windows设备驱动程序开发实务.北京:电子工业出版社,2001
    [18] 陈启美,丁传锁.计算机USB接口技术.南京,南京大学出版社,2003
    [19] Cypress. EZ-USB Manual Technical Reference. Cypress Inc.
    [20] 程昱,刘建伟.Protel DXP电路设计白金教学.北京:科学出版社,2005
    [21] Universal Serial Bus Specification 2.0. http://www.usb.org.2000
    [22] John Hyde.USB设计应用实例.北京:中国铁道出版社,2003
    [23] 邵震洪,赵杭生.基于TPS70351的板级电源设计.世界电子元器件,2003,11:42
    [24] TEXAS INSTRUMENTS. TPS70351 data.sheet. TI,2002
    [25] 季宏锋,吴军辉,徐立鸿.I~2C总线技术及应用实例.自动化与仪表,2002,VOL 17:21
    [26] Philips.I~2C总线规范.Philips Inc,2000
    [27] 何立民.I~2C总线应用系统设计.北京:北京航空航天大学出版社.1995
    [28] Philips.SAA7111A datasheet.Philips,1998,5
    [29] STMicroelectronics. LD1117 datasheet.STMicroelectronics,2004
    [30] Xilinx. Spartan-IIE Introduction and Ordering Information datasheet.Xilinx,2004
    [31] Xilinx. Platform Flash PROM User Guide. Xilinx Inc,2005
    [32] Xilinx. Platform Flash In-System Programmable Configuration PROMs. Xilinx Inc,2005
    [33] 何希顺,张跃.嵌入式系统中的JTAG接口编程技术.电子技术应用,2001,12
    [34] Xilinx. Spartan-IIE Functional Description datasheet.Xilinx,2004
    [35] 黄晓革.FPGA同步设计及实现.重庆邮电学院学报.2006.6
    [36] 陈燕,周东辉,朱晓荣.DLL在FPGA时钟设计中的应用.青岛大学学报,2004,VOL19
    [37] Cypress. CY7C68013A datasheet,Cypress Inc.2005
    [38] Cypress. CY7C 1041 CV33 datasheet, Cypress Inc.2004
    [39] Cypress. EZ-USB DVK Users Guide,Cypress Inc.2003
    [40] Walter Oney 著.马少华译. Programming The Microsoft Windows Driver Model(2nd).U SA,Microsoft Press.2003
    [41] Microsoft. Windows Driver Development Kit. Document. Microsoft,2003
    [42] Microsoft.Windows 2000 设备驱动程序开发大全.USA, Microsoft Press. 2000
    [43] Art Baker. The Windows 2000 Device Driver Book, A Guide for Programmers, Second Edition. USA: Prentice Hall PTR.2000
    [44] Chris Cant著,马莉波译.Windows WDM设备驱动程序开发指南.北京,机械工业出版社,2000
    [45] Charles Petzold著,侯捷译.Programming Windows.USA,Microsotl Press.1998
    [46] 李现勇.Visual C++串口通信技术与工程实践.北京,人民邮电出版社,2002
    [47] Microsoft, Microsoft Deveiopper Network.Microsoft,2001
    [48] Mark D. Pesce .Programming Microsoft DirectShow for Digital Video and Television. USA, Microsoft Press. 2003
    [49] 邵丹,韩家伟.YUV与RGB之间的转换.长春大学学报,2004,VOLi4.
    [50] 何斌.VisualC++数字图像处理.北京,人民邮电出版社.2005
    [51] 刘三强.流类微驱动程序研究及在视频采集中的应用:[硕士学位论文],西安:西安电子科技大学,2005

© 2004-2018 中国地质图书馆版权所有 京ICP备05064691号 京公网安备11010802017129号

地址:北京市海淀区学院路29号 邮编:100083

电话:办公室:(+86 10)66554848;文献借阅、咨询服务、科技查新:66554700