# Galaxy nexus all-in-one guide with tweaks for performance and battery life



## The_metalspring (Apr 11, 2012)

ok, from my android tweaking and modding i know it can be somewhat hard to find everything you might need to make the most of your galaxy nexus so i will put links to them here along with providing support and my own little discoveries here...

This will include everything from guides to different type of tweaks, recommended settings, flashable mods, etc...you name it and it will probably be in here (as i update it)

Any suggestions are highly appreciated and will be added with proper credit

******disclaimer- I am not responsible for any damage you may do to your device, please make sure to have a backup before doing any of these tweaks****

(still a work in progress and expect much much more to come)

Feel free to donate, I put as much time as i can spare into finding and testing all these tweaks personally and try to keep it as up to date as possible


----------



## The_metalspring (Apr 11, 2012)

*Guides/Toolkits*

[GNex TOOLKIT] Drivers, Backup, Unlock, Root, CWM, Flash, Mods + MORE [VERIZON]

[EASIEST ROOT/UNLOCK TOOLKIT] Wugfresh Galaxy Nexus Root Toolkit v1.4


----------



## The_metalspring (Apr 11, 2012)

*Build.prop tweaks*

To use these just mount /system rw, open build.prop in a text editor, add/modify whichever lines you want, save, reboot recovery, wipe cache and dalvik cache, then reboot

Screen/scrolling/gpu/video/photo tweaks

# This defines the max event window manager can
# handle in 1 s. We may adjust this # for performance
# reason later
windowsmgr.max_events_per_sec= (recommended 275)

debug.performance.tuning=1
video.accelerate.hw=1

#Improve screen responsiveness/scrolling
ro.max.fling_velocity=12000
ro.min.fling_velocity=8000

#Improve screen quality at the cost of performance (1 enabled 0 disabled)
persist.sys.use.dithering=1

#Raise Photo and video quality?
ro.media.enc.jpeg.quality=100
ro.media.dec.jpeg.memcap=8000000
ro.media.enc.hprof.vid.bps=8000000
ro.media.enc.hprof.vid.fps=65

#change lcd density (already in build.prop), which is like changing the resolution on a windows computer can be anywhere from 240 to 360 (stock 320)
ro.sf.lcd_density=

Performance/battery tweaks

#disable the zygote loader for performance
ro.wmt.blcr.enable=0

#help to free up unused ram
persist.sys.purgeable_assets=1

#sleep mode for battery savings. 0 power collapse suspend, 1 power collapse (best), 2 apps go to sleep, 3 show clock and wait, 4 wait for interrupt
pm.sleep_mode=

#battery savers
ro.ril.disable.power.collapse=0
#change to 2000 if having issues connecting after signal loss
ro.mot.eri.losalert.delay=1000

#disable sending usage data to google
ro.config.nocheckin=1

Miscellaneous tweaks

#disable camera sound?
persist.sys.camera-sound=0

#stop usb debugging on notification
persist.adb.notify=0

#incoming ringer delay (already in build.prop) sets how soon the phone starts ringing when a call comes in. set between 0 and 3000
ro.telephony.call_ring.delay=

Dalvik vm tweaks

#dalvik cache virtual memory size
dalvik.vm.heapsize= (stock 256m, recommended 320m)
dalvik.vm.heapstartsize= (stock 16m)
dalvik.vm.heapgrowthlimit= (stock 128m)

#disable extended dalvik jni checking
ro.kernel.android.checkjni=0
ro.kernel.checkjni=0
dalvik.vm.checkjni=0

#Use dalvik JIT compiler (Just In Time compiler is much faster and should be enabled by default)
dalvik.vm.execution-mode=int:jit

option 1- disable dalvik checking, increases free ram but less optimized dalvik cache
dalvik.vm.verify-bytecode=false
dalvik.vm.dexopt-flags=v=n,u=n,o=v

option 2 (preferred)- enable more checking for a better performing dalvik cache but may use a little more ram
dalvik.vm.verify-bytecode=true
dalvik.vm.dexopt-flags=v=f,u=n,o=v

