Merge lp://qastaging/~afrantzis/unity-system-compositor/voice-call-proximity-over-0.1 into lp://qastaging/unity-system-compositor/ubuntu

Proposed by Alexandros Frantzis
Status: Superseded
Proposed branch: lp://qastaging/~afrantzis/unity-system-compositor/voice-call-proximity-over-0.1
Merge into: lp://qastaging/unity-system-compositor/ubuntu
Diff against target: 587 lines (+362/-18) (has conflicts)
7 files modified
debian/changelog (+16/-3)
src/mir_screen.cpp (+47/-10)
src/mir_screen.h (+6/-2)
src/power_state_change_reason.h (+3/-1)
src/server.cpp (+6/-1)
src/server.h (+14/-0)
tests/unit-tests/test_mir_screen.cpp (+270/-1)
Text conflict in debian/changelog
To merge this branch: bzr merge lp://qastaging/~afrantzis/unity-system-compositor/voice-call-proximity-over-0.1
Reviewer Review Type Date Requested Status
PS Jenkins bot (community) continuous-integration Approve
Unity System Compositor Development Team Pending
Review via email: mp+270801@code.qastaging.launchpad.net

This proposal has been superseded by a proposal from 2015-09-25.

Commit message

Screen blanking/proximity handling improvements for voice calls.

Description of the change

Screen blanking/proximity handling improvements for voice calls.

To post a comment you must log in.
Revision history for this message
PS Jenkins bot (ps-jenkins) wrote :
review: Approve (continuous-integration)
Revision history for this message
kevin gunn (kgunn72) wrote :

so after testing, i get proximity blanking for the text messages.
but i do not get proximity blanking for the incoming voice call notification.
is that what i'm supposed to see ?
i'm on arale.

Revision history for this message
Alexandros Frantzis (afrantzis) wrote :

> so after testing, i get proximity blanking for the text messages.
> but i do not get proximity blanking for the incoming voice call notification.
> is that what i'm supposed to see ?
> i'm on arale.

No, you should also get proximity blanking for voice call notifications. This used to work, so I figured something must have changed outside USC/powerd.

After some investigation I found that the problem is the new notification handling logic in Unity8. With the new logic Unity8 sends a "turn screen on" message with reason "unknown" when a snap decision prompt is shown. This confuses USC because it has already got a "call" notification from powerd.

Once again our distributed and uncoordinated power-management logic is making our lives difficult and is a constant source of bugs and fragility.

I need to think a bit more about how to solve this particular problem. Stay tuned.

254. By Alexandros Frantzis

Rename PowerStateChangeReason::call to PowerStateChangeReason::snap_decision

255. By Alexandros Frantzis

Sync with lp:mir/0.1

Revision history for this message
PS Jenkins bot (ps-jenkins) wrote :
review: Approve (continuous-integration)
Revision history for this message
PS Jenkins bot (ps-jenkins) wrote :
review: Approve (continuous-integration)
Revision history for this message
kevin gunn (kgunn72) wrote :

retested with https://code.launchpad.net/~afrantzis/unity8/power-state-change-reason-snap-decision
it matched what i expected, I hammered on this pretty good.
I found only 2 cosmetic issues, and 1 issue that should likely be addressed (unless it's already a bug)

cosmetic issue 1: if a text or call occurs, screen is lit, no interaction it will dim. getting a call or text at that moment will not brighten the screen.

cosmetic issue 2: incoming call, cover and uncover proximity sensor quickly/rapidly and every now and then you will hear the audio stutter only very slightly

issue to fix: if you are on an active call and hit power button to blank screen, generate a second incoming call - as a user you have no idea this has occured, there is no vibra nor does the screen light. At least with a text the vibra will activate, but no lighting screen. The screen should probably light up in both these instances.

Revision history for this message
kevin gunn (kgunn72) wrote :

cosmetic issues mentioned above should not prevent landing

Revision history for this message
kevin gunn (kgunn72) wrote :

sorry for comments galore, i meant to also add if the last issue is already a bug, then I wouldn't consider it a blocker for landing this as this is a huge improvement.

Revision history for this message
Alexandros Frantzis (afrantzis) wrote :

> retested with https://code.launchpad.net/~afrantzis/unity8/power-state-change-
> reason-snap-decision
> it matched what i expected, I hammered on this pretty good.

Thanks for testing!

> I found only 2 cosmetic issues, and 1 issue that should likely be addressed
> (unless it's already a bug)

> cosmetic issue 1: if a text or call occurs, screen is lit, no interaction it
> will dim. getting a call or text at that moment will not brighten the screen.

From a quick look at the related USC code, this should be easily fixable (Famous last words? Let's see... :) )

> cosmetic issue 2: incoming call, cover and uncover proximity sensor
> quickly/rapidly and every now and then you will hear the audio stutter only
> very slightly

Covering/uncovering the proximity sensor is an intensive task that involves cross process communication and the teardown and setup of our input and graphics subsystems in USC/Mir. I can't really see anything simple (i.e. as a bugfix) we can do to improve this on the USC side.

> issue to fix: if you are on an active call and hit power button to blank
> screen, generate a second incoming call - as a user you have no idea this has
> occured, there is no vibra nor does the screen light. At least with a text the
> vibra will activate, but no lighting screen. The screen should probably light
> up in both these instances.

This is indeed a regression. With the new code, when a call arrives, USC enables proximity handling and expects a proximity event with the initial proximity state. This is done in order to avoid turning on the screen for a moment if the proximity is "near". However, if proximity handling is already enabled (in this case because the dialer-app has enabled it) USC won't receive a proximity event with the initial state and won't turn on the screen. I am confident there is a way to improve this within our current architecture, but it will probably involve more communication between powerd and USC and more state keeping. I will experiment with a few approaches.

Note that when a second call arrives the users get a beeping noise in the call audio output, so they do get some notification.

Stay tuned!

256. By Alexandros Frantzis

Set normal backlight when call or notifications arrive while the screen is on

257. By Alexandros Frantzis

Sync with lp:mir/0.1

Revision history for this message
PS Jenkins bot (ps-jenkins) wrote :
review: Approve (continuous-integration)

Unmerged revisions

257. By Alexandros Frantzis

Sync with lp:mir/0.1

256. By Alexandros Frantzis

Set normal backlight when call or notifications arrive while the screen is on

255. By Alexandros Frantzis

Sync with lp:mir/0.1

254. By Alexandros Frantzis

Rename PowerStateChangeReason::call to PowerStateChangeReason::snap_decision

253. By Alexandros Frantzis

Update files for 0.1.2 release

252. By Alexandros Frantzis

Introduce a separate, fixed timeout pair for reason 'call'

251. By Alexandros Frantzis

Improve proximity handling during voice calls

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
The diff is not available at this time. You can reload the page or download it.

Subscribers

People subscribed via source and target branches