Skip to content

Commit

Permalink
sprout: initial bringup
Browse files Browse the repository at this point in the history
  • Loading branch information
varunchitre15 committed Apr 27, 2015
0 parents commit 0348fac
Show file tree
Hide file tree
Showing 11 changed files with 494 additions and 0 deletions.
30 changes: 30 additions & 0 deletions Android.mk
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
#
# Copyright 2015 The CyanogenMod Project
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
#

# This contains the module build definitions for the hardware-specific
# components for this device.
#
# As much as possible, those components should be built unconditionally,
# with device-specific names to avoid collisions, to avoid device-specific
# bitrot and build breakages. Building a component unconditionally does
# *not* include it on all devices, so it is safe even with hardware-specific
# components.

LOCAL_PATH := $(call my-dir)

ifneq ($(filter sprout8,$(TARGET_DEVICE)),)
include $(call all-makefiles-under,$(LOCAL_PATH))
endif
27 changes: 27 additions & 0 deletions BoardConfig.mk
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
#
# Copyright (C) 2015 The CyanogenMod Project
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
#
LOCAL_PATH := device/google/sprout8

# inherit from common sprout repo
-include device/google/sprout-common/BoardConfigCommon.mk

TARGET_OTA_ASSERT_DEVICE := sprout,sprout8

PRODUCT_COPY_FILES += \
$(LOCAL_PATH)/rootdir/root/init.sprout.rc:root/init.sprout.rc \
$(LOCAL_PATH)/rootdir/root/fstab.sprout:root/fstab.sprout

TARGET_RECOVERY_FSTAB := $(LOCAL_PATH)/rootdir/root/fstab.sprout
12 changes: 12 additions & 0 deletions cm.dependencies
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
[

{
"repository": "android_device_google_sprout-common",
"target_path": "device/google/sprout-common"
}
{
"repository": "android_kernel_mediatek_sprout",
"target_path": "kernel/mediatek/sprout"
}

]
15 changes: 15 additions & 0 deletions cm.mk
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
$(call inherit-product, device/google/sprout8/sprout8.mk)

# Common CM stuff
$(call inherit-product, vendor/cm/config/common_full_phone.mk)

PRODUCT_BUILD_PROP_OVERRIDES += BUILD_FINGERPRINT=5.1/LMY47O/1783956:user/release-keys PRIVATE_BUILD_DESC="sprout-user 5.1 LMY47O 1783956 release-keys"

PRODUCT_NAME := cm_sprout8
PRODUCT_DEVICE :=sprout8
PRODUCT_BRAND := google
PRODUCT_MANUFACTURER := Google
PRODUCT_MODEL := A1

PRODUCT_BUILD_PROP_OVERRIDES += \
PRODUCT_DEVICE="sprout8"
291 changes: 291 additions & 0 deletions overlay/frameworks/base/core/res/res/values/config.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,291 @@
<?xml version="1.0" encoding="utf-8"?>
<!--
/*
** Copyright 2013, The Android Open Source Project
**
** Licensed under the Apache License, Version 2.0 (the "License");
** you may not use this file except in compliance with the License.
** You may obtain a copy of the License at
**
** http://www.apache.org/licenses/LICENSE-2.0
**
** Unless required by applicable law or agreed to in writing, software
** distributed under the License is distributed on an "AS IS" BASIS,
** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
** See the License for the specific language governing permissions and
** limitations under the License.
*/
-->

<resources xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
<!-- Set to true to add links to Cell Broadcast app from Settings and MMS app. -->
<bool name="config_cellBroadcastAppLinks">false</bool>

<!-- Whether a software navigation bar should be shown. NOTE: in the future this may be
autodetected from the Configuration. -->
<bool name="config_showNavigationBar">true</bool>

<!-- List of regexpressions describing the interface (if any) that represent tetherable
USB interfaces. If the device doesn't want to support tething over USB this should
be empty. An example would be "usb.*" -->
<string-array translatable="false" name="config_tether_usb_regexs">
<item>"rndis\\d"</item>
</string-array>

<!-- List of regexpressions describing the interface (if any) that represent tetherable
Wifi interfaces. If the device doesn't want to support tethering over Wifi this
should be empty. An example would be "softap.*" -->
<string-array translatable="false" name="config_tether_wifi_regexs">
<item>wlan\\d</item>
</string-array>

<!-- Array of allowable ConnectivityManager network types for tethering -->
<integer-array name="config_tether_upstream_types">
<item>0</item>
<item>1</item>
<item>5</item>
<item>7</item>
<item>9</item>
</integer-array>

<!-- If this is true, the screen will come on when you plug/unplug usb/power/whatever. -->
<bool name="config_unplugTurnsOnScreen">true</bool>

<!-- If this is true, the IME will be shown at screen on for keyguard password view -->
<bool name="kg_show_ime_at_screen_on">false</bool>

