bluetooth doesn't stop searching for other devices

VERIFIED FIXED in B2G C3 (12dec-1jan)


6 years ago
6 years ago


(Reporter: ggrisco, Assigned: jj.evelyn)


B2G C3 (12dec-1jan)
Gonk (Firefox OS)

Firefox Tracking Flags



(Whiteboard: [target:12/21])


(1 attachment)



6 years ago
Go to Settings>Bluetooth.
Here we observe that the device keeps inquiring for nearby devices. After Inquiry completes, again Inquiry command is sent, and thus the device keeps Inquiring.
Even when HOME key is pressed, and when power key is pressed (so that the device goes into suspend mode), the Inquiry doesn't stop.


6 years ago
Depends on: 802677
Blocks: 802677
No longer depends on: 802677


6 years ago
QA Contact: wachen
The state of discovering could be controlled by applications via calling StartDiscovery()/StopDiscovery(). I don't remember that I've ever seen this requirement or scenario defined in UX spec, especially in the case that HOME/POWER key is pressed. The latest UX spec I can find is v11:

Discovering is a heavy loading procedure. In my opinion, we should let it timed out with a period of time, like 60 or 90 seconds, and enable "Search again" button after discovering is stopped.

+needinfo Larissa, We need advice from our UX designer of Settings.
Flags: needinfo?(lco)
Triage: Blocking on certification problem potential
blocking-basecamp: ? → +
Priority: -- → P1
Assignee: nobody → echou
Target Milestone: --- → B2G C3 (12dec-1jan)

Comment 3

6 years ago
Yes, let's have it timeout after 90 seconds while the user is on the bluetooth settings page. It should automatically timeout too when the user exits the bluetooth settings page.
Flags: needinfo?(lco)
Whiteboard: [target:12/21]
Eric, what's your estimate for fixing this?
(In reply to Dietrich Ayala (:dietrich) from comment #4)
> Eric, what's your estimate for fixing this?

It would be done in Gaia, so I'll let Evelyn to estimate.

The modifications would be:

 (1) shorten the period of discovering time to a more reasonable value (90 secs).
 (2) timeout and stop discovering whenever leaving Bluetooth(in Settings) page.

If you have any questions, please let me know.
Thank you.

Assignee: echou → ehung

Comment 6

6 years ago
I'm doing now. Hope I can submit my patch today.

Comment 7

6 years ago
Created attachment 691285 [details]
point to

In this patch, I didn't update discovering time, because it's 60 seconds now, it's short enough.
I stop discovering nearby devices when Settings app is pushed to the background.
Also do some code clean up and error checking.
Attachment #691285 - Flags: review?(timdream+bugs)
Comment on attachment 691285 [details]
point to

r=me, after fixing stopDiscovery() and manual tests.
Attachment #691285 - Flags: review?(timdream+bugs) → review+

Comment 9

6 years ago
Move mozHidden checking out of stopDiscovery() function, create another function for checking instead. Tested and it works.

Eric will help on creating a follow-up issue for the problem that Bluetooth defaultAdapter.stopDiscovery() DOM request sometimes won't return back.

Commit merged:
Last Resolved: 6 years ago
Resolution: --- → FIXED
Fixed in 20121212 build
You need to log in before you can comment on or make changes to this bug.