1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

Bluetooth HID proxy to HCI mode switching (ubthidctl?)

Discussion in 'Mobile Computing' started by hlg, Jan 3, 2010.

  1. hlg

    hlg New Member

    Thanks Received:
    User: very unadvanced newbie (for clarity's sake: myself).
    Machine: advanced, a Dell Precision M6400 with an integrated multi-function Broadcom BCM2046B1 chipset.
    I recompiled the kernel without the uhid(4), the ukbd(4) and the ums(4) modules.

    Now, booting and then issuing the following sequence of commands:

    # kldload uhid
    # kldload ukbd
    # kldload ums
    # kldload ng_ubt

    and finally turning the WiFi+Bluetooth hardware switch on generates the following in /var/log/messages:

    Jan  2 03:21:48  kernel: uhub8: <Broadcom BCM2046B1, class 9/0, rev 2.00/1.00, addr 2> on usbus0
    Jan  2 03:21:48  kernel: uhub8: 3 ports with 0 removable, self powered
    Jan  2 03:21:49  kernel: ugen0.3: <vendor 0x413c> at usbus0
    Jan  2 03:21:49  kernel: ukbd0: <vendor 0x413c product 0x8157, class 0/0, rev 2.00/1.00, addr 3> on usbus0
    Jan  2 03:21:49  kernel: kbd2 at ukbd0
    Jan  2 03:21:49  kernel: ugen0.4: <vendor 0x413c> at usbus0
    Jan  2 03:21:49  kernel: ums0: <vendor 0x413c product 0x8158, class 0/0, rev 2.00/1.00, addr 4> on usbus0
    Jan  2 03:21:49  kernel: ums0: 3 buttons and [XY] coordinates ID=2

    even though I have neither a USB keyboard nor a USB mouse connected to the system.
    This page: http://wiki.freebsd.org/AppleMacbook contains a link to an article explaining the above phenomenon (http://times.usefulinc.com/2004/06/12-hidproxy), and also another link (http://svn.freebsd.org/viewvc/base/user/rpaulo/ubthidctl/) to the source code of a utility meant to solve the issue. Unfortunately, the latter source code is somewhat outdated. By modifying its # include directives, I managed to get it to compile, but it still doesn't do what it should -- doesn't do much at all, as a matter of fact.
    Can anyone with better skills than mine please help me out?

    +Extra question: I'm too stupid and ignorant to see any probable reason for which anyone would wish to configure their BIOS using a Bluetooth keyboard or a Bluetooth mouse. Could someone give me a likely case scenario?

    Off-topic footnote: Thanks to bschmidt, the WiFi works flawlessly. I would just like to express my gratitude yet again.
  2. tingo

    tingo Active Member

    Thanks Received:
    Some Bluetooth chipsets / gadgets whatever in laptops are connected to the machine via usb internally, that explains the usb messages.
  3. hlg

    hlg New Member

    Thanks Received:
    It's not the internal USB connection that I have a problem with, but the fact that the Bluetooth chip pretends to be a USB keyboard + mouse combo (known as "HID proxy mode"), and I can't tell it to stop pretending (switch it to "HCI mode" by sending the relevant instruction directly). The gist the article mentioned in my original post is that HID proxy mode makes it possible to use Bluetooth keyboards/mice to configure the BIOS. Sadly, it also prevents FreeBSD from identifying the Bluetooth chip properly and pairing it up with anything _other than_ a keyboard or a mouse. As far as I have understood, there are external Bluetooth dongles with the same feature.
  4. SnuRRe

    SnuRRe New Member

    Thanks Received:

    Old thread.. but exactly my problem. Does anyone have any solution for the HID/HCI-problem? My Bluetooth is the exact same module, Broadcom BCM2046B1, and it's recognized as a HID-device. Does this ubthidctl tool or anything simular exist for i.e. FreeBSD 8?