<!-- Allow the menu hard key to be disabled in LockScreen on some devices -->
<bool name="config_disableMenuKeyInLockScreen">true</bool>

<!-- If this is true, the screen will come on when you plug/unplug usb/power/whatever. -->
<bool name="config_unplugTurnsOnScreen">true</bool>

<!-- Default color for notification LED is green. -->
<color name="config_defaultNotificationColor">#ff00ff00</color>

<!-- Default value for led color when battery is low on charge -->
<integer name="config_notificationsBatteryLowARGB">0xffff0000</integer>

<!-- Default value for led color when battery is medium charged -->
<integer name="config_notificationsBatteryMediumARGB">0xffff0000</integer>

<!-- Default value for led color when battery is fully charged -->
<integer name="config_notificationsBatteryFullARGB">0xff00ff00</integer>

<!-- Boolean indicating if restoring network selection should be skipped -->
<!-- The restoring is handled by modem if it is true -->
<bool translatable="false" name="skip_restoring_network_selection">true</bool>

<!-- Enables SIP on WIFI only -->
<bool name="config_sip_wifi_only">false</bool>

<!-- Enable the electron beam -->
<bool name="config_animateScreenLights">false</bool>

<!-- Remote server that can provide NTP responses. -->
<string translatable="false" name="config_ntpServer">ntp.nict.jp</string>

