关于主题,本站前辈有详细的论述,我在照搬代码的时候遇到了一些问题,数据发送不成功。
原贴如下:
本usb设备的配置如下(usbview.exe查看):
Root Hub: USB#ROOT_HUB#4&2f122cdf&0#{f18a0e88-c30c-11d0-8815-00a0c906bed8}
Hub Power: Self Power
Number of Ports: 2
Power switching: None
Compound device: No
No Over-current Protection (Bus Power Only)
Device Descriptor:
bcdUSB: 0x0110
bDeviceClass: 0x00
bDeviceSubClass: 0x00
bDeviceProtocol: 0x00
bMaxPacketSize0: 0x40 (64)
idVendor: 0x10C4
idProduct: 0xEA60
bcdDevice: 0x0100
iManufacturer: 0x01
iProduct: 0x02
iSerialNumber: 0x03
bNumConfigurations: 0x01
ConnectionStatus: DeviceConnected
Current Config Value: 0x01
Device Bus Speed: Full
Device Address: 0x05
Open Pipes: 2
Endpoint Descriptor:
bEndpointAddress: 0x03
Transfer Type: Bulk
wMaxPacketSize: 0x0040 (64)
bInterval: 0x00
Endpoint Descriptor:
bEndpointAddress: 0x00
Transfer Type: Control
wMaxPacketSize: 0x0507 (1287)
wInterval: 0x0283
bSyncAddress: 0x40
按照上面的配置,HANDLE hPipe = OpenMyDevPipe("MyPipe1");“MyPipe1”管道名应该用什么来代替呢,
我试过以下数据,"0x03""03""pipe03",结果writefile()都不成功
--------------------next---------------------
阅读(1097) | 评论(0) | 转发(0) |