yashsingh1/xdaforums huggingface dataset:
[HTC U11  ROMs, Kernels, Recoveries, & Other Develo] tbalden:
The uci_user.cfg config file had to be zipped, unzip to copy it to sdcard usage. Uploaded to the folder. (here is the individual link: https://www.androidfilehost.com/?fid=745849072291688136 )
[HTC U11  ROMs, Kernels, Recoveries, & Other Develo] Whiskey103:
I have this in the default one:

proximity=0

ringing=0

silent=0

locked=0

lock_timeout=0

But this values are not in the file you upload nor in example config.

They still need to be there?

Edit: perhaps it's the companion "state" to look into from kernel right?
[HTC U11  ROMs, Kernels, Recoveries, & Other Develo] tbalden:
Yes, exactly, UCI user config is the one to edit. It's uci_user.cfg

And yes the other is uci_sys.cfg that's for the application to write.
[HTC U11  ROMs, Kernels, Recoveries, & Other Develo] Whiskey103:
There is a setting to enable button backlight?

It used to be always on and now they don't, not even when touched.
[HTC U11  ROMs, Kernels, Recoveries, & Other Develo] tbalden:
Bln button light level 20 means fully off. Seems like I uploaded with that, I prefer that mode, but set it back to 6 for default

bln_light_level=6

Sorry, small mistake
[HTC U11  ROMs, Kernels, Recoveries, & Other Develo] Whiskey103:
Ahh lol, explains it [emoji106]
[HTC U11  ROMs, Kernels, Recoveries, & Other Develo] tbalden:
If you have es file explorer you can easily link UCI user config to es text editor, then put it to home desktop. Easy editing and application... Just edit and save
[HTC U11  ROMs, Kernels, Recoveries, & Other Develo] tetrabyt:
In the included uci_user. cfg, Is that supposed to be

bln_no_charger_switch

Or

bln_on_charger_switch ?

Also, there is a typo in the permissions/donation screen. First instead of fist...

After allowing permissions, is the app supposed to move on past that screen?
[HTC U11  ROMs, Kernels, Recoveries, & Other Develo] Whiskey103:
What I have :

# Buttonlight

bln=1

bln_light_level=5

bln_no_charger_switch=1

bln_number=0

bln_speed=1

bln_dim_blink=1

bln_dim_number=0

bln_rgb_batt_colored=0

bln_rgb_light_level=0

bln_rgb_pulse=1

bln_rgb_pulse_pattern=0
[HTC U11  ROMs, Kernels, Recoveries, & Other Develo] tbalden:
No, that is all in the app, it's a background kinda service, so you can leave it with a back.

Might change later, but that's all for now. I don't plan to make it a settings app, it's lightweight to stay in memory easily. If I poke into settings, it's going to be a second app

It's Bln no charger, just like in the second post the sysfs, it's to enable Bln even when not on charger.

Thanks for the typo report, I'll fix it :)
[HTC U11  ROMs, Kernels, Recoveries, & Other Develo] Whiskey103:
So far no issues to report for me.

Everything looks solid.

New configuration system works like a charm really.

Perhaps it's now possible to get a DND overwrite configuration like :

#DND State Overwrite:

dnd_overwrite 0/1

bln_flash 0/1

led_blink 0/1

flash_blink 0/1

Basically, DND On = no blinking whatsoever.

Something, just thinking out loud here ofcourse.
[HTC U11  ROMs, Kernels, Recoveries, & Other Develo] tbalden:
These are for that:

smart_silent_mode_stop=1

smart_silent_mode_hibernate=1

Especially the last set, will stop almost all notification forms, except led but it's going to be dimmed when you set DND / silent mode

Here's detailed the three smart modes which were started by inactivity so far, but now you can set them to activate on DND https://xdaforums.com/showpost.php?p=74412439&postcount=1292
[HTC U11  ROMs, Kernels, Recoveries, & Other Develo] Whiskey103:
so, what exactly will those do?

smart_silent_mode_stop=1

smart_silent_mode_hibernate=1

Kinda lost in all the settings/options lol :laugh::p
[HTC U11  ROMs, Kernels, Recoveries, & Other Develo] tbalden:
If you set the stop to 1 and hibernate 0 then switching to DND mode will cut back a few notifications already.

If you set hibernate 1 then DND will stop KAD,bln, flash, notification booster, vibrating reminder and dims rgb led.

Leaving DND status will set back all as you specified otherwise

Check the linked post for all the modes. Silent = DND

So just set them both 1 and you'll have exactly your suggestion working
[HTC U11  ROMs, Kernels, Recoveries, & Other Develo] Whiskey103:
ahh, well not exactly what i had in mind but close.

Ill go with that, its close enough :good:
[HTC U11  ROMs, Kernels, Recoveries, & Other Develo] tbalden:
Cool

OK, so what's missing, differs? At some point I'll consider adding more settings for smart mode levels
[HTC U11  ROMs, Kernels, Recoveries, & Other Develo] Whiskey103:
For example, if possible in my case.

At night, sleeping, whatever.

On DND, have options to get notifications separated.

Split in:

Camera flash on/off

BLN on/off

Led on/off

So phone is laying face down, cam flash off, rest can stay on since not lighting up the room anyway. Etc. You get what I mean ;)

