From: toannt <toa...@gm...> - 2013-06-13 07:41:15
|
Hi all, I'm writing a sample application to simulate USB Transfers to USB Mini Pocket Airpen. I'm using the URBs capturing by USBLyzer application and libusb 1.0.9. My problem is that: All URBs are simulated successfully except for 1 Control Transfer URB as below: The result of USBLyzer on Windows: /Sent package: USBPDO-1 - usbehci: Request: get descriptor from endpoint. (code 0x24 on Windows). Request Details: report. I/O: in. URB details: Reserved 1: 0000h. Index: 00h. Descriptor type: 22h. LanguageId: 0001h. Reserved 2: 0000h. Length: 64h. Respond package: Usbehci - USBPDO-1: URB details: Setup package: bmRequestType: 82h bRequest: 06h. wValue: 2200h. wIndex: 0001h. wLength: 0064h. return actual length: 24h./ I've tried libusb_control_transfer(mHdlDevice, 0x82, 0x06, 0x2200, 0x0001, testbuff, 0x64, 0); The result is -1 and errno: 2. please anyone help me to correct my control transfer params in this case. Thought that bmRequestType x82 and mRequest x06 is not match to standard CTRL Request. below is information of the USB Device: /Bus 001 Device 004: ID 0e20:0101 Pegasus Technologies Ltd. NoteTaker Device Descriptor: bLength 18 bDescriptorType 1 bcdUSB 1.10 bDeviceClass 0 (Defined at Interface level) bDeviceSubClass 0 bDeviceProtocol 0 bMaxPacketSize0 8 idVendor 0x0e20 Pegasus Technologies Ltd. idProduct 0x0101 NoteTaker bcdDevice 3.03 iManufacturer 1 Pegasus Technologies Ltd. iProduct 2 EN202 Ver 3.02 iSerial 3 0003-0003 bNumConfigurations 1 Configuration Descriptor: bLength 9 bDescriptorType 2 wTotalLength 59 bNumInterfaces 2 bConfigurationValue 1 iConfiguration 0 bmAttributes 0xa0 (Bus Powered) Remote Wakeup MaxPower 100mA Interface Descriptor: bLength 9 bDescriptorType 4 bInterfaceNumber 0 bAlternateSetting 0 bNumEndpoints 1 bInterfaceClass 3 Human Interface Device bInterfaceSubClass 0 No Subclass bInterfaceProtocol 0 None iInterface 0 Endpoint Descriptor: bLength 7 bDescriptorType 5 bEndpointAddress 0x81 EP 1 IN bmAttributes 3 Transfer Type Interrupt Synch Type None Usage Type Data wMaxPacketSize 0x0040 1x 64 bytes bInterval 1 DEVICE CLASS: 09 21 10 01 00 01 22 24 00 Interface Descriptor: bLength 9 bDescriptorType 4 bInterfaceNumber 1 bAlternateSetting 0 bNumEndpoints 1 bInterfaceClass 3 Human Interface Device bInterfaceSubClass 0 No Subclass bInterfaceProtocol 0 None iInterface 0 Endpoint Descriptor: bLength 7 bDescriptorType 5 bEndpointAddress 0x82 EP 2 IN bmAttributes 3 Transfer Type Interrupt Synch Type None Usage Type Data wMaxPacketSize 0x0008 1x 8 bytes bInterval 1 DEVICE CLASS: 09 21 10 01 00 01 22 9d 00 Device Status: 0x0002 (Bus Powered) Remote Wakeup Enabled/ -- View this message in context: http://libusb.6.n5.nabble.com/My-problem-with-URB-FUNCTION-GET-DESCRIPTOR-FROM-ENDPOINT-tp5712051.html Sent from the LibUSB Dev mailing list archive at Nabble.com. |