Re: [android-porting] Integration of ambient light sensor and Auto brightness

314 views
Skip to first unread message

Ramya Mohan

unread,
Jun 10, 2013, 12:30:22 AM6/10/13
to cha...@gmail.com, android-porting
Hi,

As of my understanding, Settings brightness corresponds to LCD back light brightness & not ALS.
Please have a look at liblights directory in your product specific build folder.

If you still want ALS to work as your auto brightness, you might have to tweak the frameworks.

Regards,
Ramya


On Thu, Jun 6, 2013 at 8:03 PM, <cha...@gmail.com> wrote:
Hi all,
it is my first post on the group, but I read it very often. Guys you are very helpful!

I'm working on porting android to arm and recently I met some problems.
I don't know how to integrate ambient light sensor with Auto brightness (UI option in Settings/Display).
The only thing I need is integration: sensor works and returns valid values (checked by getevent -p), the slider in settings (UI) also works great (dimming and brightens the screen).
Unfortunately checking the option Auto brightness has no effect - the brightness of the screen remains the same despite ambient light changed.

What can be the reason? How can be it fixed? Any tips are welcome.

Android version is: 2.3.3

Thanks in advance for help.

chaqi

--
--
unsubscribe: android-porti...@googlegroups.com
website: http://groups.google.com/group/android-porting
 
---
You received this message because you are subscribed to the Google Groups "android-porting" group.
To unsubscribe from this group and stop receiving emails from it, send an email to android-porti...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.
 
 

Vishveshwar

unread,
Jun 10, 2013, 4:04:50 AM6/10/13
to android...@googlegroups.com
On Thursday, June 6, 2013 8:03:38 PM UTC+5:30, cha...@gmail.com wrote:
Hi all,
it is my first post on the group, but I read it very often. Guys you are very helpful!

I'm working on porting android to arm and recently I met some problems.
I don't know how to integrate ambient light sensor with Auto brightness (UI option in Settings/Display).
The only thing I need is integration: sensor works and returns valid values (checked by getevent -p), the slider in settings (UI) also works great (dimming and brightens the screen).
Unfortunately checking the option Auto brightness has no effect - the brightness of the screen remains the same despite ambient light changed.

What can be the reason? How can be it fixed? Any tips are welcome.

Android version is: 2.3.3

Thanks in advance for help.

chaqi

In ICS you need to set autobrightness in your device overlay and provide a table which maps ALS values to backlight intensity. See the following example in AOSP for 'tuna' device:
https://android.googlesource.com/device/samsung/tuna/+/android-4.0.1_r1/overlay/frameworks/base/core/res/res/values/config.xml

I am not personally familiar with corresponding Gingerbread code but simething similar may be needed in your case.

-Vishveshwar

Braganza Roberts

unread,
Jun 10, 2013, 1:01:33 PM6/10/13
to vishves...@aim.com, android...@googlegroups.com
First check if the sysfs entry for brightness is properly updated when you are moving the slide.
sysfs entry may differ for different vendors.

~Sam.

--
Reply all
Reply to author
Forward
0 new messages