Basically, let me pick what notifications are active in DND mode.
[HTC U11  ROMs, Kernels, Recoveries, & Other Develo] tbalden:
OK, then configuring the modes silent can trigger is something equal.

If I make it configurable which notifications are cut in stop and hibernate mode, then that's possible.

I didn't want to overdo config as it's already quite a lot, but this was something I considered as candidate for configuration..
[HTC U11  ROMs, Kernels, Recoveries, & Other Develo] Whiskey103:
Yea, I understand hehe.

It's hard to keep track of all the options already present [emoji1]

One other thing, if you eventually become bored, look into blocking the pull down statusbar on lockscreen by disabling the top 10 percent of the screen.

Or ignore input there, whatever is possible on kernel/driver level.

But since you now have a way to know phone state on kernel level :)

Again, just thinking out loud.
[HTC U11  ROMs, Kernels, Recoveries, & Other Develo] tbalden:
beta2 - found a missing settings from new configuration method...also working on a unified installer for Kernel + App + Sample config...
[HTC U11  ROMs, Kernels, Recoveries, & Other Develo] tbalden:
yep, that's now a thing possible. Good, good! :D I liked this back when you mentioned, but now it's possible indeed, knowing lockscreen is there :good:
[HTC U11  ROMs, Kernels, Recoveries, & Other Develo] tbalden:
Update 2.6.0 beta2​

Changes:

- unified installer: TWRP zip Installs kernel and copies companion APK / sample config to your /sdcard/

After installation you should Reboot, install kernel companion APK manually from sdcard, and rename uci_user.cfg_sample to uci_user.cfg for no root kernel config... or merge if you already have one in place.

- added a left-out config parameter for uci_user.cfg configuration (this is the squeeze power starting from 0 to 9 under which if you set Edge Sense configuration, Cleanslate squeeze control feature will be enabled:

---- squeeze_power_kernel_max_threshold=1

Download:

https://www.androidfilehost.com/?fid=673791459329060877
[HTC U11  ROMs, Kernels, Recoveries, & Other Develo] sttw1fa:
Hopefully not too stupid of a question....is the above process the same for a Leedroid user setup with Magisk?

Been lurking through all the new work you've done....sounds like a good time to jump in. :)
[HTC U11  ROMs, Kernels, Recoveries, & Other Develo] p50kombi:
Hiya matey..

I've found a bug on your dimming led feature when hibernate is set and dnd.

The led is dimmed when charging, but when fully charged it starts pulsing at normal brightness again..;)

Does that make sense [MENTION=3088420]tbalden[/MENTION] lol

Bit early,got woken by a bright pulsing led...Hehe
[HTC U11  ROMs, Kernels, Recoveries, & Other Develo] tbalden:
Yep, gonna check this. Thanks for reporting
[HTC U11  ROMs, Kernels, Recoveries, & Other Develo] tbalden:
Yes, magisk or any other rooting or no root, same installation process.

