[QtBluetooth] Help for testing HW_OSTC3 and SHEARWATER families

Anton Lundin glance at acc.umu.se
Wed Jul 8 14:35:01 PDT 2015

On 29 June, 2015 - Claudiu Olteanu wrote:

> Hello,
> I need some help to test if the native serial implementation
> works after the changes I did on the libdivecomputer project.
> If you have a device from HW_OSTC3 or SHEARWATER families
> please take the first 7 patches and apply them on the libdivecomputer
> branch.
> Unfortunately I don't have a SHEARWATER device so the only think
> I did was to make sure that the sources compile after my modifications.
> If you have a dive computer with Bluetooth support you can take the
> the last 4 patches[*] and apply them on the Subsurface branch.
> The Bluetooth support should work on Linux/OS X platforms.
> For devices that require a custom PIN code on the pairing
> step you should start a keyboard agent. One possible solution is
> to use *bluetoothctl* tool and to run the following commands:
> *# agent KeyboardOnly*
> *# default-agent*
> Also it would be useful if you could run the *hcidump *tool in
> background.
> Please let me know if you have any questions.

Chokay. I tried to test against a OSTC Sport, and got some results.

Fist off i got massively de-railed due to that somehow i got
CONFIG_BT_BCM enabled in my kernel which caused btusb to fail its
dependency on btbcm like:

Bluetooth: hci0: BCM: Read verbose config info failed (-16)

and thus not really create a working bt device.

Still hciconfig showed a hci0 but with mac 00:00... and the device didn't

Due to that broken device i got a:
"This should never happen, please contact the Subsurface developers" ...

Instead of continuing down the path to fix btusb i instead removed
CONFIG_BT_BCM and stuff loaded and everything started to look brighter.

Then i tried to scan for the OSTC Sport and came up empty, and
remembered the fact that this MacBookPro8,2 has a crappy wifi/bluetooth
interaction when running Linux so the bt device is basically useless.

So, i brought out my old trusty usb-bt stick that i normally use, and
noted that i couldn't switch adapter in the bluetooth dialog. I can
power down the internal bluetooth thingie but its still there so
subsurface just shows that one.

It would be great if there was a way to switch to using another bt
device on your host.

Another thing i thought about was (re)using your bt-libdc thingie in the
Configure Dive computers dialog there. It would be great if one could
change settings in the devices and to be able to upgrade the firmware
over native bluetooth. I think that would be a great bonus task =)


Anton Lundin	+46702-161604

More information about the subsurface mailing list