New issue
Advanced search Search tips
Note: Color blocks (like or ) mean that a user may not be available. Tooltip shows the reason.

Issue 623404 link

Starred by 2 users

Issue metadata

Status: Verified
Owner:
Closed: Jul 2016
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: Chrome
Pri: 2
Type: Bug



Sign in to add a comment

Samus keyboard backlight turning on and off during fullscreen video due to bogus hover detection

Project Member Reported by derat@chromium.org, Jun 26 2016

Issue description

Google Chrome	51.0.2704.103 (Official Build) (64-bit)
Platform	8172.56.0 (Official Build) stable-channel samus

While watching fullscreen video from Netflix last night, the keyboard backlight on my Samus was frequently turning on and off. It looks from powerd's log like the proximity sensor was flipping out and constantly reporting that hovering was starting and stopping. The lid was open at around 90 degrees and there was nothing above the touchpad or keyboard. It continued even after I adjusted the angle of the screen a bit.

Unfortunately, I didn't take a feedback report then and I'm not able to repro the issue now. I believe that we usually wait 30 seconds after the cessation of hovering to turn off the backlight; it was probably noticeable here since (IIRC) we try to turn the backlight off more quickly when fullscreen video is also playing.

I can probably work around this to some degree in powerd by keeping the backlight on for a few seconds after hovering stops while fullscreen video is playing instead of turning it off immediately. Hover detection is probably never going to be perfectly reliable, so this seems like a reasonable thing to do.

This is a PVT samus device. Is it possible that it lags behind MP devices in terms of firmware or hardware?

[0625/215225:INFO:daemon.cc(1369)] Saw fullscreen video activity
[0625/215225:INFO:daemon.cc(1385)] Saw user activity
[0625/215226:INFO:daemon.cc(560)] Hovering off
[0625/215226:INFO:keyboard_backlight_controller.cc(471)] Setting brightness to 0 (0%) over 2000 ms
[0625/215226:INFO:daemon.cc(560)] Hovering on
[0625/215226:INFO:keyboard_backlight_controller.cc(471)] Setting brightness to 40 (40%) over 200 ms
[0625/215226:INFO:daemon.cc(560)] Hovering off
[0625/215226:INFO:keyboard_backlight_controller.cc(471)] Setting brightness to 0 (0%) over 2000 ms
[0625/215227:INFO:daemon.cc(560)] Hovering on
[0625/215227:INFO:keyboard_backlight_controller.cc(471)] Setting brightness to 40 (40%) over 200 ms
[0625/215227:INFO:daemon.cc(560)] Hovering off
[0625/215227:INFO:keyboard_backlight_controller.cc(471)] Setting brightness to 0 (0%) over 2000 ms
[0625/215227:INFO:daemon.cc(560)] Hovering on
[0625/215227:INFO:keyboard_backlight_controller.cc(471)] Setting brightness to 40 (40%) over 200 ms
[0625/215230:INFO:daemon.cc(1369)] Saw fullscreen video activity
[0625/215232:INFO:daemon.cc(560)] Hovering off
[0625/215232:INFO:keyboard_backlight_controller.cc(471)] Setting brightness to 0 (0%) over 2000 ms
[0625/215232:INFO:daemon.cc(560)] Hovering on
[0625/215232:INFO:keyboard_backlight_controller.cc(471)] Setting brightness to 40 (40%) over 200 ms
[0625/215232:INFO:daemon.cc(560)] Hovering off
[0625/215232:INFO:keyboard_backlight_controller.cc(471)] Setting brightness to 0 (0%) over 2000 ms
[0625/215233:INFO:daemon.cc(560)] Hovering on
[0625/215233:INFO:keyboard_backlight_controller.cc(471)] Setting brightness to 40 (40%) over 200 ms
[0625/215233:INFO:daemon.cc(1385)] Saw user activity
[0625/215234:INFO:daemon.cc(560)] Hovering off
[0625/215234:INFO:keyboard_backlight_controller.cc(471)] Setting brightness to 0 (0%) over 2000 ms
[0625/215234:INFO:daemon.cc(560)] Hovering on
[0625/215234:INFO:keyboard_backlight_controller.cc(471)] Setting brightness to 40 (40%) over 200 ms
[0625/215235:INFO:daemon.cc(560)] Hovering off
[0625/215235:INFO:keyboard_backlight_controller.cc(471)] Setting brightness to 0 (0%) over 2000 ms
[0625/215235:INFO:daemon.cc(560)] Hovering on
[0625/215235:INFO:keyboard_backlight_controller.cc(471)] Setting brightness to 40 (40%) over 200 ms
[0625/215235:INFO:daemon.cc(1369)] Saw fullscreen video activity
[0625/215237:INFO:daemon.cc(560)] Hovering off
[0625/215237:INFO:keyboard_backlight_controller.cc(471)] Setting brightness to 0 (0%) over 2000 ms
[0625/215237:INFO:daemon.cc(560)] Hovering on
[0625/215237:INFO:keyboard_backlight_controller.cc(471)] Setting brightness to 40 (40%) over 200 ms
[0625/215237:INFO:daemon.cc(560)] Hovering off
[0625/215237:INFO:keyboard_backlight_controller.cc(471)] Setting brightness to 0 (0%) over 2000 ms
[0625/215238:INFO:daemon.cc(560)] Hovering on
[0625/215238:INFO:keyboard_backlight_controller.cc(471)] Setting brightness to 40 (40%) over 200 ms
[0625/215238:INFO:daemon.cc(560)] Hovering off
[0625/215238:INFO:keyboard_backlight_controller.cc(471)] Setting brightness to 0 (0%) over 2000 ms
[0625/215238:INFO:daemon.cc(560)] Hovering on
[0625/215238:INFO:keyboard_backlight_controller.cc(471)] Setting brightness to 40 (40%) over 200 ms
[0625/215238:INFO:daemon.cc(560)] Hovering off
[0625/215238:INFO:keyboard_backlight_controller.cc(471)] Setting brightness to 0 (0%) over 2000 ms
[0625/215238:INFO:daemon.cc(560)] Hovering on
[0625/215238:INFO:keyboard_backlight_controller.cc(471)] Setting brightness to 40 (40%) over 200 ms
 