Let me know how it goes if you try it
[HTC U11  ROMs, Kernels, Recoveries, & Other Develo] tbalden:
question: is it sure that in the morning your phone was still in DND mode? I'm suspecting something around that, as the code seems to be ok. Gonna do a test charge round in DND right now.
[HTC U11  ROMs, Kernels, Recoveries, & Other Develo] p50kombi:
Yeah it was, when I changed the led brightness manually to 15 it dimmed again
[HTC U11  ROMs, Kernels, Recoveries, & Other Develo] tbalden:
OK. Thx

Couldn't manage a full quick charge in the morning, so I'll need to test it still.

It's gonna be something around a bug while reading up the data about still being in DND mode.
[HTC U11  ROMs, Kernels, Recoveries, & Other Develo] tbalden:
meh, can't reproduce :S

can you test it a second time, charge full, and switch to DND please. Thx... maybe it's a temporary thing, and I may have a kind of solution to make this more reliable.
[HTC U11  ROMs, Kernels, Recoveries, & Other Develo] p50kombi:
okiedokie..testing now.. :)

---------- Post added at 11:27 AM ---------- Previous post was at 10:44 AM ----------

Went ok now...

Strange, will keep an eye in it.
[HTC U11  ROMs, Kernels, Recoveries, & Other Develo] tbalden:
Ok, thanks! Will change this part to a "push the change to driver" type of mechanism, instead of pull by driver to know if it's changed... But seems like it's a sync issue, I'll check if the read write mutex is good enough or not..
[HTC U11  ROMs, Kernels, Recoveries, & Other Develo] tbalden:
Lockscreen disabling top 10 -> unfortunately not so easy, if you touch the notifications part it will auto pull down first in mini version. after that you can pull it further...
[HTC U11  ROMs, Kernels, Recoveries, & Other Develo] android_patrizian:
Just playing around with the configuration file. Great. What an amount of time you put in this. Thanks a lot.
[HTC U11  ROMs, Kernels, Recoveries, & Other Develo] tbalden:
Update 2.6.0 beta3​

Changes:

- adding Laptop/Legacy chargers "fastcharge" feature to test how it goes with different laptops (I'm not sure if this actually does anything on my laptop, but i plan to test with more)

--- uci user config entry: fastcharge=1 (0/1)

- adding "Vibrate long twice even in silent mode upon phone Call" option through UCI user config. If you switch to silent mode on Stock Sense android, you cannot leave still call vibrations on. (I wanted this option, so here it is :) Works only with fully running CleanSlate Companion app installed and started!)

--- uci user config entry: phone_ring_in_silent_mode=0 (0/1) - if set to 1, will vibrate twice upon phone call in Silent DND mode.

Fixes:

- fixing Silent mode Smart Notification Stop/Hibernate stage triggering (with "listening to change event" pattern instead using the repeated pulling of silent state) thanks [MENTION=271041]p50kombi[/MENTION] for reporting this.

- fixing Lockscreen timeout measurement bug, leading to not showing KAD screen even when lockscreen is already on -- after a screen off + "lockscreen-on timeout" ended

Download:

https://www.androidfilehost.com/?fid=673791459329061033

Earlier beta posts, for installation of beta instructions and all the buzz:

Beta 1

https://xdaforums.com/u11/development/kernel-cleanslate-v1-0-t3623310/post74488246#post74488246

Beta 2

https://xdaforums.com/showpost.php?p=74494984&postcount=1355
[HTC U11  ROMs, Kernels, Recoveries, & Other Develo] LeeDroid:
Whoop whoop! :highfive:
[HTC U11  ROMs, Kernels, Recoveries, & Other Develo] tbalden:
:good::cool:

:laugh:
[HTC U11  ROMs, Kernels, Recoveries, & Other Develo] tbalden:
Thank you for the feedback. I'm happy that now it's instantly possible to tweak stuff without rooting and without a complex application.

I hope the second post in the thread explains the options well :good:
[HTC U11  ROMs, Kernels, Recoveries, & Other Develo] tbalden:
Check guys the beta 3, I can see the stable version bump soon. I cannot really find anything that pops out as a problem that blocks
[HTC U11  ROMs, Kernels, Recoveries, & Other Develo] tbalden:
And BTW thanks a lot to those who donated to my coffee and beer fund, much appreciated!!