<!-- National language single shift tables to enable for SMS encoding.
Decoding is always enabled. 3GPP TS 23.038 states that this feature
should not be enabled until a formal request is issued by the relevant
national regulatory body. Array elements are codes from the table above.
Example 1: devices sold in Turkey must include table 1 to conform with
By-Law Number 27230. (http://www.btk.gov.tr/eng/pdf/2009/BY-LAW_SMS.pdf)
Example 2: devices sold in India should include tables 4 through 13
to enable use of the new Release 9 tables for Indic languages. -->
<integer-array name="config_sms_enabled_single_shift_tables">
<item>1</item>
</integer-array>

<!-- Minimum screen brightness setting allowed by the power manager.
The user is forbidden from setting the brightness below this level. -->
<integer name="config_screenBrightnessSettingMinimum">20</integer>

<!-- Screen brightness used to dim the screen when the user activity
timeout expires. May be less than the minimum allowed brightness setting
that can be set by the user. -->
<integer name="config_screenBrightnessDim">20</integer>

<!-- Minimum allowable screen brightness to use in a very dark room.
This value sets the floor for the darkest possible auto-brightness
adjustment. It is expected to be somewhat less than the first entry in
config_autoBrightnessLcdBacklightValues so as to allow the user to have
some range of adjustment to dim the screen further than usual in very
dark rooms. The contents of the screen must still be clearly visible
in darkness (although they may not be visible in a bright room). -->
<integer name="config_screenBrightnessDark">20</integer>

<!-- This string array should be overridden by the device to present a list of network
attributes. This is used by the connectivity manager to decide which networks can coexist
based on the hardware -->
<!-- An Array of "[Connection name],[ConnectivityManager.TYPE_xxxx],
[associated radio-type],[priority],[restoral-timer(ms)],[dependencyMet] -->
<!-- the 5th element "resore-time" indicates the number of milliseconds to delay
before automatically restore the default connection. Set -1 if the connection
does not require auto-restore. -->
<!-- the 6th element indicates boot-time dependency-met value. -->
<string-array translatable="false" name="networkAttributes">
<item>"wifi,1,1,1,-1,true"</item>
<item>"mobile,0,0,0,-1,true"</item>
<item>"mobile_mms,2,0,2,60000,true"</item>
<item>"mobile_supl,3,0,2,60000,true"</item>
<item>"mobile_dun,4,0,2,60000,true"</item>
<item>"mobile_hipri,5,0,3,60000,true"</item>
<item>"mobile_fota,10,0,2,60000,true"</item>
<item>"mobile_ims,11,0,2,60000,true"</item>
<item>"mobile_cbs,12,0,2,60000,true"</item>
<item>"wifi_p2p,13,1,0,-1,true"</item>
<item>"bluetooth,7,7,2,-1,true"</item>
</string-array>

<!-- This string array should be overridden by the device to present a list of radio
attributes. This is used by the connectivity manager to decide which networks can coexist
based on the hardware -->
<!-- An Array of "[ConnectivityManager connectionType],
[# simultaneous connection types]" -->
<string-array translatable="false" name="radioAttributes">
<item>"1,1"</item>
<item>"0,1"</item>
<item>"7,1"</item>
</string-array>

<!-- List of regexpressions describing the interface (if any) that represent tetherable
bluetooth interfaces. If the device doesn't want to support tethering over bluetooth this
should be empty. -->
<string-array translatable="false" name="config_tether_bluetooth_regexs">
<item>bt-pan</item>
<item>bt-dun</item>
</string-array>

<!-- Flag indicating whether the we should enable the automatic brightness in Settings.
Software implementation will be used if config_hardware_auto_brightness_available is not set -->
<bool name="config_automatic_brightness_available">true</bool>

<!-- Minimum screen brightness setting allowed by the power manager.
The user is forbidden from setting the brightness below this level. -->
<integer name="config_screenBrightnessSettingMinimum">20</integer>

<!-- Screen brightness used to dim the screen while dozing in a very low power state.
May be less than the minimum allowed brightness setting
that can be set by the user. -->
<integer name="config_screenBrightnessDoze">20</integer>

<!-- If this is true, the screen will come on when you plug/unplug usb/power/whatever. -->
<bool name="config_unplugTurnsOnScreen">true</bool>

<!-- Shutdown if the battery temperature exceeds (this value * 0.1) Celsius. -->
<integer name="config_shutdownBatteryTemperature">600</integer>

<!-- Array of light sensor LUX values to define our levels for auto backlight brightness support.
The N entries of this array define N + 1 control points as follows:
(1-based arrays)
Point 1: (0, value[1]): lux <= 0
Point 2: (level[1], value[2]): 0 < lux <= level[1]
Point 3: (level[2], value[3]): level[2] < lux <= level[3]
...
Point N+1: (level[N], value[N+1]): level[N] < lux
The control points must be strictly increasing. Each control point
corresponds to an entry in the brightness backlight values arrays.
For example, if LUX == level[1] (first element of the levels array)
then the brightness will be determined by value[2] (second element
of the brightness values array).
Spline interpolation is used to determine the auto-brightness
backlight values for LUX levels between these control points.
Must be overridden in platform specific overlays -->
<integer-array name="config_autoBrightnessLevels">
<item>16</item>
<item>32</item>
<item>50</item>
<item>100</item>
<item>140</item>
<item>180</item>
<item>240</item>
<item>300</item>
<item>600</item>
<item>1000</item>
<item>2000</item>
<item>3000</item>
<item>4000</item>
<item>8000</item>
<item>10000</item>
</integer-array>

<!-- Array of output values for LCD backlight corresponding to the LUX values
in the config_autoBrightnessLevels array. This array should have size one greater
than the size of the config_autoBrightnessLevels array.
The brightness values must be between 0 and 255 and be non-decreasing.
This must be overridden in platform specific overlays -->
<integer-array name="config_autoBrightnessLcdBacklightValues">
<item>30</item>
<item>40</item>
<item>50</item>
<item>60</item>
<item>70</item>
<item>80</item>
<item>102</item>
<item>102</item>
<item>102</item>
<item>102</item>
<item>102</item>
<item>180</item>
<item>200</item>
<item>210</item>
<item>230</item>
<item>255</item>
</integer-array>

<!-- Safe headphone volume index. When music stream volume is below this index
the SPL on headphone output is compliant to EN 60950 requirements for portable music
players. -->
<integer name="config_safe_media_volume_index">8</integer>


<!-- Whether WiFi display is supported by this device.
There are many prerequisites for this feature to work correctly.
Here are a few of them:
* The WiFi radio must support WiFi P2P.
* The WiFi radio must support concurrent connections to the WiFi display and
to an access point.
* The Audio Flinger audio_policy.conf file must specify a rule for the "r_submix"
remote submix module. This module is used to record and stream system
audio output to the WiFi display encoder in the media server.
* The remote submix module "audio.r_submix.default" must be installed on the device.
* The device must be provisioned with HDCP keys (for protected content).
-->
<bool name="config_enableWifiDisplay">true</bool>


<!-- Set to true if the wifi display supports compositing content stored
in gralloc protected buffers. For this to be true, there must exist
a protected hardware path for surface flinger to composite and send
protected buffers to the wifi display video encoder.
If this flag is false, we advise applications not to use protected
buffers (if possible) when presenting content to a wifi display because
the content may be blanked.
This flag controls whether the {@link Display#FLAG_SUPPORTS_PROTECTED_BUFFERS}
flag is set for wifi displays.
-->
<bool name="config_wifiDisplaySupportsProtectedBuffers">false</bool>

<!-- Boolean indicating whether the wifi chipset has dual frequency band support -->
<bool translatable="false" name="config_wifi_dual_band_support">false</bool>

<!-- Boolean indicating whether the wifi chipset has background scan support -->
<bool translatable="false" name="config_wifi_background_scan_support">false</bool>

<!-- Maximum number of supported users -->
<integer name="config_multiuserMaximumUsers">4</integer>

<!-- Whether UI for multi user should be shown -->
<bool name="config_enableMultiUserUI">true</bool>

<!-- Performance profiles -->
<string name="config_perf_profile_prop">sys.perf.profile</string>
<string name="config_perf_profile_default_entry">1</string>
</resources>
Loading

0 comments on commit 0348fac

Please sign in to comment.