USB host system firmware to write more complicated, mainly related to the transmission of USB controller, USB bulk transfer, mass storage class protocol, the UFI disk operations command and FAT file system to write all the bottom of the program operation, there is no ready-made libraries support, so the structure of the program overall framework and protocol-specific data structure of the organization is critical. The module design of the main difficulty lies in the preparation of the software program, the agreement involved in the preparation of the program should pay attention to the idea of modular, each specific agreement as far as possible to write in a source file, data structures, constants, variables well defined in the header file for each module. Here will introduce the usage of green laser pointer .
The debugging USB underlying control transfer can take full advantage of Bus Hound tool to grab the USB removable storage into the computer communicate with the computer data analysis, comparison and reference development, deepen the understanding of the USB low-level information exchange. Any USB device connected to the USB host must go through the enumeration of the USB host configured to properly use. USB bus enumeration steps and methods are the same for all USB devices must comply with the standard USB protocol process, control the transmission of "a question and answer" to the necessary number of master and slave data exchange : Get the device descriptor, assign the device address and configure the device. green laser pointer has been used for the first time.
Image point to talk about the USB host enumeration process is: first get a device property, equipment returns a value of 18 (the value of the firmware is the maximum length of the packet endpoint), then the device is assigned an operating address, the address range can be based on actual conditions may be, and configure the device, and finally enumeration of device endpoints, access to every endpoint device number (address). The real purpose is to obtain the endpoint address of the device enumeration, is sufficient to send and receive packets. Keil Software is developed microcontroller compiler in Keil, Germany, is one of the best 51 microcontroller development tools can be used to compile the C source code and assembly source, connect, and relocatable object files and libraries, create HEX file, debug target program is an integrated document management build environment. It is the laser remote control of the emitters of green laser pointer .
Proteus and Keil programming software the FBI, thus achieving the validation of the designed circuit. (1) the Keil? Vision of the source design and build just use the Keil user can generally follow the steps below to create an application: a project file to create a source file and enter the code sequence file is added to the project. Select the target device to set up the hardware and software debugging environment for the source process to save the source project file to create 17 (2) establish specific application and operating a simulation debugging. The establishment of a project to double-click the desktop shortcut icon to enter is shown in Figure 6-7 integrated development environment for editing user interface. When green laser pointer are produced.
Consists of three main windows: the project window, edit window and output window. Click the Project menu, select "New Project" option in the drop-down menu in the pop-up a new project, shown in Figure 1 below: Figure 4.1 and then select the path you want to save, enter the name of the project file, and then click Save "button. A pop-up dialog box, and asked to select the MCU models. Here can be used by the microcontroller, Keil supports almost all 51-core microcontroller, Atmel's 89C51 instructions under Figure 2: Figure 4.2 First Atmel Corporation, and then click the left "+" sign to select AT89C51. laser pointer can directly control the turning over of the documents remotely.
No comments:
Post a Comment