[FAQ & Toubleshooing] ThinkingBridge ROM JB 4.2.2 - HTC Sensation

[SIZE=+3]This thread has been created strictly for
Questions & Troubleshooting[/SIZE]
[SIZE=+2]Specific to[/SIZE]
{
"lightbox_close": "Close",
"lightbox_next": "Next",
"lightbox_previous": "Previous",
"lightbox_error": "The requested content cannot be loaded. Please try again later.",
"lightbox_start_slideshow": "Start slideshow",
"lightbox_stop_slideshow": "Stop slideshow",
"lightbox_full_screen": "Full screen",
"lightbox_thumbnails": "Thumbnails",
"lightbox_download": "Download",
"lightbox_share": "Share",
"lightbox_zoom": "Zoom",
"lightbox_new_window": "New window",
"lightbox_toggle_sidebar": "Toggle sidebar"
}
[SIZE=+2]This thread has been created for people to share issues, question and help
while using this version of ThinkingBridge ROM​[/SIZE]
Link to ROM thread
PLEASE make sure to thank developer for the dedication to this ROM
Please do not clutter the Development thread with non development-related chatter
*​
F.A.Q. and COMMON ISSUES
Scripts in /etc/init.d/ folder doesn't work. Why?
At the moment you can use one of these apps as a workaround. They will run the 99kernel script (or any other script you like) at boot.
Script Manager: Play Store Link
Universal Init.d: Play Store Link
Because I noticed some errors with CPU settings while running the 99kernel script, I suggest to read the second post and to use the custom script posted there. It's basically the same script, but with CPU settings disabled.
To configure your CPU, you can find the useful tool coming with the ROM under Settings -> Common -> CPU Settings.
My phone gets hot and/or I have random reboots on low battery level.
This could be caused by your kernel settings. Please follow the instructions to run the 99kernel script with this configuration:
GPU=266667000
DD=200000000
FSYNC=2
Now set your CPU with this configuration (don't know how? read the first Q&A above):
Governor CPU: BADASS
Minimum CPU frequency: 384 MHz
Maximum CPU frequency: 1566 MHz
These settings should ensure good stability and good performance.
My UI starts to flicker, specially when I'm on lockscreen.
This is a beahvior experienced by some users. Developers are still looking for a fix. Any temporary solution/workaround will be posted here.
I'd really like to help in solving the "screen flickering issue". I'd like to get some informations to isolate the problem. Please answer these questions and post them here (when you have time and if you want, nothing mandatory!)
Are you disabling hardware overlay from Developer options?
Albino said that screen flickering can be caused by a memory leak in the framework: how many lockscreen widgets do you have? Do you use Ribbons?
Which kernel are you using?
Are you overclocking CPU or GPU? Please post your settings.
In your specific case: the problem is completely random, or does it happen on specific apps/actions?

init.d scripts
Hi guys! I hope you'll find this thread useful.
Sorry for crossposting, but I wanted to keep first post as clean as possible.
I'm trying to understand why scripts in init.d folder does not work. Searching around the web I found out that the android system can be set to run them or not by configuring something in the file init.rc. But I really don't know how to modify it and I read that this file shouldn't be modified by hand because it is re-created at every boot. I'm not a real expert. Can someone confirm this?
By the way I found a simple workaround to run the 99kernel script at boot.
I installed Script manager and I runned the 99kernel script. The script runs, but it gives "file not found" errors when trying to set CPU settings. I think this is beacuse the ROM handles this settings in a different way.
The other configurations in the script (like sweep2wake) are working properly. So I copied the script and I commented out the section related to CPU and I/O scheduler. Here's the code.
Code:
#!/system/bin/sh
#Script originally made by Axetilen. Modified by Sultan (android1234567)
#Updated for albinoman887's ChronicKernel (98% of the credit goes to android1234567. Thanks so much man :)
#Updated for ChronicKernel-linaro
# Configure your options here #
# Config default CPU Gonvernor (Disabled by default: When disabled uses internal Kernel setting)
# For better battery life switch to badass
# Kernel Default: ondemand
# Possible values
# badass
# ondemand
# interactive
#= lagfee
# performance
#GOV=badass
# Config I/O scheduler
# deadline
# cfq
# noop
# vr
# sio (default)
#IO=sio
# Config CPU max frequency
# Default: 1566000 (1566Mhtz)
# Overclockable to - 1836000 (1836Mhtz)
# for badass set to 1566mhtz (best performance/battery life)
#MAXFREQ=1566000
# Config CPU min frequency
# Default: 384000 (384Mhtz)
# Range 384000 - 1944000 (384Mhtz - 1944Mhtz)
#MINFREQ=384000
# Config 3D GPU clock
# 228571000 = 228mhz
# 266667000 = 267mhz (default)
# 300000000 = 300mhz (Recomended For balance of Performance and Battery life)
# 320000000 = 320mhz
GPU=266667000
# Config 2D GPU clock
# 145455000 = 145mhz
# 160000000 = 160mhz
# 200000000 = 200mhz (default)
# 228571000 = 228mhz (Recomended For balance of Performance and Battery life)
# 266667000 = 267mhz
DD=200000000
# Badass
# possible values
# 1 = performance
# 2 = balanced
# 3 = battery saving
#BADASS=2
# Enable Sweep2Wake
# 0 = disabled (default)
# 1 = enabled
# 2 = enabled (with no button backlight during sweep)
SWEEP=2
# Enable Fastcharge
# 0 = disabled
# 1 = substitute AC to USB charging always
# 2 = substitute AC to USB charging only if there is no USB peripheral detected
FASTCHARGE=0
# Fsync Control
# Disabled by default (recomended)
# 2 = Fsync disabled
# 1 = Fsync enabled
FSYNC=2
# TUN
# Disabled by default
# 0 = Disabled
# 1 = Enabled
TUN=0
# End of configurable options #
################# DON'T CHANGE ANYTHING BELOW THIS LINE #################
## Config CPU governor
# echo "$GOV" > /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor
# echo "$GOV" > /sys/devices/system/cpu/cpu1/cpufreq/scaling_governor
# Config 3D GPU setting
chmod 644 /sys/devices/platform/kgsl-3d0.0/kgsl/kgsl-3d0/max_gpuclk
chmod 644 /sys/devices/platform/kgsl-3d0.0/kgsl/kgsl-3d0/gpuclk
echo $GPU > /sys/devices/platform/kgsl-3d0.0/kgsl/kgsl-3d0/max_gpuclk
echo $GPU > /sys/devices/platform/kgsl-3d0.0/kgsl/kgsl-3d0/gpuclk
# Config 2D GPU setting
chmod 644 /sys/devices/platform/kgsl-2d0.0/kgsl/kgsl-2d0/max_gpuclk
chmod 644 /sys/devices/platform/kgsl-2d0.0/kgsl/kgsl-2d0/gpuclk
chmod 644 /sys/devices/platform/kgsl-2d1.1/kgsl/kgsl-2d1/max_gpuclk
chmod 644 /sys/devices/platform/kgsl-2d1.1/kgsl/kgsl-2d1/gpuclk
echo $DD > /sys/devices/platform/kgsl-2d0.0/kgsl/kgsl-2d0/max_gpuclk
echo $DD > /sys/devices/platform/kgsl-2d0.0/kgsl/kgsl-2d0/gpuclk
echo $DD > /sys/devices/platform/kgsl-2d1.1/kgsl/kgsl-2d1/max_gpuclk
echo $DD > /sys/devices/platform/kgsl-2d1.1/kgsl/kgsl-2d1/gpuclk
# Config USB forced fastcharge
chmod 644 /sys/kernel/fast_charge/force_fast_charge
echo "$FASTCHARGE" > /sys/kernel/fast_charge/force_fast_charge
# Config Sweep2Wake (with compatibility with NLJ's fix)
if [ "$SWEEP" = "0" ]
then
chown radio.system /sys/android_touch/sweep2wake
chmod 664 /sys/android_touch/sweep2wake
echo 0 > /sys/android_touch/sweep2wake
fi
if [ "$SWEEP" = "1" ]
then
chown radio.system /sys/android_touch/sweep2wake
chmod 664 /sys/android_touch/sweep2wake
echo 1 > /sys/android_touch/sweep2wake
fi
if [ "$SWEEP" = "2" ]
then
chown radio.system /sys/android_touch/sweep2wake
chmod 664 /sys/android_touch/sweep2wake
echo 2 > /sys/android_touch/sweep2wake
fi
# Config badass CPU Gonvernor
#CUR_GOV="`cat /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor`"
#echo badass > /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor
#sleep 3
#case ${BADASS} in
# 1)
# $L "badass: setting performance oriented configuration"
# echo 1188000 > /sys/devices/system/cpu/cpufreq/badass/two_phase_freq;
# echo 1512000 > /sys/devices/system/cpu/cpufreq/badass/three_phase_freq;
# echo 120 > /sys/devices/system/cpu/cpufreq/badass/busy_threshold;
# echo 80 > /sys/devices/system/cpu/cpufreq/badass/busy_clr_threshold;
# echo 8 > /sys/devices/system/cpu/cpufreq/badass/semi_busy_threshold;
# echo 4 > /sys/devices/system/cpu/cpufreq/badass/semi_busy_clr_threshold;
# ;;
# 2)
# $L "badass: setting balanced configuration"
# echo 918000 > /sys/devices/system/cpu/cpufreq/badass/two_phase_freq;
# echo 1188000 > /sys/devices/system/cpu/cpufreq/badass/three_phase_freq;
# echo 50000 > /sys/devices/system/cpu/cpufreq/badass/sampling_rate
# echo 130 > /sys/devices/system/cpu/cpufreq/badass/busy_threshold;
# echo 100 > /sys/devices/system/cpu/cpufreq/badass/busy_clr_threshold;
# echo 14 > /sys/devices/system/cpu/cpufreq/badass/semi_busy_threshold;
# echo 6 > /sys/devices/system/cpu/cpufreq/badass/semi_busy_clr_threshold;
# ;;
# 3)
# $L "badass: setting battery saving configuration"
# echo 918000 > /sys/devices/system/cpu/cpufreq/badass/two_phase_freq;
# echo 1188000 > /sys/devices/system/cpu/cpufreq/badass/three_phase_freq;
# echo 140 > /sys/devices/system/cpu/cpufreq/badass/busy_threshold;
# echo 110 > /sys/devices/system/cpu/cpufreq/badass/busy_clr_threshold;
# echo 80 > /sys/devices/system/cpu/cpufreq/badass/semi_busy_threshold;
# echo 20 > /sys/devices/system/cpu/cpufreq/badass/semi_busy_clr_threshold;
# ;;
#esac
#echo ${CUR_GOV} > /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor
# Config CPU Frequency
# chmod 644 /sys/devices/system/cpu/cpu0/cpufreq/scaling_max_freq
# echo $MAXFREQ > /sys/devices/system/cpu/cpu0/cpufreq/scaling_max_freq
# chmod 644 /sys/devices/system/cpu/cpu0/cpufreq/scaling_min_freq
# echo $MINFREQ > /sys/devices/system/cpu/cpu0/cpufreq/scaling_min_freq
#
# chmod 644 /sys/devices/system/cpu/cpu1/cpufreq/scaling_max_freq
# echo $MAXFREQ > /sys/devices/system/cpu/cpu1/cpufreq/scaling_max_freq
# chmod 644 /sys/devices/system/cpu/cpu1/cpufreq/scaling_min_freq
# echo $MINFREQ > /sys/devices/system/cpu/cpu1/cpufreq/scaling_min_freq
# Config i/o scheduler
# chmod 644 /sys/block/mmcblk0/queue/scheduler
# echo "$IO" > /sys/block/mmcblk0/queue/scheduler
# chmod 644 /sys/block/mmcblk1/queue/scheduler
# echo "$IO" > /sys/block/mmcblk1/queue/scheduler
# Config Fsync
if [ "$FSYNC" = "2" ]
then
echo "0" > sys/class/misc/fsynccontrol/fsync_enabled
fi
# Config TUN
if [ "${TUN}" = "1" ]; then
if [ -e /system/lib/modules/tun.ko ] ; then
insmod /system/lib/modules/tun.ko
$L "Inserted tun kernel module."
fi
fi
This is the script with my setup. Modify it with your preferred settings.
With Script Manager you can run this script from every directory (I'm keeping it on my SD card) and you can run it at boot.
Open the script from Script Manager and select "Root" option and "Boot" option.
I also wrote a script to check if the settings are all ok. You can run it WITHOUT root privileges with Script Manager. Here's the code.
Code:
#!/system/bin/sh
# Simple script to check GPU frequencies and other kernel features status
# Created by TheWall
echo -n "3DGPU max: "
cat /sys/devices/platform/kgsl-3d0.0/kgsl/kgsl-3d0/max_gpuclk
echo -n "3DGPU curr: "
cat /sys/devices/platform/kgsl-3d0.0/kgsl/kgsl-3d0/gpuclk
echo -n "2DGPU max: "
cat /sys/devices/platform/kgsl-2d1.1/kgsl/kgsl-2d1/max_gpuclk
echo -n "2DGPU curr: "
cat /sys/devices/platform/kgsl-2d1.1/kgsl/kgsl-2d1/gpuclk
echo -n "Fast Charge: "
FC=$(cat /sys/kernel/fast_charge/force_fast_charge)
if [ "$FC" = "0" ]
then
echo "disabled"
fi
if [ "$FC" = "1" ]
then
echo "substitute AC to USB charging always"
fi
if [ "$FC" = "2" ]
then
echo "substitute AC to USB charging only if there is no USB peripheral detected"
fi
echo -n "Sweep2Wake: "
S2W=$(cat /sys/android_touch/sweep2wake)
if [ "$S2W" = "0" ]
then
echo "disabled"
fi
if [ "$S2W" = "1" ]
then
echo "enabled"
fi
if [ "$S2W" = "2" ]
then
echo "enabled (no button backlight)"
fi
echo -n "Fsync: "
FS=$(cat sys/class/misc/fsynccontrol/fsync_enabled)
if [ "$FS" = "0" ]
then
echo "disabled"
else
echo "enabled"
fi
This is just a workaround, not a real fix. I'd like to know something more about this by ROM's dev.
Ps: as usual on xda, I'm not responsible for how you use the scripts in this post. If you don't know what you're doing don't mess with it!

Hi.. From where can I disable the google search bar.. I'm sorry but I'm not able to find any option for it...
Sent from my HTC Sensation using Tapatalk 4 Beta

nick_862003 said:
Hi.. From where can I disable the google search bar.. I'm sorry but I'm not able to find any option for it...
Sent from my HTC Sensation using Tapatalk 4 Beta
Click to expand...
Click to collapse
Google search bar? Do you mean the widget? Can't you tap and drag it to the X?

TheWall-[ITA] said:
Google search bar? Do you mean the widget? Can't you tap and drag it to the X?
Click to expand...
Click to collapse
Nope not the widget but permanent google search bar.. Please refer the attached screenshot..!
Sent from my HTC Sensation using Tapatalk 4 Beta

nick_862003 said:
Nope not the widget but permanent google search bar.. Please refer the attached screenshot..!
Sent from my HTC Sensation using Tapatalk 4 Beta
Click to expand...
Click to collapse
It must be something related to the default launcher. I use Nova, so I can't help you... sorry

nick_862003 said:
Nope not the widget but permanent google search bar.. Please refer the attached screenshot..!
Sent from my HTC Sensation using Tapatalk 4 Beta
Click to expand...
Click to collapse
you remove it from the trebuchet settings: homescreen > menu > trebuchet settings > homscreen

About the init.d scripts, I do not know what to edit, I also experienced it with Elegancia Sense 3.6 ROM, and as someone told me, I installed Universal Init.d (find it in play store), you can easily force the scripts to be run on boot.
Sent from my HTC Sensation XE with Beats Audio Z715e using xda app-developers app

ashkan-khatar said:
About the init.d scripts, I do not know what to edit, I also experienced it with Elegancia Sense 3.6 ROM, and as someone told me, I installed Universal Init.d (find it in play store), you can easily force the scripts to be run on boot.
Sent from my HTC Sensation XE with Beats Audio Z715e using xda app-developers app
Click to expand...
Click to collapse
Really cool info! Thanks!
I'm on another ROM right now, but I'm going to reflash thinkingbridge soon and try this. :good:

Yes that Universal inid.t.apk method works perfectly....
CONFIRMED

Hi guys i managed fix init.d and some init.rc in boot.img...
Now the rom superb with my custom 99kernel.
Once fresh install all working perfect even sweep2wake too...
If OP approved i can reupload this rom..
Sent from my GT-N7000 using xda app-developers app

pyramid-X said:
Hi guys i managed fix init.d and some init.rc in boot.img...
Now the rom superb with my custom 99kernel.
Once fresh install all working perfect even sweep2wake too...
If OP approved i can reupload this rom..
Sent from my GT-N7000 using xda app-developers app
Click to expand...
Click to collapse
That's really really cool. Ask the developer in the ROM thread or send him a PM. :good:

S manager! how didn't i think about it before! you remind of me! finally can enable s2w on boot efficiently and cleanly!
big thanks to you OP!

AJ205 said:
you remove it from the trebuchet settings: homescreen > menu > trebuchet settings > homscreen
Click to expand...
Click to collapse
Thanx.. It worked
Sent from my HTC Sensation using Tapatalk 4 Beta

hi Guys,
I just installed this awesome ROM a few days a go. I like it very much but I'm having a problem with it.
The problem I mean is a flickering lockscreen and sometimes even the whole UI flickers so that I have to make a complete reboot.
I'm not sure but it seems at if the flickering only happens when my battery has less than 50% of its power.
Maybe someone can help me with this problem
best regards from Germany

eltasmanico said:
hi Guys,
I just installed this awesome ROM a few days a go. I like it very much but I'm having a problem with it.
The problem I mean is a flickering lockscreen and sometimes even the whole UI flickers so that I have to make a complete reboot.
I'm not sure but it seems at if the flickering only happens when my battery has less than 50% of its power.
Maybe someone can help me with this problem
best regards from Germany
Click to expand...
Click to collapse
I had this the first days but it went away after a couple of reboots, haven't seen it for over a week now. I know this isn't much help but if it's a problem before the system have build up its cache you might just have to sit tight and wait? Anyone else experience this?
Skickat från min HTC Sensation via Tapatalk 2

thank you for your quick answer.
Today I do not have this problem yet and my battery is down to 45% now. Maybe I will be lucky like you and the problem solves itselve like it was with your phone :fingers-crossed:

eltasmanico said:
hi Guys,
I just installed this awesome ROM a few days a go. I like it very much but I'm having a problem with it.
The problem I mean is a flickering lockscreen and sometimes even the whole UI flickers so that I have to make a complete reboot.
I'm not sure but it seems at if the flickering only happens when my battery has less than 50% of its power.
Maybe someone can help me with this problem
best regards from Germany
Click to expand...
Click to collapse
jorra said:
I had this the first days but it went away after a couple of reboots, haven't seen it for over a week now. I know this isn't much help but if it's a problem before the system have build up its cache you might just have to sit tight and wait? Anyone else experience this?
Skickat från min HTC Sensation via Tapatalk 2
Click to expand...
Click to collapse
Welcome guys!
Well, our ROM is based on the CM10.1 ROM from Ablinoman887. This problem has been reported several times from some users (not everybody) and the developer is trying to solve it.
Personally, I've never had this problem in any CM10.1 based ROM I tried so far. I hope it will get solved :good:

+1...
Sent from my GT-N7000 using xda app-developers app

just let's hope that this issue will be fixed in the near time or that it will be like it was at jorra's phone

Related

[MOD]Auto Compcache & backup Swap for CM.

Many people having issues getting compcache/swap working, so here we go.
Replace the content of your userinit.sh with this code. This code was created by uwonsom and modified by yours truely and lastely by Alapapa. to see the original work click Here.
I've also attached the file ready for you to throw directly into /system/sd.
{from original post}
The current setting enables compcache with backing_swap (a physical partition). It can also be tested with linux-swap only--just comment out lines beginning with insmod, mknod, and swapon /dev/ramzswap0. Then uncomment swapon /dev/block/mmcblk0p3.
If you wish to test it out only with compcache, comment out the insmod line with backing_swap and uncomment the insmod line with disksize_kb.
{/from original post}
Code:
#!/system/bin/sh
##adb push userinit.sh /system/sd/
uname_r=`uname -r`
moddir=`find /system/modules -type d -name $uname_r`
insmod=/system/bin/insmod
$insmod $moddir/compcache/xvmalloc.ko;
#$insmod $moddir/compcache/ramzswap.ko disksize_kb=32768;
$insmod $moddir/compcache/ramzswap.ko backing_swap=/dev/block/mmcblk0p3;
mknod /dev/ramzswap0 b 253 0;
echo 20 > /proc/sys/vm/swappiness;
# Experimental settings
echo 1 > /proc/sys/vm/page-cluster; # default: 3 Changes Page clustering from 8 to 2.
echo 5 > /proc/sys/vm/laptop_mode; # default: 0 Helps keep SSD from getting worn.
echo 5000 > /proc/sys/vm/dirty_expire_centisecs; # default: 3000
echo 800 > /proc/sys/vm/dirty_writeback_centisecs; # default: 500
echo 10 > /proc/sys/vm/dirty_background_ratio; # default: 5
echo 16 > /proc/sys/vm/dirty_ratio; # default: 10
#
swapon /dev/ramzswap0;
#swapon /dev/block/mmcblk0p3;
#Over Clock CPU when in use, puts at lower freq when idol. # if you don't want it.
echo 128000 > /sys/devices/system/cpu/cpu0/cpufreq/scaling_min_freq;
echo 528000 > /sys/devices/system/cpu/cpu0/cpufreq/scaling_max_freq;
Edit: Thank Alapapa for the new code, will now work with all versions of CM 3.6.7 and higher!
Thanks! But it's not going to work if Cyanogen changes the kernal again.
2.6.29.6 is current... but probably not for long.
does the attached userinit come with those changes already or do u have to modd theose changes over to it
here's the code that will work if kernel version changes:
Code:
#!/system/bin/sh
##adb push userinit.sh /system/sd/
uname_r=`uname -r`
moddir=`find /system/modules -type d -name $uname_r`
insmod=/system/bin/insmod
$insmod $moddir/compcache/xvmalloc.ko;
#$insmod $moddir/compcache/ramzswap.ko disksize_kb=32768;
$insmod $moddir/compcache/ramzswap.ko backing_swap=/dev/block/mmcblk0p3;
mknod /dev/ramzswap0 b 253 0;
echo 20 > /proc/sys/vm/swappiness;
# Experimental settings
echo 1 > /proc/sys/vm/page-cluster; # default: 3 Changes Page clustering from 8 to 2.
echo 5 > /proc/sys/vm/laptop_mode; # default: 0 Helps keep SSD from getting worn.
echo 5000 > /proc/sys/vm/dirty_expire_centisecs; # default: 3000
echo 800 > /proc/sys/vm/dirty_writeback_centisecs; # default: 500
echo 10 > /proc/sys/vm/dirty_background_ratio; # default: 5
echo 16 > /proc/sys/vm/dirty_ratio; # default: 10
#
swapon /dev/ramzswap0;
#swapon /dev/block/mmcblk0p3;
#Over Clock CPU when in use, puts at lower freq when idol. # if you don't want it.
echo 128000 > /sys/devices/system/cpu/cpu0/cpufreq/scaling_min_freq;
echo 528000 > /sys/devices/system/cpu/cpu0/cpufreq/scaling_max_freq;
thanks Alapapa, changed the script uptop and the one attached to your modifed script.
Denkai said:
thanks Alapapa, changed the script uptop and the one attached to your modifed script.
Click to expand...
Click to collapse
De nada...I got the kernel version magic from some thread on here at some point.
Cheers!
Denkai said:
# Experimental settings
echo 1 > /proc/sys/vm/page-cluster; # default: 3 Changes Page clustering from 8 to 2.
echo 5 > /proc/sys/vm/laptop_mode; # default: 0 Helps keep SSD from getting worn.
echo 5000 > /proc/sys/vm/dirty_expire_centisecs; # default: 3000
echo 800 > /proc/sys/vm/dirty_writeback_centisecs; # default: 500
echo 10 > /proc/sys/vm/dirty_background_ratio; # default: 5
echo 16 > /proc/sys/vm/dirty_ratio; # default: 10
#
swapon /dev/ramzswap0;
#swapon /dev/block/mmcblk0p3;
#Over Clock CPU when in use, puts at lower freq when idol. # if you don't want it.
echo 128000 > /sys/devices/system/cpu/cpu0/cpufreq/scaling_min_freq;
echo 528000 > /sys/devices/system/cpu/cpu0/cpufreq/scaling_max_freq;
Click to expand...
Click to collapse
Any reason for setting page cluster to 1 instead of 0, as I think i saw earlier in the thread being recommended? Have you had better performance w/ setting it to 1? Thanks
I personally haven't screwed around with the paging. you may get better, you may not.
You could do away with this line since the CPU already scales to 528MHz:
Code:
echo 528000 > /sys/devices/system/cpu/cpu0/cpufreq/scaling_max_freq;
Click to expand...
Click to collapse
Add the following.:
Code:
echo 200 > /sys/devices/system/cpu/cpu0/cpufreq/ondemand/powersave_bias; # default: 0
#echo 2000000 > /sys/devices/system/cpu/cpu0/cpufreq/ondemand/sampling_rate; # For build <=3.9.1
"The powersave_bias parameter modifies the behavior of the ondemand governor to save more power by reducing the target frequency by a specified percentage. By default, (powersave_bias = 0), the ondemand governor selects the minimum processor frequency that can still complete a workload with minimal idle time. Doing so should result in the highest performance to power efficiency ratio. In some cases, you might prefer a greater emphasis on power efficiency than performance. In this case, set the powersave_bias parameter to a value between 1 and 1000 to reduce the target frequency by one-thousandth of that value. For example, set powersave_bias to 100 for a one-tenth reduction in target frequency. In this case, if the governor chooses a target frequency of 2 GHz (with powersave_bias = 100), the governor instead will request 1.8GHz – a one-tenth reduction. If 1.8 GHz is an exact match with an available hardware frequency (listed in the scaling_available_freq parameter), the processor is set to this frequency. If 1.8 GHz is not available, the processor fluctuates between the closest available upper and lower frequencies for an average frequency of 1.8 GHz."
If you notice lag, I would set it to 150; 100 was not much of a benefit. 250 will give you longer battery life for sure, but anything over that could result in major lag.
I pushed the file to /system/sd
I run cmd #free and there's 0 under swap
I run cmd #cat /proc/ramzswap and get an error
When I look in /system/sd the userinit.sh file is in lost+found... Did I do something wrong?
bhilgeman said:
I pushed the file to /system/sd
I run cmd #free and there's 0 under swap
I run cmd #cat /proc/ramzswap and get an error
When I look in /system/sd the userinit.sh file is in lost+found... Did I do something wrong?
Click to expand...
Click to collapse
Yeah same here (except my userinit.sh is not being moved to lost+found).
I ensured the permissions were fine... what am I doing wrong?
runderekrun said:
Yeah same here (except my userinit.sh is not being moved to lost+found).
I ensured the permissions were fine... what am I doing wrong?
Click to expand...
Click to collapse
Did you execute it or reboot? Just putting it there does nothing by itself.
In a shell, just do /system/sd/userinit.sh
What happens?
ttabbal said:
Did you execute it or reboot? Just putting it there does nothing by itself.
In a shell, just do /system/sd/userinit.sh
What happens?
Click to expand...
Click to collapse
you should not have to execute it.
ttabbal said:
Did you execute it or reboot? Just putting it there does nothing by itself.
In a shell, just do /system/sd/userinit.sh
What happens?
Click to expand...
Click to collapse
uwonsum said:
you should not have to execute it.
Click to expand...
Click to collapse
Yeah I thought Cyanogen's roms would auto-run userinit.sh?
Anyway trying to manually run it just throws up errors.
Is this correct for a linux swap partition?
I was unsure about lines
$insmod $moddir/compcache/xvmalloc.ko;
$insmod $moddir/compcache/ramzswap.ko
Does the $ mean i do not comment them out?
Code:
#!/system/bin/sh
## adb push userinit.sh /system/sd
#insmod /system/modules/lib/modules/2.6.29-cm/compcache/xvmalloc.ko;
#insmod /system/modules/lib/modules/2.6.29-cm/compcache/ramzswap.ko disksize_kb=32768;
#insmod /system/modules/lib/modules/2.6.29-cm/compcache/ramzswap.ko memlimit_kb=32768
#backing_swap=/dev/block/mmcblk0p3;
#insmod /system/modules/lib/modules/2.6.29-cm/compcache/ramzswap.ko
#backing_swap=/dev/block/mmcblk0p3;
#mknod /dev/ramzswap0 b 253 0;
echo 16 > /proc/sys/vm/swappiness; # default: 60
## Experimental settings
echo 1 > /proc/sys/vm/page-cluster; # default: 3
echo 5 > /proc/sys/vm/laptop_mode; # default: 0
echo 5000 > /proc/sys/vm/dirty_expire_centisecs; # default: 3000
echo 800 > /proc/sys/vm/dirty_writeback_centisecs; # default: 500
echo 10 > /proc/sys/vm/dirty_background_ratio; # default: 5
echo 16 > /proc/sys/vm/dirty_ratio; # default: 10
##
#swapon /dev/ramzswap0;
swapon /dev/block/mmcblk0p3;
## Additional experimental settings
echo 128000 > /sys/devices/system/cpu/cpu0/cpufreq/scaling_min_freq; # default: 245760
##
exit;
## commands to display useful system info
## **Do not uncomment**
# free
# top -m 8; displays only 8 processes
# cat /proc/swaps
# cat /proc/ramzswap0
# cat /proc/meminfo
# sysctl -a | grep vm
# cat /sys/devices/system/cpu/cpu0/cpufreq/stats/time_in_state
# vmstat -d 5 -n 10
Also i am stuck at work, so not ADB for me (don't want to install drivers on work pc)
Can i do this with userinit.sh on root of card
Code:
Code:
# su
# mount -o remount,rw -t yaffs2 /dev/block/mtdblock3 /system
# cp /sdcard/userinit.sh /system/sd/userinit.sh
# chmod 755 /system/sd/userinit.sh
ekeefe41 said:
Is this correct for a linux swap partition?
Click to expand...
Click to collapse
Yes, and you should also comment out this backing_swap=/dev/block/mmcblk0p3;
uwonsum said:
Yes, and you should also comment out this backing_swap=/dev/block/mmcblk0p3;
Click to expand...
Click to collapse
ok, how about now ^^ i edited it
runderekrun said:
Yeah I thought Cyanogen's roms would auto-run userinit.sh?
Anyway trying to manually run it just throws up errors.
Click to expand...
Click to collapse
You have to execute it somehow. Cyanogen's roms do it on boot, that's why I said "execute OR reboot".
If you can't run it manually, it's probably not working on boot either. What errors is it throwing up?
ekeefe41 said:
ok, how about now ^^ i edited it
Click to expand...
Click to collapse
It's fine the way it is. But if you look at this thread, some of my experimental settings have been implemented into a new userinit.sh script with a user.conf file that makes things so easy where you wont ever have to touch the userinit.sh script.
Now, I have edited this new script. I corrected a line that could potentially pose a problem for people using a different kernel. I also added a few more options to the script that can be set in the user.conf file. I will post it on that thread in a few minutes.
ttabbal said:
You have to execute it somehow. Cyanogen's roms do it on boot, that's why I said "execute OR reboot".
If you can't run it manually, it's probably not working on boot either. What errors is it throwing up?
Click to expand...
Click to collapse
Sorry I missed the reboot comment.
I just don't understand it. It will not run the userinit.sh. It is saying it can't find it. If I try to run it with the wrong permissions it gives me a "Permission denied" but as soon as I chmod it too 755 it suddenly can't find the file...
I accidentally pasted the whole userinit.sh text the shell and it started working, so I have no idea whats wrong with this file. None what so ever.

[KERNEL] conservative governor for HTC 2.6.32-15 kernel

This module adds to the kernel the possibility of using the 'conservative' scaling governor. It may be a little less responsive than other governors, but may also result in better battery life overall.
This is from the kernel documentation:
"The CPUfreq governor "conservative", much like the "ondemand" governor, sets the CPU depending on the current usage. It differs in behaviour in that it gracefully increases and decreases the CPU speed rather than jumping to max speed the moment there is any load on the CPU. This behaviour more suitable in a battery powered environment."
By default it will try to increase or decrease the CPU in 5% steps, and will tend to raise relatively slowly under load but decrease very quickly when idle. This means the CPU is likely to spend much more time at the lowest frequency (245MHz unless changed), but will offer the highest frequency when required for a longer period (like watching video).
The module in the attached files is compiled for the 2.6.32.15-g6a358a9 HTC kernel (released with 2.10.405.2) and the -gf9c0527 kernel (2.09.405.8).
To load, copy the module in recovery to /system/lib/modules and run:
insmod /system/lib/modules/cpufreq_conservative.ko
And to select run:
echo "conservative" > /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor
The attached update files will either load the module only, or load and select the module (active version).
Source is unmodified from the original, and thus is GPL compliant.
Hmm, great . On leedroid , waiting for yur flashable file
Sent from LeeDroid powered by HTC Sense using XDA App!
Thanks for sharing, it's great
Thanks..will try it
with kind regards...Alex
Tested and it runs fine for me. Sure enough you can see the CPU go up and down gradually as expected if you monitor it.
I've added a version for the -gf9c0527 kernel too. 'Active' versions will select this governor if flashed - custom ROMs may override this, so check your ROM.
I have added it for version g1fc4045, .ko only
cpufreq_conservative_gd96f2c0
added for version gd96f2c0, .ko only
How about g1fc4045?
SkilletDesire said:
How about g1fc4045?
Click to expand...
Click to collapse
Here it is.
How can i make this module to work with screenstate_scaling module?
screenstate_scaling script:
Code:
#!/system/bin/sh
#
# screenstate_scaling - switch CPU frequency governor on screen state change
# by [email protected] (FloHimself) - and modded NeoPhyTe
IWCONFIG=/system/xbin/iwconfig
AWAKE_GOVERNOR="ondemand"
SLEEP_GOVERNOR="ondemand"
(while [ 1 ]
do
AWAKE=`cat /sys/power/wait_for_fb_wake`
if [ $AWAKE = "awake" ]; then
echo $AWAKE_GOVERNOR > /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor
echo "998400" > /sys/devices/system/cpu/cpu0/cpufreq/scaling_max_freq
echo "245000" > /sys/devices/system/cpu/cpu0/cpufreq/scaling_min_freq
echo "2" > /proc/sys/vm/dirty_background_ratio
echo "5" > /proc/sys/vm/dirty_ratio
echo "3" > /proc/sys/vm/laptop_mode
echo "10000000" > /proc/sys/kernel/sched_latency_ns
echo "4000000" > /proc/sys/kernel/sched_min_granularity_ns
echo "760000" > /proc/sys/kernel/sched_wakeup_granularity_ns
echo "5150" > /proc/sys/kernel/threads-max
echo "20" > /sys/devices/system/cpu/cpu0/cpufreq/ondemand/up_threshold
echo "400000" > /sys/devices/system/cpu/cpu0/cpufreq/ondemand/sampling_rate
echo "0" > /sys/devices/system/cpu/cpu0/cpufreq/ondemand/powersave_bias
echo "0" > /sys/devices/system/cpu/cpu0/cpufreq/ondemand/ignore_nice_load
echo "4000" > /proc/sys/vm/dirty_expire_centisecs
echo "9000" > /proc/sys/vm/dirty_writeback_centisecs
$IWCONFIG eth0 txpower 100mW
log -p i -t screenstate_scaling "*** awake ***: switching CPU frequency governor to -> $AWAKE_GOVERNOR"
AWAKE=
fi
SLEEPING=`cat /sys/power/wait_for_fb_sleep`
if [ $SLEEPING = "sleeping" ]; then
echo $SLEEP_GOVERNOR > /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor
echo "245000" > /sys/devices/system/cpu/cpu0/cpufreq/scaling_max_freq
echo "245000" > /sys/devices/system/cpu/cpu0/cpufreq/scaling_min_freq
echo "2" > /proc/sys/vm/dirty_background_ratio
echo "5" > /proc/sys/vm/dirty_ratio
echo "5" > /proc/sys/vm/laptop_mode
echo "6000000" > /proc/sys/kernel/sched_latency_ns
echo "4000000" > /proc/sys/kernel/sched_min_granularity_ns
echo "4000000" > /proc/sys/kernel/sched_wakeup_granularity_ns
echo "4096" > /proc/sys/kernel/threads-max
echo "35" > /sys/devices/system/cpu/cpu0/cpufreq/ondemand/up_threshold
echo "800000" > /sys/devices/system/cpu/cpu0/cpufreq/ondemand/sampling_rate
echo "350" > /sys/devices/system/cpu/cpu0/cpufreq/ondemand/powersave_bias
echo "0" > /sys/devices/system/cpu/cpu0/cpufreq/ondemand/ignore_nice_load
echo "40000" > /proc/sys/vm/dirty_expire_centisecs
echo "60000" > /proc/sys/vm/dirty_writeback_centisecs
$IWCONFIG eth0 txpower 10mW
log -p i -t screenstate_scaling "*** sleeping ***: switching CPU frequency governor to -> $SLEEP_GOVERNOR"
SLEEPING=
fi
done &)
i want to make that when the phone is awake 'conservative' scaling governor will run.
Thanks.
You'd have to change AWAKE_GOVERNOR="ondemand" to "conservative". But that is a heavily hacked script and may not work ideally.
how can i test if the module is working?
Hi
I upgraded my phone to the latest OTA (FPS fix) with a vanilla ROM.
The kernel version my phone is running is: 2.6.32.15-ge2fb08e [email protected] #11
Currently from what SetCPU tells me, my only supported governors are:
ondemand, userspace and performance.
Any way for me to add conservative to my kernel for use with SetCPU?
Thanks
Sheldon
Anyone can make the mod for the 2.6.32.15-g5d39305 kernel? (AuraxTSense_7.8.1)
Thanks!
PLEASE!
or at least anyone can explain to me how do i make it myself? Thanks.
please help me make this file.
2.6.32.15-gf5a401c kernel from 2.29.405.2 update
is there conservative goverenor for 2.6.32.15-gf5a401c kernel from 2.29.405.2 official HTC Desire update ?
Tnx.
i'm running dj droid rom 2.29 based, and it has conservative.

[REF][DEV] Tweaks for i9003 list [UPDATE]

This is a list of all threads avaiable to our phone, using for ROM developer too...
i decided to post in general, becouse this is not developer threads, developer threads are done from developers and i'm a human no developer.
Adrenaline Shot v14 Universal ​What do these tweaks do?
the first improve is under /system/bin, replace 2 bin with leaked from ICS 4.0 , with GREAT EPIC improvement , 2 bins 're app_process and system_server.
app_process executes, and executes a runtime environment for a dalvik class
The system server is the core of the Android system and as described in the boot sequence post it is started as soon as Dalvik is initialized and running.
like all tweaks , this will add some /system/etc/init.d script , if kernel supports of curse
( for everyone using Gentoo, know init.d too )
the first one is 00remount
Code:
#!/system/bin/sh
#Partition mounts by Dsexton702
mount -o remount,noatime,nobh,nodiratime,nodelalloc,noauto_da_alloc,barrier=0 /system /system
mount -o remount,noatime,nobh,nodiratime,nodelalloc,noauto_da_alloc,barrier=0 /cache /cache
mount -o remount,noatime,nodiratime,delalloc,noauto_da_alloc,barrier=0 /data /data
This script will (re) mount the EXT4 partitions with some "tweaks", like noatime, nodiratime,delalloc and soso.. , speed increased in R/W
the second is 01kerneltweak
Code:
mount -t debugfs none /sys/kernel/debug
echo NO_GENTLE_FAIR_SLEEPERS > /sys/kernel/debug/sched_features
unmount /sys/kernel/debug
using NO_GENTLE_FAIR_SLEEPERS as schedule features, nothing to hard
the third 02journaling
provide to delete cache if its too big
the 4th is 03sysctl
Code:
#!/system/bin/sh
sysctl -p
This is simply call to sysctl ( parameters settings under linux kernel ), its under kernel tweak
the 5th is 04sysctltweaks
this will set a lot of utils things about kernel and its driver ( like governor ) , if people using ondemand it will set ondemand/up_threshold to 65 ( more responsive , but increase battery drain ) and ondemand/sampling_rate to 30000 ^^
05sdcardspeedfix
fixing READ_AHEAD_KB , suggest it will increase sdcard speed ( not too much )
06zipalign
provide to zipalign all /data/app/*.apk files, anything know to apk files are zip archive contains a lot of things, zipalign optimize this archive , major info at developer.android.com/guide/developing/tools/zipalign.html
07vacuum
this provide to "VACUUM" all *.db ( see SMS's DB, etc ... ) to rebuild all *.db better, increase performance too!
08ramscript
i never will use this, this is not designed for our phone IMHO it can be replace with superchanger ( see after )
/system/lib/libsqlite*
will replace sqlite's lib for better performance, sqlite has sync and async method, this will disable sync , theorically it will double the performance in I/O
/system/xbin
it simply provide a sqlite3 bin and zipalign bin, nothing tweaks
Click to expand...
Click to collapse
Thunderbolt tweaks ( this is not avaiable, i upload some script i've download a time ago )​/system/etc/init.d
s78enable_touchscreen_1
Code:
#!/system/bin/sh
#Touchscreen
#Configure touchscreen sensitivity
#Sensitive(Chainfire)
echo 7035 > /sys/class/touch/switch/set_touchscreen;
echo 8002 > /sys/class/touch/switch/set_touchscreen;
echo 11000 > /sys/class/touch/switch/set_touchscreen;
echo 13060 > /sys/class/touch/switch/set_touchscreen;
echo 14005 > /sys/class/touch/switch/set_touchscreen;
this is IMHO the best script i've ever seen , this will increase sensitivity of touchscreen
07sqlite_optimize
this will vacuum and re-index all db, better than Adrenaline's 07vacuum IMHO
S70darky_zipalign
Another zipalign script, useless
*bolt_siray*
this is not developer for our phone, this will working only with adeguate kernel ( we haven't )
S98CFS
it will provide a lot of tweaks using sysctl and kernel proc/ interface
S98system_tweaks
this is a lot of script unify in one script
i edit this to be "better" with our phone, i delete re-mount runtime , adrenaline's 00remount do it better
and modify this part:
Code:
# ==============================================================
# smartassV2
# ==============================================================
if [ -e /sys/devices/system/cpu/cpufreq/smartass/awake_ideal_freq ]; then
echo "800000" > /sys/devices/system/cpu/cpufreq/smartass/awake_ideal_freq;
if [ "`cat /sys/devices/system/cpu/cpu0/cpufreq/scaling_min_freq`" -eq 300000 ]; then
echo "300000" > /sys/devices/system/cpu/cpufreq/smartass/sleep_ideal_freq;
else
echo "300000" > /sys/devices/system/cpu/cpufreq/smartass/sleep_ideal_freq;
fi;
echo "800000" > /sys/devices/system/cpu/cpufreq/smartass/sleep_wakeup_freq;
echo "85" > /sys/devices/system/cpu/cpufreq/smartass/max_cpu_load;
echo "75" > /sys/devices/system/cpu/cpufreq/smartass/min_cpu_load;
echo "300000" > /sys/devices/system/cpu/cpufreq/smartass/ramp_down_step;
echo "0" > /sys/devices/system/cpu/cpufreq/smartass/ramp_up_step;
fi;
to have a correctly step for our processor
​
"after applied this , my phone morth into blonde, blue eyes galaxy Supersayan [cit.]
THIS IS THE ONLY MEMORY Manager, this provide a better ram manager by android, anyone know that Random Access Memory contains a kernel and all APP run, kernel are loaded in lowest address possible , and all app are loaded when open, android usually doesn't close this, for better speed when you re-open its, but if you have small RAM ( 512 MB too ) this will cause a lot of problem , superchange fix it!
i suggest to use 512HP Balanced ( or Performance ) with Bulletproof launcher + OOM FIX, Nullify lag work too
HOW INCLUDE THIS INTO MY ROM?
Poseidons ROM include this by ****ty init.d script, i suggest to delete and re-apply
if you are not ROM Developer is simple, download latest avaiable by link i provide at top and with ROOT-enabled ( check su ) and Script Manager ( or terminal emulator -> # su -> sh script_location ) follow the scripts guide, remember, using this can cause ( 0.01% ) bootloops, i suggest to use local.prop and init.rc integration
if you are a ROM Developer is more complicated than simple user, for stick you can use:
init.d script ( like poseidons )
local.prop and init.local.rc ( suggest ) under /data
build.prop
init.d script ( i do not see this, for me is the worst way to get it )
init.local.rc:
create a /data/init.local.rc contains
* This is for 512HP-Performance + Bulletproof
Code:
write /sys/module/lowmemorykiller/parameters/adj 0,3,6,10,12,15
write /sys/module/lowmemorykiller/parameters/minfree 2048,3584,19200,23040,24320,32000
# V6 SuperCharger, OOM Grouping & Priority Fixes created by zeppelinrox.
# SuperMinFree Calculator & MFK Calculator (for min_free_kbytes) created by zeppelinrox also :)
#
# See http://goo.gl/krtf9 - Linux Memory Consumption - Nice article!
# See http://goo.gl/hFdNO - Memory and SuperCharging Overview ...or... "Why `Free RAM` Is NOT Wasted RAM!"
# See http://goo.gl/4w0ba - MFK Calculator Info - explanation for vm.min_free_kbytes.
#
# DO NOT DELETE COMMENTS. DELETING COMMENTS WILL BREAK UNINSTALL ROUTINE!
#
# BEGIN OOM_MEM_Settings
setprop ro.FOREGROUND_APP_MEM 2048
setprop ro.VISIBLE_APP_MEM 3584
setprop ro.PERCEPTIBLE_APP_MEM 1024
setprop ro.HEAVY_WEIGHT_APP_MEM 19200
setprop ro.SECONDARY_SERVER_MEM 19200
setprop ro.BACKUP_APP_MEM 23040
setprop ro.HOME_APP_MEM 1024
setprop ro.HIDDEN_APP_MEM 23040
setprop ro.EMPTY_APP_MEM 32000
# END OOM_MEM_Settings
# BEGIN OOM_ADJ_Settings
setprop ro.FOREGROUND_APP_ADJ 0
setprop ro.VISIBLE_APP_ADJ 3
setprop ro.PERCEPTIBLE_APP_ADJ 2
setprop ro.HEAVY_WEIGHT_APP_ADJ 4
setprop ro.SECONDARY_SERVER_ADJ 6
setprop ro.BACKUP_APP_ADJ 7
setprop ro.HOME_APP_ADJ 0
setprop ro.HIDDEN_APP_MIN_ADJ 9
setprop ro.EMPTY_APP_ADJ 15
# END OOM_ADJ_Settings
write /proc/sys/vm/min_free_kbytes 15360
write /proc/sys/vm/oom_kill_allocating_task 0
write /proc/sys/vm/panic_on_oom 0
write /proc/sys/vm/overcommit_memory 1
write /proc/sys/vm/swappiness 0
write /proc/sys/kernel/panic_on_oops 1
write /proc/sys/kernel/panic 30
# End of V6 SuperCharged Entries.
or build.prop way ( need a supplie init.d script )
i9003 tweaks​
01loopy
this will make phone more smoothness by renice ( change priority ) the main process will run
i suggest to set your launcher process here like:
Code:
### Launcher apps ###
renice -19 `pidof com.sec.android.app.twlauncher` # TouchWiz Launcher
renice -19 `pidof org.adwfreak.launcher` # ADW Launcher Ex
renice -19 `pidof org.zeam.core` # Zeam launcher
renice -19 `pidof info.tikusoft.launcher7`# Launcher 7
PART2
95allinone
This will provide a complete collection of tweaks avaiable, i hate this becouse, a lot of tweaks here are not implemented correctly , like:
Code:
#Part below here edited by me (changed values) Credits to Juwe11
if [ -e /sys/module/lowmemorykiller/parameters/adj ]; then
echo "0,1,2,4,6,15" > /sys/module/lowmemorykiller/parameters/adj
fi
if [ -e /sys/module/lowmemorykiller/parameters/minfree ]; then
echo "2560,4096,5632,10240,11776,14848" > /sys/module/lowmemorykiller/parameters/minfree
fi
if [ -e /proc/sys/vm/swappiness ]; then
echo "20" > /proc/sys/vm/swappiness
fi
zOOM zOOM :
Code:
echo "2560,4096,5632,10240,11776,14848" > /sys/module/lowmemorykiller/parameters/minfree
This is the same things that do superchanger, but this will be wrost for our phone IMHO
Code:
echo "20" > /proc/sys/vm/swappiness
the right value ( in my cases ) is 0, i haven't swap of anyway we dont have to have a swap!
Zipalign Runtime, it will just implemented by a lot of script, this is also the wrost IMHO zip align script i've never seen
Code:
for k in $(busybox mount | grep relatime | cut -d " " -f3) ; do
sync;
busybox mount -o remount,noatime $k;
done;
this will break 00remount script
Code:
for i in /sys/block/*/queue/scheduler ; do
echo "noop" > $i;
done;
if kernel support i suggest deadline
Code:
# Tweak kernel VM management
echo 0 > /proc/sys/vm/swappiness
echo 10 > /proc/sys/vm/dirty_ratio
echo 4096 > /proc/sys/vm/min_free_kbytes
??? WHAT? again?
Code:
echo "interactive" > /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor
echo "cfq" > /sys/block/mmcblk0/queue/scheduler
see upper
Code:
echo "deadline" > /sys/block/mmcblk0/queue/scheduler
What? another change?
this is good:
Code:
# Copyright @ CRANIUM ROM
echo "500" > /proc/sys/vm/dirty_expire_centisecs
echo "1000" > /proc/sys/vm/dirty_writeback_centisecs
echo "0" > /proc/sys/net/ipv4/tcp_timestamps;
echo "1" > /proc/sys/net/ipv4/tcp_tw_reuse;
echo "1" > /proc/sys/net/ipv4/tcp_sack;
echo "1" > /proc/sys/net/ipv4/tcp_tw_recycle;
echo "1" > /proc/sys/net/ipv4/tcp_window_scaling;
echo "5" > /proc/sys/net/ipv4/tcp_keepalive_probes;
echo "30" > /proc/sys/net/ipv4/tcp_keepalive_intvl;
echo "30" > /proc/sys/net/ipv4/tcp_fin_timeout;
echo "404480" > /proc/sys/net/core/wmem_max;
echo "404480" > /proc/sys/net/core/rmem_max;
echo "256960" > /proc/sys/net/core/rmem_default;
echo "256960" > /proc/sys/net/core/wmem_default;
echo "4096,16384,404480" > /proc/sys/net/ipv4/tcp_wmem;
echo "4096,87380,404480" > /proc/sys/net/ipv4/tcp_rmem;
#End Cranium Tweaks
Conclusion: 95allinone is simply a addiction of all tweaks avaiable in one script without any review and improves for our phone ( in this case, this work ), this will only increase the boot time and break others tweaks installed ( some )
99V6_Superchanger
DO NOT USE THIS, THIS IS EPIC FAIL INIT.D SCRIPT!
Code:
mount -o remount,rw /system
mount -o remount,rw /dev/block/mtdblock3 /system
mount -o remount,rw /dev/block/mtdblock6 /system
*facepalm*
in my terminal:
Code:
# su
# ls -la /dev/block/mtd*
ls: /dev/block/mtd*: No such file or directory
anyway this is not init.d script, this is v6 script , this is not compatible with init.d ,
PART3
Build.prop and android params
Listed partial by TheFrankestain, thanks
* YOU MUST ADD IT AT BOTTOM OF /system/build.prop and delete cache and reboot*
Code:
ro.ril.hsxpa=2
This will enable High-Speed_Downlink_Packet_Access and High-Speed Uplink Packet Access ( HSDPA and HSUPA )
Code:
ro.ril.gprsclass=10
gprs class, see this LINK
Code:
ro.ril.hep=1
0 meaning off, 1 activated
Code:
ro.ril.enable.dtm=0
Dual Transfer Mode , set 1 only if your network support it
Code:
ro.ril.hsdpa.category=8
Folllow this ( thanks to tnpapadakos )
Code:
#ro.ril.hsdpa.category :
# Cat 1 = 1.2 Mbit/s
# Cat 2 = 1.2 Mbit/s
# Cat 3 = 1.8 Mbit/s
# Cat 4 = 1.8 Mbit/s
# Cat 5 = 3.6 Mbit/s
# Cat 6 = 3.6 Mbit/s
# Cat 7 = 7.2 Mbit/s
# Cat 8 = 7.2 Mbit/s
# Cat 9 = 10.1 Mbit/s
# Cat 10 = 14.0 Mbit/s
# Cat 11 = 0.9 Mbit/s
# Cat 12 = 1.8 Mbit/s
# Cat 13 = 17.6 Mbit/s
# Cat 14 = 21.1 Mbit/s
# Cat 15 = 23.4 Mbit/s
# Cat 16 = 27.9 Mbit/s
# Cat 19 = 35.3 Mbit/s
# Cat 20 = 42.2 Mbit/s
# Cat 21 = 23.4 Mbit/s
# Cat 22 = 27.9 Mbit/s
# Cat 23 = 35.3 Mbit/s
# Cat 24 = 42.2 Mbit/s
# Cat 25 = 46.8 Mbit/s
# Cat 26 = 55.9 Mbit/s
# Cat 27 = 70.6 Mbit/s
# Cat 28 = 84.4 Mbit/s
Code:
ro.ril.enable.a53=1
a53 enabling
Code:
ro.ril.enable.3g.prefix=1
1 will show 3g prefix next to network signal
Code:
ro.ril.htcmaskw1.bitmask=4294967295
ro.ril.htcmaskw1=14449
bitmask &
Code:
ro.ril.hsupa.category=6
See this:
Code:
#ro.ril.hsupa.category :
# Cat 1 = 0.73 Mbit/s
# Cat 2 = 1.46 Mbit/s
# Cat 3 = 1.46 Mbit/s
# Cat 4 = 2.93 Mbit/s
# Cat 5 = 2.00 Mbit/s
# Cat 6 = 5.76 Mbit/s
# Cat 7 = 11.5 Mbit/s
Code:
net.tcp.buffersize.default=4096,87380,256960,4096,16384,256960
net.tcp.buffersize.wifi=4096,87380,256960,4096,16384,256960
net.tcp.buffersize.umts=4096,87380,256960,4096,16384,256960
net.tcp.buffersize.gprs=4096,87380,256960,4096,16384,256960
net.tcp.buffersize.edge=4096,87380,256960,4096,16384,256960
Redefinite TCP Standard size packet, it will increased overall speed
Code:
ro.ext4fs=1
will set ext4fs prop to android system, increased performance if you are under ext4
Code:
persist.sys.purgeable_assets=1
More speed!
Code:
persist.sys.shutdown.mode=hibernate
NOT COMPATIBLE FOR OUR PHONE, we have not hibernate shutdown mode
Code:
ro.ril.disable.power.collapse=0
is ultra-battery-life mode, when phone're sleeping
Code:
ro.ril.enable.cnap
Celler name presentation
Code:
debug.sf.hw=0
Render with GPU Apps ( see last #3 post for better info )
Code:
pm.sleep_mode=1
Permits better sleep mode ( battery ++ )
Code:
wifi.supplicant_scan_interval=150
Android ( when wifi on ) periodically scan for new network, you can set time between its for better battery when wifi on
Code:
windowsmgr.max_events_per_sec=150
Increase the max events record by windows manager , better scroll
Code:
debug.performance.tuning=1
video.accelerate.hw=1
GPU Tune for scrolling performance
Code:
debug.sf.nobootanimation=1
for me, not work, it will theorically disable boot animation for faster boot
Code:
ro.HOME_APP_ADJ=1
USE ONLY IF YOU DONT USE SUPERCHANGER
Code:
ro.lge.proximity.delay=25
mot.proximity.delay=25
decrease proximity delay for better experience
Code:
ro.sf.lcd_density=240
Simply not sense
Code:
ro.kernel.android.checkjni=0
disable check jni
Code:
ro.media.dec.jpeg.memcap=8000000
ro.media.enc.hprof.vid.bps=8000000
increase media quality
WHICH GOVERNOR DO U USE?​( ref: Simba501 )
SEE THIS
Anyway i suggest:
- Smartassv2 if you want performance over less battery
- InteractiveX if you want battery over less performance
CAN ANY KERNEL DEVELOPER INCLUDE LULZACTIVE CPUFREQ-DRIVER IN OUR KERNELS? ITS THE PERFECT GOVERNOR , EITHER FOR BATTERY AND PERFORMANCE
EGL TWEAK!​Android header said:
Code:
#
# One line per configuration, of the form:
#
# D I TAG
#
# D: display (0: default)
# I: implementation (0: software, 1: hardware)
# TAG: a unique tag
#
# The library name loaded by EGL is constructed as (in that order):
#
# /system/lib/egl/libGLES_$TAG.so
# /system/lib/egl/lib{EGL|GLESv1_CM|GLESv2}_$TAG.so
#
in the stock ROM the egl.cfg is:
Code:
0 0 android
0 1 POWERVR_SGX530_125
what's meaning?
simply using cpu ( with gpu too ) to render all apps and system
if you modify to:
Code:
0 1 POWERVR_SGX530_125
it will use overall GPU render only, more fast and imho better Battery life because, CPU in our cases with overclock consume more than GPU
See original post: http://forum.xda-developers.com/showpost.php?p=14323192&postcount=8
Wow!! very good thread!! I am setting up a custom rom, could u tell me what of these could give my rom a better battery life? Thank u man!
luiseteyo said:
Wow!! very good thread!! I am setting up a custom rom, could u tell me what of these could give my rom a better battery life? Thank u man!
Click to expand...
Click to collapse
Battery life is influence by:
Running Apps
Governors do you use
Memory Manager ( #1 addicted )
If you set /etc/init.d script to set conservative governor and implemented v6 without any stupid app like facebook or bloatware samsung, and your battery seems infinite
in the past i used SCH Rom , its used only v6 and most important tweaks , without any stupid bloatware, battery seems very infinite ^^ like 2% in 5 hours under 2G network
Ok, sorry for my noob question but I am learning a lot of things this days.. where can I find a tutorial about how to set a governor or a frecuency by default in my kernel? Thank u very much
luiseteyo said:
Ok, sorry for my noob question but I am learning a lot of things this days.. where can I find a tutorial about how to set a governor or a frecuency by default in my kernel? Thank u very much
Click to expand...
Click to collapse
I'm noob too
for frequency are too kernel releated to be generalized,
or if you using XDA_Bam kernel
39frequency
Code:
#!/system/bin/sh
echo "300" > /sys/power/overclock_opp1
echo "600" > /sys/power/overclock_opp2
echo "800" > /sys/power/overclock_opp3
echo "1000" > /sys/power/overclock_opp4
anyway you can create init.d script like
40governorbattery
with:
Code:
#!/system/bin/sh
echo "conservative" > /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor
and see if it stick ^^
Hi.
Are there codes that can remove or dissable the TouchUI aka TouchWiz interface on the i9003 and just use the android deffult launcher?
Another thing something that will easy-up my ram usage and allow more usable ram?
If so how do i implement them?
I just want to add a cool sound and audio tweaks using MagaBassBeats_Mod
First download the MagaBassBeats_Mod_9003.zip file from the xda forum.
Now copy it to the sdcard.
Reboot to the recovery mode.
Now select install from zip file and chose internal sdcard.
Search for the zip file, hit power button, and chose yes.
That's it now you can enjoy a great sound quality.
details from here

[FIX] Bricked kernel fix for kernel tuner users

Some people that used kernel tuner had some problems with kernel tuner! it worked good for sometime but after a specified time the min freq would stick to 918 mhz(boost freq as showp has explained) for both cores and not switching lower! This would make my phone very warm and drain my battery very fast! so i came up with a solution to reset the cpu min freq when you turn on/of your screen! This script i have made has worked very good and battery is in its best with this truly beast kernel! To install the script:
1.copy it in your sdcard
2.save it to a file like S98bricked_fix
3.push it in /system/etc/init.d
4. change permisions
5. reboot or run from terminal emulator
su [enter]
exec /system/etc/init.d/S98bricked_fix [enter]
6.while in terminal emulatur turn on off the screen to see if the script works! you should see cpu freq fixed and after turn on cpu freq refixed!
Ps:Kernel tuner is not needed in this kernel
The script:
#!/system/bin/sh
#
# ==============================================================
# ==============================================================
# begining of bricked fix loop by Mr.Nigma
# ==============================================================
# ==============================================================
(while [ 1 ];
do
# ==============================================================
# ==============================================================
# ==============================================================
# reset low when screen on
# ==============================================================
# ==============================================================
# ==============================================================
AWAKE=`cat /sys/power/wait_for_fb_wake`;
if [ $AWAKE = "awake" ]; then
sleep 2 && chmod 666 /sys/devices/system/cpu/cpu0/cpufreq/scaling_min_freq ;
echo "384000" > /sys/devices/system/cpu/cpu0/cpufreq/scaling_min_freq ;
echo cpu0 freq fixed;
AWAKE=;
fi;
# ==============================================================
# ==============================================================
# ==============================================================
# reset low whwn screen off
# ==============================================================
# ==============================================================
# ==============================================================
SLEEPING=`cat /sys/power/wait_for_fb_sleep`;
if [ $SLEEPING = "sleeping" ]; then
sleep 2 && chmod 666 /sys/devices/system/cpu/cpu0/cpufreq/scaling_min_freq ;
echo "384000" > /sys/devices/system/cpu/cpu0/cpufreq/scaling_min_freq ;
echo cpu0 freq refixed;
SLEEPING=;
fi;
done &);
Get an error :
Sent from my HTC One S using Tapatalk 2
its not a sh script its a binary! you can change the name to smth like fix push it to system/bin
and call it with an init.d script liike
#!system/bin/sh
fix
EDIT:ill post a new version with led notification to notify when the script is running, tomorow!
Can't call it
Sent from my HTC One S using Tapatalk 2
are you sure you set the right permisions rwxrwxrwx??
Alternative would be to use SetCpu and just activate profiles. But this is cool too for those Kernel tuner fans.
echó en Android

Control CPU and many other features via Init.d

Control CPU without any custom application via Init.d :victory:
Disclaimer :
Code:
Please Note : You are solely responsible for what you do to your phone. I nor XDA are responsible for damage you may cause to your device if you mess up something
Here i present you a technique to control CPU and Dyn Fsync, Vibration on supported kernels & also Voltage.
I have attached the Init.d script you can change vdd, Turn on/off Dynamic Fsync, Change CPU Scaling levels.
Detailed Guide on how to use this is coming soon
Download the attached file rename it to just 99init no extension and save it give it 755 permission. & Restart and see i have edited this for my use and am on my personal build of Phoenix Kernel so experience and usage might change on other kernels.
Detailed Guide
echo 1 > /sys/module/rpm_resources/enable_low_power/L2_cache
echo 1 > /sys/module/rpm_resources/enable_low_power/pxo
echo 1 > /sys/module/rpm_resources/enable_low_power/vdd_dig
echo 1 > /sys/module/rpm_resources/enable_low_power/vdd_mem
echo 1 > /sys/module/pm_8x60/modes/cpu0/power_collapse/suspend_enabled
echo 1 > /sys/module/pm_8x60/modes/cpu1/power_collapse/suspend_enabled
echo 1 > /sys/module/pm_8x60/modes/cpu2/power_collapse/suspend_enabled
echo 1 > /sys/module/pm_8x60/modes/cpu3/power_collapse/suspend_enabled
echo 1 > /sys/module/pm_8x60/modes/cpu0/standalone_power_collapse/suspend_enabled
echo 1 > /sys/module/pm_8x60/modes/cpu1/standalone_power_collapse/suspend_enabled
echo 1 > /sys/module/pm_8x60/modes/cpu2/standalone_power_collapse/suspend_enabled
echo 1 > /sys/module/pm_8x60/modes/cpu3/standalone_power_collapse/suspend_enabled
echo 1 > /sys/module/pm_8x60/modes/cpu0/standalone_power_collapse/idle_enabled
echo 1 > /sys/module/pm_8x60/modes/cpu1/standalone_power_collapse/idle_enabled
echo 1 > /sys/module/pm_8x60/modes/cpu2/standalone_power_collapse/idle_enabled
echo 1 > /sys/module/pm_8x60/modes/cpu3/standalone_power_collapse/idle_enabled
echo 1 > /sys/module/pm_8x60/modes/cpu0/power_collapse/idle_enabled
•>> Enables suspend and sleep modules.( i think so.. :silly: )
echo "ondemand" > /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor
echo "ondemand" > /sys/devices/system/cpu/cpu1/cpufreq/scaling_governor
•>> This tweak sets ondemand as default governor.
echo 80 > /sys/devices/system/cpu/cpufreq/ondemand/up_threshold
echo 1 > /sys/devices/system/cpu/cpufreq/ondemand/io_is_busy
echo 4 > /sys/devices/system/cpu/cpufreq/ondemand/sampling_down_factor
echo 10 > /sys/devices/system/cpu/cpufreq/ondemand/down_differential
echo 80 > /sys/devices/system/cpu/cpufreq/ondemand/up_threshold_multi_core
echo 3 > /sys/devices/system/cpu/cpufreq/ondemand/down_differential_multi_core
echo 918000 > /sys/devices/system/cpu/cpufreq/ondemand/optimal_freq
echo 918000 > /sys/devices/system/cpu/cpufreq/ondemand/sync_freq
echo 80 > /sys/devices/system/cpu/cpufreq/ondemand/up_threshold_any_cpu_load
•>> Sets advanced options of ondemand Gov
echo 1188000 > /sys/devices/system/cpu/cpu0/cpufreq/scaling_max_freq
echo 1188000 > /sys/devices/system/cpu/cpu1/cpufreq/scaling_max_freq
echo 384000 > /sys/devices/system/cpu/cpu0/cpufreq/scaling_min_freq
echo 384000 > /sys/devices/system/cpu/cpu1/cpufreq/scaling_min_freq
•>> Sets Min/Max frequencies respectively. for both the CPU's
chown system /sys/devices/system/cpu/cpu0/cpufreq/scaling_max_freq
chown system /sys/devices/system/cpu/cpu0/cpufreq/scaling_min_freq
chown system /sys/devices/system/cpu/cpu1/cpufreq/scaling_max_freq
chown system /sys/devices/system/cpu/cpu1/cpufreq/scaling_min_freq
chown root.system /sys/devices/system/cpu/mfreq
chmod 220 /sys/devices/system/cpu/mfreq
chown root.system /sys/devices/system/cpu/cpu1/online
chown root.system /sys/devices/system/cpu/cpu2/online
chmod 664 /sys/devices/system/cpu/cpu1/online
chmod 664 /sys/devices/system/cpu/cpu2/online
•>> Sets Permissions
echo 18 > /sys/devices/virtual/timed_output/vibrator/level
•>> Vibration Control on supported kernels, Supported in Phoenix Kernel
vdd=-62500
echo ${vdd} > /sys/devices/system/cpu/cpufreq/vdd_table/vdd_levels
echo "All voltages changed by ${vdd}" > /data/local/tmp/vdd.txt
•>> Voltage Control Script, It has been set to max UV by defaule i.e. -62 mV
Note : As the Name suggests its init.d script saved in etc/init.d folder set the permission of the script to 755.​
Added Detailed info
I have added detailed info on each individual script :good: , All of the above scripts have been tested on my Sony Xperia L C2104 running my personal build of Phoenix Kernel
you don't mention where to save it on the phone....
Its init.d script
getochkn said:
you don't mention where to save it on the phone....
Click to expand...
Click to collapse
Actually as the Name suggests its init.d script saved in etc/init.d folder set the permission of the script to 755.
Gonna try this!
Sent from my C2105 using XDA Premium 4 mobile app
try it
abielzuliom said:
Gonna try this!
Sent from my C2105 using XDA Premium 4 mobile app
Click to expand...
Click to collapse
Try it and report back
first we have to enable init.d dude with universal init.d app
yep
yash989 said:
first we have to enable init.d dude with universal init.d app
Click to expand...
Click to collapse
Yep if you are on a kernel that doesnt have init.d support which might be weird :silly:

Categories

Resources