Highly experimental tweaks

The following tweaks are currently still in the testing phase (not yet determined to improve performance/battery life/work at all/etc...)
use at your own risk (should not really hurt your phone in any permanent way, should boot just fine, no random freezes reboots, etc)

Enjoy testing and feel free to report back here









#GPU/Video/Scrolling/Media tweaks
persist.sys.ui.hw=1
ro.config.disable.hw_accel=false
debug.composition.type=gpu
ro.min_pointer_dur=8
debug.egl.profiler=1
debug.egl.hw=1
ro.media.dec.vid.wmv.enabled=1
ro.media.dec.aud.wma.enabled=1
ro.media.dec.aud.flac.enabled=1
ro.media.dec.vid.avi.enabled=1
#Remove FPS cap. May be unstable - better have it activated
debug.gr.swapinterval=0

# Enable Stagefright helps stream Video and Music Faster
media.stagefright.enable-player=true
media.stagefright.enable-meta=true
media.stagefright.enable-scan=true
media.stagefright.enable-http=true
media.stagefright.enable-rtsp=true
media.stagefright.enable-record=false

#Disable debugging/error reporting/logging
logcat.live=disable
profiler.force_disable_err_rpt=1
profiler.force_disable_ulog=1

#signal/data tweaks
persist.cust.tel.eons=1
ro.ril.enable.amr.wideband=1
ro.config.hw_fast_dormancy=1
persist.telephony.support.ipv6=1
persist.telephony.support.ipv4=1

# MMS APN retry timer set to 2 sec( if SMS/MMS couldn`t be sent, it retries after 2 instead of 5 seconds)
ro.gsm.2nd_data_retry_config=max/_retries=3, 2000, 2000, 2000

#Battery tweaks
persist.sys.shutdown.mode=hibernate

#Miscellaneous tweaks
debug.enabletr=true
persist.android.strictmode=0
dalvik.vm.jmiopts=forcecopy

# Disable boot animation for faster boot
debug.sf.nobootanimation=1
#Faster boot.
ro.config.hw_quickpoweron=true

#Better video and picture taking quality
ro.media.capture.maxres=8m
ro.media.panorama.defres=3264x1840
ro.media.panorama.frameres=1280x720
ro.camcorder.videoModes=true


----------



## The_metalspring (Apr 11, 2012)

*Init.d tweaks*

To use mount /system rw, go to /system/etc/init.d create new file with #!/system/bin/sh as the first line, add the lines in, save, and set permissions to rwxr-xr-x

#disable logcat for performance increase
rm dev/log/main

#Flags blocks as non-rotational and increases cache size for performance increase
LOOP=`ls -d /sys/block/loop*`;
RAM=`ls -d /sys/block/ram*`;
MMC=`ls -d /sys/block/mmc*`;
for j in $LOOP $RAM
do
echo "0" > $j/queue/rotational;
echo "2048" > $j/queue/read_ahead_kb;
done

#Disable normalize sleeper for performance
mount -t debugfs none /sys/kernel/debug
echo NO_NORMALIZED_SLEEPER > /sys/kernel/debug/sched_features

#Defrags database files for increased I/O perfomance (requires sqlite3 binary in /system/xbin)
for i in \
`find /data -iname "*.db"`
do \
sqlite3 $i 'VACUUM;';
done

