yashsingh1/xdaforums huggingface dataset:
[OnePlus 3 ROMs, Kernels, Recoveries, & Other Devel] andip71:
Hi all,

kernel update is out.

Version

1.0-beta9

11.10.2016

Update: Updated with latest official CM kernel commits as of 11.10.16, 8am CET

Change: Internal kernel busybox updated to latest version 1.25.1 (self-compiled from sources, www.busybox.net)

Change: Build script improvements

Enjoy

Andi
[OnePlus 3 ROMs, Kernels, Recoveries, & Other Devel] ZeNiXxX:
Hi Andy and welcome back. Does beta9 supports pocketmod?
[OnePlus 3 ROMs, Kernels, Recoveries, & Other Devel] andip71:
I have not added something like that myself.

I believe CM comes without, so the answer is likely no.

Andi
[OnePlus 3 ROMs, Kernels, Recoveries, & Other Devel] ZeNiXxX:
Hmmm ok. Just asked cause elemtalx kernel supports it :).thanks for the reply
[OnePlus 3 ROMs, Kernels, Recoveries, & Other Devel] andip71:
Ok, can you explain what you exactly mean with pocket mode?

If you mean - switching off the fingerprint sensor based on proximity (when in pocket), then it is not in. And I really dont see the need for that. I might be wrong, then please explain.

If you mean something else with pocket mode, please elaborate.

Andi
[OnePlus 3 ROMs, Kernels, Recoveries, & Other Devel] KaszasM:
if we link you the commit woupd you be so kind and add it? we don't have a work-around from cm side but there is 1 should be the same in rr, sultans and some other custom roms and needs kernel support... i know you dont "support" "us" but would be very appreciated. perhaps [MENTION=5623053]sunsettrack4[/MENTION] could link hes git/commit pls
[OnePlus 3 ROMs, Kernels, Recoveries, & Other Devel] hellcat50:
i think they mean a pocket mode like oos has?.
[OnePlus 3 ROMs, Kernels, Recoveries, & Other Devel] KaszasM:
yes that kernel change/+app arrived at that weekend to rr,so fp is deactive if prox sensor off.
[OnePlus 3 ROMs, Kernels, Recoveries, & Other Devel] andip71:
I have seen the commit already a while ago in BlueSpark repo.

But before I have no idea what "pocket mode" in this context means, i.e. somebody explaining me what this "mode" should achieve, I will not add anything.

Also when it is useless for original CM roms for some reasons, I will not add it.

I need to fully understand first what it is - not technically, but what it changes for the user. Then I can decide.

Andi
[OnePlus 3 ROMs, Kernels, Recoveries, & Other Devel] andip71:
Ok, that is what I read out of the code when I looked at the commit.

But - why would we need that?

Nobody would put his finger on the fingerprint sensor when the phone is in the pocket anyways. Or am I wrong?

So I still do not get the benefits of that.

Andi
[OnePlus 3 ROMs, Kernels, Recoveries, & Other Devel] andip71:
...and ignore my stupidity please. But what the heck is the OOS pocket mode?

When phone is covered (proximity sensor), touchscreen, capacitive buttons and fingerprint is switched off. This is how OOS behaves.

On CM, touchscreen and capac. buttons are also deactivated when phone is covered, only the fingerprint is still active.

I still do not get the point, I might by dumb, sorry :)

Andi
[OnePlus 3 ROMs, Kernels, Recoveries, & Other Devel] andip71:
Then tell me... why should the FP sensor be off in the pocket, when anyways nobody would try to touch it in the pocket?

I am curious.

(and which app arrived, are you saying a specific app is even needed for it??)

By the way:

Why I am a bit reluctant to merge this change in is: I looked at it and I do not feel very comfortable with it, honestly. This is heavy stuff on the interrupt controller level. So I will only even consider that when I have a strong use case why this should be in.

Andi
[OnePlus 3 ROMs, Kernels, Recoveries, & Other Devel] hellcat50:
this i think
[OnePlus 3 ROMs, Kernels, Recoveries, & Other Devel] andip71:
Yep, I have seen this screen many times before, but never understood what is is about.

