[Atrix 4G Android Development] Swiftks:
My CM7 Tweaks

Just thought I'd share the tweaks I use for CM7. I am currently using the latest nightly (#32), but these should work on nightly, weekly & beta.

Thanks to Notorious544d for giving me the inspiration, as all of these tweaks & more are present in his Neutrino ROM.

Below is the process I use, when installing a new CM7 based ROM, some of this will be redundant for some of you...

1) After installing ROM, install a custom Faux Kernel:

http://rootzwiki.com/topic/1666-kernelatrix-frgbcm7263256unified-v024oc145ghzuvslqbbfqfeb-04/

- a) use the 1.0GHz Enhanced version for best battery life

- b) use the 1.3GHz version as balance between battery life & performance

- c) use the 1.45GHz version for performance

2) Under volt the above kernel with SetCPU like so:

*Start with the higher frequencies, as they typically can not be undervolted as much as the lower frequencies.

*Make sure that "Set on Boot" is not checked, until you have all your values set and tested, less you risk a bootloop.

- a) Download Stability Test, or other stress tester of your choice (SetCPU has a built in stress tester undrer Info, but I like Stability Test better).

- b) Set you Max & Min to the same level you want to test your undervolt for. So to start from scratch, you would set both levels to 1000/1300/1450 (depending on your kernel choice).

- c) Go to the Voltage table, select the frequency you want to use, and start with -25mV, hit Apply. Now go do a stress test. For Stability Test, I use the CPU+GPU Test (at least for the higher frequencies) to really put a load on it. Also may want to try real world performance, like opening multiple apps, playing graphic intensive games, scrolling as fast as you can, etc.

- d) If after a bit of testing, all is stable, go back to SetCPU and and increase the undervolt by another -25mV, and test again. If at any point you get a reboot, which you eventually will b/c you've hit your undervolt limit, you know you need to go back down a -25mV step and set it there.

- e) Do this for each frequency in the voltage table, high to low, remembering to set both the Max & Min for the frequency step you are testing.

- f) Keep in mind a 100 undervolt step rule applies. i.e. your current mV values (under the frequency) must all be within +/-100mV of the previous frequency above it.

3) After you have your kernel situation sorted out, I suggest you install the V6 Supercharger Script.

*DO NOT use the most recent RC6 version, caused a soft brick on mine. Use RC5.2 instead, until a new update comes out.

- a) The script can be found here: http://xdaforums.com/showpost.php?p=18703418&postcount=5021

- b) You need Script Manager to install it.

- c) When first running Script Manger, make sure to select "Browse as Root"

- d) Navigate to where you saved the V6 script, select it, select su (root) from the top menu, then select Run.

- e) Once the script runs, it will eventually ask you to set text scroll speed, I selected Yes for build.prop integration & Yes for system integration.

- f) Once those option are set, and you are back at the driver console selection, select option #9 to install.

- g) After install has finished, select Yes for reboot and dalvik cache wipe.

4) My next suggestion, is you use Autostarts, and diable many of the apps you have installed from starting in the "After Startup" section. This will greatly improve your boottime & amount of free RAM that you start with.

*Note: I wouldn't disable any of the processes for Google Services Framework or any widgets you are currently useing.

5) Build.prop edits:

*Build.prop located @ /system

*Make a copy of your build.prop for a backup.

*I like to do this after I have installed the V6 script, that way the additons to the build.prop are already there.

- a) Copy your build.prop to your PC and use a eidtor like Notepad++ to edit.

- b) The following changes in RED are additons to the build.prop, those in BLUE are changes and those notes in GREEN, are simply that.. notes, do not include them. This is an example from a CM7 Nightly, with V6 already installed.

