Skip to content

Commit

Permalink
Fix Bluetooth and USB Tethering
Browse files Browse the repository at this point in the history
+ Reformatting config.xml and removing non used ones or stock declared

Change-Id: I5113c1348eb82cd82d4b2e8cca32bc619b84624d
  • Loading branch information
HazouPH committed Feb 23, 2015
1 parent b178153 commit 097b628
Show file tree
Hide file tree
Showing 2 changed files with 25 additions and 42 deletions.
59 changes: 21 additions & 38 deletions overlay/frameworks/base/core/res/res/values/config.xml
Original file line number Diff line number Diff line change
Expand Up @@ -21,23 +21,11 @@
<!-- If this is true, the screen will come on when you unplug usb/power/whatever. -->
<bool name="config_unplugTurnsOnScreen">true</bool>

<!-- Flag indicating whether the surface flinger has limited
alpha compositing functionality in hardware. If set, the window
manager will disable alpha trasformation in animations where not
strictly needed. -->
<bool name="config_sf_limitedAlpha">false</bool>

<!-- If this is true, the screen will fade off. -->
<bool name="config_animateScreenLights">false</bool>

<!-- Flag indicating whether the surface flinger is inefficient
at performing a blur. Used by parts of the UI to turn off
the blur effect where it isn't worth the performance hit. -->
<bool name="config_sf_slowBlur">true</bool>

<bool name="config_ui_enableFadingMarquee">false</bool>

<bool name="config_enableLockScreenTranslucentDecor">true</bool>
<!-- Enables or disables fading edges when marquee is enabled in TextView. -->
<bool name="config_ui_enableFadingMarquee">false</bool>

<!-- Enables swipe versus poly-finger touch disambiguation in the KeyboardView -->
<bool name="config_swipeDisambiguation">true</bool>
Expand All @@ -58,9 +46,6 @@
Software implementation will be used if config_hardware_auto_brightness_available is not set -->
<bool name="config_automatic_brightness_available">true</bool>

<!-- Default interface to monitor data use -->
<string name="config_datause_iface">rmnet0</string>

<!-- Is the notification LED intrusive? Used to decide if there should be a disable option -->
<bool name="config_intrusiveNotificationLed">true</bool>

Expand Down Expand Up @@ -135,11 +120,6 @@
<item>255</item>
</integer-array>

<!-- Amount of time it takes for the light sensor to warm up in milliseconds.
For this time after the screen turns on, the Power Manager
will not debounce light sensor readings -->
<integer name="config_lightSensorWarmupTime">0</integer>

<!-- Package name(s) containing location provider support.
These packages can contain services implementing location providers,
such as the Geocode Provider, Network Location Provider, and
Expand Down Expand Up @@ -183,21 +163,24 @@
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>bluetooth,7,7,1,-1,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>mobile_agps,30,0,2,60000,true</item>
<item>mobile_entitle,34,0,2,60000,true</item>
<item>mobile_corpsync,35,0,2,60000,true</item>
<item>mobile_stdhipri,36,0,2,60000,true</item>
<item>mobile_800apn,37,0,2,60000,true</item>
<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>"bluetooth,7,7,1,-1,true"</item>
<item>"ethernet,9,9,1,-1,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>"mobile_ia,14,0,2,-1,true"</item>
<item>"mobile_agps,30,0,2,60000,true"</item>
<item>"mobile_entitle,34,0,2,60000,true"</item>
<item>"mobile_corpsync,35,0,2,60000,true"</item>
<item>"mobile_stdhipri,36,0,2,60000,true"</item>
<item>"mobile_800apn,37,0,2,60000,true"</item>
</string-array>

<!-- This string array should be overridden by the device to present a list of radio
Expand All @@ -209,6 +192,7 @@
<item>"1,1"</item>
<item>"0,1"</item>
<item>"7,1"</item>
<item>"9,1"</item>
</string-array>

<!-- List of regexpressions describing the interface (if any) that represent tetherable
Expand All @@ -223,7 +207,6 @@
should be empty. An example would be "softap.*" -->
<string-array translatable="false" name="config_tether_wifi_regexs">
<item>"wlan\\d"</item>
<item>"softap.*"</item>
</string-array>

<!-- List of regexpressions describing the interface (if any) that represent tetherable
Expand Down
8 changes: 4 additions & 4 deletions rootdir/init.moto.usb.rc
Original file line number Diff line number Diff line change
Expand Up @@ -9,17 +9,17 @@ on init
on boot
write /sys/class/android_usb/android0/iManufacturer ${ro.product.manufacturer}
write /sys/class/android_usb/android0/iProduct ${ro.product.model}
write /sys/class/android_usb/android0/f_mass_storage/vendor ${ro.product.manufacturer}
write /sys/class/android_usb/android0/f_mass_storage/product ${ro.product.model}
write /sys/class/android_usb/android0/idProduct 0x710B
write /sys/class/android_usb/android0/functions rndis
setprop usb.mtp.pid 0x710F
setprop usb.mtp.cdrom 1
setprop usb.mtp.config mass_storage

on charger
write /sys/class/android_usb/android0/iManufacturer ${ro.product.manufacturer}
write /sys/class/android_usb/android0/iProduct ${ro.product.model}
write /sys/class/android_usb/android0/f_mass_storage/vendor ${ro.product.manufacturer}
write /sys/class/android_usb/android0/f_mass_storage/product ${ro.product.model}
write /sys/class/android_usb/android0/idProduct 0x710C
write /sys/class/android_usb/android0/functions rndis,adb
setprop sys.usb.config charger

# Perms
Expand Down

0 comments on commit 097b628

Please sign in to comment.