# File System Mounts for I/O performance
busybox mount -o remount,noatime,nodiratime,discard,noauto_da_alloc,nosuid,nodev,data=writeback,barrier=0 -t auto /
busybox mount -o remount,noatime,nodiratime,discard,noauto_da_alloc,nosuid,nodev,data=writeback,barrier=0 -t auto /dev
busybox mount -o remount,noatime,nodiratime,discard,noauto_da_alloc,nosuid,nodev,data=writeback,barrier=0 -t auto /proc
busybox mount -o remount,noatime,nodiratime,discard,noauto_da_alloc,nosuid,nodev,data=writeback,barrier=0 -t auto /sys
busybox mount -o remount,noatime,nodiratime,discard,noauto_da_alloc,nodev,data=writeback,barrier=0 -t auto /system
busybox mount -o remount,noatime,nodiratime,discard,noauto_da_alloc,nosuid,nodev,data=writeback,barrier=0 -t auto /data
busybox mount -o remount,noatime,nodiratime,discard,noauto_da_alloc,nosuid,nodev,data=writeback,barrier=0 -t auto /data/data
busybox mount -o remount,noatime,nodiratime,discard,noauto_da_alloc,nosuid,nodev,data=writeback,barrier=0 -t auto /cache
busybox mount -o remount,noatime,nodiratime,discard,noauto_da_alloc,nosuid,nodev,data=writeback,barrier=0 -t auto /acct
busybox mount -o remount,noatime,nodiratime,discard,noauto_da_alloc,nosuid,nodev,data=writeback,barrier=0 -t auto /dev/pts
busybox mount -o remount,noatime,nodiratime,discard,noauto_da_alloc,nosuid,nodev,data=writeback,barrier=0 -t auto /dev/cpuctl
busybox mount -o remount,noatime,nodiratime,discard,noauto_da_alloc,nosuid,nodev,data=writeback,barrier=0 -t auto /mnt/asec
busybox mount -o remount,noatime,nodiratime,discard,noauto_da_alloc,nosuid,nodev,data=writeback,barrier=0 -t auto /mnt/obb
busybox mount -o remount,noatime,nodiratime,discard,noauto_da_alloc,nosuid,nodev,data=writeback,barrier=0 -t auto /mnt/sdcard
busybox mount -o remount,noatime,nodiratime,discard,noauto_da_alloc,nosuid,nodev,data=writeback,barrier=0 -t auto /storage/sdcard0

# SD Card Speed Boost
if [ -e /sys/devices/virtual/bdi/179:0/read_ahead_kb ]; then
echo 2048 > /sys/devices/virtual/bdi/179:0/read_ahead_kb
fi

#Disable color-control safety + color presents for Ezekeel color control (not the same as cm9/aokp settings style) 
#
echo "0" > /sys/class/misc/colorcontrol/safety_enabled
echo "0 0 0" > /sys/class/misc/colorcontrol/v1_offset
echo "0" > /sys/class/misc/colorcontrol/blue_v1_offset
echo "0" > /sys/class/misc/colorcontrol/green_v1_offset
echo "0" > /sys/class/misc/colorcontrol/red_v1_offset
echo "2004318071 2004318071 2004318071" > /sys/class/misc/colorcontrol/multiplier
echo "0" > /sys/devices/platform/omapdss/manager0/gamma


----------



## The_metalspring (Apr 11, 2012)

*Recoveries/Radios/Etc*

List of flashable verizon radios-
radiosvzw-all-radios-in-flashable-zip/

Team win recovery project (custom touchscreen recovery)
twrp-212-touch-recovery-2012-04-20/

Clockwork recovery touch toro-
recovery-clockwork-touch-5.8.0.2-toro.img

clockwork recovery no skip edition-
http://rootzwiki.com...o-skip-edition/


----------



## The_metalspring (Apr 11, 2012)

*Mods/other*

*Suggested color control settings-*
*whitest whites*
red 200
green 200
blue 265
gamma red -6
gamma green 0
gamma blue 8
omap4 gamma 6 (1.2 via franco app)
*Morfic battery saving settings-*
Red 135
green 135
blue 200
gamma red 0
gamma green 0
gamma blue 0
omap4 gamma 6 (1.2 via franco app)
*Franco suggested settings-*
Red 180
Green 192
Blue 200
gamma red -4
gamma green 0
gamma blue 5
omap4 gamma 6 (1.2 via franco app)

Custom auto brightness tweaks (super power save + conservative power save settings)
For both sets of settings-
Light sensor filter enabled yes
Window length 5s
Reset threshold 400 lux
Sample interval 5s
Use custom yes
Screen dim level 1
Allow light decrease yes
Decrease hysteresis 50%

Conservative power save settings-
Edit other levels under screen column-
15
17
19
21
23
25
27
30
32
40
49
54
65
75
100
125
146
179
211
225

