bluetooth working on 5.1-release

From: Kim Culhan <fbsd_current_at_kim.net>
Date: Sun, 17 Aug 2003 17:35:05 -0400 (EDT)
Greetings current-

Have bluetooth almost working on 5.1-release, thank you Max.

On Sun, 17 Aug 2003, Maksim Yevmenkin wrote:

> first of all - all kernel modules and user space tools were committed to
> -current. so you do not have to use snapshots. all kernel modules are
> connected to buildkernel process, so you should have all bluetooth
modules
> in /boot/kernel/modules. note: user space tools are not connected to the
> buildworld process, so you have to build them by hand, i.e.
>
> # cd /usr/src/usr.bin/bluetooth
> # make depend && make intall && make clean
>
> # cd /usr/src/usr.sbin/bluetooth
> # make depend && make intall && make clean

> example of rc.bluetooth script can be found in
>
> /usr/src/share/examples/netgraph/bluetooth

The device is a Belkin F8T001, at plugin it logs:

Aug 17 16:43:01 radio kernel: ubt0: Broadcom Corp. BCM2033, rev 1.01/0.a0,
addr 2
Aug 17 16:43:01 radio kernel: ubt0: Interface 0 endpoints: interrupt=0x81,
bulk-in=0x82, bulk-out=0x2
Aug 17 16:43:01 radio kernel: ubt0: Interface 1 (alt.config 4) endpoints:
isoc-in=0x83, isoc-out=0x3; wMaxPacketSize=64; nframes=5, buffer size=320

Procedure which works as follows:

> 1) make sure the USB device is detached
> 2) load ubtbcmfw(4) module
> 3) load ng_ubt(4) module
> 4) attach the device

It logs:

Aug 17 16:10:31 radio kernel: ubtbcmfw0: Broadcom product 0x2033, rev
1.01/0.a0, addr 2             ^^^^^^^^^

> 5) load Broadcom firmware with bcmfw(8) tools (in
> /usr/src/usr.sbin/bluetooth)
> (note: you need to get firmware off the internet - see man page)

Off the net:

http://bluez.sourceforge.net/download/bluez-bluefw-0.9.tar.gz

Then load the minidriver and firmware:

bcmfw -n ubtbcmfw0 -m /usr/local/bin/BCM2033-MD.hex -f [all one line..]
/usr/local/bin/BCM2033-FW.bin

> 6) verify that ubtbcmfw0: device was detached and ubt0: device was
> attached

It logs:

Aug 17 17:25:24 radio kernel: ubtbcmfw0: at uhub0 port 1 (addr 2)
disconnected
Aug 17 17:25:24 radio kernel: ubtbcmfw0: detached
Aug 17 17:25:25 radio kernel: ubt0: Broadcom Corp. BCM2033, rev 1.01/0.a0,
addr 2
Aug 17 17:25:25 radio kernel: ubt0: Interface 0 endpoints: interrupt=0x81,
bulk-in=0x82, bulk-out=0x2
Aug 17 17:25:25 radio kernel: ubt0: Interface 1 (alt.config 4) endpoints:
isoc-in=0x83, isoc-out=0x3; wMaxPacketSize=64; nframes=5, buffer size=320

> 7) run rc.bluetooth script on ubt0 device

Aug 17 16:45:40 radio kernel: ng_hci_process_event: ubt0hci - got HCI
event=0xe, length=4
Aug 17 16:45:40 radio kernel: ng_hci_process_event: ubt0hci - got HCI
event=0xe, length=10
Aug 17 16:45:40 radio kernel: ng_hci_process_event: ubt0hci - got HCI
event=0xe, length=12
Aug 17 16:45:40 radio kernel: ng_hci_process_event: ubt0hci - got HCI
event=0xe, length=11
Aug 17 16:45:40 radio kernel: ng_hci_process_event: ubt0hci - got HCI
event=0xe, length=4
Aug 17 16:45:40 radio last message repeated 2 times
Aug 17 16:45:40 radio kernel: ng_l2cap_lower_rcvmsg: ubt0l2cap - HCI node
is up, bdaddr: 0:3:c9:2d:c9:b5, pkt_size=377 bytes, num_pkts=10

Yeah !! Great !!

Now it returns:

radio# /etc/rc.bluetooth start ubt0
BD_ADDR: 00:03:c9:2d:c9:b5
Features: 0xff 0xfd 0x5 00 00 00 00 00
<3-Slot> <5-Slot> <Encryption> <Slot offset>
<Timing accuracy> <Switch> <Hold mode> <Sniff mode>
<Park mode> <Channel quality> <SCO link> <HV2 packets>
<HV3 packets> <u-law log> <A-law log> <CVSD>
<Power control>
Max. ACL packet size: 377 bytes
Number of ACL packets: 10
Max. SCO packet size: 16 bytes
Number of SCO packets: 0

Now this problem:

radio# hccontrol -n ubt0hci inquiry
Inquiry complete. Status: No error [00]

It logs:

Aug 17 17:28:41 radio kernel: ng_hci_process_event: ubt0hci - got HCI
event=0xf, length=4
Aug 17 17:28:47 radio kernel: ng_hci_process_event: ubt0hci - got HCI
event=0x1, length=1
Aug 17 17:29:59 radio kernel: ng_hci_process_event: ubt0hci - got HCI
event=0xf, length=4
Aug 17 17:30:05 radio kernel: ng_hci_process_event: ubt0hci - got HCI
event=0x7, length=255

What do you think Max ?

-kim

--
fbsd_current_at_kim.net
Received on Sun Aug 17 2003 - 12:33:21 UTC

This archive was generated by hypermail 2.4.0 : Wed May 19 2021 - 11:37:19 UTC