I had been having issues with erratic loss of connection to a USB accessory. The log showed "could not open /dev/usb_accessory". Extensive troubleshooting revealed that adb was interfering with the USB connection and invalidating the filedescriptor for the accessory.
On Tuesday, January 15, 2013 9:36:45 AM UTC-6, Andy Doan wrote:
I'm sending this email to gauge interest in a proposed change to host-side ADB:
I'm currently using ADB in conjunction with a USB mass storage device that must be powered on/off repeatedly via the /sys interface on I Linux[1]. This was working correctly until I recently added ADB into the workflow. The problem I now see is that this sequence won't work:
power off device run set of adb commands (that cause the daemon to run in background) power on device
It seems the probing of my devices entry under /dev/bus/usb is causing it to enter a weird state. The only way I've gotten it out of that state is to run "adb kill-server" and then physically unplug/plug the device.
My proposed solution (attached) gives you two options:
- ignore USB devices entirely
- black list certain devices
I would like to see this patch make it to AOSP in some form, but I'm not sure if my use-case is too specific for you guys. Any interest?