No Bluetooth pairing handler when systemsettings isn't open

Bug #1474296 reported by Michael Zanetti
20
This bug affects 4 people
Affects Status Importance Assigned to Milestone
ubuntu-system-settings (Ubuntu)
Confirmed
Low
Matthew Paul Thomas

Bug Description

Currently the Bluetooth pairing handler is implemented in the Bluetooth plugin of the system-settings app. This has the side effect that devices can only be paired when the system settings are open and in foreground. Instead, those pairing handlers should be implemented in a service that keeps running in the background.

(this is related to bug #1474295)

Tags: bluetooth
Revision history for this message
Sebastien Bacher (seb128) wrote :

Thanks, is pairing something done often enough that it requires a service? Having more service means more power usage when idle. How are other platforms handle that (trying on a s3 android phone it seems you need to be in settings to pair as well).

Once the device has been paired and is known/trusted bluez should allows pairing without UI, so it's a "first time use" thing only right?

Changed in ubuntu-system-settings (Ubuntu):
importance: Undecided → Low
Changed in ubuntu-system-settings (Ubuntu):
assignee: nobody → Matthew Paul Thomas (mpt)
Revision history for this message
Michael Zanetti (mzanetti) wrote :

I agree that most cases when a pairing handler is required happen during the initial searching/pairing process, which is when system-settings is running anyways. However, Bluetooth allows some flexibility there. For example a device could just remember the BT MAC address and try to do the pairing later. Or a device is also allowed to invalidate the link key and reinitiate the pairing sequence at any time. If bluez has no agent registered at that time it will fail. I could well imagine some of the car connectivity issues we have are related to this. Can't tell for sure without reproducing.

In any case, from a user point of view it's not really obvious that one can only receive the Bluetooth PIN entry dialog while the system-setting's bluetooth page is open. Even if the car kit would be able to deal with this, I'm sure some users just don't manage to pair it because they're not aware of that fact. Even if the system-settings app is running, but not focused it will be frozen, which causes bluez's D-Bus connection to get stuck and will definitely confuse the other device with timeouts etc.

Kinda related to this, but probably justifies a separate bug report is that when having the bluetooth page open we do a continuous Inquiry. An Inquiry uses up about 20% of the available bandwidth. Having the car and the phone doing those constant inquiries causes half of the bandwidth to be jammed which decreases likelyhood of a successful pairing too. Having the pairing handler separated from the "scan for devices" should help too.

Revision history for this message
Matthew Paul Thomas (mpt) wrote :

I'm sorry to do this just after marking bug 1474295 as Incomplete, but this bug report does not have steps to reproduce and I can't guess what they are.

Per spec, the Bluetooth settings are supposed to have a list of devices to which the phone should "Connect automatically when detected:". <https://wiki.ubuntu.com/Bluetooth#Listing_devices> Is that implemented? If so, how is it different from what you are asking for here?

Changed in ubuntu-system-settings (Ubuntu):
status: New → Incomplete
Revision history for this message
Michael Zanetti (mzanetti) wrote :

This bug is not about the list to search for devices, but about how to set your own device being visible to others. Also currently one cannot pair the phone without having the system-settings' Bluetooth page open, while instead the pairing code should be running all the time.

Changed in ubuntu-system-settings (Ubuntu):
status: Incomplete → New
Revision history for this message
Launchpad Janitor (janitor) wrote :

Status changed to 'Confirmed' because the bug affects multiple users.

Changed in ubuntu-system-settings (Ubuntu):
status: New → Confirmed
tags: added: bluetooth
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.