Comment 1 by adlr@chromium.org, Jun 26 2016

We haven't done a hardware or firmware change since launch and at this point I strongly doubt we will. If there are bugs in that, there's no much we can do unless they are severe :/

Comment 2 by derat@chromium.org, Jun 29 2016

Status: Started (was: Untriaged)
The powerd keyboard backlight code was due for a refactor anyway.
Project Member

Comment 3 by bugdroid1@chromium.org, Jul 1 2016

The following revision refers to this bug:
  https://chromium.googlesource.com/chromiumos/platform2/+/473db12e6d9fc060d0fe56e32b8f8077b3e9774b

commit 473db12e6d9fc060d0fe56e32b8f8077b3e9774b
Author: Daniel Erat <derat@chromium.org>
Date: Wed Jun 29 00:41:00 2016

power: Refactor KeyboardBacklightController.

Consolidate the logic for updating the keyboard backlight
brightness into the existing UpdateState() function.

No user-visible changes intended (apart from turning the
backlight on more quickly when fullscreen video stops), but
this paves the way for a future change to keep the backlight
on for a short period after hovering or user activity during
fullscreen video to reduce jank when hover detection is
noisy.

BUG= chromium:623404 
TEST=existing tests pass with after one minor change

Change-Id: If758688a331841e517faab4c5f81cb930604189b
Reviewed-on: https://chromium-review.googlesource.com/356850
Commit-Ready: Dan Erat <derat@chromium.org>
Tested-by: Dan Erat <derat@chromium.org>
Reviewed-by: Eric Caruso <ejcaruso@chromium.org>