I never had to press this key combination for something. What would it do?

Maybe I am missing a great feature which I never discovered so far :D

andi
[OnePlus 3 ROMs, Kernels, Recoveries, & Other Devel] JanNegron:
I think what Pocket Mode do is turn off the sensor, IIRC is the Fingerprint Scanner, when the device is in your pocket. The problem is how to write a code for that, because OnePlus doesn't provided yet.

Sorry if I can said this, but in Sultan kernel, a person provide the code for that feature and its works. You can try to contact him and tell you more about it!
[OnePlus 3 ROMs, Kernels, Recoveries, & Other Devel] sunsettrack4:
The mode disables the fingerprint scanner when the phone is in the pocket, to prevent unnecessary tries to scan a fingerprint, to save battery life.

Sent from my resurrected OnePlus 3 #GetResurrected
[OnePlus 3 ROMs, Kernels, Recoveries, & Other Devel] PunchUp:
If I remember correctly, the main reason this was implemented by OnePlus is because, while in pocket, the fingerprint reader kept waking the phone which caused battery drain and heating. There had been a lot of complaints in OnePlus forums as soon as the phone was launched and hence they did that.
[OnePlus 3 ROMs, Kernels, Recoveries, & Other Devel] ZeNiXxX:
The oos pocketmode is something like that:

When your device is in your pocket your fingersensor ( on cm at the moment) is working all the time. Then you put your hand over the proximity sensor you can still unlock the device. That means that the fingersensor is consuming power all the time. With pocket mode the fingersensor is disable as long the device is in a pocket. That's pocket mode
[OnePlus 3 ROMs, Kernels, Recoveries, & Other Devel] hellcat50:
it basically deactivates the buttons and touch screen

how to test it:

cover the proximity sensor and turn on the phone via power button. the message disappears if proximity gets uncovered

but this mode does not deactivate the fp sensor
[OnePlus 3 ROMs, Kernels, Recoveries, & Other Devel] KaszasM:
[MENTION=947981]Lord Boeffla[/MENTION] so yes without that the fp is always active even if prox. is covered.

any touch wakes the phone, except if you dont have any security set
[OnePlus 3 ROMs, Kernels, Recoveries, & Other Devel] AlkaliV2:
This is the commit they are talking about for CM13 written by myfluxi but not implemented yet. SultanXDA says that pocket mode written by myfluxi is included in his ROM and on by default.

review.cyanogenmod.org/#/c/162420

Basically the problem people are having is facing the screen of the phone towards their leg with pants/shorts that have thin pocket material and the device reading the leg as a finger because the device reads skin as skin. So the phone cannot enter deep sleep in the pocket because the fingerprint sensor is constantly checking to see if your leg matches the fingerprint. OOS did what you were saying and implemented a fix that popped up the message you see in the screenshot preventing the fingerprint from being activated when the proximity detector reads anything close to it. Since CM13 had no such working feature, myfluxi wrote one. But again, as far as I can tell it hasn't been approved. I'll link to Sultan's other statements when I'm back at my computer.

Sultan's post pointing to myfluxi's fix: http://xdaforums.com/showpost.php?p=68708812&postcount=1011

Sultan's Discovery of the Need for Pocket Mode: http://xdaforums.com/showpost.php?p=68754573&postcount=1126