Going to add the new xda enthusiasts to the donators hall of fame very soon
[HTC U11  ROMs, Kernels, Recoveries, & Other Develo] The Great Dane:
To be quite frank and this ain't going to be nice, trust me it's going to be a ban........

YOU ROCK MAN!!!!!!!

Have a whoop whoop on me 2BA96118CA6471325
[HTC U11  ROMs, Kernels, Recoveries, & Other Develo] p50kombi:
More awesomeness...well done matey..

I do ahve a small favor to ask, I don't use UCI file as I switch some configs on the fly depending on time of day (like LED brightness etc.) and I have everthing setup in ExKM anyway.

I can't seem to find your latest phone vibration in dnd in the sysfs fpf folder though, where did you hide those :)

also can't find /sys/fpf/fpf_unlock_vib_strength [MENTION=3088420]tbalden[/MENTION]
[HTC U11  ROMs, Kernels, Recoveries, & Other Develo] tbalden:
:laugh::highfive::highfive:

BTW the transaction id I cannot find in my history, let's hope it went to a good charity :)
[HTC U11  ROMs, Kernels, Recoveries, & Other Develo] tbalden:
The former is yes I'll check to add (BTW you can mix the two configuration till then just leave only the needed parameter in the file). Will add

The latter is bug then will check
[HTC U11  ROMs, Kernels, Recoveries, & Other Develo] p50kombi:
I was testing it by running the script in elementalx script manager and it doesn't work for some reason.

After reboot the values are set correctly to 0 though, so looks like it's a problem running the script from the script manager..

Thanks again for your help :)
[HTC U11  ROMs, Kernels, Recoveries, & Other Develo] tbalden:
great, that it worked out. :good:

I'm still testing the functionality, and later today i'll be fathoming if i could make it optional some way without reinstalling the kernel or requiring root / scripts... :)
[HTC U11  ROMs, Kernels, Recoveries, & Other Develo] tbalden:
Yeah, same here. Depending on what Im doing, simple squeeze can be quite convenient.

Especially when just reading stuff and not typing.
[HTC U11  ROMs, Kernels, Recoveries, & Other Develo] tbalden:
Update 1.5.1

Feature changes:

- in-kernel Squeeze-to-wake/sleep: now it depends on the Edge Sense minimum squeeze power level set by the user, if in-kernel squeeze-to-wake/sleep is active

--- Explanation: this way, on your unrooted phone, simply flashing this kernel, setting up Edge Sense the way described AND setting the minimum squeeze power level to MINIMUM (level 1 out of the 10) will switch the feature ON, setting minimum power level 2 or above will switch it OFF.

--- So even without root or any third party app, just using HTC's Edge Sense settings you can switch it ON and OFF. (check screenshots attached, for clarity) (Thanks [MENTION=271041]p50kombi[/MENTION] for raising the question/issue)

Bugfix: tuning squeeze detection to avoid false positives where screen turns off inadvertently.

Download:

https://www.androidfilehost.com/?fid=889764386195921848

Screenshot attached shows what additional thing to set to make sure the in-kernel Squeeze-To-Wake/Sleep still works with version cleanslate 1.5.1

Full squeeze to sleep/wake set up description HERE
[HTC U11  ROMs, Kernels, Recoveries, & Other Develo] tbalden:
[MENTION=8395457]velimirchek[/MENTION] so this about passing safetynet... If my phone is not rooted and without custom ROM I don't need magisk hide to pass the test.

I also only temp boot twrp when flashing kernel leaving stock recovery intact.

All this because I'm fine with official rom too, and I can update with ota anytime :)
[HTC U11  ROMs, Kernels, Recoveries, & Other Develo] velimirchek:
thanks for explanation, I knew that :), just thought something changed since I was last time unrooted on stock :)
[HTC U11  ROMs, Kernels, Recoveries, & Other Develo] tbalden:
Actually this didn't check out initially, I left out the patch needed till 1.5 that's the only change
[HTC U11  ROMs, Kernels, Recoveries, & Other Develo] velimirchek:
LoL, I feel like "lost in translation" :).. :D

I know you added it in 1.5, but CPTB answered in the other thread that only way to pass SafetyNet is with Magisk so I thought Sultans patch stopped working even with stock rom, custom kernel and no root

