摘要:随着信息时代的到来,信息的数据采集以及存储也逐渐的发展起来。而伴随着现在工业领域对数据采集的要求越来越高,传统的数据采集卡由于一些问题已经不能满足当代数据采集的要求,所以高速的数据传输对整个系统的提升有着很大的意义。近年来,通用串行总线USB以其快速、即插即用、使用安装方便等优点逐渐成为现代数据传输的发展趋势,所以将USB应用于数据采集系统有着很大的应用价值。本论文主要设计、完成基于USB的数据采集系统,系统包含硬件和软件两部分,硬件主要是器件选型,软件则包括主机应用软件、单片机固件程序和驱动三大部分。硬件部分包括了对于单片机器件的选型、A/D转换模块、USB总线接口电路等,文中给出了硬件电路模块的实现过程,并完成了系统硬件实物的设计和调试。10546
关键词:数据采集;USB;单片机;固件
USB data acquisition system design
Abstract: With the advent of the information age, data acquisition and storage of information has gradually developed. Along with the industrial areas of data acquisition increasingly high demand for traditional data acquisition card due to some problems can no longer meet the requirements of the contemporary data acquisition, high-speed data transmission upgrade of the entire system has a lot of sense. In recent years, the Universal Serial Bus (USB), its fast, plug and play, easy installation gradually become the development trend of modern data transmission, so the USB applied to the data acquisition system has great value. In this paper, design, complete USB-based data acquisition system, the system includes both hardware and software parts, hardware device selection, software including the host application software, microcontroller firmware and drivers of three parts. The hardware includes a selection of microcontroller devices, A / D conversion module, USB bus interface circuit, the paper presents the implementation process of the hardware circuit module, and the kind of system hardware design and debug.
Keyword:Data acquisition; USB; MCU; firmware
1 绪论 1
1.1 本课题研究意义 1
1.2 课题背景 1
1.3 USB的优点 1
1.4 国内外研究现状 2
1.4 课题研究内容 3
2 USB协议与规范 4
2.1 USB发展过程 4
2.2 体系结构概述 4
2.2.1 USB系统描述 4
2.2.2 物理接口 5
2.3 USB设备 5
2.3.1 设备接口 6
2.3.2 USB逻辑设备 6
2.3.3 功能单元 7
2.4 USB数据传输 7
2.4.1控制传输 7
2.4.2同步传输 7
2.4.3中断传输 8
2.4.4批量传输 8
2.4.5 四种传输类型总结 8
3 系统硬件设计 9
3.1实际应用系统设计 9
3.2 USB控制电路 9
3.2.1 USB控制芯片的选型 9
3.2.2 PDIUSBD12 9
3.2.3 USB模块电路设计 13
3.3 STC89C51单片机结构与特点 14
3.3.1 STC89C51封装及引脚说明 15
3.3.2 单片机模块电路设计 17
3.3.3 STC89C51内置USB控制器 17
3.4 A/D转换电路设计 19
3.4.1 A/D转换器 19
3.4.2 A/D转换器接口电路 21
4.系统软件实现 23
4.1 固件程序任务 23
4.1.1 固件程序任务 23