Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 25 Nov 2003 10:53:29 +0100
From:      Toni Andjelkovic <toni@soth.at>
To:        Dan Langille <dan@langille.org>
Cc:        hackers@freebsd.org
Subject:   Re: using devel/libusb to access USB
Message-ID:  <20031125095329.GB1975@acme.soth.at>
In-Reply-To: <3FC1CEA0.28542.14DD8CEF@localhost>
References:  <3FC1CEA0.28542.14DD8CEF@localhost>

next in thread | previous in thread | raw e-mail | index | archive | help
On Mon, Nov 24 2003 (09:25:52 -0500), Dan Langille wrote:
> We have been looking at the devel/libusb port and experimenting with 
> testlibusb which is a part of that port.  We have noticed that 
> usb_find_devices() does not find any devices.  Looking at the usb.c 
> code within libusb, we found that usb_os_find_devices() does not 
> return any devices, and therefore the while loop is never entered.
> 
> We tracked the problem down to usb_os_find_devices() (within bsd.c) 
> and found that various things were preventing the list from being 
> created.

I have experienced a similar problem a few months ago. I've tracked
it to ugenopen() in sys/dev/usb/ugen.c, which returned EBUSY if
the control endpoint /dev/ugen0 was already open. Consequently,
usb_find_devices() failed to return anything useful.

However, as Bernd Walter suggested in a recent posting to hackers@,
this could be avoided by using interface specific endpoints (/dev/ugen?.?)
instead of the control endpoint (/dev/ugen?) for communication.

Cheers,
Toni



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20031125095329.GB1975>