All clear now and thanks for the efforts..

now let's fix custom kernels on 1.27 base :p hehe.. I am running now 1.27 base with stock signed 1.03 kernel and haven't noticed any micro lags yet, so there "must" be a comitt that all three custom kernels use (cc [MENTION=3428502]Freak07[/MENTION] [MENTION=4684315]flar2[/MENTION]) that causes micro lags.. because kernel sources are 1.03.. or maybe I am totally wrong :) or we need to have some beer :p
[HTC U11  ROMs, Kernels, Recoveries, & Other Develo] tbalden:
Hmm, I don't patch anything related to performance or governor or remotely attached to core functionality. I'm confused...
[HTC U11  ROMs, Kernels, Recoveries, & Other Develo] velimirchek:
I'm even more confused, you have knowledge and I don't :crying:.. [MENTION=3428502]Freak07[/MENTION] cheked my dmesg and logcats and also couldn't find anything wrong

so, beer time :D
[HTC U11  ROMs, Kernels, Recoveries, & Other Develo] tbalden:
Agreed, on the beer :D

BTW I've asked [MENTION=398245]LeeDroid[/MENTION] about his experience with stutters, he didn't mention it with cleanslate, tho he is over a mega session of merging the new base, so let's not bother him with his experience on micro stutters for now. :D

I hope it's gonna roll out officially in the coming days so I can test it myself as well, I'm too stubborn keeping the phone almost stock lol
[HTC U11  ROMs, Kernels, Recoveries, & Other Develo] guidogsbn:
on Lee´s newest version 45 with your kernel I miss the squeeze to wake/sleep functions. I have chosen the minimum sensitivity option, but short press does nothing :

no wake, no sleep (as I have disabled short press function even nothing else happenes.)
[HTC U11  ROMs, Kernels, Recoveries, & Other Develo] tbalden:
Thanks for reporting

Hmm, is it working on previous version 1.5.0?

Maybe vibration length changed in new base...

Can you grab a dmesg kernel log maybe?
[HTC U11  ROMs, Kernels, Recoveries, & Other Develo] velimirchek:
works fine over here on MHD2.0.0 and CS1.5.1
[HTC U11  ROMs, Kernels, Recoveries, & Other Develo] guidogsbn:
Thank you, I hope that helps...
[HTC U11  ROMs, Kernels, Recoveries, & Other Develo] tbalden:
Thanks!

Could you please grab another one, grabbed when you are setting the Squeeze Power level in Settings/Edge Sense, to the first level?

It seems that the problem is with that on LeeDroid rom, when the squeeze power is changed, it doesn't set up things as it should...

(as on maximushd it works, as [MENTION=8395457]velimirchek[/MENTION] confirmed a few minutes back here)

I'm looking for a line like this: "... squeeze call new_level power ..."
[HTC U11  ROMs, Kernels, Recoveries, & Other Develo] p50kombi:
Maybe [MENTION=398245]LeeDroid[/MENTION] can shed some loght on this? :D
[HTC U11  ROMs, Kernels, Recoveries, & Other Develo] LeeDroid:
[12516.981178] c1 3655 register_squeeze_power_threshold_change squeeze call new_level power 3 max level 0 power 171
[12518.057888] c4 3655 nanohub: edge_threshold = 100
[12518.057896] c4 3655 register_squeeze_power_threshold_change squeeze call new_level power 0 max level 0 power 100

No issues here
[HTC U11  ROMs, Kernels, Recoveries, & Other Develo] tbalden:
Looks good to me.
[MENTION=2344619]guidogsbn[/MENTION] are you testing the squeeze in the settings screen or after exiting it?
[HTC U11  ROMs, Kernels, Recoveries, & Other Develo] guidogsbn:
So got another log, sorry, was at work
[HTC U11  ROMs, Kernels, Recoveries, & Other Develo] p50kombi:
So am I correct to assume the UCI only sets it at boot, if you use EXKM after that, it uses the value you set in exkm?

Or does the companion app keep reading the uci and keep resetting it to those values?

For instance, if I manually change the charging LED brighness with a script at night, does it revert back to the uci value again?
[HTC U11  ROMs, Kernels, Recoveries, & Other Develo] tbalden:
Ok, so let me clear up: Companion App is only writing uci_sys.cfg which is not to be edited.

