Return-Path: <Olivier.Bornet@puck.ch>
Received: from mail.axiom.ch [213.221.158.30]
	by localhost with IMAP (fetchmail-6.1.0)
	for bol@localhost (single-drop); Tue, 28 Oct 2003 09:28:42 +0100 (CET)
Received: from obelix.spectraweb.ch (mailrelay03.sunrise.ch [194.158.229.31])
	by pop.axiomail.ch (8.11.6/8.11.6) with ESMTP id h9S8ROa28771
	for <olivier.bornet@smartdata.ch>; Tue, 28 Oct 2003 09:27:25 +0100
Received: from delta (adsl-62-167-40-36.adslplus.ch [62.167.40.36])
	by obelix.spectraweb.ch (8.12.9/8.12.6) with ESMTP id h9S8RXwZ024825
	for <olivier.bornet@smartdata.ch>; Tue, 28 Oct 2003 09:27:33 +0100
Received: from bol by delta with local (Exim 3.36 #1 (Debian))
	id 1AEPBy-0003Vz-00
	for <olivier.bornet@smartdata.ch>; Tue, 28 Oct 2003 09:27:06 +0100
Resent-From: Olivier.Bornet@puck.ch
Resent-Date: Tue, 28 Oct 2003 09:27:06 +0100
Resent-Message-ID: <20031028082706.GB27228@puck.ch>
Resent-To: olivier.bornet@smartdata.ch
Received: from puck.ch [153.109.180.3]
	by localhost with IMAP (fetchmail-5.9.11)
	for bol@localhost (single-drop); Mon, 13 Oct 2003 01:29:02 +0200 (CEST)
Received: from duba04h04-0.dplanet.ch ([212.35.36.38])
	by puck.ch with esmtp (Exim 3.36 #1)
	id 1A8pe3-0003tZ-00
	for Olivier.Bornet@puck.ch; Mon, 13 Oct 2003 01:29:03 +0200
Received: from delta (adsl-62-167-97-142.adslplus.ch [62.167.97.142])
	by duba04h04-0.dplanet.ch (8.12.10/8.12.10/2.00dplanet-smtp) with ESMTP id h9CNSuCq029282;
	Mon, 13 Oct 2003 01:28:57 +0200
Received: from bol by delta with local (Exim 3.36 #1 (Debian))
	id 1A8pcx-00062N-00; Mon, 13 Oct 2003 01:27:55 +0200
Date: Mon, 13 Oct 2003 01:27:55 +0200
To: Peter Klausler <peter@klausler.com>
Cc: Olivier Bornet <Olivier.Bornet@puck.ch>
Subject: bthid 0.6 with logitech keyboard/mouse
Message-ID: <20031012232755.GA21217@puck.ch>
Mime-Version: 1.0
Content-Type: multipart/signed; micalg=pgp-sha1;
	protocol="application/pgp-signature"; boundary="UlVJffcvxoiEqYs2"
Content-Disposition: inline
X-From: Olivier Bornet <Olivier.Bornet@puck.ch>
X-Url: http://puck.ch/
User-Agent: Mutt/1.5.4i
From: Olivier Bornet <Olivier.Bornet@puck.ch>
X-Virus-Scan: Scanned by TrashScan v0.09 running on delta
X-Spam-Status: No, hits=-3.7 required=5.0
	tests=NO_EXPERIENCE,PGP_SIGNATURE_2,RESENT_TO,USER_AGENT_MUTT
	version=2.55
X-Spam-Level: 
X-Spam-Checker-Version: SpamAssassin 2.55 (1.174.2.19-2003-05-19-exp)


--UlVJffcvxoiEqYs2
Content-Type: text/plain; charset=iso-8859-1
Content-Disposition: inline
Content-Transfer-Encoding: quoted-printable

Hi Peter,

first, thanks for your bthid software. I'm trying to use it with a
Logitech bluetooth keyboard. (see http://www.logitech.com/bluetooth for
more information on it). but don't search it on the market at this
time, it is not available now. I have one sample because we work with
Logitech on it.

I have try to use bthid-0.6 today with my Debian 2.4.21-mh2 system.
Connecting the keyboard/mouse is sometime ok, sometime not. But this is
not a problem at this time, and I will search the reason why the
connection is not always ok later.

The first "major" problem I was having is with the button 1 of the
mouse. It doesn't work. I see the bluetooth packets, but nothing in X. I
have do some debuging, and all is ok now. :-) The problem was with the
number of buttons of the Logitech mouse : 8 buttons:
- 1: left
- 2: right
- 3: middle
- 4: side 1 (SIDE)
- 5: side 2 (EXTRA)
- 6: top (don't know the function, maybe "new window")
- 7: forward
- 8: backward
and the wheel.

Your code was mapping unknown button (in this case top, forward and
backward) to "primary" button left. And, as when I use the mouse all the
"buttons events" are sent to bthid whith theyre state, the buttons 6, 7
and 8 cleared the 1, event if the 1 is setted.

The attached patch correct this. Note I'm not sure this will be
necessary with the public product, as mine are alpha release product
with alpha firmeware. But if the mouse send all the buttons when one has
is state changed, this patch is necessary.

Another problem I have is the key < and > are not working. The layout of
my keyboard is fr_CH (Swiss French), and the key with < and > is on the
bottom line. Here is the bottom line:

lowercase:
SHIFT < y x c v b n m , . - SHIFT
uppercase:
SHIFT > Y X C V B N M ; : _ SHIFT

The key with the  < and > has also the \ with the Alt Gr mode.

Here is the hcidump when I press and release the < key:

> ACL data: handle 0x002e flags 0x02 dlen 14
    L2CAP(d): cid 0x41 len 10 [psm 19]
      A1 01 00 00 64 00 00 00 00 00=20
> ACL data: handle 0x002e flags 0x02 dlen 14
    L2CAP(d): cid 0x41 len 10 [psm 19]
      A1 01 00 00 00 00 00 00 00 00=20

I suspect I must put something in the array hid_to_linux[], position
0x64, but I don't have search what to put at this time. (maybe next
patch ;-), but another day: I must go to sleep now. )

Other normal keys seems to work ok.

Last point. I will be happy if I can try to use the "hotkeys". I have
see this must be supported, but I don't known how. I have installed the
hotkeys package, but as I have no experience with hotkeys, I don't know
how to use it. I have try to start with:
hotkeys --type=3Dlogitech-cfo --osd=3Don -b --loglevel=3D7
but I see only the splash screen, and nothing else. The keys are routed
on the bluetooth layer, here is the hcidump -x of the "home" key:

> ACL data: handle 0x002e flags 0x02 dlen 10
    L2CAP(d): cid 0x41 len 6 [psm 19]
      A1 03 23 02 00 00=20
> ACL data: handle 0x002e flags 0x02 dlen 10
    L2CAP(d): cid 0x41 len 6 [psm 19]
      A1 03 00 00 00 00=20

Can you help me with this feature ?

Thanks in advance for your help. And thanks for bthid.

		Olivier
--=20
Olivier Bornet                 |      fran=E7ais : http://puck.ch/f
Swiss Ice Hockey Results       |      english  : http://puck.ch/e
http://puck.ch/                |      deutsch  : http://puck.ch/g
Olivier.Bornet@puck.ch         |      italiano : http://puck.ch/i
Get my PGP-key at http://puck.ch/pgp or at http://wwwkeys.pgp.net

--UlVJffcvxoiEqYs2
Content-Type: application/pgp-signature
Content-Disposition: inline

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.1 (GNU/Linux)

iD8DBQE/ieN6dj3R/MU9khgRArcmAKDjmBwcpQm1oz+ekrFe5gxr8LAstgCfRLOd
2FOSXS3LWKO8ovqjOjtgdwc=
=+RbS
-----END PGP SIGNATURE-----

--UlVJffcvxoiEqYs2--

