From: Roger B. <ro...@ro...> - 2003-12-10 05:54:01
|
>> usb_set_debug: Setting debugging level to 255 (on) >> usb_os_find_busses: Found 003 >> usb_os_find_busses: Found 003 >> usb_os_find_busses: Found 003 >> usb_os_find_busses: Found 002 >> usb_os_find_devices: Found 001 on 003 >> usb_os_find_devices: Found 002 on 003 >> usb_os_find_devices: Found 001 on 003 >> usb_os_find_devices: Found 001 on 003 That is all normal. >> usb_os_open: 05ac:8005 >> USB error: could not open device That isn't. My complete output on Linux is at the bottom. However looking at the code, I only need to open the device to get vendor and product strings (not the same as the integer ids) and to actually open the bulk interfaces later on. I will look into making that change in the code, although it won't do any good for you anyway. > usb_os_open: 1004:6000 > USB error: usb_os_open: Another process already has exclusive access to > the device. That is your phone. The libusb api has you claiming the interfaces seperately from the device as a whole. On Linux you can't claim an interface if there is a device driver attached, but the acm driver only attaches to interface 0 & 1 (interrupt and data for the modem) and leaves the diagnostics interface (2) seperate. I don't know how you get around it. Some places you should look at are projects on SourceForge for scanners and digital cameras. They usually use libusb on Linux, Windows and Mac. Here is my complete output: rb.com rogerb /space/bitpim/native/usb > python usb.py usb_set_debug: Setting debugging level to 255 (on) usb_os_init: Found USB VFS at /proc/bus/usb usb_find_busses: Skipping non bus directory devices usb_find_busses: Skipping non bus directory drivers usb_find_busses: Found 002 usb_find_busses: Found 001 usb_find_devices_on_bus: Found 001 on 001 usb_find_devices_on_bus: Found 002 on 001 usb_find_devices_on_bus: Found 003 on 001 usb_find_devices_on_bus: Found 010 on 001 skipped 4 class/vendor specific interface descriptors usb_find_devices_on_bus: Found 001 on 002 0 busses, 0 devices 001 0/0 001 class USB_CLASS_HUB subclass 0 protocol 0 interface number 0 class USB_CLASS_HUB subclass 0 protocol 0 endpointaddress 0x1 TYPE_INTERRUPT 451/2046 002 class USB_CLASS_HUB subclass 0 protocol 0 interface number 0 class USB_CLASS_HUB subclass 0 protocol 0 endpointaddress 0x1 TYPE_INTERRUPT 4b8/5 003 class USB_CLASS_PER_INTERFACE subclass 0 protocol 0 interface number 0 class USB_CLASS_PRINTER subclass 1 protocol 2 endpointaddress 0x1 TYPE_BULK OUT endpointaddress 0x2 TYPE_BULK IN 1004/6000 010 class USB_CLASS_COMM subclass 0 protocol 0 interface number 0 class USB_CLASS_COMM subclass 2 protocol 1 endpointaddress 0x1 TYPE_INTERRUPT interface number 1 class USB_CLASS_DATA subclass 0 protocol 0 endpointaddress 0xa TYPE_BULK IN endpointaddress 0xb TYPE_BULK OUT interface number 2 class USB_CLASS_VENDOR_SPEC subclass 255 protocol 0 endpointaddress 0x3 TYPE_BULK IN endpointaddress 0x6 TYPE_BULK OUT 002 0/0 001 class USB_CLASS_HUB subclass 0 protocol 0 interface number 0 class USB_CLASS_HUB subclass 0 protocol 0 endpointaddress 0x1 TYPE_INTERRUPT Roger |