# begin build properties
# autogenerated by buildinfo.sh
ro.build.id=4.5.91
ro.build.display.id=GWK74
ro.build.version.incremental=eng.rmcc.20120212.024936
ro.build.version.sdk=10
ro.build.version.codename=REL
ro.build.version.release=2.3.7
ro.build.date=Sun Feb 12 02:49:52 UTC 2012
ro.build.date.utc=0
ro.build.type=user
ro.build.user=rmcc
ro.build.host=RMCC-TESTING
ro.build.tags=test-keys
ro.product.model=MB860
ro.product.brand=MOTO
ro.product.name=olyatt
ro.product.device=olympus
ro.product.board=olympus
ro.product.cpu.abi=armeabi-v7a
ro.product.cpu.abi2=armeabi
ro.product.manufacturer=Motorola
ro.product.locale.language=en
ro.product.locale.region=US
ro.wifi.channels=
ro.board.platform=tegra
# ro.build.product is obsolete; use ro.product.device
ro.build.product=olympus
# Do not try to parse ro.build.description or .fingerprint
ro.build.description=olympus-user 2.3.4 4.5.91 110625 release-keys
ro.build.fingerprint=MOTO/olyatt/olympus:2.3.4/4.5.91/110625:user/release-keys
ro.cm.device=olympus
# end build properties
#
# system.prop for olympus
#
ro.sf.lcd_density=240
[COLOR="RED"][B]dalvik.vm.heapstartsize=8m
dalvik.vm.heapgrowthlimit=32m[/B][/COLOR]
dalvik.vm.heapsize=[COLOR="BLUE"][B]128m[/B][/COLOR]

#RIL
ro.telephony.ril_class=mototegra
rild.libpath=/system/lib/libmoto_ril.so
persist.ril.mux.noofchannels=9
persist.ril.mux.ttydevice=/dev/ttyHS3
ro.telephony.call_ring.multiple=false
ro.telephony.call_ring.delay=500
persist.ril.modem.ttydevice=/dev/ttySPI0
persist.ril.modem.mode=2
persist.ril.features=0x24
persist.ril.mux.retries=500
persist.ril.mux.sleep=2
ro.kernel.android.ril=yes
persist.ril.pppd.start.fail.max=16
mobiledata.interfaces=ppp0
ro.ril.ntmodeglobal=true

#Define TCP buffer sizes for various networks
#ReadMin, ReadInitial, ReadMax, WriteMin, WriteInitial, WriteMax,
net.tcp.buffersize.default=131072,262144,524288,4096,16384,147456
net.tcp.buffersize.wifi=131072,262144,524288,4096,16384,147456
net.tcp.buffersize.hspa=131072,262144,524288,4096,16384,147456
net.tcp.buffersize.umts=131072,262144,524288,4096,16384,147456
net.tcp.buffersize.edge=16384,32768,65536,4096,16384,32768
net.tcp.buffersize.gprs=4096,8192,12288,4096,8192,12288

# Default network type.
# 0 -> WCDMA/3G preferred
ro.telephony.default_network=0

# Mount the internal SD card, too
ro.additionalmounts=/mnt/emmc

#special moto usb handling
ro.usb.use_custom_service=1

# Time between scans in seconds. Keep it high to minimize battery drain.
# This only affects the case in which there are remembered access points,
# but none are in range.
wifi.supplicant_scan_interval=[COLOR="BLUE"][B]60[/B][/COLOR] [COLOR="LIME"]<---- or 120 if you perfer a long interval time[/B][/COLOR]

# To set wifi (AP) driver's firmware path
ro.wifi-ap.fw-path=/system/etc/wl/sdio-g-cdc-roml-reclaim-wme-apsta-idauth-minioctl.bin

ro.bt.bdaddr_path=/pds/bt/bt_bdaddr

# use 1% battery steps
ro.product.use_charge_counter=1

#OpenGL ES version
ro.opengles.version = 131072

# Forbid format of these partitions in mount menu :
ro.cwm.forbid_format=/misc,/radio,/pds,/bootloader,/recovery,/efs

# Battery light while charging, enabled by default
ro.battery_light=true

# Allow people to exchange sdcard and emmc mountpoints from CMParts
ro.vold.switchablepair=/mnt/sdcard,/mnt/emmc

# Tegra debugging
persist.tegra.nvlog.level=4
#persist.tegra.nvlog.14.level=5

# DRM
persist.tegra.drmlib.asfdrm=libnvdrm.so
Drmdll.asfdrm=libnvdrm.so

# Set locale to English US by default
ro.product.locale.language=en
ro.product.locale.region=US

# Enable detailed GC data and SMP dexopt
dalvik.vm.dexopt-flags=m=y,u=n

[COLOR="RED"][B]# Bravia Engine
ro.service.swiqi.supported=true
persist.service.swiqi.enable=1[/B][/COLOR] [COLOR="LIME"]<---- Only use this if you're going to add the additonal addons from .zip below. [/COLOR]

