Closed Bug 826097 Opened 12 years ago Closed 6 years ago

geolocation doesn't turn off while Gaia camera app is running

Categories

(Core :: DOM: Geolocation, defect)

18 Branch
x86
Gonk (Firefox OS)
defect
Not set
normal

Tracking

()

RESOLVED WONTFIX
blocking-basecamp -

People

(Reporter: djf, Unassigned)

References

Details

Attachments

(1 file)

The Gaia camera app calls getCurrentPosition() once every 10 minutes.  (That is broken and it should be changed to use watchPosition(), but that is a separate bug).

But it looks like the GPS hardware never spins down.  In logcat, I see GPS-related messages once a second, and they seem to go on for at least 5 minutes. They do stop when I kill the camera app, though.
Attached file logcat
This is adb logcat | grep LocSvc while I launched the camera, let it run for 10 seconds or so, and then killed the camera.

It shows GPS startup and shutdown, and updates every second.  Those 1 second updates seem to go on forever while the camera is running, which is surprising since the camera does not use watchPosition().
Assignee: nobody → doug.turner
Nominating this as blocking so that the risk to battery life can be assesed in triage.
blocking-basecamp: --- → ?
basecamp- based on the current information. Please renom if this can be proven to have serious implications on battery life.
blocking-basecamp: ? → -
Assignee: doug.turner → nobody
Garvan: do you think this camera app bug reported on B2G 1.1 in 2013 is still relevant on B2G 2.1?
Blocks: geo-b2g
Flags: needinfo?(gkeeley)
The geolocation service (side note: this is a singleton, and on B2G is persistent) shuts down its provider after a timeout. 
http://mxr.mozilla.org/mozilla-central/source/dom/src/geolocation/nsGeolocation.cpp#873

The provider is a layer above the GPS hardware interface, so that lower level could stay alive. Agreed that GPS is an expensive chip to keep awake. This would need to be researched further to see if it still happens.
Flags: needinfo?(gkeeley)
See Also: → 863051
Closing as we are not working on Firefox OS anymore.
Status: NEW → RESOLVED
Closed: 6 years ago
Resolution: --- → WONTFIX
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: