Closed
Bug 987071
Opened 11 years ago
Closed 11 years ago
[Camera] The screen doesn't going to sleep in the preview gallery
Categories
(Firefox OS Graveyard :: Gaia::Camera, defect, P1)
Tracking
(blocking-b2g:1.4+, b2g-v1.4 verified, b2g-v2.0 verified)
People
(Reporter: hyuna.cho82, Assigned: wilsonpage)
References
()
Details
(Keywords: regression)
Attachments
(3 files, 1 obsolete file)
* Repro.
1) Camera launch
2) Take some picture
3) Click thumbnail button
4) Open the preview gallery
4) leave with idle
Do not going to sleep
status-b2g-v1.4:
--- → affected
Whiteboard: burirun1.4-2
Updated•11 years ago
|
QA Contact: jschmitt
Comment 2•11 years ago
|
||
(In reply to Jason Smith [:jsmith] from comment #1)
> Does this happen on 1.3?
I was unable to repro this issue on 1.3, the device goes to sleep after idle.
Environmental Variables:
Device: Buri 1.3 MOZ
BuildID: 20140331004004
Gaia: 0d54a796bdaeb96ca7fb63da2166a46b4f8859f2
Gecko: ad91817a1967
Version: 28.0
Firmware Version: V1.2-device.cfg
Keywords: qawanted
Comment 3•11 years ago
|
||
I wasn't able to reproduce this on 1.4 Buri using the STR in Comment 0:
Gaia 4c3b2f57f4229c5f36f0d8fd399e65f4db88f104
SourceStamp 3aaca223b673
BuildID 20140331000202
Version 30.0a2
Comment 4•11 years ago
|
||
I think the reporter filed this on a Madai build - I do this bug reproducing on Buri using:
Gaia 26839cb46f856d610b192f5655a8c38a6bfe0829
SourceStamp d8e8f13bd4ae
BuildID 20140331040200
Version 31.0a1
Updated•11 years ago
|
status-b2g-v1.4:
affected → ---
Whiteboard: burirun1.4-2
Comment 5•11 years ago
|
||
Exact STR to get this bug on current Master:
1. Make sure screen timeout is set to 1 minute
2. Take a picture with camera
3. Select the preview to the left of the shutter button
4. Wait for screen to timeout - it never does
Assignee | ||
Updated•11 years ago
|
Priority: -- → P1
Assignee | ||
Updated•11 years ago
|
Assignee: nobody → wilsonpage
Updated•11 years ago
|
Comment 6•11 years ago
|
||
Wilson, please work on this first if you don't have any other blockers that are more critical
Assignee | ||
Comment 7•11 years ago
|
||
Attachment #8400565 -
Flags: review?(dmarcos)
Assignee | ||
Comment 8•11 years ago
|
||
Overview of patch:
- Found that device is indirectly forced into a 'wakelock' when the camera stream starts flowing.
- Added test coverage for viewfinder controller
- Added test coverage for related camera functions
- Had to rework Camera.prototype.release() to make sure it didn't always reload the camera when the document is visible. Moved logic into CameraController.
Still looking into edge-case STR:
1. Move to PreviewGallery
2. Allow device to sleep.
3. Awake
4. Close preview gallery
5. Observe device sleeps - it shouldn't
Updated•11 years ago
|
Attachment #8400565 -
Flags: review?(dmarcos) → review+
Assignee | ||
Comment 9•11 years ago
|
||
Could not recreate edge-case. I'm concerned there is still a series of steps that could cause the viewfinder to sleep. But I'm going to keep an eye out and file a follow-up bug if need be.
Assignee | ||
Comment 10•11 years ago
|
||
Comment 11•11 years ago
|
||
Looks like you forgot to resolve the bug after landing. But just as well because I was going to re-open it.
The patch that landed allows the screen to sleep once while in the preview gallery. But if you then wake it up and unlock the lockscreen it will never go back to sleep again. I think the 'focus' event handler in the camera controller is causing the camera preview stream to start running again.
The patch adds code like this:
this.app.set('previewGalleryOpen', false);
But it never uses the variable it sets on the app. Perhaps it was there so that the camera controller could easily test it when waking up?
Comment 12•11 years ago
|
||
Assignee | ||
Comment 13•11 years ago
|
||
Comment on attachment 8400565 [details] [review]
pull-request (master)
https://github.com/mozilla-b2g/gaia/pull/17936
Assignee | ||
Comment 14•11 years ago
|
||
Attachment #8400565 -
Attachment is obsolete: true
Attachment #8401112 -
Flags: review?(dmarcos)
Assignee | ||
Comment 15•11 years ago
|
||
Added one liner to check if preview-gallery is open before starting the stream again on 'focus' event.
Assignee | ||
Updated•11 years ago
|
Attachment #8401112 -
Flags: review?(dmarcos)
Assignee | ||
Comment 16•11 years ago
|
||
Assignee | ||
Updated•11 years ago
|
Status: NEW → RESOLVED
Closed: 11 years ago
Resolution: --- → FIXED
Comment 17•11 years ago
|
||
The bug still reproduces on master 1.5 build
The device doesn't go to sleep mode after screen timeout
1.5 Environmental Variables:
Device: Buri Master
BuildID: 20140408040204
Gaia: 1958454595b1fa0e061f0652ae965629993f5708
Gecko: 8883360b1edb
Version: 31.0a1
Firmware Version: v1.2-device.cfg
Comment 18•11 years ago
|
||
(In reply to sarsenyev from comment #17)
> The bug still reproduces on master 1.5 build
> The device doesn't go to sleep mode after screen timeout
>
> 1.5 Environmental Variables:
> Device: Buri Master
> BuildID: 20140408040204
> Gaia: 1958454595b1fa0e061f0652ae965629993f5708
> Gecko: 8883360b1edb
> Version: 31.0a1
> Firmware Version: v1.2-device.cfg
Wilson - Can you confirm?
Flags: needinfo?(wilsonpage)
Assignee | ||
Comment 19•11 years ago
|
||
Requesting 1.4 uplift.
blocking-b2g: --- → 1.4?
Flags: needinfo?(wilsonpage) → needinfo?(hkoka)
Assignee | ||
Comment 20•11 years ago
|
||
Tested working correctly. Device stays awake when taking pictures and sleeps when preview-gallery is open with:
- Helix
- Nexus4
- Hamachi
Although, I was once able to get my Hamachi into a state where it would *never* sleep in *any* app. I tried repeatedly, but was not able to get my device back into this state.
Comment 21•11 years ago
|
||
sarsenyev, can you verify if this bug is fixed after this patch gets uplifted to 1.4? please also test this on master as well.
blocking-b2g: 1.4? → 1.4+
Flags: needinfo?(sarsenyev)
Whiteboard: verifyme
Updated•11 years ago
|
Flags: needinfo?(hkoka)
Comment 22•11 years ago
|
||
After further research the bug still reproduces on the latest build 1.4 and master builds
I tested with 2 scenarios
The bug doesn't reproduce when:
From a preview image I go to the gallery, then after 1 minute the device goes to "sleep" mode
!!! But the bug reproduces when:
But when I stay on the preview image, then the device stays idle
As a proof I was shoot a video and attached a log file
STR:
1. Make sure screen timeout is set to 1 minute
2. Take a picture with camera
3. Select the preview to the left of the shutter button
Actual result:
Wait for screen to timeout - it never does
Expected result:
Screen goes to sleep after timeout
1.4 Environmental Variables:
Device: Buri 1.4 MOZ
BuildID: 20140409000202
Gaia: 26983f356ecb1bcf30e862d334b5de790071803e
Gecko: e450e07e3a58
Version: 30.0a2
Firmware Version: v1.2-device.cfg
1.5 Environmental Variables:
Device: Buri 1.5 Master
BuildID: 20140409040202
Gaia: 650e8c2c611ed07495d3bf3769f44a0efd88a492
Gecko: 5811efc11011
Version: 31.0a1
Firmware Version: v1.2-device.cfg
Flags: needinfo?(sarsenyev)
Comment 23•11 years ago
|
||
The YouTube video is pretty long, you can skip to 1 min to verify the device stays idle
Whiteboard: verifyme
Comment 25•11 years ago
|
||
Assignee | ||
Comment 26•11 years ago
|
||
I don't know what's going on. I've also uploaded a video to prove that I'm not going insane. Can you confirm that your devices sleep within other apps, such as Homescreen?
https://www.youtube.com/watch?v=S-ZV1ZqAl-U
Flags: needinfo?(wilsonpage) → needinfo?(sarsenyev)
Comment 27•11 years ago
|
||
Yes, the screen goes to sleeping mode with other scenarious
I tested on 2 different devices and I am hitting the same issue, screen is not going to sleep mode, also I noticed after the bug reproduces the sleeping mode does't work at all, the devices needs to be restarted to make it work.
I will keep "needinfo" tag, to verify when the patch will be uplifted on 1.4
Comment 28•11 years ago
|
||
Verified the bug is fixed on the latest 1.4 and master builds.
The screen goes to sleeping mode in "preview gallery" after timeout
1.4 Environmental Variables:
Device: Buri 1.4 MOZ
BuildID: 20140410000201
Gaia: 9b2da43dfee3792cd311ae55f0b06272313208f0
Gecko: 9d9ead7d6afa
Version: 30.0a2
Firmware Version: v1.2-device.cfg
1.5 Environmental Variables:
Device: Buri 1.5 MOZ
BuildID: 20140410040201
Gaia: 9d0b1bdf746823a94b13e6574c1d8304dc584763
Gecko: 690c810c8e3e
Version: 31.0a1
Firmware Version: v1.2-device.cfg
Status: RESOLVED → VERIFIED
Flags: needinfo?(sarsenyev)
You need to log in
before you can comment on or make changes to this bug.
Description
•