[modify] https://crrev.com/473db12e6d9fc060d0fe56e32b8f8077b3e9774b/power_manager/powerd/policy/keyboard_backlight_controller_unittest.cc
[modify] https://crrev.com/473db12e6d9fc060d0fe56e32b8f8077b3e9774b/power_manager/powerd/policy/keyboard_backlight_controller.cc
[modify] https://crrev.com/473db12e6d9fc060d0fe56e32b8f8077b3e9774b/power_manager/powerd/policy/keyboard_backlight_controller.h

Project Member

Comment 4 by bugdroid1@chromium.org, Jul 2 2016

The following revision refers to this bug:
  https://chromium.googlesource.com/chromiumos/platform2/+/41ec8e520d723f124458d76eb48e43d8c584d867

commit 41ec8e520d723f124458d76eb48e43d8c584d867
Author: Daniel Erat <derat@chromium.org>
Date: Wed Jun 29 22:48:58 2016

power: Keep backlight on for short period during video.

KeyboardBacklightController previously turned the backlight
off immediately when hovering stopped while fullscreen video
was playing. Hover detection can be jittery, which resulted
in the backlight frequently turning off and back on.

Introduce a new keyboard_backlight_keep_on_during_video_ms
pref that defines how long the backlight should remain on
after hovering stops (similar to the existing
keyboard_backlight_keep_on_ms pref, but used while
fullscreen video is playing).

BUG= chromium:623404 
TEST=updated existing tests for new behavior; also manually
     verified on samus that backlight doesn't turn off
     immediately when taking hands off touchpad while
     fullscreen video is playing

Change-Id: Ifa6474ce0577086bac5151c117b98e920855ccf0
Reviewed-on: https://chromium-review.googlesource.com/357411
Commit-Ready: Dan Erat <derat@chromium.org>
Tested-by: Dan Erat <derat@chromium.org>
Reviewed-by: Dan Erat <derat@chromium.org>

[modify] https://crrev.com/41ec8e520d723f124458d76eb48e43d8c584d867/power_manager/common/power_constants.cc
[modify] https://crrev.com/41ec8e520d723f124458d76eb48e43d8c584d867/power_manager/powerd/policy/keyboard_backlight_controller_unittest.cc
[modify] https://crrev.com/41ec8e520d723f124458d76eb48e43d8c584d867/power_manager/common/power_constants.h
[modify] https://crrev.com/41ec8e520d723f124458d76eb48e43d8c584d867/power_manager/powerd/policy/keyboard_backlight_controller.cc
[modify] https://crrev.com/41ec8e520d723f124458d76eb48e43d8c584d867/power_manager/powerd/policy/keyboard_backlight_controller.h
[add] https://crrev.com/41ec8e520d723f124458d76eb48e43d8c584d867/power_manager/default_prefs/keyboard_backlight_keep_on_during_video_ms

Comment 5 by derat@chromium.org, Jul 2 2016

Status: Fixed (was: Started)
Labels: VerifyIn-54
Project Member

Comment 7 by bugdroid1@chromium.org, Sep 7 2016

Labels: merge-merged-release-R53-8530.B
The following revision refers to this bug:
  https://chromium.googlesource.com/chromiumos/platform2/+/b9fe446718733d368bc316222989350e89b5528e

commit b9fe446718733d368bc316222989350e89b5528e
Author: Daniel Erat <derat@chromium.org>
Date: Wed Jun 29 00:41:00 2016

power: Refactor KeyboardBacklightController.

Consolidate the logic for updating the keyboard backlight
brightness into the existing UpdateState() function.

No user-visible changes intended (apart from turning the
backlight on more quickly when fullscreen video stops), but
this paves the way for a future change to keep the backlight
on for a short period after hovering or user activity during
fullscreen video to reduce jank when hover detection is
noisy.

BUG= chromium:623404 
TEST=existing tests pass with after one minor change