Reference to implemented pocket mode on Sultan's CM13: http://xdaforums.com/showpost.php?p=68286104&postcount=2
[OnePlus 3 ROMs, Kernels, Recoveries, & Other Devel] xanthrax:
That pocket mode (when the top of the screen it's covered) disables the screen touch gestures all together and the fingerprint scanner to prevent the accidentally wake up of the phone but it also disables the fingerprint scanner while the screen is on, just cover the top of the screen and try to use the fingerprint scanner, it doesn't react , this is on oos, I don't know on CM

Does this pocket mode effects the screen touch or only the fingerprint scanner on CM? It would have make more sense to apply it on CM kernels if it effects the screentouch

Sent from my Darkside of Oneplus 3
[OnePlus 3 ROMs, Kernels, Recoveries, & Other Devel] andip71:
Thanks for the many explanations.

So I get the point, this is basically a feature to save some battery only (as fp sensor is off when phone in pocket).

Now the question for users that already tried it - does it really make a difference in real life?

I would be interested to have some comments on the real benefits.

Thanks

Andi
[OnePlus 3 ROMs, Kernels, Recoveries, & Other Devel] zzzhead:
Never tried it before as I don't use oos, but I try not to put my phone in the pocket, as it usually wakes my phone
[OnePlus 3 ROMs, Kernels, Recoveries, & Other Devel] v7:
There used to be an issue with the fingerprint scanner false triggering while in pocket causing 'fpc_ttw_wl' wakelock.This wakelock used to drain a lot.

With the pocket mode,this issue was resolved.

Pocket Mode is already available in OOS,but for CM,kernel side changes are needed to implement this feature.

__

v7

Forum Moderator
[OnePlus 3 ROMs, Kernels, Recoveries, & Other Devel] andip71:
Ok, so if someone could give me some facts (numbers for drain, with and without this patch), I would consider looking at it again.

But only if it really pays off massively, I do not like this patch at all.

Andi
[OnePlus 3 ROMs, Kernels, Recoveries, & Other Devel] andip71:
Ok, I did some R&D on the pocket mode implementation this morning and here are the results:

After reviewing the code again + trying the raw functionality, I might consider it for the next update.

However, what I do not like is:

This requires an additional app that is not part of CM but only custom roms like the mentioned ones.

So I want to ask: How big is the demand to have this feature also in CM? If the demand is high enough, I would quickly code a companion app that enables this feature also on vanilla CM. But as this is maybe 1-2 hours work, I only do it when there is demand. I am personally using OOS as my daily driver, so I have no need for it really.

Curious now...

Andi
[OnePlus 3 ROMs, Kernels, Recoveries, & Other Devel] zzzhead:
It would be a fair useful feature for me!
[OnePlus 3 ROMs, Kernels, Recoveries, & Other Devel] andip71:
Ok, thanks for the opinion.

I - by the way - believe this is only a temporary thing anyways. I would expect CM team to come around the corner with somethin as well in future.

So I want to keep efforts as low as possible as it is likely to be for the trash not too far away again :)

Andi
[OnePlus 3 ROMs, Kernels, Recoveries, & Other Devel] andip71:
*** Pocket mode poor-man's workaround topic ***

Let's make it simpler for you - here is an official poll for it:

http://www.easypolls.net/poll.html?p=57fdfdb5e4b0a54546788162

Tell us your opinion.

Andi
[OnePlus 3 ROMs, Kernels, Recoveries, & Other Devel] KaszasM:
thanks for the poll,

cant you cook a 1or2releases pure + 1 with pocket mode?

i belive you and would keep it clean but :

i dont use any lock on my phone so wouldnt be importent ,

but if i would use 1 i couldn't even :)

i remember i had my phone screen out in my pocket to not have it always screen on because

the battery drain was horror (depens on the jeans) if you move like 15%/h..

as i wrote earlier every touch wakes the phone+screen. even if you try to pull out from your pocket...

but your choice anyway i think you do your best and i would listen, but clearly sad i would only NOT import that if its causing any bugs breaks.... but for everyone how uses FP is a must have no question...

but your choice just keep the level XD
[OnePlus 3 ROMs, Kernels, Recoveries, & Other Devel] andip71:
I am not going even for multiple kernel variants. With having 11 active kernels for 6 devices out, this is not doable anymore for me.

Andi
[OnePlus 3 ROMs, Kernels, Recoveries, & Other Devel] zzzhead:
On an unrelated note, recently I have this issue, but unsure if it is kernel related.

The time displayed is 9.41pm, where	by the actual time is actually later 9.48pm as reflected by the network time..
[OnePlus 3 ROMs, Kernels, Recoveries, & Other Devel] andip71:
This is not kernel related.

Time is fully handled on rom level.

Andi
[OnePlus 3 ROMs, Kernels, Recoveries, & Other Devel] andip71:
By the way... my companion app to allow pocket mode also on original CM roms (and roms that do not have the feature built in) is ready.

