From: Bastien Nocera <hadess@hadess.net>
To: BlueZ development <bluez-devel@lists.sourceforge.net>
Subject: Re: [Bluez-devel] HID initiated connections and input service
Date: Sat, 16 Jun 2007 17:35:15 +0100 [thread overview]
Message-ID: <1182011715.31424.346.camel@cookie.hadess.net> (raw)
In-Reply-To: <1181977540.6846.38.camel@aeonflux.inter-touch.com>
Hey Marcel,
On Sat, 2007-06-16 at 09:05 +0200, Marcel Holtmann wrote:
<snip>
> > * Second device: Sixaxis PS3 Bluetooth joypad
> >
> > Again, 2 connections modes. Firstly, there's no pairing, the joypad
> > knows about the computer when one runs sixpair when the pad is connected
> > via USB, as per:
> > http://www.pabr.org/sixlinux/sixlinux.en.html
> > (Marcel talked about integrating this with udev, which should be pretty
> > straight forward)
> >
> > Once disconnected from USB, and turned on, the device will try to
> > connect to the computer. bluetooth-applet will request auth, and ask us
> > whether we want to allow the connection. But as the device was never
> > discovered/setup using CreateDevice, the get_store_device_info in
> > input/server.c will fail.
> >
> > You can't use CreateDevice with the device, as it's either connecting to
> > our computer, or off, and connection requests will fail.
>
> The sixpair.c tool needs to do some nasty tricks. It hast to get its own
> Bluetooth address from the controller and then get its HID report
> descriptor over USB. Then store them in /var/lib/bluetooth and also set
> itself to trusted.
>
> We might wanna integrate that into the input service, but to be honest I
> currently don't know how. It also might make more sense to let a HAL
> addon handle this kind of authentication instead of at udev level.
What we could do is:
1) have a HAL addon that will set the device's bdaddr in a property of
the device when plugged into USB
2) have bluetooth-applet (or any other front-end) ask the user whether
to set the device as trusted when it's plugged in (can be switched off
with a config item)
3) Add a method to the input service (AddUSBDevice(string address,
string usbdev) that will get the USB HID report descriptor, and set the
device as trusted along with the rest of the info
I could work on that (it should be pretty straight-forward), except I
don't have any code to get the bdaddr from the device and I don't know
how to get the HID report descriptor from the device either. If you have
some code that does that, feel free to pass it on, I can do the
integration.
Cheers
--
Bastien Nocera <hadess@hadess.net>
-------------------------------------------------------------------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
_______________________________________________
Bluez-devel mailing list
Bluez-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/bluez-devel
next prev parent reply other threads:[~2007-06-16 16:35 UTC|newest]
Thread overview: 17+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-06-15 16:44 [Bluez-devel] HID initiated connections and input service Bastien Nocera
2007-06-16 7:05 ` Marcel Holtmann
2007-06-16 16:35 ` Bastien Nocera [this message]
2007-06-16 19:35 ` Marcel Holtmann
2007-06-17 20:25 ` Bastien Nocera
2007-06-18 13:06 ` Bastien Nocera
2007-06-18 14:00 ` Pascal
2007-06-18 14:36 ` Bastien Nocera
2007-06-18 16:00 ` Bastien Nocera
2007-06-18 17:30 ` Pascal
2007-06-18 19:23 ` Bastien Nocera
2007-06-18 20:16 ` Pascal
2007-06-18 22:40 ` Bastien Nocera
2007-06-16 7:25 ` Marcel Holtmann
2007-06-16 16:44 ` Bastien Nocera
2007-06-16 19:24 ` Marcel Holtmann
2007-06-18 16:08 ` Bastien Nocera
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1182011715.31424.346.camel@cookie.hadess.net \
--to=hadess@hadess.net \
--cc=bluez-devel@lists.sourceforge.net \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox