usb_ddk_interface.h
- |
-int32_t UsbInitHostSdk(struct UsbSession **session);
- |
-Initializes the USB host driver DDK.
- |
-
-int32_t UsbExitHostSdk(const struct UsbSession *session);
- |
-Exits the USB host driver DDK.
- |
-
-const struct UsbInterface *UsbClaimInterface(const struct UsbSession *session, uint8_t busNum, uint8_t usbAddr, uint8_t interfaceIndex);
- |
-Obtains a USB interface.
- |
-
-int UsbReleaseInterface(const struct UsbInterface *interfaceObj);
- |
-Releases a USB interface.
- |
-
-int UsbAddOrRemoveInterface(const struct UsbSession *session, uint8_t busNum, uint8_t usbAddr, uint8_t interfaceIndex, UsbInterfaceStatus status);
- |
-Adds or removes a USB interface.
- |
-
-UsbInterfaceHandle *UsbOpenInterface(const struct UsbInterface *interfaceObj);
- |
-Opens a USB interface.
- |
-
-int32_t UsbCloseInterface(const UsbInterfaceHandle *interfaceHandle);
- |
-Closes a USB interface.
- |
-
-int32_t UsbSelectInterfaceSetting(const UsbInterfaceHandle *interfaceHandle, uint8_t settingIndex, struct UsbInterface **interfaceObj);
- |
-Sets a USB interface.
- |
-
-int32_t UsbGetPipeInfo(const UsbInterfaceHandle *interfaceHandle, uint8_t settingIndex, uint8_t pipeId, struct UsbPipeInfo *pipeInfo);
- |
-Obtains USB pipe information.
- |
-
-int32_t UsbClearInterfaceHalt(const UsbInterfaceHandle *interfaceHandle, uint8_t pipeAddress);
- |
-Clears the state of the pipe with the specified index.
- |
-
-struct UsbRequest *UsbAllocRequest(const UsbInterfaceHandle *interfaceHandle, int isoPackets, int length);
- |
-Allocates a request object.
- |
-
-int UsbFreeRequest(const struct UsbRequest *request);
- |
-Releases a request object.
- |
-
-int UsbSubmitRequestAsync(const struct UsbRequest *request);
- |
-Sends an asynchronous request.
- |
-
-int32_t UsbFillRequest(const struct UsbRequest *request, const UsbInterfaceHandle *interfaceHandle, const struct UsbRequestParams *params);
- |
-Fills in a request.
- |
-
-sint UsbCancelRequest(const struct UsbRequest *request);
- |
-Cancels an asynchronous request.
- |
-
-int UsbSubmitRequestSync(const struct UsbRequest *request);
- |
-Sends a synchronous request.
- |
-
-usb_raw_api.h
- |
-int UsbRawInit(struct UsbSession **session);
- |
-Initializes the USB raw APIs.
- |
-
-int UsbRawExit(const struct UsbSession *session);
- |
-Exits the USB raw APIs.
- |
-
-UsbRawHandle *UsbRawOpenDevice(const struct UsbSession *session, uint8_t busNum, uint8_t usbAddr);
- |
-Opens a USB device.
- |
-
-int UsbRawCloseDevice(const UsbRawHandle *devHandle);
- |
-Closes a USB device.
- |
-
-int UsbRawSendControlRequest(const struct UsbRawRequest *request, const UsbRawHandle *devHandle, const struct UsbControlRequestData *requestData);
- |
-Performs a control transfer synchronously.
- |
-
-int UsbRawSendBulkRequest(const struct UsbRawRequest *request, const UsbRawHandle *devHandle, const struct UsbRequestData *requestData);
- |
-Performs a bulk transfer synchronously.
- |
-
-int UsbRawSendInterruptRequest(const struct UsbRawRequest *request, const UsbRawHandle *devHandle, const struct UsbRequestData *requestData);
- |
-Performs an interrupt transfer synchronously.
- |
-
-int UsbRawGetConfigDescriptor(const UsbRawDevice *rawDev, uint8_t configIndex, struct UsbRawConfigDescriptor **config);
- |
-Obtains the configuration descriptor of a device.
- |
-
-void UsbRawFreeConfigDescriptor(const struct UsbRawConfigDescriptor *config);
- |
-Releases the memory space of a configuration descriptor.
- |
-
-int UsbRawGetConfiguration(const UsbRawHandle *devHandle, int *config);
- |
-Obtains the configuration in use.
- |
-
-int UsbRawSetConfiguration(const UsbRawHandle *devHandle, int config);
- |
-Sets the configuration in use.
- |
-
-int UsbRawGetDescriptor(const struct UsbRawRequest *request, const UsbRawHandle *devHandle, const struct UsbRawDescriptorParam *param, const unsigned char *data);
- |
-Obtains descriptor information.
- |
-
-UsbRawDevice *UsbRawGetDevice(const UsbRawHandle *devHandle);
- |
-Obtains the device pointer based on the device handle.
- |
-
-int UsbRawGetDeviceDescriptor(const UsbRawDevice *rawDev, struct UsbDeviceDescriptor *desc);
- |
-Obtains the device descriptor of the specified USB device.
- |
-
-int UsbRawClaimInterface(const UsbRawHandle *devHandle, int interfaceNumber);
- |
-Declares the interface on the specified device handle.
- |
-
-int UsbRawReleaseInterface(const UsbRawHandle *devHandle, int interfaceNumber);
- |
-Releases the previously declared interface.
- |
-
-int UsbRawResetDevice(const UsbRawHandle *devHandle);
- |
-Resets a device.
- |
-
-struct UsbRawRequest *UsbRawAllocRequest(const UsbRawHandle *devHandle, int isoPackets, int length);
- |
-Allocates a transfer request with the specified number of sync packet descriptors.
- |
-
-int UsbRawFreeRequest(const struct UsbRawRequest *request);
- |
-Releases the previously allocated transfer request.
- |
-
-int UsbRawFillBulkRequest(const struct UsbRawRequest *request, const UsbRawHandle *devHandle, const struct UsbRawFillRequestData *fillData);
- |
-Fills in a bulk transfer request.
- |
-
-int UsbRawFillControlSetup(const unsigned char *setup, const struct UsbControlRequestData *requestData);
- |
-Fills in a control setup packet.
- |
-
-int UsbRawFillControlRequest(const struct UsbRawRequest *request, const UsbRawHandle *devHandle, const struct UsbRawFillRequestData *fillData);
- |
-Fills in a control transfer request.
- |
-
-int UsbRawFillInterruptRequest(const struct UsbRawRequest *request, const UsbRawHandle *devHandle, const struct UsbRawFillRequestData *fillData);
- |
-Fills in an interrupt transfer request.
- |
-
-int UsbRawFillIsoRequest(const struct UsbRawRequest *request, const UsbRawHandle *devHandle, const struct UsbRawFillRequestData *fillData);
- |
-Fills in an isochronous transfer request.
- |
-
-int UsbRawSubmitRequest(const struct UsbRawRequest *request);
- |
-Submits a transfer request.
- |
-
-int UsbRawCancelRequest(const struct UsbRawRequest *request);
- |
-Cancels a transfer request.
- |
-
-int UsbRawHandleRequests(const UsbRawHandle *devHandle);
- |
-Handles a transfer request event.
- |
-
-
-