I just pushed it to Google Play store. As soon as it shows up I will also release beta10 of the kernel, which adds this feature.

This means, people using a custom rom with this functionality built in (e.g. Sultans CM afaik) do not need my app of course.

Everyone on a rom without pocketmode support can install my small companion app (below 70 kb size) to add this feature as well.

Reason for this decision was the current standings of the poll, see attached pic.

So - stay tuned !!! :)

Andi
[OnePlus 3 ROMs, Kernels, Recoveries, & Other Devel] KaszasM:
[MENTION=947981]Lord Boeffla[/MENTION] grats for the GREAT solution :)

and thanks to give support/time/energy for some unofficial change :)

just push the kernel so we can test it just to be sure its stable until the app arrives [emoji1] [emoji1] [emoji1]
[OnePlus 3 ROMs, Kernels, Recoveries, & Other Devel] andip71:
Hi all,

kernel update to implement the many times wished "pocket mode".

Version

1.0-beta10

12.10.2016

New: Implemented "pocket mode" for CM13

Note, this is only a workaround solution (or how Fluxi himself called it - poor man's pocket mode), that requires additionally a custom rom that support this feature (e.g. Sultans CM).

If you do use original CM (like me) or another rom that does not support pocket mode feature from rom side, install my own little companion app from Google Play Store to achieve the same functionality (start app once, grant root access and external write access, done).

Boeffla CM Pocketmode companion app in Play Store

Enjoy

Andi
[OnePlus 3 ROMs, Kernels, Recoveries, & Other Devel] KaszasM:
just to confirm it works on RR rom thank you
[OnePlus 3 ROMs, Kernels, Recoveries, & Other Devel] Berlino:
And pocket mode works on official cm13 as well with latest kernel and app. :good:
[OnePlus 3 ROMs, Kernels, Recoveries, & Other Devel] ZeNiXxX:
Thank you for the update and sry for making you stress with the pocketmode. I don't know that it would make such a "argumention" about 2 pages.
[OnePlus 3 ROMs, Kernels, Recoveries, & Other Devel] zzzhead:
Installed and using.

Some feedback - Added the app to exclusion from doze, after leaving the phone for a bit, fingerprint unlock seems to be disabled, even out of pocket.

It functions as intended only during the first few minutes after screen off.

Edit

Test case 1

Screen off wait 5 sec, attempt fingerprint unlock

Takes more time than usual (normally it takes 1 sec or immediately), phone unlocks

Test case 2

Screen off block sensor, attempt fingerprint unlock

Fingerprint unlock does not work when sensor is covered

Test case 2.1

Continuation from case 2, attempt to unlock phone using fingerprint after unblocking sensor

Fingerprint unlock does not work
[OnePlus 3 ROMs, Kernels, Recoveries, & Other Devel] andip71:
Hi and good morning,

here my first comments:

1) I cannot replicate your results. I have doze active, added the app to the doze exclution list under battery optimisations. I cover the proximity sensor and let the phone ly around for 30 minutes. Then I try to use fingerprint when still covered -> no function as intended. Then I uncover the phone, voila, fingerprint working for me.

2) From theory: An app developer can do zero when Doze decides to suspend an app after a while. But as said, does not seem to be the case for me.

3) Doze is one of the worst inventions Google ever did (this is my personal opinion), so I anway have all my phones running with disabled Doze. It only creates a hell of issues everywhere while not saving any significant juice. I recommend to switch it off for long time (can be done in Boeffla-Config or there is even a specific app in play store by me to do that).

To your test cases:

Test case 1:

- fingerprint performance is fully independent of this control. And it is also not being slower at all on my side. Which is logical.

Test case 2:

- Correct, this is how it should be.

Test case 2.1:

- it does work for me

So - something else seems to either put the app to suspend or blocking intents after a while.

What you can do: Enable logging in the app, redo your tests (with noting exact timing), then we could try to analyze if the app is going to suspend on your phone after a while.

As I cannot replicate any of your behaviours I have to ask - anywhere else facing the same?

Thanks

Andi
[OnePlus 3 ROMs, Kernels, Recoveries, & Other Devel] zzzhead:
Same result for me.

