Brightness control in Lollipop

308 views
Skip to first unread message

Zach Rhonheimer

unread,
Dec 4, 2014, 11:13:21 AM12/4/14
to tas...@googlegroups.com
It seems that now with Android 5.0 Lollipop we have the ability to manually adjust brightness levels while leaving adaptive brightness enabled.  Will Tasker be updated to support this as well?  Currently it still sees adaptive brightness as being the same as auto brightness and doesn't seem to let you control it when adaptive is enabled unless I am missing something.  Thanks.

Matt R

unread,
Dec 4, 2014, 1:00:02 PM12/4/14
to tas...@googlegroups.com
I'm not on lollipop, but on my phone (LG G2) the brightness can be adjusted while autobrightness is enabled.  I can do this in Tasker as well as independent of Tasker (in the system settings).  It still might be device specific though, I'll have to defer to the dev.

Matt

Zach Rhonheimer

unread,
Dec 4, 2014, 1:18:52 PM12/4/14
to tas...@googlegroups.com
It does on Lollipop too but it doesn't do anything to actually adjust the brightness setting so I am guessing the problem might just be from changes to the API's that handle brightness settings although I haven't tested it with adaptive brightness off.

Roderick Gadellaa

unread,
Feb 23, 2016, 9:08:01 AM2/23/16
to Tasker
Hmm I've found something on stackoverflow that might do the trick. It needs to be implemented in Tasker though because it's java code?

The key is the (hidden) settings key "screen_auto_brightness_adj" which should control the brightness slider when auto adjust is enabled

float value = (((float)brightness*2)/255) - 1.0f;
Settings.System.putFloat(contentResolver, "screen_auto_brightness_adj", value);

Pent

unread,
Feb 23, 2016, 11:48:46 AM2/23/16
to Tasker
There's no official way for apps to control adaptive brightness. As mentioned in the thread you linked, the
code you pasted doesn't work on Samsung devices (and probably others).

There's at least one plugin with which you can change system settings, if you wish to
do that.

Pent

Roderick Gadellaa

unread,
Feb 23, 2016, 12:54:12 PM2/23/16
to Tasker
@Pent oh great I didn't read that line. Why the hell does samsung insist on changing stupid things like this? It works on pretty much everything that's (close to) AOSP. Which samsung dev went through that code and was all like "oh we don't need this, it's not even official. If I remove this we'll have more RAM for all the memory leaks or own apps have" :S

</rant>

Anyway. It works when I run a shell command:

settings put system screen_auto_brightness_adj [value] works perfectly fine. With root. And only one of my devices is rooted :S

Which plugin can do this? I've looked around but couldn't find one yet.

Pent

unread,
Feb 23, 2016, 2:28:49 PM2/23/16
to Tasker

Anyway. It works when I run a shell command:

settings put system screen_auto_brightness_adj [value] works perfectly fine. With root. And only one of my devices is rooted :S

Which plugin can do this? I've looked around but couldn't find one yet.

There's a thread on it and I was sure it had been published in play store, but I can't find it
(didn't search extensively)

Pent
Reply all
Reply to author
Forward
0 new messages