Change-Id: Id9e4474f04e43b965947bda5501d4355844c912d
Old-Change-Id: If758688a331841e517faab4c5f81cb930604189b
Reviewed-on: https://chromium-review.googlesource.com/356850
Commit-Ready: Dan Erat <derat@chromium.org>
Tested-by: Dan Erat <derat@chromium.org>
Reviewed-by: Eric Caruso <ejcaruso@chromium.org>
Reviewed-on: https://chromium-review.googlesource.com/381316
Reviewed-by: Wei-Ning Huang <wnhuang@chromium.org>
Reviewed-by: Dan Erat <derat@chromium.org>
Commit-Queue: Wei-Ning Huang <wnhuang@chromium.org>
Tested-by: Wei-Ning Huang <wnhuang@chromium.org>

[modify] https://crrev.com/b9fe446718733d368bc316222989350e89b5528e/power_manager/powerd/policy/keyboard_backlight_controller_unittest.cc
[modify] https://crrev.com/b9fe446718733d368bc316222989350e89b5528e/power_manager/powerd/policy/keyboard_backlight_controller.cc
[modify] https://crrev.com/b9fe446718733d368bc316222989350e89b5528e/power_manager/powerd/policy/keyboard_backlight_controller.h

Project Member

Comment 8 by bugdroid1@chromium.org, Sep 7 2016

The following revision refers to this bug:
  https://chromium.googlesource.com/chromiumos/platform2/+/71dbe73f6c15c1495ec26ecee270638e045b5650

commit 71dbe73f6c15c1495ec26ecee270638e045b5650
Author: Daniel Erat <derat@chromium.org>
Date: Wed Jun 29 22:48:58 2016

power: Keep backlight on for short period during video.

KeyboardBacklightController previously turned the backlight
off immediately when hovering stopped while fullscreen video
was playing. Hover detection can be jittery, which resulted
in the backlight frequently turning off and back on.

Introduce a new keyboard_backlight_keep_on_during_video_ms
pref that defines how long the backlight should remain on
after hovering stops (similar to the existing
keyboard_backlight_keep_on_ms pref, but used while
fullscreen video is playing).

BUG= chromium:623404 
TEST=updated existing tests for new behavior; also manually
     verified on samus that backlight doesn't turn off
     immediately when taking hands off touchpad while
     fullscreen video is playing

Change-Id: I8b108d3c53baf43862cd636c7e8044fc75d7d929
Old-Change-Id: Ifa6474ce0577086bac5151c117b98e920855ccf0
Reviewed-on: https://chromium-review.googlesource.com/357411
Commit-Ready: Dan Erat <derat@chromium.org>
Tested-by: Dan Erat <derat@chromium.org>
Reviewed-by: Dan Erat <derat@chromium.org>
Reviewed-on: https://chromium-review.googlesource.com/381317
Reviewed-by: Wei-Ning Huang <wnhuang@chromium.org>
Commit-Queue: Wei-Ning Huang <wnhuang@chromium.org>
Tested-by: Wei-Ning Huang <wnhuang@chromium.org>

[modify] https://crrev.com/71dbe73f6c15c1495ec26ecee270638e045b5650/power_manager/common/power_constants.cc
[modify] https://crrev.com/71dbe73f6c15c1495ec26ecee270638e045b5650/power_manager/powerd/policy/keyboard_backlight_controller_unittest.cc
[modify] https://crrev.com/71dbe73f6c15c1495ec26ecee270638e045b5650/power_manager/common/power_constants.h
[modify] https://crrev.com/71dbe73f6c15c1495ec26ecee270638e045b5650/power_manager/powerd/policy/keyboard_backlight_controller.cc
[modify] https://crrev.com/71dbe73f6c15c1495ec26ecee270638e045b5650/power_manager/powerd/policy/keyboard_backlight_controller.h
[add] https://crrev.com/71dbe73f6c15c1495ec26ecee270638e045b5650/power_manager/default_prefs/keyboard_backlight_keep_on_during_video_ms

Comment 9 by son...@google.com, Sep 28 2016

Status: Verified (was: Fixed)
Verified on build 8844.0.0

Sign in to add a comment