I noticed an anolomy on the logs

13.10.2016-16.49.38: ProximitySensor: pocketmode set to off 13.10.2016-16.49.39: ProximitySensor: pocketmode set to on 13.10.2016-16.49.39: ProximitySensor: pocketmode set to off 13.10.2016-16.49.42: ProximitySensor: pocketmode set to on 13.10.2016-16.49.42: ProximitySensor: pocketmode set to off 13.10.2016-16.49.45: ProximitySensor: pocketmode set to on 13.10.2016-16.49.45: ProximitySensor: pocketmode set to off 13.10.2016-16.49.47: ProximitySensor: pocketmode set to on 13.10.2016-16.49.47: ProximitySensor: pocketmode set to off 13.10.2016-16.49.49: ProximitySensor: pocketmode set to on 13.10.2016-16.49.49: ProximitySensor: pocketmode set to off 13.10.2016-16.49.50: ProximitySensor: pocketmode set to on 13.10.2016-16.49.50: ProximitySensor: pocketmode set to off 13.10.2016-16.49.51: ProximitySensor: pocketmode set to on 13.10.2016-16.49.51: ProximitySensor: pocketmode set to off 13.10.2016-16.49.53: ProximitySensor: pocketmode set to on 13.10.2016-16.49.54: ProximitySensor: pocketmode set to off 13.10.2016-16.50.01: ProximitySensor: pocketmode set to on 13.10.2016-16.50.23: ProximitySensor: pocketmode set to off 13.10.2016-16.50.27: ProximitySensor: pocketmode set to on 13.10.2016-16.50.27: ProximitySensor: pocketmode set to off 13.10.2016-16.50.31: ProximitySensor: pocketmode set to on 13.10.2016-16.50.32: ProximitySensor: pocketmode set to off 13.10.2016-16.50.36: ProximitySensor: pocketmode set to on 13.10.2016-16.50.36: ProximitySensor: pocketmode set to off 13.10.2016-16.50.38: ProximitySensor: pocketmode set to on 13.10.2016-16.50.39: ProximitySensor: pocketmode set to off 13.10.2016-16.50.39: ProximitySensor: pocketmode set to on 13.10.2016-16.50.40: ProximitySensor: pocketmode set to off 13.10.2016-16.50.41: ProximitySensor: pocketmode set to on 13.10.2016-16.50.41: ProximitySensor: pocketmode set to off 13.10.2016-16.50.43: ProximitySensor: pocketmode set to on 13.10.2016-16.50.43: ProximitySensor: pocketmode set to off 13.10.2016-16.50.45: ProximitySensor: pocketmode set to on 13.10.2016-16.50.45: ProximitySensor: pocketmode set to off 13.10.2016-16.50.45: ProximitySensor: pocketmode set to on 13.10.2016-16.50.46: ProximitySensor: pocketmode set to off 13.10.2016-16.50.46: ProximitySensor: pocketmode set to on 13.10.2016-16.50.46: ProximitySensor: pocketmode set to off 13.10.2016-16.50.59: ProximitySensor: pocketmode set to on 13.10.2016-16.51.00: ProximitySensor: pocketmode set to off 13.10.2016-16.51.02: ProximitySensor: pocketmode set to on 13.10.2016-16.51.03: ProximitySensor: pocketmode set to off 13.10.2016-16.51.04: ProximitySensor: pocketmode set to on 13.10.2016-16.51.05: ProximitySensor: pocketmode set to off 13.10.2016-16.51.05: ProximitySensor: pocketmode set to on 13.10.2016-16.51.05: ProximitySensor: pocketmode set to off 13.10.2016-16.52.02: ProximitySensor: pocketmode set to on 13.10.2016-16.52.06: ProximitySensor: pocketmode set to off 13.10.2016-16.52.09: PocketModeService: Display on - proximity sensor disabled
[OnePlus 3 ROMs, Kernels, Recoveries, & Other Devel] andip71:
Hi all,

maintenance update is out.

Version

1.0-beta11

12.10.2016

Update: Updated with latest official CM kernel commits as of 17.10.16, 8am CET

