The Realization of Host/Slave USB Interface
- Author
- CaoFang
- Advisor
- YuanZuoZuo
- School
- Shenyang University of Technology
- Major
- Measuring Technology and Instruments
- Classification
- TP336 Bus channel
- Degree
- Master's thesis
- Year
- 2007
- Downloads
- 570
- Citations
- 12
Abstract
USB (Universal Serial Bus) has been developing rapidly in recent years, having the attributes of low-cost, rapid-speed, ease-of-extend, plug-and-play, so it is applied widely. USB Specification compartmentalizes the data transfer system to two parts: host computer and peripheral device. At present, PC acts as the host computer, the market’s USB products act as the peripheral device. But the embedded systems which use microcomputer such as MCU as the core lack the direct interfaces to USB products. As a result, the host USB interface applied the embedded systems becomes the focus of USB field. MCU reads and writes flash memory disk directly, furthermore the technology can be applied on instruments to realize portable instrument. On the basis of the host USB interface, the system with the slave USB interface which can be used as peripheral device is more popular. This paper follows the new idea to design and practice the host/slave USB interface.The system selects Winbond’s W78E54B to act as the CPU, and selects Cypress’s SL811HS to act as USB host/slave interface chip to buildup the interface module. The hardware of the system possesses the virtue of cheapness, speediness, etc. From the point of the host USB software, the system integrates USB Driver, USB host controller driver and user software, it enumerates and configures flash memory disk well. Moreover, the system follows mass storage class protocol and establishes FAT(File Allocation Table) file system so that it can read and write flash memory disk. The slave USB software includes device end’s firmware and PC end’s device driver which is exploited using VC++, DDK and DriverStudio as well as PC end’s user software to realize the module acting as universal device to communicate with PC.According to the method introduced in this paper, the host/slave USB interface module is established successfully. The experiments proved that this system is reliable, extendable and can be transplanted to other embedded system.
Table of contents
Abstract 5-6
Abstract 6-10
1 Introduction 10-14
1.1 subject sources 10
1.2 research purposes 10
1.3 research significance 10-11
1.4 research status 11-12
1.5 Problems 12
1.6 This research ideas and expectations 12-14
2 USB protocol outlined 14-25
2.1 the USB Profile 14-16
2.1.1 USB characteristics 14-15
2.1.2 USB system model and topology 15
2.1.3 USB specification Introduction 15-16
2.2 USB data communication structure 16-19
2.2.1 data communication protocol About 16-18
2.2.2 type of data transmission 18-19
2.3 USB protocol stack device framework 19-22
2.3.1 USB descriptor 20
2.3.2 standard USB device request command 20-21
2.3.3 Universal USB firmware process 21-22
2.4 USB device class 22-23
2.4.1 Device Class Overview 22
2.4.2 Mass Storage Device Class Bulk-Only class transport protocol 22-23
2.4.3 Mass Storage subclass command 23
2.5 USB host 23-24
2.6 Summary 24-25
3 the initiative driven the overall design of the USB interface program 25-29
3.1 ways and programs active USB interface 25-28
3.1.1 using common interface / bus-USB converter 25
3.1.2 system on a chip using a dedicated USB transceiver 25
3.1.3 direct use MCU to achieve 25-26
3.1.4 the active USB interface hardware overall structure 26-27
the 3.1.5 USB main control chip select 27-28
3.2 the follower USB interface Way and programs 28
3.3 Summary 28-29
4 initiative driven USB interface hardware to achieve 29-37
4.1 the active USB interface hardware design 29-34
4.1.1 W78E54B type microcontroller 30
4.1.2 W78E54B SL811HS communication interface design 30-31
4.1.3 power conversion circuits AS1117 31
4.1.4 external data memory 62256 and 8D latch 74HC573 31-32
4.1.5 level converter the MAX232 and system clock 32
4.1.6 USB master / slave controller chip SL811HS 32-34
4.1.7 active USB port design 34
4.2 the follower USB interface hardware design 34-35
4.2.1 SL811HS driven USB interface design 34-35
4.2.2 follower USB port design 35
4.3 and initiative driven USB interface hardware debugging 35-36
4.4 Summary 36-37
5 the active USB interface software design 37-53
5.1 Active USB interface software designed to simplify 40-41
5.2 SL811HS initialization and driver design 41-42
5.3 USB host protocol stack software design 42-45
5.3.1 USB settings, input and output processing services 42-44
5.3.2 USB data transfer mode 44-45
5.3.3 implements the standard USB request command 45
5.3.4 enumerate devices and get descriptor 45
5.4 Mass Storage Class protocol programming 45-46
the
the 5.5 embedded file system created 46-48
5.6 Active USB interface software debugging and testing of file system 48-51
5.7 Summary 51-53
6 the follower USB interface software design 53-68
6.1 the follower USB interface software structure Overview 53-54
6.2 USB device-side firmware 54-57
6.3 PC-side driver 57-62
6.3.1 Windows operating system, device drivers way 57-58
6.3.2 USB device driver system 58-59
6.3.3 device driver program development tools 59-60
6.3.4 with DriverStudio development of device drivers 60-62
6.4 PC-side user application 62-65
6.4.1 device application program and WDM communication 62-64
the 6.4.2 user application program development 64-65
6.5 the follower USB interface software debugging and functional testing 65-66
6.6 Summary 66-68
7 Conclusion 68-70
the
References 70-72
the
Appendix A list of procedures 72-82
the
Appendix B machine circuit diagram 82-83
learn research 83-84
Acknowledgements 84
Related dissertations
- The Foam Insulation Greenhouse Monitoring System Design
- Research of a System Integrated Rotational Speed and Temperature Measurement Based on MCU
- The Wireless Temperature and Humidity Monitoring System Design
- The Design for Wireless Multiple Measuring System of Small Area Crop Growth Environment
- Development of Intelligent Control System for Precise Wheat Seeder with Suction and Stepless Speed Regulation
- The Design of PCR Temperature Control System in STC
- Design of Temperature and Humidity Control System Based on Micro-controller
- The Design and Implementation of Automatic Nail System for Greenhouses Heat Preservation Quilt
- Research and Design of Transfer Robot Using Competition
- The Design of Kerosene Vapor Concentration Detector
- Study of CPS Communication Based on MCU and Intelligent Optimization Algorithms
- Research on System of Digital Image Proccessing and Recognition of Instruments
- Application Research of Wireless Anti-theft System Based on GSM/GPRS
- The design and Realization of DDS technology of high precision signal source based on
- On the Design of Digital Synthesizer Based on Phase-Locked Loop
- Design and Implementation of a MCS-51-instruction-set-compatible High Speed MCU
- Design and Realize the JTAG Debugging Module on MCU
- Development of Control System for Medical Multi-leaf Collimator
- Measurment System Design and Experimental Study on the Thermo-physical Parameters of Blood Vessel
- Design and Simulation of Refrigeration and Oxygenation Control System for Live Fish Transportation