Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 10 Jan 2008 07:57:58 +0800
From:      "Xiaofan Chen" <xiaofanc@gmail.com>
To:        "Hans Petter Selasky" <hselasky@c2i.net>
Cc:        johnjen@reynoldsnet.org, R.Tobin@ed.ac.uk, Mikhail Teterin <mi+kde@aldan.algebra.com>, usb@freebsd.org
Subject:   Re: BlackBerry (Re: using libusb)
Message-ID:  <a276da400801091557x3f044d96y80d74855487be4cc@mail.gmail.com>
In-Reply-To: <200801091934.54053.hselasky@c2i.net>
References:  <200801090114.56195@aldan> <200801091015.17730@aldan> <200801091934.54053.hselasky@c2i.net>

next in thread | previous in thread | raw e-mail | index | archive | help
On Jan 10, 2008 2:34 AM, Hans Petter Selasky <hselasky@c2i.net> wrote:
> On Wednesday 09 January 2008, Mikhail Teterin wrote:
> > We really need the low-level (ugen?) interfaces available for all
> > USB-devices -- even those, which are /also/ handled by higher-level
> > interfaces (like ulpt, uscan, umass). As things stand, the higher-level
> > ones are "greedy" and will prevent ugen from appearing, even if one wanted
> > to.
>
> Yes, you are completely right. And this is not very far away from happening.
> I've wanted to do this for a long time, but have found no time yet.
>
> My plan is to extend /dev/usbX so that it becomes a so-called clonable device.
> When you open up "/dev/usb0.2.3" for example, you open up the device having
> index 2 on USB bus 0 and endpoint 3. This will need some modifications in
> libusb. Ugen will still be there, but I plan to move the functionality over
> to "usb.c". Accessing endpoints will then work regardless of what drivers are
> hooked on.

I am a non-programmer (I only know a bit of C) and not a USB expert. But I
like libusb and use it with some USB devices. If you can get this done for
FreeBSD, it will be wonderful.

On the Linux libusb front, there are two new things going on. One is that
the new libusb maintainer will be Daniel Drake and he will use his fpusb
as the base for libusb 1.0 and get rid of the old 1.0 code. The 0.1 branch
may also get some fixes.
http://www.nabble.com/libusb-future-to14571903.html
http://reactivated.net/fprint/wiki/Fpusb

The other development is OpenUSB (under Solaris and Linux) mainly
sponsored by Sun.
http://openusb.sourceforge.net/wiki/index.php/Main_Page

So you might look into these two.

> Some open problems that needs to be resolved:
>
> Should we allow parallell access to USB interfaces?

Do you mean thread safe access and/or assynchronous I/O? You might want
to check out OpenUSB.

> And what about rights management?
>From what I know, it seems devfs rule works fine under FreeBSD.
http://mcuee.blogspot.com/2007/11/setting-up-permissions-for-usb-ports-to.html
(my blog post).

Under Linux, the old one is using hotplug, now udev rules or HAL.

Regards,
Xiaofan



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