Enjoy

Andi
[OnePlus 3 ROMs, Kernels, Recoveries, & Other Devel] andip71:
** Looking for some user help... **

Hi all,

as you have noticed in the past days, I was very reluctant to put the pocketmode code in, which has been developed in other kernels. Reason is, I am not very happy about how "heavy" this change is and how it hooks into interrupt control of the fingerprint sensor.

In the end I did to make some people happy that use CM13 as their daily driver.

However, after trying to port this to the OP2 I found there a very lean solution which I am very happy with. And I was able to apply this also for the OP3 finally.

Now, I wonder of course, why other devs have created such a big change when my little and lean change would do as well. So, I am really searching for the catch now.

In order to help me, I would like to ask people that are currently happily using pocketmode with a supporting rom (or my app) and my kernel, to try an experimental kernel version I can make available for them.

This kernel version has now my very lean implementation built in, instead of the heavy changes I took from another kernel.

And I really would appreciate if 1 or 2 people could help testing whether they run into any issues with my new implementation of the driver.

If you this all applies to you and you are willing to test, please drop me a mail on support@boeffla.de

Many thanks

Andi
[OnePlus 3 ROMs, Kernels, Recoveries, & Other Devel] hellcat50:
send me the link :good:
[OnePlus 3 ROMs, Kernels, Recoveries, & Other Devel] andip71:
-- deleted --
[OnePlus 3 ROMs, Kernels, Recoveries, & Other Devel] KaszasM:
send i can test it too_bin auch dabei :)

actually i deleted the PM app in the RR rom i had some screenfreezes needed to turn off and on, but now with your app seems like it running fine again

possible my PM was implemented from the RR maintainer maybe bit different coding in kernel-app..
[OnePlus 3 ROMs, Kernels, Recoveries, & Other Devel] andip71:
Sorry, but as I mentioned, I need you to drop me a mail. Then you can join testing of course.

Thanks

Andi
[OnePlus 3 ROMs, Kernels, Recoveries, & Other Devel] ZeNiXxX:
Hi Andi,

after testing your kernel with pocketmod i noticed some things (not only related to pocketmode)

first: Sometimes when i unlock my device and an app is open my screen is brigth and than it automatically change the brightness level. I'm not sure but i would say that the konstrast is always being set again when unlocking device. My Keyboard is totally bright after unlocking than it gets darker. Just wanted to say i dont know if its kernel related.

second. Sometimes the home/fingersensor-button isnt working. Its just not reacting. I have to lock and unlock the display than the home button works again.

that are the only things that i noticed. The rest is awesome as always.

And ohh i just forget to ask you to include advanced settings for io sheduler in your app. I always mod the zen sheduler to get better performance and batterylife.
[OnePlus 3 ROMs, Kernels, Recoveries, & Other Devel] fantamadnesss:
[MENTION=947981]Lord Boeffla[/MENTION] No bugs noticed for now.
[OnePlus 3 ROMs, Kernels, Recoveries, & Other Devel] andip71:
Hi,

the contrast thing is certainly not something coming from the kernel.

At least not something I built in or changed. It might be some adaptive brightness stuff, dont know, I have never experienced that.

Fingerprint/Homebutton: Are you using pocket mode, is it since then or was it already before?

If you use pocket mode, are you using with a custom rom or using my app?

Here I would need much more input please.

Tunables for schedulers: Thought I answered already, I am not planning that as this is so much effort for so limited use. I would say your personal script in Boeffla-Config or an init.d script would serve you well.

Andi
[OnePlus 3 ROMs, Kernels, Recoveries, & Other Devel] andip71:
Hehe. Good.

But I am convinced that will change over the time.

Still, feel free to use it.

Andi
[OnePlus 3 ROMs, Kernels, Recoveries, & Other Devel] Phelicks:
Is this kernel better than the firm RR kernel in terms on battery life?

Отправлено с моего ONEPLUS A3000 через Tapatalk
[OnePlus 3 ROMs, Kernels, Recoveries, & Other Devel] andip71:
Not sure someone will give you an answer, we usually do not compare kernels in kernel threads :)

Andi