Device overlays

From Omni
Revision as of 22:03, 3 February 2015 by Simonsickle (Talk | contribs)

(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search

Device specific overlay values

How to configure overlay values to enable device specific features This values must be placed in the overlay folder of the device tree


If you are wishing to maintain AOSP compliance in your tree or multiple products, consider multiple overlay directories

For example:





If the device has a LED


Enable notification LED support

frameworks/base - config.xml

   <bool name="config_intrusiveNotificationLed">true</bool>


Enable charging LED support

frameworks/base - config.xml

   <bool name="config_intrusiveBatteryLed">true</bool>

If the LED has more then one color

   <bool name="config_multiColorBatteryLed">true</bool>


OmniGears - config.xml

If device supports RGB colors on LEDs

   <bool name="config_has_multi_color_led" translatable="false">true</bool>

Else a list of supported colors can be provided the default is red/green

OmniGears - arrays.xml

   <string-array name="entries_led_colors" translatable="false">
   <string-array name="values_led_colors" translatable="false">

Buttons and Keys


Define the number of buttons available on the device

frameworks/base - config.xml

   Hardware 'face' keys present on the device, stored as a bit field.
        This integer should equal the sum of the corresponding value for each
        of the following keys present:
            1 - Home
            2 - Back
            4 - Menu
            8 - Assistant (search)
           16 - App switch
        For example, a device with Home, Back and Menu keys would set this
        config to 7.
   <integer name="config_deviceHardwareKeys">7</integer>

Enable custom button config in Settings

OmniGears - config.xml

   <bool name="config_has_hardware_buttons">true</bool>

If kernel has volume wake support

   <bool name="config_show_volumeRockerWake">true</bool>


If the device has capacitive buttons with backlight that should be handled separate of the screen brightness.

Enable support of custom button backlight

frameworks/base - config.xml

   <bool name="config_button_brightness_support">true</bool>

Define the default button brightness values for automatic brightness

   <integer-array name="config_autoBrightnessButtonBacklightValues">

This also requires support of setting button backlight separate in liblights