Super power save settings-
Edit other levels under screen column-
6
8
9
11
12
14
16
19
23
27
33
40
50
64
85
97
111
146
178
225

Get google wallet for verizion galaxy nexus from the play store and have it available in the all section of my apps in play store for future redownloading
install marketenabler http://db.tt/Q2X967Pj
set to t-mobile us (should be first option)
wipe play store data (settings>apps>play store> clear data)
open play store and accept the prompt
search for google wallet and install
open marketenabler and change back to verizon
clear play store data
enjoy


----------



## Jubakuba (Sep 8, 2011)

I personally don't support toolkits...
But cool beans man.


----------



## gnex0422 (Mar 5, 2012)

The_metalspring said:


> *Mods/other*
> 
> Suggested color control settings for whitest whites-
> red 200
> ...


Thanks for the color settings....looks great!

Sent from my Galaxy Nexus using RootzWiki


----------



## abbofro (Apr 1, 2012)

Thanks for taking ur time to right these up!

Google Galaxy Nexus (GSM)
ROM: AXIOM HYBRYD B6
Kernel: GLaDOS 1.34


----------



## Helltoupee (Jun 12, 2011)

gnex0422 said:


> Thanks for the color settings....looks great!
> 
> Sent from my Galaxy Nexus using RootzWiki


+1 The white is noticeably more white and the "linen" look is gone completely on my screen even at lower brightness setting. My screen looks amazing. I had just learned to live with the linen look done I got the phone on launch day and I wish I had found these settings 9 months ago. Thank you. I have my beautiful screen back on low brightness without chewing up my battery.

Sent from my Galaxy Nexus


----------



## hacku (Jul 14, 2011)

Helltoupee said:


> +1 The white is noticeably more white and the "linen" look is gone completely on my screen even at lower brightness setting. My screen looks amazing. I had just learned to live with the linen look done I got the phone on launch day and I wish I had found these settings 9 months ago. Thank you. I have my beautiful screen back on low brightness without chewing up my battery.
> 
> Sent from my Galaxy Nexus


Where do you guys adjust the color settings?


----------



## Jubakuba (Sep 8, 2011)

hacku said:


> Where do you guys adjust the color settings?


Via Franco Updater
Or via lean tweaks if you run Lean Kernel
Or via Glados Control
Or via your rom's color settings.

The first three values he mentions are Color Multipliers.
The rest are gamma.


----------



## hacku (Jul 14, 2011)

Jubakuba said:


> Via Franco Updater
> Or via lean tweaks if you run Lean Kernel
> Or via Glados Control
> Or via your rom's color settings.
> ...


Is there a way to adjust this on a stock ROM?

Sent from my Nexus using Tapatalk 2


----------



## The_metalspring (Apr 11, 2012)

hacku said:


> Is there a way to adjust this on a stock ROM?
> 
> Sent from my Nexus using Tapatalk 2


If you use Franco, glados, leankernel or other kernels that use Ezekeels color control, yes...I'll have to look up terminal commands though and look up where the cm9 color control is located for kernels that use that


----------



## The_metalspring (Apr 11, 2012)

Added custom auto brightness tweaks for custom roms with that option (should help save a lot of battery, actually can go lower than manual brightness)


----------



## hacku (Jul 14, 2011)

Im running stock just unlocked and rooted. Not running any custom ROM or kernel.


----------



## The_metalspring (Apr 11, 2012)

hacku said:


> Im running stock just unlocked and rooted. Not running any custom ROM or kernel.


The color control is built into most custom kernels but not the stock one, sorry
You could always flash a stable custom kernel and run it at stock speeds though


----------



## havens1515 (Jun 21, 2011)

Sweet! I started using these color multipliers and brightness settings this morning. I had some similar values for the brightness, but mine were closer to your Super power savings settings, and it was a little too dark at times. Your regular power saving settings work a little better for me. Thanks!


----------



## nklenchik (Dec 1, 2011)

hacku said:


> Im running stock just unlocked and rooted. Not running any custom ROM or kernel.


