USB HOST DRIVER V03 Freescale Semiconductor / Motorola, USB HOST DRIVER V03 Datasheet - Page 18

no-image

USB HOST DRIVER V03

Manufacturer Part Number
USB HOST DRIVER V03
Description
USB Host Driver v03
Manufacturer
Freescale Semiconductor / Motorola
Datasheet
InterfaceData, len, &len, NULL);
}
To close a connection handle on a particular Device object use
function, specifying the opened handle for the Device object in question.
See the Microsoft Platform SDK documentation for further information.
2.4.5.
The Device object represents a physical Device. It provides Default Control Pipe
transfers, pipe connections, and some system control (Power Management, PnP, etc.).
Some Win32 API functions should be used to interact with the MOTUSB Device object.
Function Name
CreateFile
CloseHandle
DeviceIoControl
All operations involving Device object handles can be requested through the
DeviceIoControl function, while CreateFile and CloseHandle functions are used for
Device object connections only. Note that no data flow operations via ReadFile and
WriteFile can be performed. All data transmission to the Default Control Pipe requires
DeviceIoControl usage.
The following tasks can be performed using MOTUSB Device object:
M
InterfaceData->cbSize = sizeof(SP_DEVICE_INTERFACE_DETAIL_DATA);
bOK = SetupDiGetDeviceInterfaceDetail(devList, &DevData,
if ( !bOK ) {
}
hDevice = CreateFile(
return ( hDevice );
Descriptor retrieval
Configuration control
Setting / Clear Feature for specified recipient
free( InterfaceData );
return INVALID_HANDLE_VALUE;
Device Object Functions.
Table 2.2 Win32 API operations list for a Device object.
InterfaceData->DevicePath,
GENERIC_READ | GENERIC_WRITE,
FILE_SHARE_WRITE | FILE_SHARE_READ, // share mode
NULL,
OPEN_EXISTING,
NULL,
NULL
);
PRELIMINARY—SUBJECT TO CHANGE WITHOUT NOTICE
Description
Opens handle to Device object
Close handle to Device object
Performs requests on Device object
Driver Model.
// access mode
// security desc.
// how to create
// template file
CloseHandle
// file attributes
Win32 API
2-7

Related parts for USB HOST DRIVER V03