#
# ADDITIONAL_BUILD_PROPERTIES
#
keyguard.no_require_sim=true
ro.rommanager.developerid=cyanogenmodnightly
ro.url.legal=http://www.google.com/intl/%s/mobile/android/basic/phone-legal.html
ro.url.legal.android_privacy=http://www.google.com/intl/%s/mobile/android/basic/privacy.html
ro.com.google.clientidbase=android-google
ro.com.android.wifi-watchlist=GoogleGuest
ro.setupwizard.enterprise_mode=1
ro.com.android.dateformat=MM-dd-yyyy
ro.com.android.dataroaming=false
ro.config.ringtone=Playa.ogg
ro.config.notification_sound=regulus.ogg
ro.config.alarm_alert=Alarm_Beep_03.ogg
persist.sys.themeId=Cyanbread
persist.sys.themePackageName=com.tmobile.theme.Cyanbread
ro.modversion=CyanogenMod-7-02122012-NIGHTLY-Olympus
ro.setupwizard.mode=OPTIONAL
net.bt.name=Android
dalvik.vm.stack-trace-file=/data/anr/traces.txt

[COLOR="RED"][B]# Tweaks
# Touch response tweaks
Debug.performance.tuning=1
video.accelerate.hw=1
windowsmgr.max_events_per_sec=70

# Battery tweaks
ro.ril.disable.power.collapse=0
pm.sleep_mode=1

# Dialing out Fixes
ro.lge.proximity.delay=25
mot.proximity.delay=25
ro.telephony.call_ring.delay=0
# End Tweaks[/B][/COLOR]

# V6 SuperCharger, OOM Grouping & Priority Fixes created by zeppelinrox.
#
# DO NOT DELETE COMMENTS. DELETING COMMENTS WILL BREAK UNINSTALL ROUTINE!
#
# BEGIN OOM_MEM_Settings
ro.FOREGROUND_APP_MEM=2048
ro.VISIBLE_APP_MEM=4096
ro.PERCEPTIBLE_APP_MEM=1024
ro.HEAVY_WEIGHT_APP_MEM=51200
ro.SECONDARY_SERVER_MEM=51200
ro.BACKUP_APP_MEM=56320
ro.HOME_APP_MEM=1024
ro.HIDDEN_APP_MEM=56320
ro.EMPTY_APP_MEM=70400
# END OOM_MEM_Settings
# BEGIN OOM_ADJ_Settings
ro.FOREGROUND_APP_ADJ=0
ro.VISIBLE_APP_ADJ=4
ro.PERCEPTIBLE_APP_ADJ=2
ro.HEAVY_WEIGHT_APP_ADJ=5
ro.SECONDARY_SERVER_ADJ=7
ro.BACKUP_APP_ADJ=6
ro.HOME_APP_ADJ=1
ro.HIDDEN_APP_MIN_ADJ=12
ro.EMPTY_APP_ADJ=15
# END OOM_ADJ_Settings
# Miscellaneous Tweaks!
persist.sys.purgeable_assets=1
wifi.supplicant_scan_interval=180
windowsmgr.max_events_per_sec=200
pm.sleep_mode=1
# 3G TurboCharger Enhancment!
net.tcp.buffersize.default=6144,87380,1048576,6144,87380,1048576
net.tcp.buffersize.wifi=87380,1048576,2097152,87380,1048576,2097152
net.tcp.buffersize.lte=87380,524288,1048576,87380,524288,1048576
net.tcp.buffersize.hsdpa=6144,87380,1048576,6144,87380,1048576
net.tcp.buffersize.evdo_b=6144,87380,1048576,6144,87380,1048576
net.tcp.buffersize.umts=6144,87380,1048576,6144,87380,1048576
net.tcp.buffersize.gprs=6144,87380,1048576,6144,87380,1048576
net.tcp.buffersize.edge=6144,87380,524288,6144,16384,262144
net.tcp.buffersize.hspa=6144,87380,524288,6144,16384,262144
# End of V6 SuperCharged Entries.

6) Add-ons, & Tweaks

*The attached flashable .zip contains the fllowing:

*See Neutrino ROM OP for more explanation.

- MIUI Camera (might want to freeze your stock CM7 camera w/ Tibackup)

- DarkyROM's fast zipalignment

- Bravia Engine

- Ext4 w/o journaling

- U.S.A. GPS Mod (if you are not in the U.S. delete gps.conf from /system/etc in the .zip & see Neutrino ROM OP for other countries)

- Mounting Tweak

REMEMBER TO MAKE A RECOVERY BACKUP FIRST BEFORE ATTEMPTING ANY OF THE ABOVE, JUST IN CASE!!!!

**Edit**

Turned out a little longer than I had originally anticipated... guess I will also add to N00B Guide. :)