Do you just do it for the rooted apps? Cuz to be honest I only use like 6ish that need root, and 2 of those are superuser and terminal emulator


----------



## JeremySoftBeard (Jun 4, 2012)

Are you aware of anything in these settings that wouldn't work in Jelly Bean?


----------



## The_metalspring (Apr 11, 2012)

JeremySoftBeard said:


> Are you aware of anything in these settings that wouldn't work in Jelly Bean?


Nope, they all should work
This one is especially nice since there is no option built in to disable it
#stop usb debugging on notification
persist.adb.notify=0


----------



## The_metalspring (Apr 11, 2012)

sorry, for lack of updates the past few days, between Jellybean roms dropping and finding a HUGE amount of new tweaks to test its been busy...i will be adding some today though


----------



## mystilleef (Jun 12, 2012)

Looking forward to the update.


----------



## The_metalspring (Apr 11, 2012)

finally got to get the updates up, new tweaks include manual color control settings via terminal or init.d to auto set on boot, more build.prop tweaks including my still in testing tweaks (highly experimental)...they shouldnt really hurt your phone at all, its just yet to be determined whether they improve anything or do anything at all yet. Feel free to test them out and report back


----------



## PrimeDirective (Dec 31, 2011)

[background=rgb(245, 245, 245)]LOOP=`ls -d /sys/block/loop*`;[/background]
[background=rgb(245, 245, 245)]RAM=`ls -d /sys/block/ram*`;[/background]
[background=rgb(245, 245, 245)]MMC=`ls -d /sys/block/mmc*`;[/background]
[background=rgb(245, 245, 245)]for j in $LOOP $RAM[/background]
[background=rgb(245, 245, 245)]do[/background]
[background=rgb(245, 245, 245)]echo "0" > $j/queue/rotational;[/background]
[background=rgb(245, 245, 245)]echo "2048" > $j/queue/read_ahead_kb;[/background]
[background=rgb(245, 245, 245)]done[/background]

[background=rgb(245, 245, 245)]i'm interested in this one. do you have any benchmark comparisons between different settings? preferably with default android settings? why would VM in sysctl be labeled for 4096 for swapping which is used a lot less and only 2048 for blocks[/background]


----------



## The_metalspring (Apr 11, 2012)

PrimeDirective said:


> [background=rgb(245, 245, 245)]LOOP=`ls -d /sys/block/loop*`;[/background]
> [background=rgb(245, 245, 245)]RAM=`ls -d /sys/block/ram*`;[/background]
> [background=rgb(245, 245, 245)]MMC=`ls -d /sys/block/mmc*`;[/background]
> [background=rgb(245, 245, 245)]for j in $LOOP $RAM[/background]
> ...


not entirely sure what VM has to do with this? This script is similar to the one to set the sdcard buffer size, except its for ram and loop and a slightly different format
the stock values are rotational=1 and queue/read_ahead_kb= 128
That script flags the blocks as nonrotational and increases the read ahead buffer size to 2048
I will run a few tests though now


----------



## Cloud Nine (May 19, 2012)

The "whitest whites" worked great. Using those settings with 40% brightness


----------



## PrimeDirective (Dec 31, 2011)

The_metalspring said:


> not entirely sure what VM has to do with this? This script is similar to the one to set the sdcard buffer size, except its for ram and loop and a slightly different format
> the stock values are rotational=1 and queue/read_ahead_kb= 128
> That script flags the blocks as nonrotational and increases the read ahead buffer size to 2048
> I will run a few tests though now


i tried 4096 last night. man was it fast as shit but it KILLS your battery.


----------



## The_metalspring (Apr 11, 2012)

PrimeDirective said:


> i tried 4096 last night. man was it fast as shit but it KILLS your battery.


Yeah i bet, buffering that far ahead for something like ram which is always in use cant be good for battery but I'm sure something like 512 or 1024 would work well
without the huge battery drain (probably any multiple of 128 would work really)

Also added an almost foolproof way for Verizon users to get Google wallet from the play store and be able to redownload it on different roms (via the all tab in my apps on the play store)


----------