uci_user.cfg if in place /sdcard/uci_user.cfg, the lines in it (and only those) will be overwriting the sysfs set values, no matter when you set it through sysfs, the config always precedes.

So kernel continuously uses the file's given properties, and based on a filesystem notification listening I added to kernel, will read it upon change.

The lines not included/removed are falling back to sysfs values.
[HTC U11  ROMs, Kernels, Recoveries, & Other Develo] p50kombi:
ok thanks, that clears it up.

So in my case I need to make sure to delete the uci_user.cfg after every flash as it will override my personal settings I use in exkm.

And since I change those values automatically during the course of the day with various scripts, I need to make sure that file is not there.

Does the companion app function without the uci_user.cfg to read locked states and in pocket etc?

Sorry for the many questions, I just customised my device pretty hefty with automagic to do different things during different times of the day :)

btw.. have a cuppa on me:

0AU362817J771422X
[HTC U11  ROMs, Kernels, Recoveries, & Other Develo] tbalden:
Thanks for the cuppa! :good::good:

The installer doesn't add the file into the working place, it just adds an uci_user.cfg_sample that is not live.

Also yes, for the Companion app, no need for the user cfg file.
[HTC U11  ROMs, Kernels, Recoveries, & Other Develo] The Great Dane:
Anything else you wanna complain about?

Actually just trying to be nice :crying:
[HTC U11  ROMs, Kernels, Recoveries, & Other Develo] tbalden:
Sorry, my friend, didn't want to sound like complaining. :crying: I was just not sure if that was you, and wanted to help you to be aware if something went wrong.

So again, thanks for the donation, very much appreciating also thanks for testing and your great feedback, and all around cheering up things! :highfive: :victory:
[HTC U11  ROMs, Kernels, Recoveries, & Other Develo] tbalden:
TEST AND REPORT!!! Stable release impending :)

:good:
[HTC U11  ROMs, Kernels, Recoveries, & Other Develo] p50kombi:
Uhm.... Test and Report what exactly? Lol

Only thing I can't find are those sysfs settings to set in kernel, other than that all looks good :)
[HTC U11  ROMs, Kernels, Recoveries, & Other Develo] tbalden:
I know, it's just unbelievable that I'm so good at this.

???

And you did your part already, thank you for the report.

One last thing I plan to add, actually two into stable

- possibility to tune kcal grayscale parameters for kernel ambient display, so we can find the best readability high contrast setting for the two interesting parameters kcal magic value and contrast.

- UCI interface for unboosted vibration voltage
[HTC U11  ROMs, Kernels, Recoveries, & Other Develo] tbalden:
ok, for the unlock vib strength, it's this, instead of fp_unlock_vib_strength /sys/fpf/unlock_vib_strength
[HTC U11  ROMs, Kernels, Recoveries, & Other Develo] p50kombi:
Found it, only one left now is vibrate when phonecal in DND
[HTC U11  ROMs, Kernels, Recoveries, & Other Develo] tbalden:
Thats done in git just now. Working in some more stuff, gonna upload them together in one last beta it stable...
[HTC U11  ROMs, Kernels, Recoveries, & Other Develo] tbalden:
More new features for tomorrow's stable, ready, under testing :

- adding "Block power button when in pocket (proximity sensor triggers)"

--- uci user config entry: block_power_key_in_pocket=0 (0/1) - if set to 1, will block power button turning on when in proximity (pocket, face down, your head talkin' :) )

--- /sys/fpf/block_power_key_in_pocket (0 default / 1) off/on

- adding "default vibration power" setting - you can set the power of vibrator motor for those vibrations where notification booster is not being applied

--- uci user config entry: vibration_power_set=0 (0/1) and vibration_power_percentage=40 (0-100)=0 (0/1) - if first set to 1, percentage will be applied. (sysfs won't be added, it's on the standard path already)

- adding possibility to tweak Kernel Ambient Display grayscale "Magic Value" and "Contrast" for KCal:

---- /sys/fpf/kad_kcal_cont /sys/fpf/kad_kcal_val -- UCI: kad_kcal_cont and kad_kcal_val