As most of you no im currently working on porting firefox os to are phone but i am having a lot of bother when compiling so im going to take a break from it until i get it compiling fully and make an toolkit for are phone this will include:
Recovery's:
Lastest CWM
Latest TWRP
Latest RZ Recovery
Tweaks:
zram tweaks
build.prop tweaks
vm tweaks
cpu tweaks
low ram tweaks
internet tweaks
3G tweaks
sheduler tweaks
I/O tweaks
Launchers:
ADW Launcher
Go Launcher EX with beta version if available
and more free ones
Data partition mods:
CronMod-A2SD
CronMod-D2EXT
CronMod-INT2EXT
CronMod-A2SD+
CronMod-A2SD++
CronMod-D2EXT+
CronMod-INT2EXT+
Mount2SD
data2sd by Jikantaru
Link2SD
Mods:
Zipalign on boot
Force GPU Rendering
db defrag on boot
beats audio with srs and xloud
Apps:
Gapps packages
Superuser + SU binary
SuperSU + SuperSU SU binary
Latest Play Store
Latest Youtube
Google Search since Google renamed it to Google Now with only supports ICS and above
And more that i can think of before release and also what ever the end user wants added the reason im doing this is because i hate when i need to do a factory reset that i need to install loads of zips to get the basic setup right so making this toolkit will help speed things up after a factory reset
Ideas are welcome so please add them below
Add apex launcher, titanium backup and a file manager (Solid explorer or Es file manager)
Great work.
For a file manager, I'd recommend file manager by rhythm. It's not quite root explorer, but it will pick up the .name files on your sd when others won't.
Sent from my HTC_A510c using Tapatalk 2
Add titanium backup, es file explorer, and latest superuser, supersu. If you can, try making a root script which roots the phone
I always wanted something like this. I hope you get it done quick, because it's really handy to have something like this. Good luck.
Sent from my LG-P500 using xda app-developers app
SomeDudeOnTheNet said:
Add titanium backup, es file explorer, and latest superuser, supersu. If you can, try making a root script which roots the phone
I always wanted something like this. I hope you get it done quick, because it's really handy to have something like this. Good luck.
Sent from my LG-P500 using xda app-developers app
Click to expand...
Click to collapse
If I add the superuser/supersu apps and a user installs them that will root it anyway ill just need to add unit.d functionality to the installer .
Btw guys who don't no aroma is a zip archive that runs in recovery to install mods etc so this will need a custom recovery pre-installed.
Sent from my Wildfire S A510e using Tapatalk 2
eoghan2t7 said:
If I add the superuser/supersu apps and a user installs them that will root it anyway ill just need to add unit.d functionality to the installer .
Btw guys who don't no aroma is a zip archive that runs in recovery to install mods etc so this will need a custom recovery pre-installed.
Sent from my Wildfire S A510e using Tapatalk 2
Click to expand...
Click to collapse
Oh and one more thing, init.d should be compatible with stock. I've seen a few ones I tried causing bootloops. So careful about that.
Sent from my LG-P500 using xda app-developers app
SomeDudeOnTheNet said:
Oh and one more thing, init.d should be compatible with stock. I've seen a few ones I tried causing bootloops. So careful about that.
Sent from my LG-P500 using xda app-developers app
Click to expand...
Click to collapse
Don't worry I no what's wrong with the unit.d bootloops
Sent from my Wildfire S A510e using Tapatalk 2
eoghan2t7 said:
Don't worry I no what's wrong with the unit.d bootloops
Sent from my Wildfire S A510e using Tapatalk 2
Click to expand...
Click to collapse
Alright then. Best of luck! Expecting this soon.
Sent from my HTC Wildfire S A510e using xda premium
SomeDudeOnTheNet said:
Alright then. Best of luck! Expecting this soon.
Sent from my HTC Wildfire S A510e using xda premium
Click to expand...
Click to collapse
ill most likely have the first version out during the week once tweak it a bit more
If you want you can check me git about recoveryflasher:
It's just a bash/batch script, for automatical flashes of recoveries, I'm currently working on it:
https://github.com/OliverG96/SuperRecoveryFlasher
Check the marvel branch
OliverG96 said:
If you want you can check me git about recoveryflasher:
It's just a bash/batch script, for automatical flashes of recoveries, I'm currently working on it:
https://github.com/OliverG96/SuperRecoveryFlasher
Check the marvel branch
Click to expand...
Click to collapse
thanks but its ok recovery supports the flash_image command and since aroma is a recovery zip all i need to do is add the commands and bobs your uncle but nice work any way on the installer.
You should add some wfs optimized init.d scripts.
Sent from my HTC Wildfire S A510e using xda app-developers app
baluuu said:
You should add some wfs optimized init.d scripts.
Sent from my HTC Wildfire S A510e using xda app-developers app
Click to expand...
Click to collapse
That's the idea but it wont be in the first version as I need to make custom tweak scripts.
Sent from my Wildfire S A510e using Tapatalk 2
Cool I'm planning to write 1 myself if it ends up somewhat useful I might upload it
Sent from my HTC Wildfire S A510e using xda app-developers app
baluuu said:
Cool I'm planning to write 1 myself if it ends up somewhat useful I might upload it
Sent from my HTC Wildfire S A510e using xda app-developers app
Click to expand...
Click to collapse
Nice one sure once your finished upload it for testing
Sent from my Wildfire S A510e using Tapatalk 2
eoghan2t7 said:
Nice one sure once your finished upload it for testing
Sent from my Wildfire S A510e using Tapatalk 2
Click to expand...
Click to collapse
So here is The init.d script 99WFStweaks
And a shell script to add lines to build prop Build.prop.sh
This is like really half assed work tough I think I got it runing on boot but i havent had the chance to test for performance improvement, also I took the optimizations as is and didnt bother looking for the optimal WFS values so enjoy my ****ty work lol.
I used this thread as a guidline so thank to optik19918
Here is the code.
99WFStweaks
Code:
#!/system/bin/sh
#WFS Tweaks
#Internet speed twaks
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;
#VM mamagement tweaks
echo "4096" > /proc/sys/vm/min_free_kbytes
echo "0" > /proc/sys/vm/oom_kill_allocating_task;
echo "0" > /proc/sys/vm/panic_on_oom;
echo "0" > /proc/sys/vm/laptop_mode;
echo "0" > /proc/sys/vm/swappiness;
echo "50" > /proc/sys/vm/vfs_cache_pressure;
echo "90" > /proc/sys/vm/dirty_ratio;
echo "70" > /proc/sys/vm/dirty_background_ratio;
#Battery Tweaks
echo "500" > /proc/sys/vm/dirty_expire_centisecs;
echo "1000" > /proc/sys/vm/dirty_writeback_centisecs;
#Ext4 tweaks
tune2fs -o journal_data_writeback /dev/block/mtdblock3;
tune2fs -O ^has_journal /dev/block/mtdblock3;
tune2fs -o journal_data_writeback /dev/block/mtdblock4;
tune2fs -O ^has_journal /dev/block/mtdblock4;
tune2fs -o journal_data_writeback /dev/block/mtdblock5;
tune2fs -O ^has_journal /dev/block/mtdblock5;
busybox mount -o remount,noatime,noauto_da_alloc,nodiratime,barrier=0,nobh /system;
busybox mount -o remount,noatime,noauto_da_alloc,nosuid,nodev,nodiratime,barrier=0,nobh /data;
busybox mount -o remount,noatime,noauto_da_alloc,nosuid,nodev,nodiratime,barrier=0,nobh /cache;
#Flags blocks as non-rotational and increases cache size
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;
#MicroSD speed fix
echo "2048" > /sys/devices/virtual/bdi/179:0/read_ahead_kb;
#DB vacum
for i in \
`find /data -iname "*.db"`
do \
sqlite3 $i 'VACUUM;';
done;
#Removes logger
rm /dev/log/main
Build.prop.sh
Code:
#!/system/bin/sh
#Build.prop tweaks
echo "ro.media.enc.jpeg.quality=100" >> /system/build.prop;
echo "dalvik.vm.heapsize=48m" >> /system/build.prop;
echo "debug.sf.hw=1" >> /system/build.prop;
echo "ro.telephony.call_ring.delay=0" >> /system/build.prop;
echo "windowsmgr.max_events_per_sec=150" >> /system/build.prop;
echo "wifi.supplicant_scan_interval=180" >> /system/build.prop;
echo "pm.sleep_mode=1" >> /system/build.prop;
echo "ro.ril.disable.power.collapse=0" >> /system/build.prop;
echo "debug.performance.tuning=1" >> /system/build.prop;
echo "video.accelerate.hw=1" >> /system/build.prop;
echo "ro.media.dec.jpeg.memcap=12000000" >> /system/build.prop;
echo "ro.media.enc.hprof.vid.bps=12000000" >> /system/build.prop;
echo "ro.ril.hsxpa=2" >> /system/build.prop;
echo "ro.ril.gprsclass=10" >> /system/build.prop;
echo "ro.ril.hep=1" >> /system/build.prop;
echo "ro.ril.enable.dtm=1" >> /system/build.prop;
echo "ro.ril.hsdpa.category=10" >> /system/build.prop;
echo "ro.ril.enable.a53=1" >> /system/build.prop;
echo "ro.ril.enable.3g.prefix=1" >> /system/build.prop;
echo "ro.ril.htcmaskw1.bitmask=4294967295" >> /system/build.prop;
echo "ro.ril.htcmaskw1=14449" >> /system/build.prop;
echo "ro.ril.hsupa.category=5" >> /system/build.prop;
echo "net.tcp.buffersize.default=4096,87380,256960,4096,16384,256960" >> /system/build.prop;
echo "net.tcp.buffersize.wifi=4096,87380,256960,4096,16384,256960" >> /system/build.prop;
echo "net.tcp.buffersize.umts=4096,87380,256960,4096,16384,256960" >> /system/build.prop;
echo "net.tcp.buffersize.gprs=4096,87380,256960,4096,16384,256960" >> /system/build.prop;
echo "net.tcp.buffersize.edge=4096,87380,256960,4096,16384,256960" >> /system/build.prop;
baluuu said:
So here is The init.d script 99WFStweaks
And a shell script to add lines to build prop Build.prop.sh
This is like really half assed work tough I think I got it runing on boot but i havent had the chance to test for performance improvement, also I took the optimizations as is and didnt bother looking for the optimal WFS values so enjoy my ****ty work lol.
I used this thread as a guidline so thank to optik19918
Here is the code.
99WFStweaks
Code:
#!/system/bin/sh
#WFS Tweaks
#Internet speed twaks
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;
#VM mamagement tweaks
echo "4096" > /proc/sys/vm/min_free_kbytes
echo "0" > /proc/sys/vm/oom_kill_allocating_task;
echo "0" > /proc/sys/vm/panic_on_oom;
echo "0" > /proc/sys/vm/laptop_mode;
echo "0" > /proc/sys/vm/swappiness;
echo "50" > /proc/sys/vm/vfs_cache_pressure;
echo "90" > /proc/sys/vm/dirty_ratio;
echo "70" > /proc/sys/vm/dirty_background_ratio;
#Battery Tweaks
echo "500" > /proc/sys/vm/dirty_expire_centisecs;
echo "1000" > /proc/sys/vm/dirty_writeback_centisecs;
#Ext4 tweaks
tune2fs -o journal_data_writeback /dev/block/mtdblock3;
tune2fs -O ^has_journal /dev/block/mtdblock3;
tune2fs -o journal_data_writeback /dev/block/mtdblock4;
tune2fs -O ^has_journal /dev/block/mtdblock4;
tune2fs -o journal_data_writeback /dev/block/mtdblock5;
tune2fs -O ^has_journal /dev/block/mtdblock5;
busybox mount -o remount,noatime,noauto_da_alloc,nodiratime,barrier=0,nobh /system;
busybox mount -o remount,noatime,noauto_da_alloc,nosuid,nodev,nodiratime,barrier=0,nobh /data;
busybox mount -o remount,noatime,noauto_da_alloc,nosuid,nodev,nodiratime,barrier=0,nobh /cache;
#Flags blocks as non-rotational and increases cache size
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;
#MicroSD speed fix
echo "2048" > /sys/devices/virtual/bdi/179:0/read_ahead_kb;
#DB vacum
for i in \
`find /data -iname "*.db"`
do \
sqlite3 $i 'VACUUM;';
done;
#Removes logger
rm /dev/log/main
Build.prop.sh
Code:
#!/system/bin/sh
#Build.prop tweaks
echo "ro.media.enc.jpeg.quality=100" >> /system/build.prop;
echo "dalvik.vm.heapsize=48m" >> /system/build.prop;
echo "debug.sf.hw=1" >> /system/build.prop;
echo "ro.telephony.call_ring.delay=0" >> /system/build.prop;
echo "windowsmgr.max_events_per_sec=150" >> /system/build.prop;
echo "wifi.supplicant_scan_interval=180" >> /system/build.prop;
echo "pm.sleep_mode=1" >> /system/build.prop;
echo "ro.ril.disable.power.collapse=0" >> /system/build.prop;
echo "debug.performance.tuning=1" >> /system/build.prop;
echo "video.accelerate.hw=1" >> /system/build.prop;
echo "ro.media.dec.jpeg.memcap=12000000" >> /system/build.prop;
echo "ro.media.enc.hprof.vid.bps=12000000" >> /system/build.prop;
echo "ro.ril.hsxpa=2" >> /system/build.prop;
echo "ro.ril.gprsclass=10" >> /system/build.prop;
echo "ro.ril.hep=1" >> /system/build.prop;
echo "ro.ril.enable.dtm=1" >> /system/build.prop;
echo "ro.ril.hsdpa.category=10" >> /system/build.prop;
echo "ro.ril.enable.a53=1" >> /system/build.prop;
echo "ro.ril.enable.3g.prefix=1" >> /system/build.prop;
echo "ro.ril.htcmaskw1.bitmask=4294967295" >> /system/build.prop;
echo "ro.ril.htcmaskw1=14449" >> /system/build.prop;
echo "ro.ril.hsupa.category=5" >> /system/build.prop;
echo "net.tcp.buffersize.default=4096,87380,256960,4096,16384,256960" >> /system/build.prop;
echo "net.tcp.buffersize.wifi=4096,87380,256960,4096,16384,256960" >> /system/build.prop;
echo "net.tcp.buffersize.umts=4096,87380,256960,4096,16384,256960" >> /system/build.prop;
echo "net.tcp.buffersize.gprs=4096,87380,256960,4096,16384,256960" >> /system/build.prop;
echo "net.tcp.buffersize.edge=4096,87380,256960,4096,16384,256960" >> /system/build.prop;
Click to expand...
Click to collapse
looks good but these lines might not give that much of a boost as we dont have a ext4 file system
Code:
#Ext4 tweaks
tune2fs -o journal_data_writeback /dev/block/mtdblock3;
tune2fs -O ^has_journal /dev/block/mtdblock3;
tune2fs -o journal_data_writeback /dev/block/mtdblock4;
tune2fs -O ^has_journal /dev/block/mtdblock4;
tune2fs -o journal_data_writeback /dev/block/mtdblock5;
tune2fs -O ^has_journal /dev/block/mtdblock5;
busybox mount -o remount,noatime,noauto_da_alloc,nodiratime,barrier=0,nobh /system;
busybox mount -o remount,noatime,noauto_da_alloc,nosuid,nodev,nodiratime,barrier=0,nobh /data;
busybox mount -o remount,noatime,noauto_da_alloc,nosuid,nodev,nodiratime,barrier=0,nobh /cache;
it would possible work better if you added this in
Code:
#Ext4 tweaks
tune2fs -o journal_data_writeback /dev/block/mtdblock3;
tune2fs -O ^has_journal /dev/block/mtdblock3;
tune2fs -o journal_data_writeback /dev/block/mtdblock4;
tune2fs -O ^has_journal /dev/block/mtdblock4;
tune2fs -o journal_data_writeback /dev/block/mtdblock5;
tune2fs -O ^has_journal /dev/block/mtdblock5;
busybox mount -o remount,noatime,noauto_da_alloc,nodiratime,barrier=0,nobh /system;
busybox mount -o remount,noatime,noauto_da_alloc,nosuid,nodev,nodiratime,barrier=0,nobh /data;
busybox mount -o remount,noatime,noauto_da_alloc,nosuid,nodev,nodiratime,barrier=0,nobh /cache;
#EXT Partition
tune2fs -o journal_data_writeback /dev/block/mmcblk0p2;
tune2fs -O ^has_journal /dev/block/mmcblk0p2;
#If using Link2sd or another data2sd script that symlinks /data to /sd-ext
busybox mount -o remount,noatime,noauto_da_alloc,nosuid,nodev,nodiratime,barrier=0,nobh /sd-ext;
Lol dunno why i even added that haha. Didnt bother reading. Yes you are right i ll replace these lines
Edit: Omg the difference. Sd write went from 10 to 30 i ll further test to see if it wasnt just some kind of bug.
Edit2: No mistake thats what antutu says 29mb/s write altho its probably something causing the program to make mistakes atleast i know the lines are doing something
baluuu said:
Lol dunno why i even added that haha. Didnt bother reading. Yes you are right i ll replace these lines
Edit: Omg the difference. Sd write went from 10 to 30 i ll further test to see if it wasnt just some kind of bug.
Edit2: No mistake thats what antutu says 29mb/s write altho its probably something causing the program to make mistakes atleast i know the lines are doing something
Click to expand...
Click to collapse
ill test it on rom toolbox it has a sd benchtest on it now
edit:
also add this in instead of this
Code:
#Flags blocks as non-rotational and increases cache size
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;
add in:
Code:
#Flags blocks as non-rotational and increases cache size
LOOP=`ls -d /sys/block/loop*`;
RAM=`ls -d /sys/block/ram*`;
MMC=`ls -d /sys/block/mmc*`;
ZRAM=`ls -d /sys/block/zram*`;
for j in $LOOP $RAM $MMC $ZRAM
do
echo "0" > $j/queue/rotational;
echo "2048" > $j/queue/read_ahead_kb;
done;
That is for cm7 only right? I don't recall sense using zram or am I wrong.
Sent from my HTC Wildfire S A510e using xda app-developers app
Related
I've adapted the original performance tweaks by 'hardcore' @ XDA for my overclocked/undervolted Galaxy Tab. The tweaked values are pretty much the same as the ones recommended by the original poster, but my simple init.d/ script allows me to log default system values when pushing new values, which is useful for debugging. The script also contains comments to describe the role of each setting. Note that if you don't have init.d/ support in your kernel / initramfs, you can still run the script manually at each system start (use an app like GScript).
Code:
#!/system/bin/sh
#
# Original tweaks by 'hardcore' @ XDA
# http://forum.xda-developers.com/showthread.php?t=813309
# This is a startup script designed for /system/etc/init.d/.
# Note that "run-parts" support (for init.d/ scripts) is normally provided by custom a initramfs,
# which should bundle busybox in /sbin/. The /sbin/run-parts.sh script should take care of
# running init scripts (by calling /sbin/runparts), and it should subsequently trigger
# the device startup (using "setprop filesystem.ready 1", or similar).
# Note that the recovery mode typically doesn't run /system/etc/init.d/ startup scripts.
# Ensure /sbin/busybox takes precedence.
# Normally this is redundant, because the /init.rc startup script already sets the correct path.
export PATH=/sbin:$PATH
# Logging of old/new sysfs values, useful for double-checking.
logFile=/data/local/tmp/S_perf_tweaks.log
if [ -f $logFile ]
then
rm $logFile
fi
touch $logFile
# This function logs the old value and writes the new value.
echo_()
{
echo '' >> $logFile
echo -n "${2}${3} (${1}): " >> $logFile
#head -1 ${2}${3} >> $logFile
#read $firstLine < ${2}${3}
#echo -n $firstLine >> $logFile
contents=`echo -n $(cat ${2}${3})`
echo -n $contents >> $logFile
echo -n " ---> " >> $logFile
echo $1 > ${2}${3}
contents=`echo -n $(cat ${2}${3})`
echo -n $contents >> $logFile
}
# Note that the settings pushed by VoltageControl.apk
# could also be managed here (this only applies to kernels with clock/frequency tables and undervolt sysfs support):
#echo_ "50 50 50 25 25 25 25 " "/sys/devices/system/cpu/cpu0/cpufreq" "/UV_mV_table"
#echo_ 1400000 "/sys/devices/system/cpu/cpu0/cpufreq" "/scaling_max_freq"
echo "---------" >> $logFile
# Remount all partitions that use relatime with noatime and nodiratime instead.
# Note: atime generates a write-after-every-read, relatime is an optimized version of atime.
for k in $(mount | grep relatime | cut -d " " -f3)
do
echo "mount -o remount,noatime,nodiratime $k" >> $logFile
sync
mount -o remount,noatime $k
done
# Here is a sample test to measure read/write performance on rfs partitions:
### test for write: dd if=/dev/zero of=/data/test count=30000
### test for read: dd if=/data/test of=/dev/zero
echo "---------" >> $logFile
# Log the mount table
mount >> $logFile
echo "---------" >> $logFile
# Optimize the cfq/bfq I/O scheduler for flash memory (defaults are designed for spinning harddisks).
# Lower the idle wait, re-enable the low latency mode, remove the penalty for back-seeks,
# and explicitly tell the kernel that the storage is not a spinning disk.
for i in $(ls -1 /sys/block/stl*) $(ls -1 /sys/block/mmc*) $(ls -1 /sys/block/bml*) $(ls -1 -d /sys/block/tfsr*)
#for i in `ls /sys/block/stl* /sys/block/mmc* /sys/block/bml* /sys/block/tfsr*`;
do
# DEF noop anticipatory deadline cfq [bfq]
echo_ "bfq" $i "/queue/scheduler"
# DEF 1 ?
echo_ "0" $i "/queue/rotational"
# DEF 1 ?
echo_ "1" $i "/queue/iosched/low_latency"
# DEF 2 ?
echo_ "1" $i "/queue/iosched/back_seek_penalty"
# DEF 16384 ?
echo_ "1000000000" $i "/queue/iosched/back_seek_max"
# DEF 6 ?
echo_ "3" $i "/queue/iosched/slice_idle"
sync
done
# Set tendency of kernel to swap to minimum, since swap isn't used anyway.
# (swap = move portions of RAM data to disk partition or file, to free-up RAM)
# (a value of 0 means "do not swap unless out of free RAM", a value of 100 means "swap whenever possible")
# (the default is 60 which is okay for normal Linux installations)
# DEF 60
echo_ "0" "/proc/sys/vm" "/swappiness"
# Lower the amount of unwritten write cache to reduce lags when a huge write is required.
# DEF 20
echo_ "10" "/proc/sys/vm" "/dirty_ratio"
# Increase minimum free memory, in theory this should make the kernel less likely to suddenly run out of memory.
# DEF 3102
echo_ "4096" "/proc/sys/vm" "/min_free_kbytes"
# Increase tendency of kernel to keep block-cache to help with slower RFS filesystem.
# DEF 100
echo_ "1000" "/proc/sys/vm" "/vfs_cache_pressure"
# Increase the write flush timeouts to save some battery life.
# DEF 250
echo_ "2000" "/proc/sys/vm" "/dirty_writeback_centisecs"
# DEF 200
echo_ "1000" "/proc/sys/vm" "/dirty_expire_centisecs"
# Make the task scheduler more 'fair' when multiple tasks are running,
# which improves user-interface and application responsiveness.
# DEF 10000000
echo_ "20000000" "/proc/sys/kernel" "/sched_latency_ns"
# DEF 2000000
echo_ "2000000" "/proc/sys/kernel" "/sched_wakeup_granularity_ns"
# DEF 1000000
echo_ "1000000" "/proc/sys/kernel" "/sched_min_granularity_ns"
sync
# Miscellaneous tweaks
setprop dalvik.vm.startheapsize 8m
#setprop wifi.supplicant_scan_interval 90
echo '' >> $logFile
echo "---------" >> $logFile
#This apply a tweaked deadline scheduler to all RFS (and ext2/3/4, if existent) partitions.
#for i in /sys/block/*
#do
# DEF noop anticipatory deadline cfq [bfq]
#echo deadline > $i/queue/scheduler
#echo 4 > $i/queue/iosched/writes_starved
#echo 1 > $i/queue/iosched/fifo_batch
#echo 256 > $i/queue/nr_requests
#done
Thanks for this Daniel - since I know absolutely nothing about anything Android, all I can say is that I have 2 questions
1 - Would this script be any benefit to someone running a custom ROM (Overcome 1.1.3 in my case) and a custom kernel (Richard Trip's 1.4gHz EXT4)? I ask because I don't know if these guys have already including these tweaks or not... but maybe I should ask them instead...
2 - Is there any way you could put that script - in its most efficient, non-debugging form - in to a script file that us speed-freaks can just toss in to init.d and reboot?
Please do forgive me for any newbishness I have displayed here.
So should I put this script in /system/etc/init.d/ ?
UPDATE: Ok, I've done the script(without extension at the back of the file name) and put it in ~/init.d/, it runs well. I comment out the remount and logging function tho Tested it on some games that required load time like gangstar which lags alot previously, now just dnt have any lag time in it! Thanks!
Anyway, im running Overcome rom with richard's kernel, other than voltage script, i saw 2 more script that does the following:
10fixsh does:
"#!/system/bin/sh
busybox mount -o remount,rw /
find /sbin -maxdepth 1 -type l -exec rm {} \;
busybox mount -o remount,ro /
"
99done does:
"#!/system/bin/sh
sync;
setprop mcr.filesystem.ready 1;
"
So I just add your script as userinit since they do not have conflicting calls
Personally thinks that similar tweaks should be included in custom kernels so that those who wish to do more extreme settings can go with it while those who just wants increased performance as it is can still have the boost provided by such init script.
fastcx said:
Personally thinks that similar tweaks should be included in custom kernels so that those who wish to do more extreme settings can go with it while those who just wants increased performance as it is can still have the boost provided by such init script.
Click to expand...
Click to collapse
so basically just copy and paste the whole "code" in the first post, and create it as userinit.sh and put the userinit.sh file in /system/etc/init.d ?
am i right?
kay_kiat88 said:
so basically just copy and paste the whole "code" in the first post, and create it as userinit.sh and put the userinit.sh file in /system/etc/init.d ?
am i right?
Click to expand...
Click to collapse
still need more time to test, after some verification, none of the "/proc/sys/kernel" setting works with any of the kernel i'm using. thats y i need more time to rectify..
used richard's kernel and overcome kernel, both dont do anything now..perhaps wrong command in the script? Cause run-parts.sh does specify where to run script, and init.d does have 2 script in there that runs. So i'll need more time to make sure it works now..
Dont need to have .sh as extension, just a name for your script like the other 2 script that i posted in previous reply. And I did not copy the whole script to run, as the script seems questionable in some part..
fastcx said:
still need more time to test, after some verification, none of the "/proc/sys/kernel" setting works with any of the kernel i'm using. thats y i need more time to rectify..
used richard's kernel and overcome kernel, both dont do anything now..perhaps wrong command in the script? Cause run-parts.sh does specify where to run script, and init.d does have 2 script in there that runs. So i'll need more time to make sure it works now..
Dont need to have .sh as extension, just a name for your script like the other 2 script that i posted in previous reply. And I did not copy the whole script to run, as the script seems questionable in some part..
Click to expand...
Click to collapse
okay.. so basically just copy everything under the "code" and create it as userinit?
edit: hmmm okay thanks for you help. i don't think it's of any use for me now as my tab is quite fast and i don't do any intensive stuff on it. thanks anyway!
kay_kiat88 said:
okay.. so basically just copy everything under the "code" and create it as userinit?
edit: hmmm okay thanks for you help. i don't think it's of any use for me now as my tab is quite fast and i don't do any intensive stuff on it. thanks anyway!
Click to expand...
Click to collapse
Now i'm editing init.rc file instead, but it's not the safest thing to do
Wow all the best.. lol.
Sent from my GT-P1000 using Tapatalk
fastcx said:
Now i'm editing init.rc file instead, but it's not the safest thing to do
Click to expand...
Click to collapse
The init.rc file gets extracted from the initramfs ramdisc (packaged inside the zImage kernel) at each device startup. Changing this file's content is not a good idea. Regards, Dan
fastcx said:
So should I put this script in /system/etc/init.d/ ?
UPDATE: Ok, I've done the script(without extension at the back of the file name) and put it in ~/init.d/, it runs well.
Click to expand...
Click to collapse
Yes, the filename of the startup script must start with "S_" and must not end with ".sh". This is standard Linux stuff.
fastcx said:
find /sbin -maxdepth 1 -type l -exec rm {}
Click to expand...
Click to collapse
Removing the symlinks from "/sbin/" ... why ?
Normally Busybox should be installed properly in "/sbin/" by your kernel provider, you shouldn't have to touch this folder.
fastcx said:
99done does:
"#!/system/bin/sh
sync;
setprop mcr.filesystem.ready 1;
"
Click to expand...
Click to collapse
The "mcr.filesystem.ready" is only relevant if the "init.rc" file in the kernel zImage's initramfs ramdisc responds to a change to the "mcr.filesystem.ready" property (for example, when its value changes from 0 to 1). This is typically used to start the device normally, after *all* of the "/system/etc/init.d/" startup scripts have been executed.
The line of code "setprop mcr.filesystem.ready 1" is therefore typically included in "/sbin/runparts.sh", not in one of the "S_startup_scripts" (as this may trigger the device normal startup prematurely).
It really depends on your kernel, so it should be documented by your kernel provider.
daniel.weck said:
Yes, the filename of the startup script must start with "S_" and must not end with ".sh". This is standard Linux stuff.
It really depends on your kernel, so it should be documented by your kernel provider.
Click to expand...
Click to collapse
Great! thanks for clarifying! Sadly none of the kernel provider states any info on such matter. Will try your script again, as previously running thru gscript not all command works..
Copied your script 100%, put it in init.d with chmod 755, named it S_userinit, doesnt run..i double checked by cat value that I stated to change in the script.
Help? It obviously runs the UV script in init.d tho.
EDIT: Got it to work by editing the UV script, now settings are in! Great! Time to test anyway, nodiratime is not needed, noatime already has it
So how can I use this script - I want to
Hi, Just connected to my galaxy tab running froyo, and went looking in my filesystem for the init.d folder and yeah there isn't one
do i create one? where? and what permissions?
I try to keep this brief and not waste too much of your time.
many thanks for the script
Ttime & effort ++
andytof46 said:
Hi, Just connected to my galaxy tab running froyo, and went looking in my filesystem for the init.d folder and yeah there isn't one
do i create one? where? and what permissions?
I try to keep this brief and not waste too much of your time.
many thanks for the script
Ttime & effort ++
Click to expand...
Click to collapse
you will need a kernel that support init script, after that, /etc/init.d(or /system/etc/init.d) will be created
fastcx said:
Copied your script 100%, put it in init.d with chmod 755, named it S_userinit, doesnt run..i double checked by cat value that I stated to change in the script.
Help? It obviously runs the UV script in init.d tho.
EDIT: Got it to work by editing the UV script, now settings are in! Great! Time to test anyway, nodiratime is not needed, noatime already has it
Click to expand...
Click to collapse
Don't suppose you could post a copy of your trimmed & tweaked version of Daniel's script for us to use?
Cuz I, for example, have no idea what's useful in the original script, and what's not useful. But I at least know how to edit the UV script, heh.
jeebspawnshop said:
Don't suppose you could post a copy of your trimmed & tweaked version of Daniel's script for us to use?
Cuz I, for example, have no idea what's useful in the original script, and what's not useful. But I at least know how to edit the UV script, heh.
Click to expand...
Click to collapse
LOL here it goes
Code:
#!/system/bin/sh
#set UV
echo "0 0 0 0 0 0 0 0 " > /sys/devices/system/cpu/cpu0/cpufreq/UV_mV_table
echo 1000000 > /sys/devices/system/cpu/cpu0/cpufreq/scaling_max_freq
#select enabled states
echo "0 0 0 0 0 0 0 0 " > /sys/devices/system/cpu/cpu0/cpufreq/states_enabled_table
#set scheduler for stl, bml and mmc
for i in `ls /sys/block/stl*` /sys/block/bml* /sys/block/mmcblk*
do
echo "bfq" > $i/queue/scheduler
echo "0" > $i/queue/rotational
echo "1" > $i/queue/iosched/low_latency
echo "1" > $i/queue/iosched/back_seek_penalty
echo "1000000000" > $i/queue/iosched/back_seek_max
echo "3" > $i/queue/iosched/slice_idle
done
# Remount all partitions with noatime
for k in $(busybox mount | grep relatime | cut -d " " -f3)
do
sync
busybox mount -o remount,noatime $k
done
# 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
# Tweak kernel scheduler, less aggressive settings
echo "18000000" > /proc/sys/kernel/sched_latency_ns
echo "3000000" > /proc/sys/kernel/sched_wakeup_granularity_ns
echo "1500000" > /proc/sys/kernel/sched_min_granularity_ns
# Misc tweaks for battery life
echo "2000" > /proc/sys/vm/dirty_writeback_centisecs
echo "1000" > /proc/sys/vm/dirty_expire_centisecs
# Miscellaneous tweaks
setprop dalvik.vm.startheapsize 8m
done
NOTE: If you change any settings in uv app, u'll revert S_volt_scheduler to ONLY UV settings, so It's recommended to edit your UV setting on this file instead of using uv app from now on if you wants to keep your other settings
Thanks dude!
I hit your Thanks Button too.
jeebspawnshop said:
Thanks dude!
I hit your Thanks Button too.
Click to expand...
Click to collapse
Thanks U should thanks the thread starter too U should just take it as reference, modify any that you feels ok, and perhaps post here as feedback on which makes things better, especially disc scheduler and task scheduler settings.
UPDATE: Made some changes to suggested value by daniel for "fairness", these setting really deals with multitasking better
echo "20000000" > /proc/sys/kernel/sched_latency_ns
echo "2000000" > /proc/sys/kernel/sched_wakeup_granularity_ns
echo "1000000" > /proc/sys/kernel/sched_min_granularity_ns
hey fastcx, i copied and pasted your script in the UV scheduler file in init.d but it seems that it's not working as the values don't apply. any ideas why?
Added a big list of disable/enable android.permissions
Cleaned up Op.
Made information more concise and easier on the eyes.
read_ahead_kb:
Code:
#
for i in /sys/devices/virtual/bdi/*/read_ahead_kb
do
echo "(AnyMultipleOf 128)" > $i
done
inode_readahead_blks
Code:
#
for i in /sys/fs/ext4/*/inode_*
do
echo "VAR" > $i
done
You won't find more simple scripting SETTING=VALUE...
Code:
write='busybox sysctl -w /sys/devices/system/cpu'
i=$write/cpufreq/conservative
j=$write/cpu0/cpufreq
$j/scaling_governor=conservative
$j/scaling_max_freq=1200000
$jscaling_min_freq=25000
$i/sampling_rate=25000
$i/up_threshold=40
$i/down_threshold=50
$i/freq_step=5
$i/sampling_down_factor=2
|
Code:
\( An Ondemand example \)
write='busybox sysctl -w /sys/devices/cpu'
i=$write/cpufreq/ondemand
j=$write/cpu0/cpufreq
$j/scaling_governor=ondemand
$j/scaling_min_freq=25000
$j/scaling_max_freq=1400000
$i/sampling_rate=50000
$i/up_threshold=65
$i/powersave_bias=10
$i/sampling_down_factor=3
$i/down_differential=30
$i/freq_step=65
|
Code:
\( Pegasus example \)
write='busybox sysctl -w /sys/devices/system/cpu'
i=$write/cpufreq/pegasusq
j=$write/cpu0/cpufreq
$j/scaling_governor=pegasusq
$j/scaling_min_freq=25000
$j/scaling_max_freq=1400000
$i/pegasusq/up_threshold=80
$i/pegasusq/up_threshold_at_min_freq=65
$i/pegasusq/sampling_down_factor=5
$i/pegasusq/down_differential=5
$i/pegasusq/freq_step=60
$i/freq_for_responsiveness=500000
$i/pegasusq/cpu_up_rate=10
$i/pegasusq/cpu_down_rate=20
$i/pegasusq/hotplug_freq_1_1=500000
$i/pegasusq/hotplug_freq_2_0=200000
$i/pegasusq/hotplug_rq_1_1=300
$i/pegasusq/hotplug_rq_2_0=350
$i/pegasusq/ignore_nice_load=0
$i/pegasusq/io_is_busy=1
$i/pegasusq/max_cpu_lock=0
$i/pegasusq/hotplug_lock=0
|
|
simple shell for speed and memory management
Code:
\( You can virtually write any setting \)\
ext4=`busybox sysctl -w /sys/fs/ext4/mmcblk0`
lmk=`busybox sysctl -w /sys/module/lowmemorykiller/parameters`
$ext4\p10/inode_readahead_blks=128
$ext4\p9/inode_readahead_blks=128
$ext4\p7/inode_readahead_blks=256
$ext4\p12/inode_readahead_blks=64
$ext4\p10/inode_goal=16
$ext4\p9/inode_goal=16
$ext4\p7/inode_goal=16
$ext4\p12/inode_goal=16
busybox sysctl -w /proc/1/oom_adj=-17
$lmk/adj=0,2,-4,8,12,15
$lmk/minfree=1024,3072,5120,12288,17408,24566
Screen state script that turns on and off both cpus
For now, this Post will be home to I/O tweaks
Queue settings unknown to most that
Code:
for i in /sys/block/*/*/force*
do
echo "0" > $i
echo 0 > /sys/block/mmcblk0/mmcblk0p1/ro
echo 0 > /sys/block/mmcblk0/mmcblk0p10/ro
echo 0 > /sys/block/mmcblk0/mmcblk0p11/ro
echo 0 > /sys/block/mmcblk0/mmcblk0p12/ro
echo 0 > /sys/block/mmcblk0/mmcblk0p2/ro
echo 0 > /sys/block/mmcblk0/mmcblk0p3/ro
echo 0 > /sys/block/mmcblk0/mmcblk0p4/ro
echo 0 > /sys/block/mmcblk0/mmcblk0p5/ro
echo 0 > /sys/block/mmcblk0/mmcblk0p6/ro
echo 0 > /sys/block/mmcblk0/mmcblk0p7/ro
echo 0 > /sys/block/mmcblk0/mmcblk0p8/ro
echo 0 > /sys/block/mmcblk0/mmcblk0p9/ro
Now you`re ready to adjust stuff...
Code:
for i in /sys/devices/virtual/block/*/queue
do
echo "sio" > $i/scheduler
echo "4096" > $i/minimum_io_size
echo "1" > $i/add_random
echo "4096" > $i/discard_granularity
echo "1" > /discard_zeroes_data
echo "1" > $i/discard_max_bytes
echo "1024" > $i/optimal_io_size
done
|or
for i in /sys/devices/virtual/block/*/queue
do
echo "deadline" > $i/scheduler
echo "2048" > $i/minimum_io_size
echo "1" > $i/add_random
echo "0" > $i/discard_max_bytes
echo "0" > $i/discard_granularity
echo "1" > /discard_zeroes_data
echo "128" > $i/optimal_io_size
done
I have so many variations and these ftmp dont have parameters so Ill let you get creative on those.
Sys Call
Valid keys for /etc/sysctl.conf
I meant for this list to be the OP.. but alas.. i was 11000 or so character to heavy.. lol
A gift ( not all sysctl calls are adjustable and this list is raw. there will be one or two no goes ..)
( wow, I hadn't realized there was near 800 settings in here.... )
ICS SYSCALL MASTER KEY
Alright, I know that most of you will already know how to use a sysctl.conf, but there are probably a couple
things that you didn't know about sysctl, so I may as well start with the obvious...
Code:
\\the following is the easiest way to use sysctl.conf, it is ideally done at init but is equally as easy to use from termemu\\
#/system/bin/sh \\ for init.d \\
sysctl -p \\ from terminal emulator you would have first signed it as usr \\
Now for one you may not now
I'm sure you've seen it used on each command.. (something like 'busybox sysctl -e -w vm.ridin_dirty=example)
*note in sysctl, -(e) is to skip displaying key (e)rrors and keep reading; -n is umber errors i believe; -w is (w)rite; the -p above is (p)rint sysclt.conf
Code:
\\ this is a nice little trick, there are over around 30 kb of keys,,what to do?? \\
su \\ or #/system/bin/sh if in a script \\
sysctl -p /etc/where/ever/your/2nd/sysctl/is
sysctl -p /or/your/5th
sysctl -p $0 <\\ or call your working script itself.\\>
<\\next is the command to create master list from your own device\\>
[B]sysctl -A > /data/log/MasterSysctl.txt[/B]
<\\and this next one,,, well this next is just priceless.. how's this for difficult syntax\\>
sysctl -w /proc/1/oom_adj=-17 <\\yes,, I mean..it...\\>
sysctl -w /sys/devices/virtual/block/loop1/queue/scheduler=easiest_way_to_apply_any_setting_you_arent_sure_of
Some working examples coming soon.
CpuFreq slash Governor settings
Similar but more refined and for a PEGASUS SETUP
Customize it all...
This is an advanced example made simple.. This one will set (between 6) governor and its settings, max and min freq, readahead kb in all of BDI, and inode readahead blks in each mmcblk.
And its 2.2* kb. And you only need to edit the subs if you wamt...
{no mem management or screenstate, but I just had a 4.5 hour screen on cycle at 1.4 max and scoring 4600+ on quadrants...}
Code:
#!/system/bin/sh
chmod 0644 /sys/block/*/queue/*
mount -o remount,rw / /
mount -o remount.rw /system /system
governor=pegasusq
max_freq=1400000
min_freq=50000
inode_readahead=128
read_ahead_kb=3840
cpu=/sys/devices/system/cpu/cpu0/cpufreq
echo "$min_freq" > $cpu/scaling_min_freq
echo "$max_freq" > $cpu/scaling_max_freq
for i in /sys/block/*/*/force_ro
do
echo "0" > $i
done
for i in /sys/class/bdi/*/read*
do
echo "$read_ahead_kb" > $i
done
for i in /sys/fs/ext4/*/inode_*
do
echo "$inode_readahead" > $i
done
for i in $cpu/scaling_governor
do
echo "$governor" > $i
done
for i in /sys/devices/system/cpu/cpufreq
do
active=`cat $cpu/scaling_governor`
Begin_ondemand
echo "40000" > $i/ondemand/sampling_rate
echo "70" > $i/ondemand/up_threshold
echo "15" > $i/ondemand/powersave_bias
echo "70" > $i/ondemand/freq_step
echo "3" > $i/ondemand/sampling_down_factor
Begin_smartassv2
echo "800000" > $i/smartass/awake_ideal_freq
echo "200000" > $i/smartass/sleep_ideal_freq
echo "800000" > $i/smartass/sleep_wakeup_freq
echo "75" > $i/smartass/max_cpu_load
echo "45" > $i/smartass/min_cpu_load
echo "0" > $i/smartass/ramp_up_step
echo "0" > $i/smartass/ramp_down_step
echo "24000" > $i/smartass/up_rate_us
echo "99000" > $i/smartass/down_rate_us
Begin_interactive
echo "80" > $i/interactive/go_hispeed_load
echo "40000" > $i/interactive/min_sample_time
echo "20000" > $i/interactive/timer_rate
#Begin_pegasusq
echo "80" > $i/pegasusq/up_threshold
echo "65" > $i/pegasusq/up_threshold_at_min_freq
echo "5" > $i/pegasusq/sampling_down_factor
echo "5" > $i/pegasusq/down_differential
echo "60" > $i/pegasusq/freq_step
echo "400000" > $i/freq_for_responsiveness
echo "10" > $i/pegasusq/cpu_up_rate
echo "20" > $i/pegasusq/cpu_down_rate
echo "400000" > $i/pegasusq/hotplug_freq_1_1
echo "300000" > $i/pegasusq/hotplug_freq_2_0
echo "300" > $i/pegasusq/hotplug_rq_1_1
echo "350" > $i/pegasusq/hotplug_rq_2_0
echo "0" > $i/pegasusq/ignore_nice_load
echo "1" > $i/pegasusq/io_is_busy
echo "0" > $i/pegasusq/max_cpu_lock
echo "0" > $i/pegasusq/hotplug_lock
#Begin_lulzactive
echo "60" > $i/lulzactive/inc_cpu_load
echo "4" > $i/lulzactive/pump_up_step
echo "1" > $i/lulzactive/pump_down_step
echo "10000" > $i/lulzactive/up_sample_time
echo "70000" > $i/lulzactive/down_sample_time
echo "5" > $i/lulzactive/screen_off_min_step
#Begin_conservative
echo "55" > $i/conservative/up_threshold
echo "25000" > $i/conservative/sampling_rate
echo "3" > $i/conservative/sampling_down_factor
echo "40" > $i/conservative/down_threshold
echo "5" > $i/conservative/freq_step
done
exit 0
Odex all data apps
http://forum.xda-developers.com/showthread.php?p=32305612
Here's a link to a post with a Flashable busybox (with extra-goodies)
PhAkEer said:
a place where one can come to copy/plaste sections
Click to expand...
Click to collapse
I know how to copy, but what is this plaste you speak of?
anyways, this looks promising for adding some more scripts in one spot for all.
Sent from my SPH-D710 using Tapatalk
Click here for custom mods for your E4GT
Prove it
PhAkEer said:
Prove it
Click to expand...
Click to collapse
Edited in a quote before you edited :screwy: haha
Sent from my SPH-D710 using Tapatalk
Click here for custom mods for your E4GT
What is a script? And what do all those fancy thingy things you posted do? Oh, and I spilled grape juice all over my phone. Its still dripping out of it. Why do you think it won't turn on? Also, can you come help me pick my nose?
{
"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"
}
How did this thread sneak in on me bro? A little sly-of-hand action there huh.... hook 'em in placebo and create another thread... then mention nonchalantly in placebo thread to check your other thread for the latest.Lol
Looking forward to seeing where this one leads.. nice work man!
Sent from my SPH-D710 using Xparent Blue Tapatalk 2
blackcanopy said:
How did this thread sneak in on me bro? A little sly-of-hand action there huh.... hook 'em in placebo and create another thread... then mention nonchalantly in placebo thread to check your other thread for the latest.Lol
Looking forward to seeing where this one leads.. nice work man!
Sent from my SPH-D710 using Xparent Blue Tapatalk 2
Click to expand...
Click to collapse
Come one now, brah. You know exactly where this goes....
(this leads to me being in your backpack after a while.. and...
to my ultimate goal.... I sleep.. for at least 6 hours at once...)
Anybody want a script to odex data/apps??
Wrote it this morning.
Just need dexopt-wrapper and then execute this.. no reboot, apps keep their classes.dex for the future as well...
Code:
#!/system/bin/sh
J=/system/framework
A=/data/app
W=/system/xbin/dexopt-wrapper
mount -o remount,rw /system /system
mount -o remount,rw /data /data
rm -f $A/*.odex
for i in $A/*
do
name=`basename $i .apk`
$W $A/$name.apk $A/$name.odex $J/core.jar:$J/core-junit.jar:$J/bouncycastle.jar:$J/ext.jar:$J/framework.jar:$J/framework2.jar:$J/android.policy.jar:$J/services.jar:$J/apache-xml.jar
chmod 0644 $A/$name.odex
done
echo $i
sleep 2
exit 0
( and telling me if this stuff does or does not work is NOT off topic ftr )
Haven't even had time to look at this to see what it does...
Found it in an unnamed folder in a backup..
If anybodies knows who's work this is please say so..
I'm only posting it to get it off of my work pc.. I'll look into it later.
Code:
#!/system/bin/sh
#
#
readdebug() {
DUAL_CORE_DEBUG=`cat /system/etc/dual_core/debug`
DUAL_CORE_DEBUG=${DUAL_CORE_DEBUG:=0}
}
log() {
if [ "$DUAL_CORE_DEBUG" = "1" ] ; then
echo "$(date): [email protected]" >> /devlog/dual_core
fi
}
logcpu() {
if [ "$DUAL_CORE_DEBUG" = "1" ] ; then
local NOW_FREQ=`cat /sys/devices/system/cpu/cpu0/cpufreq/scaling_max_freq`
local NOW=`cat /sys/devices/system/cpu/cpu0/cpufreq/scaling_max_freq`
log "CPU[0]: scaling_max_freq=$NOW"
local NOW_ONLINE=`cat /sys/devices/system/cpu/cpu1/online`
log "CPU[1]: online=$NOW_ONLINE"
if [ -f /sys/devices/system/cpu/cpu1/cpufreq/scaling_max_freq ] ; then
local NOW=`cat /sys/devices/system/cpu/cpu1/cpufreq/scaling_max_freq`
log "CPU[1]: scaling_max_freq=$NOW"
fi
fi
}
init_dc_fs() {
sysrw
touch /devlog/dual_core ; chmod 777 /devlog/dual_core
touch /system/etc/dual_core/debug ; chmod 777 /system/etc/dual_core/debug
touch /system/etc/dual_core/sleep_frequency ; chmod 777 /system/etc/dual_core/sleep_frequency
touch /system/etc/dual_core/disable_sleep_freq ; chmod 777 /system/etc/dual_core/disable_sleep_freq
sysro
}
waitforwakeup() {
log "waitforwakeup{" ; logcpu
AWAKE=`cat /sys/power/wait_for_fb_wake`
if [ "$AWAKE" = "awake" ] ; then
CPU0_FREQ_AWAKE=${CPU0_FREQ_AWAKE:="$CPU0_FREQ_BOOT"}
log "Awake triggered... old awake is: $CPU0_FREQ_AWAKE"
log "CPU[1] try set online"
chmod 644 /sys/devices/system/cpu/cpu1/online
echo "1" > /sys/devices/system/cpu/cpu1/online
chmod 444 /sys/devices/system/cpu/cpu1/online
log "CPU[1] online"
if [ "$DISABLE_SLEEP" = "1" ] || [ "$OC_DAEMON" = "1" ] ; then
log "sleep cpu0 frequency mod disabled"
else
log "waking up from earlier sleep.. set to old awake frequency = $CPU0_FREQ_AWAKE"
echo "$CPU0_FREQ_AWAKE" > /sys/devices/system/cpu/cpu0/cpufreq/scaling_max_freq
fi
sleep 1
echo "$CPU0_FREQ_AWAKE" > /sys/devices/system/cpu/cpu1/cpufreq/scaling_max_freq
chmod 644 /sys/devices/system/cpu/cpu1/cpufreq/scaling_governor
echo "ondemand" > /sys/devices/system/cpu/cpu1/cpufreq/scaling_governor
chmod 444 /sys/devices/system/cpu/cpu1/cpufreq/scaling_governor
log "}wakeup" ; logcpu
fi
}
waitforsleep() {
log "waitforsleep{" ; logcpu
SLEEPING=`cat /sys/power/wait_for_fb_sleep`
if [ "$SLEEPING" = "sleeping" ] ; then
log "Sleep triggered..."
sleep_cpu0
log "CPU[1]: try set offline"
chmod 644 /sys/devices/system/cpu/cpu1/online
echo "0" > /sys/devices/system/cpu/cpu1/online
chmod 444 /sys/devices/system/cpu/cpu1/online
log "CPU[1]: offline"
fi
log "}waitforsleep" ; logcpu
}
sleep_cpu0() {
CPU0_FREQ_AWAKE=`cat /sys/devices/system/cpu/cpu0/cpufreq/scaling_max_freq`
log "Sleeping, remember awake frequency: $CPU0_FREQ_AWAKE"
DISABLE_SLEEP=`cat /system/etc/dual_core/disable_sleep_freq`
if [ "$DISABLE_SLEEP" = "1" ] || [ "$OC_DAEMON" = "1" ] ; then
log "DISABLE_SLEEP=1 or OCD detected"
else
if [ -e /system/etc/dual_core/sleep_frequency ] ; then
SLEEP_FREQUENCY=`cat /system/etc/dual_core/sleep_frequency`
log "sleep_frequency setting found, using $SLEEP_FREQUENCY instead of $CPU0_FREQ_AWAKE"
fi
SLEEP_FREQUENCY=${SLEEP_FREQUENCY:=DEFAULT_SLEEP_FREQUENCY}
echo "$SLEEP_FREQUENCY" > /sys/devices/system/cpu/cpu0/cpufreq/scaling_max_freq
log "Set cpu0 frequency to $SLEEP_FREQUENCY"
fi
}
DEFAULT_SLEEP_FREQUENCY=192000
init_dc_fs
DUAL_CORE_DEBUG="1"
log "Starting..."; logcpu
if [ -f /system/etc/virtuous_oc/wake_max_freq ] ; then
OC_DAEMON=1
log "OC Daemon found."
fi
DISABLE_SLEEP=`cat /system/etc/dual_core/disable_sleep_freq`
CPU0_FREQ_BOOT=`cat /sys/devices/system/cpu/cpu0/cpufreq/scaling_max_freq`
STATE=`cat /sys/power/state_onchg`
if [ "$STATE" = "chgoff" ] ; then
log "device is asleep, scaling down"
sleep_cpu0
fi
DUAL_CORE_DEBUG="0"
(while : ; do
waitforwakeup
readdebug
waitforsleep
readdebug
done &)
at a glance it looks like an extremely over complicated screenstate script....
PhAkEer said:
Haven't even had time to look at this to see what it does...
Found it in an unnamed folder in a backup..
If anybodies knows who's work this is please say so..
I'm only posting it to get it off of my work pc.. I'll look into it later.
Code:
#!/system/bin/sh
#
#
readdebug() {
DUAL_CORE_DEBUG=`cat /system/etc/dual_core/debug`
DUAL_CORE_DEBUG=${DUAL_CORE_DEBUG:=0}
}
log() {
if [ "$DUAL_CORE_DEBUG" = "1" ] ; then
echo "$(date): [email protected]" >> /devlog/dual_core
fi
}
logcpu() {
if [ "$DUAL_CORE_DEBUG" = "1" ] ; then
local NOW_FREQ=`cat /sys/devices/system/cpu/cpu0/cpufreq/scaling_max_freq`
local NOW=`cat /sys/devices/system/cpu/cpu0/cpufreq/scaling_max_freq`
log "CPU[0]: scaling_max_freq=$NOW"
local NOW_ONLINE=`cat /sys/devices/system/cpu/cpu1/online`
log "CPU[1]: online=$NOW_ONLINE"
if [ -f /sys/devices/system/cpu/cpu1/cpufreq/scaling_max_freq ] ; then
local NOW=`cat /sys/devices/system/cpu/cpu1/cpufreq/scaling_max_freq`
log "CPU[1]: scaling_max_freq=$NOW"
fi
fi
}
init_dc_fs() {
sysrw
touch /devlog/dual_core ; chmod 777 /devlog/dual_core
touch /system/etc/dual_core/debug ; chmod 777 /system/etc/dual_core/debug
touch /system/etc/dual_core/sleep_frequency ; chmod 777 /system/etc/dual_core/sleep_frequency
touch /system/etc/dual_core/disable_sleep_freq ; chmod 777 /system/etc/dual_core/disable_sleep_freq
sysro
}
waitforwakeup() {
log "waitforwakeup{" ; logcpu
AWAKE=`cat /sys/power/wait_for_fb_wake`
if [ "$AWAKE" = "awake" ] ; then
CPU0_FREQ_AWAKE=${CPU0_FREQ_AWAKE:="$CPU0_FREQ_BOOT"}
log "Awake triggered... old awake is: $CPU0_FREQ_AWAKE"
log "CPU[1] try set online"
chmod 644 /sys/devices/system/cpu/cpu1/online
echo "1" > /sys/devices/system/cpu/cpu1/online
chmod 444 /sys/devices/system/cpu/cpu1/online
log "CPU[1] online"
if [ "$DISABLE_SLEEP" = "1" ] || [ "$OC_DAEMON" = "1" ] ; then
log "sleep cpu0 frequency mod disabled"
else
log "waking up from earlier sleep.. set to old awake frequency = $CPU0_FREQ_AWAKE"
echo "$CPU0_FREQ_AWAKE" > /sys/devices/system/cpu/cpu0/cpufreq/scaling_max_freq
fi
sleep 1
echo "$CPU0_FREQ_AWAKE" > /sys/devices/system/cpu/cpu1/cpufreq/scaling_max_freq
chmod 644 /sys/devices/system/cpu/cpu1/cpufreq/scaling_governor
echo "ondemand" > /sys/devices/system/cpu/cpu1/cpufreq/scaling_governor
chmod 444 /sys/devices/system/cpu/cpu1/cpufreq/scaling_governor
log "}wakeup" ; logcpu
fi
}
waitforsleep() {
log "waitforsleep{" ; logcpu
SLEEPING=`cat /sys/power/wait_for_fb_sleep`
if [ "$SLEEPING" = "sleeping" ] ; then
log "Sleep triggered..."
sleep_cpu0
log "CPU[1]: try set offline"
chmod 644 /sys/devices/system/cpu/cpu1/online
echo "0" > /sys/devices/system/cpu/cpu1/online
chmod 444 /sys/devices/system/cpu/cpu1/online
log "CPU[1]: offline"
fi
log "}waitforsleep" ; logcpu
}
sleep_cpu0() {
CPU0_FREQ_AWAKE=`cat /sys/devices/system/cpu/cpu0/cpufreq/scaling_max_freq`
log "Sleeping, remember awake frequency: $CPU0_FREQ_AWAKE"
DISABLE_SLEEP=`cat /system/etc/dual_core/disable_sleep_freq`
if [ "$DISABLE_SLEEP" = "1" ] || [ "$OC_DAEMON" = "1" ] ; then
log "DISABLE_SLEEP=1 or OCD detected"
else
if [ -e /system/etc/dual_core/sleep_frequency ] ; then
SLEEP_FREQUENCY=`cat /system/etc/dual_core/sleep_frequency`
log "sleep_frequency setting found, using $SLEEP_FREQUENCY instead of $CPU0_FREQ_AWAKE"
fi
SLEEP_FREQUENCY=${SLEEP_FREQUENCY:=DEFAULT_SLEEP_FREQUENCY}
echo "$SLEEP_FREQUENCY" > /sys/devices/system/cpu/cpu0/cpufreq/scaling_max_freq
log "Set cpu0 frequency to $SLEEP_FREQUENCY"
fi
}
DEFAULT_SLEEP_FREQUENCY=192000
init_dc_fs
DUAL_CORE_DEBUG="1"
log "Starting..."; logcpu
if [ -f /system/etc/virtuous_oc/wake_max_freq ] ; then
OC_DAEMON=1
log "OC Daemon found."
fi
DISABLE_SLEEP=`cat /system/etc/dual_core/disable_sleep_freq`
CPU0_FREQ_BOOT=`cat /sys/devices/system/cpu/cpu0/cpufreq/scaling_max_freq`
STATE=`cat /sys/power/state_onchg`
if [ "$STATE" = "chgoff" ] ; then
log "device is asleep, scaling down"
sleep_cpu0
fi
DUAL_CORE_DEBUG="0"
(while : ; do
waitforwakeup
readdebug
waitforsleep
readdebug
done &)
at a glance it looks like an extremely over complicated screenstate script....
Click to expand...
Click to collapse
You might be right! It kinda looks like the script from the CPU sleep thread from here http://forum.xda-developers.com/showthread.php?t=1739457
Sent from my SPH-D710 using Tapatalk 2
Customizable Pegasus.
As is I'm getting something I'd recognize as a score in quad on jb... I thought the day would never come....
Code:
#!/system/bin/sh
# SETUP FOR PEGASUS
# I/O Settings
scheduler=deadline
read_ahead=3072
inode_blks=64
inode_goal=8
# CPU Freq Settings
min_freq=200
max_freq=1200
up_thresh=80
sampling=40000
sampling_factor=3
down_diff=5
freq_step=60
response_freq=500000
up_rate=20
down_rate=30
freq_1_1=400000
freq_2_0=300000
rq_1_1=400
rq_2_0=350
ignore_nice=0
io_is_busy=0
cpu_lock=0
lockR=0
# Stream settings
max_mb_scan=0
min_mb_scan=0
mb_stream_req=0
max_writeback_bump=32
req_order2=0
prealloc_mb=768
# Here we go again...lol
set -x
exec > /data/log/Pegasus.log 2>&1
/system/bin/sh
for j in $(/system/xbin/busybox mount | /system/xbin/busybox grep ext4 | /system/xbin/busybox cut -d " " -f3)
do
sync
/system/xbin/busybox mount -o remount,noatime,barrier=0,commit=5 $j
done
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,commit=0 /cache /cache
mount -o remount,noatime,nodiratime,delalloc,noauto_da_alloc,barrier=0,commit=0 /data /data
for i in /sys/fs/ext4/*
do
echo "$max_mb_scan" > $i/mb_max_to_scan
echo "$min_mb_scan" > $i/mb_min_to_scan
echo "$inode_blks" > $i/inode_readahead_blks
echo "$inode_goal" > $i/inode_goal
echo "$mb_stream_req" > $i/mb_stream_req
echo "$max_writeback_bump" > $i/max_writeback_mb_bump
echo "$preaoc_mb" > $i/mb_group_prealloc
echo "$req_order2" > $i/mb_order2_req
done
echo "pegasusq" > /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor
for i in /sys/devices/system/cpu/cpufreq/pegasusq
do
echo "$up_thresh" > $i/up_threshold
echo "$sampling" > $i/sampling_rate
echo "$sampling_factor" > $i/sampling_down_factor
echo "$down_diff" > $i/down_differential
echo "$freq_step" > $i/freq_step
echo "$up_rate" > $i/cpu_up_rate
echo "$down_rate" > $i/cpu_down_rate
echo "$freq_1_1" > $i/hotplug_freq_1_1
echo "$freq_2_0" > $i/hotplug_freq_2_0
echo "$rq_1_1" > $i/hotplug_rq_1_1
echo "$rq_2_0" > $i/hotplug_rq_2_0
echo "$ignore_nice" > $i/ignore_nice_load
echo "$io_is_busy" > $i/io_is_busy
echo "$cpu_lock" > $i/max_cpu_lock
done
for i in /sys/devices/virtual/bdi/*/read_ahead_kb
do
echo "$read_ahead" > $i
done
for i in /sys/class/block/*/queue
do
echo "$scheduler" > $i/scheduler
echo "$read_ahead" > $i/read_ahead_kb
done
case "$min_freq" in
*)
i=/sys/devices/system/cpu/cpu0/cpufreq
;;
25)
echo "25000" > $i/scaling_min_freq
;;
50)
echo "50000" > $i/scaling_min_freq
;;
100)
echo "100000" > $i/scaling_min_freq
;;
200)
echo "200000" > $i/scaling_min_freq
;;
300)
echo "300000" > $i/scaling_min_freq
;;
400)
echo "400000" > $i/scaling_min_freq
;;
500)
echo "500000" > $i/scaling_min_freq
;;
esac;
case "$max_freq" in
800)
echo "800000" > $cpu/scaling_max_freq
;;
900)
echo "900000" > $cpu/scaling_max_freq
;;
1000)
echo "1000000" > $cpu/scaling_max_freq
;;
1100)
echo "1100000" > $cpu/scaling_max_freq
;;
1200)
echo "1200000" > $cpu/scaling_max_freq
;;
1300)
echo "1300000" > $cpu/scaling_max_freq
;;
1400)
echo "1400000" > $cpu/scaling_max_freq
;;
1600)
echo "1600000" > $cpu/scaling_max_freq
;;
esac;
Nice to see this in the development section :thumbup:
-TeaM VeNuM Like A Boss
MiguelHogue said:
Nice to see this in the development section :thumbup:
-TeaM VeNuM Like A Boss
Click to expand...
Click to collapse
It isn't so such much for something to develop, I mainly just wanted the resources available the Tw themers and the like.
The parameters for the section said dev/mod/hack so I'm sure it fits in there somewhere.. I need to start getting some material in here though. . ... watch this...
EEECCCCCCHOOOO
khoeoeoeoe
ohohohohhh
See...
This one is a WIP so pay attention
Dual cpu screenstate script.. simple stuff
the way I have this setup it setup it will call powersave when screen is off. This is only practical if it calls another governor when the screen comes back on, so change it from "sh /data/local/pegasus" to "sh wherever you have a gov script" or to
"echo govofchoice > /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor"
Code:
#!/system/bin/sh
#
#
sleep 1m
while [[ "awake" = $AWAKE ]]
do
AWAKE=`cat /sys/power/wait_for_fb_wake`
if [ "awake" = $AWAKE ]
then
echo "1" > /sys/devices/system/cpu/cpu1/online
echo "1" > /sys/devices/system/cpu/cpu0/online
sh /data/local/Pegasus
fi
sleep 2
ASLEEP=`cat /sys/power/wait_for_fb_sleep`
if [ "sleeping" = $ASLEEP ]
then
echo "0" > /sys/devices/system/cpu/cpu1/online
echo "0" > /sys/devices/system/cpu/cpu0/online
echo "powersave" > /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor
fi
sleep 2
done
exit 0
PhAkEer said:
Anybody want a script to odex data/apps??
Wrote it this morning.
Just need dexopt-wrapper and then execute this.. no reboot, apps keep their classes.dex for the future as well...
Code:
#!/system/bin/sh
J=/system/framework
A=/data/app
W=/system/xbin/dexopt-wrapper
mount -o remount,rw /system /system
mount -o remount,rw /data /data
rm -f $A/*.odex
for i in $A/*
do
name=`basename $i .apk`
$W $A/$name.apk $A/$name.odex $J/core.jar:$J/core-junit.jar:$J/bouncycastle.jar:$J/ext.jar:$J/framework.jar:$J/framework2.jar:$J/android.policy.jar:$J/services.jar:$J/apache-xml.jar
chmod 0644 $A/$name.odex
done
echo $i
sleep 2
exit 0
( and telling me if this stuff does or does not work is NOT off topic ftr )
Click to expand...
Click to collapse
Where do we get a copy of dexopt-wrapper? I downloaded the odex station that has it in the zip you had somewhere, but I get status7 error when flashing it.
Sent from my SPH-D710 using Xparent Blue Tapatalk 2
Just extract the wrapper to xbin and youre gtg
Warning: hideous sig acomin..
Need a change of pace?
Odexing Data with a simple script
or
Change your boot splash-screen in two steps
The following scripts are made to ease the life of a flashaholic and LTE. I flash a ton of Cyanogen Nightlies and new Roms of others.
They have been working for me for a while now and I though I should share them.
Soon ill look into adding the APN for Tmobile LTE to the apns-conf.xml and possibly combine into one script.
You Must Have Root! I have run these using the free $cripter but you should be able to use Script Manager as well.
I have also added them as attachments below.
Please test these before blindly running. Just because they work flawless for me doesn't mean it will for everyone in every case. The Tmobile sound edits are the newest one so please watch this one a little more careful and I have not run it as much and mine uses tab and not spaces as the reference post.
If you find any of the scripts useful, feel free to hit the [Thanks] button below
Disclaimer: I am not responsible bricking your phone, voiding your warranty, or any other issue may have as result of using these scripts
Build.prop Editor
Last Updated: 04/13/2013
Version: b01 custom b02 prop edit to possible speed up internet
Description: This will change entries if already in build.prop or add the needed entries at the bottom to enable LTE and also perfered network options in Cyanogenmod. It will make a backup of the file prior to doing this.
Code:
#!/system/bin/sh
# Nexus 4 build.prop Editor to enabled LTE
# created by XDA user: justinaz
# created on 4/13/13
# version: b01
# mounting system as rw
busybox mount -o remount,rw /system
if [ $? != 0 ] ; then exit
fi
# Set the File to Edit
FILE=/system/build.prop
#Make Backup of build.prop
if [ -f $FILE.orig ];
then
cp $FILE $FILE.orig.1
else
cp $FILE $FILE.orig
fi
# Set the Build.prop items below
# line# is the Build Prop you want to change
# lineArg# is the value you want it to be
line1=telephony.lteOnGsmDevice
lineArg1=1
line2=ro.telephony.default_network
lineArg2=9
line3=ro.ril.def.preferred.network
lineArg3=9
# X should end with number of changes above 1 2 3
for X in 1 2 3
do
lineNum=
eval prop=\$line$X
eval arg=\$lineArg$X
echo $prop=$arg
if grep -Fq $prop $FILE ; then
lineNum=`sed -n "/${prop}/=" $FILE`
echo $lineNum
sed -i "${lineNum} c${prop}=${arg}" $FILE
else
echo "$prop does not exist in $FILE"
echo "Adding to end of $FILE"
echo $prop=$arg >> $FILE
fi
done;
# mounting system as ro
busybox mount -o remount,ro /system
Soundfile Editor (Tmobile Fixes)
Last Updated: 04/13/2013
Version: s01
Description: This will change the needed snd_soc_msm_2x_Fusion3 entries for T-Mobile. It will make a backup prior to doing this.
Reference: XDA post: simobile: Fix for no in-call audio/T-Mobile US/4.2.2/.33 radio or lower
Code:
#!/system/bin/sh
# Nexus 4 Sound File Editor to fix enabled LTE Sound Issues
# created by XDA user: justinaz
# created on 4/13/13
# version: s01
# Reference XDA post: simobile http://forum.xda-developers.com/showthread.php?t=2233319
# mounting system as rw
busybox mount -o remount,rw /system
if [ $? != 0 ] ; then exit
fi
# Set the File to Edit
FILE=/system/etc/snd_soc_msm/snd_soc_msm_2x_Fusion3
#Make Backup File we ar editing just in case
if [ -f $FILE.orig ];
then
cp $FILE $FILE.orig.1
else
cp $FILE $FILE.orig
fi
# line# is the Line Item you want to change
# lineArg# is the value you want it to be
line1=" ACDBID 81:1"
lineArg1=" ACDBID 7:1"
line2=" ACDBID 91:2"
lineArg2=" ACDBID 6:2"
# X should end with number of changes above 1 2
for X in 1 2
do
lineNum=
eval prop=\$line$X
eval arg=\$lineArg$X
if grep -Fq "$prop" $FILE ; then
lineNum=`sed -n "/${prop}/=" $FILE`
echo "Line number $lineNum found for: $prop"
sed -i "${lineNum} c${arg}" $FILE
echo "$lineNum from: $prop :TO: $arg"
else
echo "$prop does not exist in $FILE"
fi
done;
# mounting system as ro
busybox mount -o remount,ro /system
justinaz said:
The following scripts are made to ease the life of a flashaholic and LTE. I flash a ton of Cyanogen Nightlies and new Roms of others.
They have been working for me for a while now and I though I should share them.
Soon ill look into adding the APN for Tmobile LTE to the apns-conf.xml and possibly combine into one script.
You Must Have Root! I have run these using the free $cripter but you should be able to use Script Manager as well.
I have also added them as attachments below.
Please test these before blindly running. Just because they work flawless for me doesn't mean it will for everyone in every case. The Tmobile sound edits are the newest one so please watch this one a little more careful and I have not run it as much and mine uses tab and not spaces as the reference post.
If you find any of the scripts useful, feel free to hit the [Thanks] button below
Disclaimer: I am not responsible bricking your phone, voiding your warranty, or any other issue may have as result of using these scripts
Build.prop Editor
Last Updated: 04/13/2013
Version: b01
Description: This will change entries if already in build.prop or add the needed entries at the bottom to enable LTE and also perfered network options in Cyanogenmod. It will make a backup of the file prior to doing this.
Code:
#!/system/bin/sh
# Nexus 4 build.prop Editor to enabled LTE
# created by XDA user: justinaz
# created on 4/13/13
# version: b01
# mounting system as rw
busybox mount -o remount,rw /system
if [ $? != 0 ] ; then exit
fi
# Set the File to Edit
FILE=/system/build.prop
#Make Backup of build.prop
if [ -f $FILE.orig ];
then
cp $FILE $FILE.orig.1
else
cp $FILE $FILE.orig
fi
# Set the Build.prop items below
# line# is the Build Prop you want to change
# lineArg# is the value you want it to be
line1=telephony.lteOnGsmDevice
lineArg1=1
line2=ro.telephony.default_network
lineArg2=9
line3=ro.ril.def.preferred.network
lineArg3=9
# X should end with number of changes above 1 2 3
for X in 1 2 3
do
lineNum=
eval prop=\$line$X
eval arg=\$lineArg$X
echo $prop=$arg
if grep -Fq $prop $FILE ; then
lineNum=`sed -n "/${prop}/=" $FILE`
echo $lineNum
sed -i "${lineNum} c${prop}=${arg}" $FILE
else
echo "$prop does not exist in $FILE"
echo "Adding to end of $FILE"
echo $prop=$arg >> $FILE
fi
done;
# mounting system as ro
busybox mount -o remount,ro /system
Soundfile Editor (Tmobile Fixes)
Last Updated: 04/13/2013
Version: s01
Description: This will change the needed snd_soc_msm_2x_Fusion3 entries for T-Mobile. It will make a backup prior to doing this.
Reference: XDA post: simobile: Fix for no in-call audio/T-Mobile US/4.2.2/.33 radio or lower
Code:
#!/system/bin/sh
# Nexus 4 Sound File Editor to fix enabled LTE Sound Issues
# created by XDA user: justinaz
# created on 4/13/13
# version: s01
# Reference XDA post: simobile http://forum.xda-developers.com/showthread.php?t=2233319
# mounting system as rw
busybox mount -o remount,rw /system
if [ $? != 0 ] ; then exit
fi
# Set the File to Edit
FILE=/system/etc/snd_soc_msm/snd_soc_msm_2x_Fusion3
#Make Backup File we ar editing just in case
if [ -f $FILE.orig ];
then
cp $FILE $FILE.orig.1
else
cp $FILE $FILE.orig
fi
# line# is the Line Item you want to change
# lineArg# is the value you want it to be
line1=" ACDBID 81:1"
lineArg1=" ACDBID 7:1"
line2=" ACDBID 91:2"
lineArg2=" ACDBID 6:2"
# X should end with number of changes above 1 2
for X in 1 2
do
lineNum=
eval prop=\$line$X
eval arg=\$lineArg$X
if grep -Fq "$prop" $FILE ; then
lineNum=`sed -n "/${prop}/=" $FILE`
echo "Line number $lineNum found for: $prop"
sed -i "${lineNum} c${arg}" $FILE
echo "$lineNum from: $prop :TO: $arg"
else
echo "$prop does not exist in $FILE"
fi
done;
# mounting system as ro
busybox mount -o remount,ro /system
Click to expand...
Click to collapse
I LOVE YOU !!! lol
Will this work with the new radio?
Sent from my Nexus 4
Contivity said:
Will this work with the new radio?
Sent from my Nexus 4
Click to expand...
Click to collapse
No, newest radio can't use lte
I know this is off topic, but was wondering if you can help me with this. Can you please make a script that will add these 4 lines to the build.prop?
ro.ril.hsxpa=2
ro.ril.gprsclass=12
ro.ril.hsdpa.category=24
ro.ril.hsupa.category=7
I got these lines from Simms22 awhile back. It helps with data connection and speeds with T-Mobile. Please! =)
Goog1e Phone said:
I know this is off topic, but was wondering if you can help me with this. Can you please make a script that will add these 4 lines to the build.prop?
ro.ril.hsxpa=2
ro.ril.gprsclass=12
ro.ril.hsdpa.category=24
ro.ril.hsupa.category=7
I got these lines from Simms22 awhile back. It helps with data connection and speeds with T-Mobile. Please! =)
Click to expand...
Click to collapse
Its pretty easy to add additional build prop additions.
THis is the new one.... i tested and appears to work correctly
Code:
#!/system/bin/sh
# Nexus 4 build.prop Editor to enabled LTE
# created by XDA user: justinaz
# created on 4/13/13
# version: b02
# mounting system as rw
busybox mount -o remount,rw /system
if [ $? != 0 ] ; then exit
fi
# Set the File to Edit
FILE=/system/build.prop
#Make Backup of build.prop
if [ -f $FILE.orig ];
then
cp $FILE $FILE.orig.1
else
cp $FILE $FILE.orig
fi
# Set the Build.prop items below
# line# is the Build Prop you want to change
# lineArg# is the value you want it to be
line1=telephony.lteOnGsmDevice
lineArg1=1
line2=ro.telephony.default_network
lineArg2=9
line3=ro.ril.def.preferred.network
lineArg3=9
line4=ro.ril.hsxpa
lineArg4=2
line5=ro.ril.gprsclass
lineArg5=12
line6=ro.ril.hsdpa.category
lineArg6=24
line7=ro.ril.hsupa.category
lineArg7=7
# X should end with number of changes above 1 2 3
for X in 1 2 3 4 5 6 7
do
lineNum=
eval prop=\$line$X
eval arg=\$lineArg$X
echo $prop=$arg
if grep -Fq $prop $FILE ; then
lineNum=`sed -n "/${prop}/=" $FILE`
echo $lineNum
sed -i "${lineNum} c${prop}=${arg}" $FILE
else
echo "$prop does not exist in $FILE"
echo "Adding to end of $FILE"
echo $prop=$arg >> $FILE
fi
done;
# mounting system as ro
busybox mount -o remount,ro /system
justinaz said:
Its pretty easy to add additional build prop additions.
THis is the new one.... i tested and appears to work correctly
Code:
#!/system/bin/sh
# Nexus 4 build.prop Editor to enabled LTE
# created by XDA user:justinaz
# created on 4/13/13
# version:b02
# mounting system as rw
busybox mount -o remount,rw /system
if [ $? != 0 ] ; then exit
fi
# Set the File to Edit
FILE=/system/build.prop
#Make Backup of build.prop
if [ -f $FILE.orig ];
then
cp $FILE $FILE.orig.1
else
cp $FILE $FILE.orig
fi
# Set the Build.prop items below
# line# is the Build Prop you want to change
# lineArg# is the value you want it to be
line1=telephony.lteOnGsmDevice
lineArg1=1
line2=ro.telephony.default_network
lineArg2=9
line3=ro.ril.def.preferred.network
lineArg3=9
line4=ro.ril.hsxpa
lineArg4=2
line5=ro.ril.gprsclass
lineArg5=12
line6=ro.ril.hsdpa.category
lineArg6=24
line7=ro.ril.hsupa.category
lineArg7=7
# X should end with number of changes above 1 2 3
for X in 1 2 3 4 5 6 7
do
lineNum=
eval prop=\$line$X
eval arg=\$lineArg$X
echo $prop=$arg
if grep -Fq $prop $FILE ; then
lineNum=`sed -n "/${prop}/=" $FILE`
echo $lineNum
sed -i "${lineNum} c${prop}=${arg}" $FILE
else
echo "$prop does not exist in $FILE"
echo "Adding to end of $FILE"
echo $prop=$arg >> $FILE
fi
done;
# mounting system as ro
busybox mount -o remount,ro /system
Click to expand...
Click to collapse
You're the man. Thank you for this! I would give you 10 thanks if I could!
Sent from my Nexus 4
Will these need to run on boot or just run once?
Sent from my Nexus 4 using xda app-developers app
n2d551 said:
Will these need to run on boot or just run once?
Sent from my Nexus 4 using xda app-developers app
Click to expand...
Click to collapse
Just once until you dirty flash a rom
It said I need to mount? How do I that?
Sent from my Nexus 4 using xda premium
Julianmgn said:
It said I need to mount? How do I that?
Sent from my Nexus 4 using xda premium
Click to expand...
Click to collapse
Can you give the actual error it says and detail about how you are running it? Your description is very vague.
Couple things it could be...... of the top of my head
are you running it as ROOT? (its required)
do you have busybox installed? (its required)
are you trying to run this in recovery/init.d script? (this is a shell script not one of those, you would have to modify it to run like that)
justinaz said:
Can you give the actual error it says and detail about how you are running it? Your description is very vague.
Couple things it could be...... of the top of my head
are you running it as ROOT? (its required)
do you have busybox installed? (its required)
are you trying to run this in recovery/init.d script? (this is a shell script not one of those, you would have to modify it to run like that)
Click to expand...
Click to collapse
I'm rooted and I have busy box installed, I downloaded scripter like the op said and when I try to run it, it give me the error "mount: permission denied are you root?"
Sent from my Nexus 4 using xda premium
Julianmgn said:
I'm rooted and I have busy box installed, I downloaded scripter like the op said and when I try to run it, it give me the error "mount: permission denied are you root?"
Sent from my Nexus 4 using xda premium
Click to expand...
Click to collapse
Same thing happened to me, try script manager, it worked for me.
Sent from my Nexus 4 using Tapatalk 2
MidtownHD said:
Same thing happened to me, try script manager, it worked for me.
Sent from my Nexus 4 using Tapatalk 2
Click to expand...
Click to collapse
Tried that also its giving me the same error
Sent from my Nexus 4 using xda premium
Julianmgn said:
Tried that also its giving me the same error
Sent from my Nexus 4 using xda premium
Click to expand...
Click to collapse
well, I would delete app data from root access app and the script app, then uninstall the script app. Reboot phone, check root access with other apps, ex. a file manager, then install preferred script app and try the scripts again. Worst case, do it manually.
Sent from my Nexus 4 using Tapatalk 2
You are making it more complicated than you need to.
You have to run the script as root. If you are using scripter long press the script and edit it. On the top there is a check box for Run as root? Check that and hit save. Then run the script.
Sent from my Nexus 4 using Tapatalk 2
Or just run it in rom toolbox
Sent from my Nexus 4 using xda app-developers app
justinaz said:
You are making it more complicated than you need to.
You have to run the script as root. If you are using scripter long press the script and edit it. On the top there is a check box for Run as root? Check that and hit save. Then run the script.
Sent from my Nexus 4 using Tapatalk 2
Click to expand...
Click to collapse
Maybe the apps are not detecting the root access correctly.
Sent from my Nexus 4 using Tapatalk 2
justinaz said:
You are making it more complicated than you need to.
You have to run the script as root. If you are using scripter long press the script and edit it. On the top there is a check box for Run as root? Check that and hit save. Then run the script.
Sent from my Nexus 4 using Tapatalk 2
Click to expand...
Click to collapse
Yup that did it lol
Sent from my Nexus 4 using xda premium
Julianmgn said:
Yup that did it lol
Sent from my Nexus 4 using xda premium
Click to expand...
Click to collapse
so you never granted root access?
Sent from my Nexus 4 using Tapatalk 2
Code:
* Your warranty is now void..
* I am not responsible for bricked devices, dead SD cards,
* thermonuclear war, you getting dumped or you getting fired because your phone
* bootloops and alarm does not go off. Please do some research if you have any
* YOU are choosing to make these modifications.
{
"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"
}
Requirements :-
- Android 4.0+
- Custom kernel (with init.d support)
- Root and Busybox installed
- 3MB of free space in "/system".
Feature :-
- Full memory management.
- kernel tweaks and improvements for better performance and battery life.
- Entropy generator engine used to reduce lags.
- Zipalign apps in "/system" and apps in "/data" every 48 hours which result in less RAM usage.
- Sqlite optimizations and faster database access.
- CPU governors tweaks and improvements for better performance and battery life.
- Increased SD Card read-ahead cache to 2048 KB .
- Ad blocking.
- Default.prop tweaks and improvements.
- Cleans log files and tombstones at every boot.
- Many other tweaks for better performance and battery life!
Steps :-
- go to system/etc/init.d/delete all files in it
- Download the zip
- Flash zip via recovery
- Feel the difference (1st boot may take time)
User praise :-
Code:
$lim $hady :- Awesome....!!!!!!!!!
One word Awesome....!!!!
Playing Subway Surfers without a Single Lag... Feels like my phone is running on GB..
Code:
skaloyskie :- Thanks man! I've noticed that my phone suffered less lag even I'm using Opera mini (Multi-tabbed browsing) and downloading movies via torrent. Nice share!
Code:
iossux :- U rock bro really boosted my performance
Some part of my Default .prop
#enable harware egl profile
debug.egl.profiler=1
#16BIT transparency , Smother Scrolling
persist.sys.use_16bpp_alpha=1
#debug.composition.type=gpu
debug.composition.type=c2d
debug.performance.tuning=1
debug.enabletr=true
debug.qctwa.preservebuf=1
dev.pm.dyn_samplingrate=1
video.accelerate.hw=1
ro.vold.umsdirtyratio=20
debug.overlayui.enable=1
debug.egl.hw=1
ro.fb.mode=1
hw3d.force=1
persist.sys.composition.type=c2d
persist.sys.ui.hw=1
ro.sf.compbypass.enable=0
#Enable tile rendering
debug.enabletr=true
persist.sys.composition.type=gpu
#3d performance
persist.android.strictmode=0
ro.min_pointer_dur=1
ro.secure=0
#Media quality
ro.media.enc.jpeg.quality=100
ro.media.dec.jpeg.memcap=8000000
ro.media.enc.hprof.vid.bps=8000000
ro.media.dec.aud.wma.enabled=1
ro.media.dec.vid.wmv.enabled=1
ro.media.cam.preview.fps=0
ro.media.codec_priority_for_thumb=so
#Speed liquid
persist.service.lgospd.enable=0
persist.service.pcsync.enable=0
# For sensor sleep control
ro.ril.sensor.sleep.control=1
#loggers
ro.config.htc.nocheckin=1
ro.config.nocheckin=1
profiler.force_disable_ulog=1
profiler.force_disable_err_rpt=1
#Scrolling
windowsmgr.max_events_per_sec=90
ro.max.fling_velocity=12000
ro.min.fling_velocity=8000
#battery saver
ro.ril.disable.power.collapse=1
pm.sleep_mode=1
usb_wakeup=enable
proximity_incall=enable
power_supply.wakeup=enable
ro.config.hw_power_saving=1
ro.config.hw_fast_dormancy=1
ro.config.hw_quickpoweron=true
persist.sys.use_dithering=0
#improve battery under no signal -- need test
ro.mot.eri.losalert.delay=1000
#net speedtweaks
net.tcp.buffersize.default=4096,87380,256960,4096, 16384,256960
net.tcp.buffersize.wifi=4096,87380,256960,4096,163 84,256960
net.tcp.buffersize.umts=4096,87380,256960,4096,163 84,256960
net.tcp.buffersize.gprs=4096,87380,256960,4096,163 84,256960
net.tcp.buffersize.edge=4096,87380,256960,4096,163 84,256960
net.tcp.buffersize.hspda=4096,87380,256960,4096,16 384,256960
net.tcp.buffersize.hspa=4096,87380,256960,4096,163 84,256960
#streaming faster
media.stagefright.enable-player=true
media.stagefright.enable-meta=true
media.stagefright.enable-scan=true
media.stagefright.enable-http=true
media.stagefright.enable-aac=true
media.stagefright.enable-qcp=true
media.stagefright.enable-record=true
Some part of INIT.D :-
# Disable Logger
busybox rm /dev/log/main
# Busybox Remounting
busybox mount -o remount,noatime,barrier=0,nobh /system
busybox mount -o remount,noatime,barrier=0,nobh /data
busybox mount -o remount,noatime,barrier=0,nobh /cache
echo "Mounted Busybox"
# clearing junk files
busybox find /data/data -type d -iname "*cache*" -exec busybox rm -f {}/* ';' -exec echo "Cleared {}" ';'
rm -f /data/local/*.apk
rm -f /data/local/tmp/*.apk
rm -f /data/*.log
rm -f /data/log/*.log
rm -f /cache/*.*
rm -f /cache/recovery/*.*
rm -f /data/system/dropbox/*.txt
rm -f /data/backup/pending/*.tmp
rm -f /data/tombstones/*.*
echo "Junk cleared"
# Defrag Database Files
for i in \
`find /data -iname "*.db"`
do \
sqlite3 $i 'VACUUM;';
# Move Dalvik-Cache To Cache Partition
CACHESIZE=$(df -k /cache | tail -n1 | tr -s ' ' | cut -d ' ' -f2)
if [ $CACHESIZE -gt 4000 ]
then
echo "Large cache detected, moving dalvik-cache to /cache"
if [ ! -d /cache/dalvik-cache ]
then
busybox rm -rf /cache/dalvik-cache /data/dalvik-cache
mkdir /cache/dalvik-cache /data/dalvik-cache
fi
busybox chown 1000:1000 /cache/dalvik-cache
busybox chmod 0771 /cache/dalvik-cache
busybox mount -o bind /cache/dalvik-cache /data/dalvik-cache
busybox chown 1000:1000 /data/dalvik-cache
busybox chmod 0771 /data/dalvik-cache
else
echo "Small cache detected, dalvik-cache will remain on /data"
fi
echo "Moved Dalvik-Cache To Cache Partition"
# Mod: Battery
setprop wifi.supplicant_scan_interval=180
setprop pm.sleep_mode=1
setprop ro.ril.disable.power.collapse=1
# Mod: Performance
setprop ro.kernel.android.checkjni=0
setprop persist.sys.purgeable_assets=1
setprop debug.sf.hw=1
setprop ro.telephony.call_ring.delay=0
setprop ro.foreground_app_mem=1280
setprop ro.visible_app_mem=2560
setprop ro.perceptible_app_mem=3840
setprop ro.heavy_weight_app_mem=6400
setprop ro.secondary_server_mem=7680
setprop ro.backup_app_mem=8960
setprop ro.home_app_mem=2048
setprop ro.hidden_app_mem=12800
setprop ro.content_provider_mem=15360
setprop ro.empty_app_mem=20480
setprop ro.foreground_app_adj=0
setprop ro.visible_app_adj=1
setprop ro.perceptible_app_adj=2
setprop ro.heavy_weight_app_adj=4
setprop ro.secondary_server_adj=5
setprop ro.backup_app_adj=6
setprop ro.home_app_adj=1
setprop ro.hidden_app_min_adj=7
setprop ro.empty_app_adj=15
# Mod: Graphics
setprop debug.performance.tuning=1
setprop video.accelerate.hw=1
setprop ro.media.dec.jpeg.memcap=8000000
setprop ro.media.enc.hprof.vid.bps=8000000
setprop persist.sys.use_dithering 1
# Touch Screen Sensitivity
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;
# Renice Apps
renice -20 `pidof com.android.phone`
renice -19 `pidof com.android.inputmethod.latin`
renice -19 `pidof com.swype.android.inputmethod`
renice -17 `pidof com.android.systemui`
renice -9 `pidof com.android.settings`
renice -9 `pidof com.android.vending`
renice -6 `pidof com.sec.android.app.camera`
renice -6 `pidof com.sec.android.app.fm`
renice -6 `pidof com.google.android.apps.maps`
renice -4 `pidof com.google.android.apps.googlevoice`
renice -3 `pidof android.process.media`
# SqLite Optimize
for i in \
`busybox find /data -iname "*.db"`;
do \
/system/xbin/sqlite3 $i 'VACUUM;';
/system/xbin/sqlite3 $i 'REINDEX;';
done;
if [ -d "/dbdata" ]; then
for i in \
`busybox find /dbdata -iname "*.db"`;
do \
/system/xbin/sqlite3 $i 'VACUUM;';
/system/xbin/sqlite3 $i 'REINDEX;';
done;
fi;
if [ -d "/datadata" ]; then
for i in \
`busybox find /datadata -iname "*.db"`;
do \
/system/xbin/sqlite3 $i 'VACUUM;';
/system/xbin/sqlite3 $i 'REINDEX;';
done;
fi;
for i in \
`busybox find /sdcard -iname "*.db"`;
do \
/system/xbin/sqlite3 $i 'VACUUM;';
/system/xbin/sqlite3 $i 'REINDEX;';
done;
echo "SqLite Database Optimized"
echo "System Optimized And Boosted at $( date +"%m-%d-%Y %H:%M:%S" )"
function mountrw {
mount|grep "/system "|grep rw >/dev/null
[ $? -eq 1 ] && mount -o remount,rw $(mount|grep "/system "|awk '{ print $1 }') /system
}
function mountro {
mount|grep "/system "|grep ro >/dev/null
[ $? -eq 1 ] && mount -o remount,ro $(mount|grep "/system "|awk '{ print $1 }') /system
}
echo " Starting package optimization"
echo "Starting ZipAlign $( date +"%m-%d-%Y %H:%M:%S" )"
zipalign -c 4 $apk;
ZIPCHECK=$?;
if [ $ZIPCHECK -eq 1 ]; then
mountrw;
echo ZipAligning $(basename $apk)
zipalign -f 4 $apk /cache/$(basename $apk);
if [ -e /cache/$(basename $apk) ]; then
cp -f -p /cache/$(basename $apk) $apk
rm /cache/$(basename $apk);
else
echo ZipAligning $(basename $apk) Failed DC;
fi;
else
echo Velocity ZipAlign already completed on $apk
fi;
done;
for apk in /data/app/*.apk ; do
zipalign -c 4 $apk;
ZIPCHECK=$?;
if [ $ZIPCHECK -eq 1 ]; then
echo ZipAligning $(basename $apk)
zipalign -f 4 $apk /cache/$(basename $apk);
if [ -e /cache/$(basename $apk) ]; then
cp -f -p /cache/$(basename $apk) $apk
rm /cache/$(basename $apk);
else
echo ZipAligning $(basename $apk) Failed DC
fi;
else
echo Velocity ZipAlign already completed on $apk
fi;
done;
mountro;
echo "ZipAlign finished at $( date +"%m-%d-%Y %H:%M:%S" )"
Tested on Xperia S thnxx to EXBLAZE
credits
persanno
exblaze
kuro
Works with trinity kernel and ROM,now testing
Sent from my LT26ii using XDA Premium 4 mobile app
red-Tequila said:
Works with trinity kernel and ROM,now testing
Sent from my LT26ii using XDA Premium 4 mobile app
Click to expand...
Click to collapse
Trinity ROM and kernel already has many tweaks applied in it.. You don't need to try any.. If u have a Stock ROM without any mods, but with some custom kernel, then try this..
sudhindrakv said:
Trinity ROM and kernel already has many tweaks applied in it.. You don't need to try any.. If u have a Stock ROM without any mods, but with some custom kernel, they try this..
Click to expand...
Click to collapse
Trinity Rom has tweaks but they are not enabled by default as in init.d does not run at boot... It never did in his previous roms either, and I don't think he is to bothered to fix it!
Sent from my LT26i using xda premium
Damoedge said:
Trinity Rom has tweaks but they are not enabled by default as in init.d does not run at boot... It never did in his previous roms either, and I don't think he is to bothered to fix it!
Sent from my LT26i using xda premium
Click to expand...
Click to collapse
Yes. Its your choice in Aroma to select which kind of tweaks you need.. Anyway try this.. Do have a backup.. Lets not spam this thread.. There's another thread to discuss about Trinity ROM..
Damoedge said:
Trinity Rom has tweaks but they are not enabled by default as in init.d does not run at boot... It never did in his previous roms either, and I don't think he is to bothered to fix it!
Sent from my LT26i using xda premium
Click to expand...
Click to collapse
Hi, Just like.I.said, Ive added Init.d enabler on. 3.6 via.Settings.apk
Even you install this tweak it will never work, unless you enabled some required perm. For the init.d files
Sent from my LT26ii using xda app-developers app
TrinityHaxxorX said:
Hi, Just like.I.said, Ive added Init.d enabler on. 3.6 via.Settings.apk
Even you install this tweak it will never work, unless you enabled some required perm. For the init.d files
Sent from my LT26ii using xda app-developers app
Click to expand...
Click to collapse
You are referring on your ROM or you genaralise?
If you are using stock ROM, rooted and deodexed I don't see why it shouldn't work (at least some part of it)
Sent from my LT26i using Tapatalk 4
TrinityHaxxorX said:
Even you install this tweak it will never work, unless you enabled some required perm. For the init.d files
Sent from my LT26ii using xda app-developers app
Click to expand...
Click to collapse
So you are saying that this will not work??
Sent from my LT26i using xda premium
Man I doubt about it cause I installed and notice more fluidity,however about bb..
Sent from my LT26ii using XDA Premium 4 mobile app
I still haven't tried but guys, when you try it, test firmly.
Every device will fly after restart - when you restart it - your RAM gets cleared and device will work softer and faster.
Try to see what's happening after one or two hours - don't fall on placebo effect afrer restart.
And please, don't get me wrong, I'm not saying it doesn't work, I haven't tried it yet.
I'm just saying how to test
Sent from my LT26i using Tapatalk 4
Tested. Well done. I report two bugs, some apps does not start automatically after a reboot,like Antitirus,etc. and photos won't open from Album Widget, only from the album itself.Anyway, good job, waiting for a stable version,until then, I'm back to my backup.
sure
Mr.AnakinSkywalker said:
Tested. Well done. I report two bugs, some apps does not start automatically after a reboot,like Antitirus,etc. and photos won't open from Album Widget, only from the album itself.Anyway, good job, waiting for a stable version,until then, I'm back to my backup.
Click to expand...
Click to collapse
as i dont own this device i cannot test it many times on friends mobile
need some tester/devs from this thread
BOSS said:
as i dont own this device i cannot test it many times on friends mobile
need some tester/devs from this thread
Click to expand...
Click to collapse
I understand, at least for now we know two bugs on SONY XPERIA S
Does it work on CM ? haahah newbie question but does it?
uDroid said:
Does it work on CM ? haahah newbie question but does it?
Click to expand...
Click to collapse
I dont think so
Pls read the op
Sent from my LT26i using Tapatalk 4
Rangeeshnathan said:
I dont think so
Pls read the op
Sent from my LT26i using Tapatalk 4
Click to expand...
Click to collapse
im sorry but i tested it and it works i guess.
i feel the difference.
whaiting for XPERIA Z version
Save much reading and go to page 61. Answers to bad battery on the HTC 10 are worked out there. It's simplifies everything. Many posts here are works in progress kind of back and forth.
Guides I used for amplify are at the bottom of page 13.
(Remember to thank me in the op if anything here helped.)
After numerous hours of research and testing . Just wanted to reveal what I found. This is made for the OP-3 which is also a snapdragon 820 chipset device.
Ive been using on my Verizon HTC 10 with zero issues so far/ Lee-droid oreo rom/Elemental X -3.02 kernel. Much copy and pasting going on, just wanted to share my find.I take no credit for any of this : other than being willing to test on my device. After flashing the final version of (AKT.V1.6/FinalZIP )through twrp/ located on next page I ticked for the Op3 OR SNAPDRAGON 820 DEVICE from a terminul emilator, then I choose "Project Zhana battery" . I used rom toolbox pro's terminal emulator. Choose whatever profile you desire but the one I picked works fine/zero lag. Our other options (as of now) are soilwork scripts made for the HTC 10 or the helix engine now that pnpmgr has been disabled.
. First link is a huge thread on profiles from AKT. Go find which ever works best for your situation.
( I'm not telling you to flash anything. I'm showing you possible routes that have been tested by me. If you do not like results simply Ruu back to stock or dirty flash rom being used to get rid of it all.)
I'm about to tell you how to get buttery smooth, lag-free performance with insanely good battery life, using an old school governor featured in practically every kernel... This tweak is applicable to every phone with any ROM or kernel--stock or custom--that provides the Interactive Governor.
Yeah, yeah... everyone promises good battery with great performance, but who actually delivers? Maybe it isn't as smooth as you want, or maybe it requires something your kernel or ROM don't support. Or maybe the battery life promises just aren't what you expected. There's always some awful compromise. Not here!
This isn't a guide to get 36 hour battery life... provided you never use your phone. That's deep sleep optimization, which is lovely and all, but what good is the phone if you can never use it?! And with the new Marshmallow Doze feature, this strategy is becoming a thing of the past. What I'm talking about is 7-14 hour screen on, actual hands-on usage times! Without compromising anything, you can get 7-8 hour screen on usage with regular, no-compromise usage habits: daytime visible screen brightness, both radios on, sync on, network location on, all the regular usage features, the whole kit and kaboodle... all smooth as a baby's butt and snappy as a Slim Jim! (Up to 14+ hours if you can stand minimum brightness and WiFi-only with a custom ROM and other stuff turned off! And this is with stock voltages and full frequency range--you'll likely get even more if you choose to optimize those as well!)
However, it should be noted that this does not apply to gaming, heavy camera use, etc. Anything that is an automatic battery killer in and of itself. There's nothing that can be done about anything that forces the phone to utilize its maximum resources all the time. But you should know that by now. Further, this guide is about optimizing the CPU as much as possible. It does not cover things like eliminating wakelocks so your phone sleeps well, removing unnecessary and battery draining stock apps, keeping your screen brightness down*, and all that stuff that's been covered in other posts ad infinitum. Those optimizations are up to you.
If you really want to know the principles of this tweaks, please go to this thread since there everything is really well explained and I know you guys just want to apply the tweak and forget about everything behind it, so just keep scrolling!
Voltages and Frequencies:
So recently I have been investigating about the Voltages of our device (since that is a really useful information to know) before that we only have the Nominal frequencies (If you don't know what I am talking about go ahead and read @soniCron thread because I won't explain it) we could develop some tweaks with that, but we were pretty much making blind shots, guessing and hoping that all will be right. Well, now that we have all this information we can optimize our tweaks even more so expect new updates and rework for the current tweaks and of course new ones.
What About Touchboost?
Since I've noticed that a lot of people was asking about Touchboost, I decided to add this little explanation from @soniCron
" Touchboost is a nifty feature in a lot of kernels (including stock on Nexus 5X) that jumps up the frequency so that you experience minimal lag. However, with all the above settings, touchboost is usually detrimental to the efficiency of the device!
We generally want to keep the CPU on the lowest possible frequency as much as possible, and touchboost interferes with that. Further, because we've set up the maximal and minimal efficient clock rates, as well as burst processing from the 2nd CPU core, we don't need touchboost!
If your kernel allows you to shut it off, try to do so and see if the responsiveness of your device is acceptable. On the OP3 (and pretty much all the devices), touchboost adds no perceptual performance gain and only hurts efficiency and battery life. If your kernel doesn't allow you to turn off touchboost, try another one.
Your battery life will thank you! "
With all that been said, you shouldn't confuse Touchboost with CPU Boost and more specifically Input boost. Both are used to boost the clock speed of our device whenever we touch the touchscreen, so we don't suffer any lags.
The difference is that Input boost can be configured and Touchboost cannot, making it a really inefficient.
MY DEVICE LAGS!!! WHY?!?!
First of all, it's a "normal" thing, as I have stated before, all these tweaks have been done for fit my usage or certain usage which is most likely not the same as yours. Because this, when the are put on a certain scenario the might stutter or lag just a bit (If you are experimenting huge lags, you have done something wrong)
And yes, this can be fixed. We have a couple of ways of fixing it:
First of all, Check If the tweaks have been applied correctly
Our first one is modifying the Input boost (not touchboost) most of our tweaks have an already established Input boost clock speeds and time, you can incise does too a bit. For example, we have 960(Mhz) for all the CPU at 40ms you could bump it up to ~1036(Mhz) and 42ms, don't modify too much this values since it will potentially increase your battery drain.
Our second tool for fixing lags is min_sample_time , my recommendation is to increase the value by 5000 each time till you no longer suffer any stutter or lag.
Try another tweak, for example;
If you are using Project X.A.N.A Battery, try using Balanced option...
Still having lag?
Get rid of unnecessary (background-)apps
Try a different IO-Scheduler
Try another profile
My phone still uses too much battery
First of all, Check If the tweaks have been applied correctly
Make sure that you have disabled touchboost.
Set brightness to a lower level.
Use a dark / black theme
Don't play games all day
Try other tweak, for example;
If you are using Project Zhana Balanced, try using Battery option...
How to install:
A flashable zip to be flashed via recovery, which installs scripts of the latest iterations of most profiles (some legacy profiles had to be eliminated for more convenience) and a master script that takes control of all the installed scripts and applies your desired profile at will as soon as you recall it via Terminal Emulator app and get guided by the on-screen instructions.
So to wrap it up:
1- Download the latest AKT_Profile_vX.x.zip file
2- Reboot into TWRP recovery and flash the .zip file
3- After you boot up the phone, leave it to settle for a minute
4- Open up your favorite Terminal Emulator app
5- Grant it superuser permissions by typing in "su" without the quotes
6- After superuser permissions are granted, type in "AKT" without the quotes (yes capitalized)
Download link for AKT
https://forum.xda-developers.com/showpost.php?p=70352820&postcount=2146
Xposed with magic information and downloads.
This is where the rubber meets the road. Amplify and greenify for Oreo!!!
https://forum.xda-developers.com/xposed/unofficial-systemless-xposed-t3388268
(Save yourself some time and jump to page 61 Finally found the answers there. Long live the HTC 10. My device is finally a beast.)
Sounds interesting - might give it a try
It's running like a totally different phone. I'm amazed almost 2 hours of screen on time and still at 70% battery. And I'm casting to my living room TV as well. Still zero lag. So phone is running tasks as well. And I'm back and forth on here. Works nicely.
mattie_49 said:
It's running like a totally different phone. I'm amazed almost 2 hours of screen on time and still at 70% battery. And I'm casting to my living room TV as well. Still zero lag. So phone is running tasks as well. And I'm back and forth on here. Works nicely.
Click to expand...
Click to collapse
Are you using stock elemental x settings or other ?
Code:
#!/system/bin/sh
#Author: Asiier
#Settings By: Asiier
#Device: One Plus 3
#Codename: Project Zhana (BT)
#Build Status: Stable
#Version: 4.2
#Last Updated: 22/01/2017
#Notes: Please give credit when using this in your work!
#TWEAKS_BEGIN
echo ""
echo --------------------------------------------------------
echo Applying 'Project Zhana (Battery variant)' v4.3
echo Advanced Kernel Settings
echo --------------------------------------------------------
sleep 0.5
echo Author: Asiier
echo Settings By: Asiier
echo "Device: One Plus 3 & SD820 Devices"
echo Codename: 'Project Zhana (BT)'
echo Build Status: Stable
echo Last Updated: 19/09/2017
echo For more information go to the XDA theard
echo ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
sleep 0.3
echo Checking Android version...
if grep -q 'ro.build.version.sdk=25' /system/build.prop; then
echo Android Nougat 7.1.X detected!
sleep 0.3
echo N detected... Applying proper settings
fi
if grep -q 'ro.build.version.sdk=24' /system/build.prop; then
echo Android Nougat 7.0.X detected!
sleep 0.3
echo N detected... Applying proper settings
fi
if grep -q 'ro.build.version.sdk=23' /system/build.prop; then
echo Android Marshmallow 6.0.1 detected!
sleep 0.3
echo MM detected... Applying proper settings
fi
echo ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
sleep 0.3
#Apply settings to LITTLE cluster
echo Applying settings to LITTLE Cluster...
sleep 0.5
#Temporarily change permissions to governor files for the LITTLE cluster to enable Interactive governor
chmod 644 /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor
echo interactive > /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor
chmod 444 /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor
#Grab Maximum Achievable Frequency for the LITTLE Cluster
maxfreq=$(cat "/sys/devices/system/cpu/cpu0/cpufreq/scaling_max_freq")
if test "$maxfreq" -eq 1593600; then
#Temporarily change permissions to governor files for the Big cluster to set the maximum frequency to 1593MHz
echo No LITTLE Cluster Overclocking detected.
echo Applying appropriate values.
chmod 644 /sys/devices/system/cpu/cpu0/cpufreq/scaling_max_freq
echo 1593600 > /sys/devices/system/cpu/cpu0/cpufreq/scaling_max_freq #Core 0 Maximum Frequency = 1593MHz
chmod 444 /sys/devices/system/cpu/cpu0/cpufreq/scaling_max_freq
chmod 644 /sys/devices/system/cpu/cpu0/cpufreq/interactive/target_loads
echo 70 480000:65 556800:75 729600:82 960000:86 1036800:2 1228800:99 > /sys/devices/system/cpu/cpu0/cpufreq/interactive/target_loads
chmod 444 /sys/devices/system/cpu/cpu0/cpufreq/interactive/target_loads
fi
if test "$maxfreq" -eq 1728000; then
#Temporarily change permissions to governor files for the Little cluster to set the maximum frequency to 1728MHz
echo LITTLE Cluster Overclocking detected.
echo Applying appropriate values.
chmod 644 /sys/devices/system/cpu/cpu0/cpufreq/scaling_max_freq
echo 1728000 > /sys/devices/system/cpu/cpu0/cpufreq/scaling_max_freq #Core 0 Maximum Frequency = 1728MHz
chmod 444 /sys/devices/system/cpu/cpu0/cpufreq/scaling_max_freq
chmod 644 /sys/devices/system/cpu/cpu0/cpufreq/interactive/target_loads
echo 70 480000:65 556800:75 729600:82 960000:86 1036800:2 1228800:99 > /sys/devices/system/cpu/cpu0/cpufreq/interactive/target_loads
chmod 444 /sys/devices/system/cpu/cpu0/cpufreq/interactive/target_loads
maxfreq=$(cat "/sys/devices/system/cpu/cpu0/cpufreq/scaling_max_freq")
fi
if test "$maxfreq" -lt 1593600; then
#Temporarily change permissions to governor files for the Big cluster to set the maximum frequency to 1593MHz
echo LITTLE Cluster Underclocking detected!!
sleep 1
echo We recommend not to UnderClock the CPU as the tweaks already will take care of that If needed
echo The tweaks will continue getting applied but we recommend setting the CPU to Max frequency!
sleep 4
#chmod 644 /sys/devices/system/cpu/cpu0/cpufreq/scaling_max_freq
#echo 1593600 > /sys/devices/system/cpu/cpu0/cpufreq/scaling_max_freq #Core 0 Maximum Frequency = 1593MHz
#chmod 444 /sys/devices/system/cpu/cpu0/cpufreq/scaling_max_freq
chmod 644 /sys/devices/system/cpu/cpu0/cpufreq/interactive/target_loads
echo 70 480000:65 556800:75 729600:82 960000:86 1036800:2 1228800:99 > /sys/devices/system/cpu/cpu0/cpufreq/interactive/target_loads
chmod 444 /sys/devices/system/cpu/cpu0/cpufreq/interactive/target_loads
elif test $maxfreq -gt 1728000; then
#Temporarily change permissions to governor files for the Little cluster to set the maximum frequency to 1728MHz
echo LITTLE Cluster Overclocking detected.
sleep 1
echo This OverClock is higher than normal and only possible on Xceed Kernel
echo The tweak will continue getting applyed
echo " Althought it might no reach the maximum frequency you have setted as it haven't been made to work with frecuencies higher than 1728 Mhz "
#chmod 644 /sys/devices/system/cpu/cpu0/cpufreq/scaling_max_freq
#echo 1728000 > /sys/devices/system/cpu/cpu0/cpufreq/scaling_max_freq #Core 0 Maximum Frequency = 1728MHz
#chmod 444 /sys/devices/system/cpu/cpu0/cpufreq/scaling_max_freq
chmod 644 /sys/devices/system/cpu/cpu0/cpufreq/interactive/target_loads
echo 70 480000:65 556800:75 729600:82 960000:86 1036800:2 1228800:99 > /sys/devices/system/cpu/cpu0/cpufreq/interactive/target_loads
chmod 444 /sys/devices/system/cpu/cpu0/cpufreq/interactive/target_loads
fi
chmod 644 /sys/devices/system/cpu/cpu0/cpufreq/interactive/*
echo 220000 > /sys/devices/system/cpu/cpu0/cpufreq/interactive/timer_slack
echo 307200 > /sys/devices/system/cpu/cpu0/cpufreq/interactive/hispeed_freq
echo 100000 > /sys/devices/system/cpu/cpu0/cpufreq/interactive/timer_rate
echo 0 729600:76000 960000:99000 1228800:150000 1478400:170000 > /sys/devices/system/cpu/cpu0/cpufreq/interactive/above_hispeed_delay
echo 155 > /sys/devices/system/cpu/cpu0/cpufreq/interactive/go_hispeed_load
echo 22000 > /sys/devices/system/cpu/cpu0/cpufreq/interactive/min_sample_time
echo 0 > /sys/devices/system/cpu/cpu0/cpufreq/interactive/max_freq_hysteresis
echo 0 > /sys/devices/system/cpu/cpu0/cpufreq/interactive/ignore_hispeed_on_notif
echo 0 > /sys/devices/system/cpu/cpu0/cpufreq/interactive/boost
echo 0 > /sys/devices/system/cpu/cpu0/cpufreq/interactive/fast_ramp_down
echo 0 > /sys/devices/system/cpu/cpu0/cpufreq/interactive/align_windows
echo 1 > /sys/devices/system/cpu/cpu0/cpufreq/interactive/use_migration_notif
echo 0 > /sys/devices/system/cpu/cpu0/cpufreq/interactive/use_sched_load
echo 0 > /sys/devices/system/cpu/cpu0/cpufreq/interactive/boostpulse_duration
echo 0 > /sys/devices/system/cpu/cpu0/cpufreq/interactive/io_is_busy
if [ -e "/sys/devices/system/cpu/cpu0/cpufreq/interactive/enable_prediction" ]; then
chmod 644 /sys/devices/system/cpu/cpu0/cpufreq/interactive/enable_prediction
echo 0 > /sys/devices/system/cpu/cpu0/cpufreq/interactive/enable_prediction
fi
sleep 0.5
#Apply settings to Big cluster
echo Applying settings to BIG Cluster
sleep 0.2
#Temporarily change permissions to governor files for the LITTLE cluster to enable Interactive governor
chmod 644 /sys/devices/system/cpu/cpu2/cpufreq/scaling_governor
echo interactive > /sys/devices/system/cpu/cpu2/cpufreq/scaling_governor
chmod 444 /sys/devices/system/cpu/cpu2/cpufreq/scaling_governor
#Grab Maximum Achievable Frequency for the Big Cluster
maxfreq=$(cat "/sys/devices/system/cpu/cpu2/cpufreq/cpuinfo_max_freq")
if test $maxfreq -eq 2150400; then
#Temporarily change permissions to governor files for the Big cluster to set the maximum frequency to 2150MHz
echo No BIG Cluster Overclocking detected.
echo Applying appropriate values.
chmod 644 /sys/devices/system/cpu/cpu2/cpufreq/scaling_max_freq
echo 2150400 > /sys/devices/system/cpu/cpu2/cpufreq/scaling_max_freq #Core 2 Maximum Frequency = 2150MHz
chmod 444 /sys/devices/system/cpu/cpu2/cpufreq/scaling_max_freq
chmod 644 /sys/devices/system/cpu/cpu2/cpufreq/interactive/target_loads
echo 65 940800:80 1036800:2 1401600:95 1824000:98 > /sys/devices/system/cpu/cpu2/cpufreq/interactive/target_loads
chmod 444 /sys/devices/system/cpu/cpu2/cpufreq/interactive/target_loads
#Set overclock max frequency compatible target_loads
elif test $maxfreq -eq 2265600; then
#Temporarily change permissions to governor files for the Big cluster to set the maximum frequency to 2265MHz
echo BIG Cluster Overclocking detected.
echo Applying appropriate values.
chmod 644 /sys/devices/system/cpu/cpu2/cpufreq/scaling_max_freq
echo 2265600 > /sys/devices/system/cpu/cpu2/cpufreq/scaling_max_freq #Core 2 Maximum Frequency = 2265MHz
chmod 444 /sys/devices/system/cpu/cpu2/cpufreq/scaling_max_freq
chmod 644 /sys/devices/system/cpu/cpu2/cpufreq/interactive/target_loads
echo 65 940800:80 1036800:2 1401600:95 1824000:98 > /sys/devices/system/cpu/cpu2/cpufreq/interactive/target_loads
chmod 444 /sys/devices/system/cpu/cpu2/cpufreq/interactive/target_loads
fi
if test $maxfreq -lt 2150400; then
#Temporarily change permissions to governor files for the Big cluster to set the maximum frequency to 1593MHz
echo BIG Cluster Underclocking detected!!
sleep 1
echo We recommend not to UnderClock the CPU as the tweaks already will take care of that If needed
echo The tweaks will continue getting applied but we recommend setting the CPU to Max frequency!
sleep 4
#chmod 644 /sys/devices/system/cpu/cpu2/cpufreq/scaling_max_freq
#echo 1593600 > /sys/devices/system/cpu/cpu2/cpufreq/scaling_max_freq #Core 0 Maximum Frequency = 1593MHz
#chmod 444 /sys/devices/system/cpu/cpu2/cpufreq/scaling_max_freq
chmod 644 /sys/devices/system/cpu/cpu2/cpufreq/interactive/target_loads
echo 65 940800:80 1036800:2 1401600:95 1824000:98 > /sys/devices/system/cpu/cpu2/cpufreq/interactive/target_loads
chmod 444 /sys/devices/system/cpu/cpu2/cpufreq/interactive/target_loads
elif test $maxfreq -gt 2265600; then
#Temporarily change permissions to governor files for the Little cluster to set the maximum frequency to 1728MHz
echo BIG Cluster Overclocking detected.
sleep 1
echo This OverClock is higher than normal and only possible on Xceed Kernel
echo The tweak will continue getting applyed
echo " Althought it might no reach the maximum frequency you have setted as it haven't been made to work with frecuencies higher than 2265600 Mhz "
sleep 4
#chmod 644 /sys/devices/system/cpu/cpu2/cpufreq/scaling_max_freq
#echo 1728000 > /sys/devices/system/cpu/cpu2/cpufreq/scaling_max_freq #Core 0 Maximum Frequency = 1728MHz
#chmod 444 /sys/devices/system/cpu/cpu2/cpufreq/scaling_max_freq
chmod 644 /sys/devices/system/cpu/cpu2/cpufreq/interactive/target_loads
echo 65 940800:80 1036800:99 1401600:95 1824000:98 > /sys/devices/system/cpu/cpu2/cpufreq/interactive/target_loads
chmod 444 /sys/devices/system/cpu/cpu2/cpufreq/interactive/target_loads
fi
sleep 0.5
#Tweak Interactive Governor
chmod 644 /sys/devices/system/cpu/cpu2/cpufreq/*
echo 140000 > /sys/devices/system/cpu/cpu2/cpufreq/interactive/timer_slack
echo 1401600 > /sys/devices/system/cpu/cpu2/cpufreq/interactive/hispeed_freq
echo 65000 > /sys/devices/system/cpu/cpu2/cpufreq/interactive/timer_rate
echo 32000 940800:85000 1248000:96000 1401600:88000 1632000:80000 > /sys/devices/system/cpu/cpu2/cpufreq/interactive/above_hispeed_delay
echo 99 > /sys/devices/system/cpu/cpu2/cpufreq/interactive/go_hispeed_load
echo 11000 > /sys/devices/system/cpu/cpu2/cpufreq/interactive/min_sample_time
echo 0 > /sys/devices/system/cpu/cpu2/cpufreq/interactive/max_freq_hysteresis
echo 1 > /sys/devices/system/cpu/cpu2/cpufreq/interactive/ignore_hispeed_on_notif
echo 0 > /sys/devices/system/cpu/cpu2/cpufreq/interactive/boost
echo 1 > /sys/devices/system/cpu/cpu2/cpufreq/interactive/fast_ramp_down
echo 0 > /sys/devices/system/cpu/cpu2/cpufreq/interactive/align_windows
echo 1 > /sys/devices/system/cpu/cpu2/cpufreq/interactive/use_migration_notif
echo 0 > /sys/devices/system/cpu/cpu2/cpufreq/interactive/use_sched_load
echo 0 > /sys/devices/system/cpu/cpu2/cpufreq/interactive/boostpulse_duration
echo 0 > /sys/devices/system/cpu/cpu2/cpufreq/interactive/io_is_busy
if [ -e "/sys/devices/system/cpu/cpu2/cpufreq/interactive/enable_prediction" ]; then
chmod 644 /sys/devices/system/cpu/cpu2/cpufreq/interactive/enable_prediction
echo 0 > /sys/devices/system/cpu/cpu2/cpufreq/interactive/enable_prediction
fi
echo "=========================================="
echo Checking whether you are using a Sultanxda based ROM or not
echo "=========================================="
#Checking whether you are using a Sultanxda based ROM or not
echo Checking ROM...
sleep 0.2
echo Applying appropriate values.
if [ -e "/sys/kernel/cpu_input_boost/enabled" ]; then
echo Enabling Input Boost for the LITTLE cluster @556 MHz and for the BIG Cluster @0Mhz and Custom thermal driver of Sultanxda
chmod 644 /sys/kernel/cpu_input_boost/*
echo 1 > /sys/kernel/cpu_input_boost/enabled
echo 66 > /sys/kernel/cpu_input_boost/ib_duration_ms
echo 556800 0 > /sys/kernel/cpu_input_boost/ib_freqs
chmod 444 /sys/kernel/cpu_input_boost/*
chmod 644 /sys/kernel/msm_thermal/enabled
echo 0 > /sys/kernel/msm_thermal/enabled
chmod 444 /sys/kernel/msm_thermal/enabled
else
#Checking whether you are using a Lineage based ROM or not
echo Checking ROM...
sleep 0.2
if grep -q 'ro.build.flavor=lineage_oneplus3-userdebug' /system/build.prop; then
#Enable Input Boost for LITTLE cluster @556MHz and for BIG cluster @729MHz for 66ms
echo Lineage Based ROM detected
echo Applying appropriate values.
echo Enabling Input Boost at 556 MHz for the LITTLE cluster and at 0 MHz for the BIG Cluster
if [ -e "/sys/module/cpu_boost/parameters/input_boost_freq" ]; then
chmod 644 /sys/module/cpu_boost/parameters/input_boost_freq
echo 0:556800 1:0 2:0 3:0 > /sys/module/cpu_boost/parameters/input_boost_freq
chmod 644 /sys/module/cpu_boost/parameters/input_boost_ms
echo 55 > /sys/module/cpu_boost/parameters/input_boost_ms
else
echo "*Input Boost is not avalible for your Kernel*"
fi
if [ -e "/sys/module/cpu_boost/parameters/boost_ms" ]; then
chmod 644 /sys/module/cpu_boost/parameters/boost_ms
echo 0 > /sys/module/cpu_boost/parameters/boost_ms
else
echo "*Cpu_Boost is not avalible for your Kernel*"
fi
else
#Enable Input Boost for LITTLE cluster @729MHz and for BIG cluster @729Hz for 100ms
echo Non-Lineage ROM detected
echo Applying appropriate values.
echo Enabling Input Boost at 729 MHz for the LITTLE cluster and at 0 MHz for the BIG Cluster
if [ -e "/sys/module/cpu_boost/parameters/input_boost_freq" ]; then
chmod 644 /sys/module/cpu_boost/parameters/input_boost_freq
echo 0:729600 1:0 2:0 3:0 > /sys/module/cpu_boost/parameters/input_boost_freq
chmod 644 /sys/module/cpu_boost/parameters/input_boost_ms
echo 77 > /sys/module/cpu_boost/parameters/input_boost_ms
else
echo "*Input Boost is not avalible for your Kernel*"
fi
if [ -e "/sys/module/cpu_boost/parameters/boost_ms" ]; then
chmod 644 /sys/module/cpu_boost/parameters/boost_ms
echo 0 > /sys/module/cpu_boost/parameters/boost_ms
else
echo "*Cpu_Boost is not avalible for your Kernel*"
fi
fi
fi
sleep 0.3
echo "=========================================="
#Disable TouchBoost
echo Disabling TouchBoost
if [ -e "/sys/module/msm_performance/parameters/touchboost" ]; then
chmod 644 /sys/module/msm_performance/parameters/touchboost
echo 0 > /sys/module/msm_performance/parameters/touchboost
else
echo "*Not supported for your current Kernel*"
fi
#Disable BCL
echo Disabling BCL and Removing Perfd
if [ -e "/sys/devices/soc/soc:qcom,bcl/mode" ]; then
echo -n disable > /sys/devices/soc/soc:qcom,bcl/mode
fi
#Enable Core Control and Disable MSM Thermal Throttling allowing for longer sustained performance
echo Disabling Aggressive CPU Thermal Throttling
if [ -e "/sys/module/msm_thermal/core_control/enabled" ]; then
echo 1 > /sys/module/msm_thermal/core_control/enabled
fi
if [ -e "/sys/module/msm_thermal/parameters/enabled" ]; then
echo N > /sys/module/msm_thermal/parameters/enabled
fi
#Tweak HMP Scheduler to feed the Big cluster more tasks
sleep 0.3
#echo Tweaking HMP Scheduler for correcting BIG Cluster utilization
echo 2 > /proc/sys/kernel/sched_window_stats_policy
echo 85 > /proc/sys/kernel/sched_upmigrate
echo 62 > /proc/sys/kernel/sched_downmigrate
echo 5 > /proc/sys/kernel/sched_spill_nr_run
echo 100 > /proc/sys/kernel/sched_spill_load
echo 30 > /proc/sys/kernel/sched_init_task_load
if [ -e "/proc/sys/kernel/sched_heavy_task" ]; then
echo 65 > /proc/sys/kernel/sched_heavy_task
fi
if [ -e "/proc/sys/kernel/sched_enable_power_aware" ]; then
echo 1 > /proc/sys/kernel/sched_enable_power_aware
fi
echo 10 > /proc/sys/kernel/sched_upmigrate_min_nice
echo 4 > /proc/sys/kernel/sched_ravg_hist_size
if [ -e "/proc/sys/kernel/sched_small_wakee_task_load" ]; then
echo 7 > /proc/sys/kernel/sched_small_wakee_task_load
fi
if [ -e "/proc/sys/kernel/sched_wakeup_load_threshold" ]; then
echo 110 > /proc/sys/kernel/sched_wakeup_load_threshold
fi
if [ -e "/proc/sys/kernel/sched_small_task" ]; then
echo 7 > /proc/sys/kernel/sched_small_task
fi
if [ -e "/proc/sys/kernel/sched_big_waker_task_load" ]; then
echo 35 > /proc/sys/kernel/sched_big_waker_task_load
fi
echo 950000 > /proc/sys/kernel/sched_rt_runtime_us
echo 1000000 > /proc/sys/kernel/sched_rt_period_us
if [ -e "/proc/sys/kernel/sched_migration_fixup" ]; then
echo 1 > /proc/sys/kernel/sched_migration_fixup
fi
if [ -e "/proc/sys/kernel/sched_freq_dec_notify" ]; then
echo 410000 > /proc/sys/kernel/sched_freq_dec_notify
fi
if [ -e "/proc/sys/kernel/sched_freq_inc_notify" ]; then
echo 600000 > /proc/sys/kernel/sched_freq_inc_notify
fi
if [ -e "/proc/sys/kernel/sched_boost" ]; then
echo 0 > /proc/sys/kernel/sched_boost
fi
#Tweaks for other various Settings
sleep 0.5
echo "=========================================="
echo Tweaking other various Settings
echo ·I/O Values
if [ -d /sys/block/dm-0 ] || [ -d /sys/devices/virtual/block/dm-0 ]; then
if [ -e /sys/devices/virtual/block/dm-0/queue/scheduler ]; then
DM_PATH=/sys/devices/virtual/block/dm-0/queue
fi
if [ -e /sys/block/dm-0/queue/scheduler ]; then
DM_PATH=/sys/block/dm-0/queue
fi
string=/sys/devices/virtual/block/dm-0/queue/scheduler;
Zen_Available=false;
if $BB grep 'zen' $string; then
Zen_Available=true;
fi
if [ "$Zen_Available" == "true" ]; then
if [ -e $DM_PATH/scheduler_hard ]; then
echo zen > $DM_PATH/scheduler_hard
fi
echo zen > $DM_PATH/scheduler
sleep 2
echo 300 > $DM_PATH/iosched/sync_expire
echo 2800 > $DM_PATH/iosched/async_expire
echo 14 > $DM_PATH/iosched/fifo_batch
chmod 644 $DM_PATH/iosched/sync_expire
echo 300 > $DM_PATH/iosched/sync_expire
fi
if [ "$Zen_Available" = "false" ]; then
if grep -q 'ro.build.flavor=lineage_oneplus3-userdebug' /system/build.prop; then
echo ZEN not avalible, setting 'Noop' instead...
if [ -e $DM_PATH/scheduler_hard ]; then
echo noop > $DM_PATH/scheduler_hard
fi
echo noop > $DM_PATH/scheduler
else
echo ZEN not avalible, setting 'CFQ' instead...
if [ -e $DM_PATH/scheduler_hard ]; then
echo cfq > $DM_PATH/scheduler_hard
fi
echo cfq > $DM_PATH/scheduler
fi
fi
fi
for i in /sys/block/../devices/soc/624000.ufshc/host0/target0:0:0/0:0:0:[0-4]/block/*/queue; do
string4=$($BB readlink -f $i/scheduler | cut -d 'q' -f1 | cut -d 'k' -f2 | cut -d '/' -f2 | tr a-z A-Z)
string5=$($BB cat $i/scheduler | cut -d ']' -f1 | cut -d '[' -f2 | $BB tr a-z A-Z)
if [ "$string5" == "NOOP" ]; then
echo "Leaving $string4 block at default $string5"
echo ""
sleep 0.1
fi
if [ "$string5" != "NOOP" ]; then
echo "Changing $string4 block I/O scheduler"
if [ -e $i/scheduler_hard ]; then
echo zen > $i/scheduler_hard
fi
echo zen > $i/scheduler
echo ""
sleep 2
# Initialize string 6 to avoid reference conflicts
string6=$($BB cat $i/scheduler | cut -d ']' -f1 | cut -d '[' -f2)
if [ "$string6" == "zen" ]; then
echo 300 > $i/iosched/sync_expire
echo 2800 > $i/iosched/async_expire
echo 14 > $i/iosched/fifo_batch
chmod 644 $i/iosched/sync_expire
echo 300 > $i/iosched/sync_expire
fi
fi
done
if [ -e "$DM_PATH/iostats" ]; then
echo 0 > $DM_PATH/iostats
fi
if [ -e "$DM_PATH/rq_affinity" ]; then
echo 1 > $DM_PATH/rq_affinity
fi
if [ -e "/sys/block/dm-0/bdi/read_ahead_kb" ]; then
echo 512 > /sys/devices/virtual/block/dm-0/bdi/read_ahead_kb
fi
if [ -e "/sys/block/sda/bdi/read_ahead_kb" ]; then
echo 512 > /sys/block/sda/bdi/read_ahead_kb
fi
echo ·Memory Values
echo 0 > /proc/sys/vm/swappiness
echo 100 > /proc/sys/vm/vfs_cache_pressure
echo 80 > /proc/sys/vm/dirty_ratio
echo 20 > /proc/sys/vm/dirty_background_ratio
echo 4096 > /proc/sys/vm/min_free_kbytes
echo 100 > /proc/sys/vm/dirty_expire_centisecs
echo 250 > /proc/sys/vm/dirty_writeback_centisecs
echo 0 > /proc/sys/vm/oom_kill_allocating_task
echo 3 > /proc/sys/vm/page-cluster
if [ -e "/sys/module/lowmemorykiller/parameters/enable_adaptive_lmk" ]; then
chmod 666 /sys/module/lowmemorykiller/parameters/enable_adaptive_lmk
chown root /sys/module/lowmemorykiller/parameters/enable_adaptive_lmk
echo 0 > /sys/module/lowmemorykiller/parameters/enable_adaptive_lmk
fi
if [ -e "/sys/module/lowmemorykiller/parameters/enable_adaptive_lmk" ]; then
echo 0 > /sys/module/lowmemorykiller/parameters/enable_adaptive_lmk
else
echo ' *Adaptive LMK is not present on your Kernel* '
fi
if [ -e "/sys/module/lowmemorykiller/parameters/minfree" ]; then
echo 23939,44091,58788,73485,88182,102879 > /sys/module/lowmemorykiller/parameters/minfree
else
echo ' *LMK cannot currently be modified on your Kernel* '
fi
echo ·TCP Values
string2=/proc/sys/net/ipv4/tcp_available_congestion_control
if grep 'westwood' $string2; then
echo westwood > /proc/sys/net/ipv4/tcp_congestion_control
else
echo Westwood not avilable, using Cubic
echo cubic > /proc/sys/net/ipv4/tcp_congestion_control
fi
#Tweaking GPU
sleep 0.4
echo GPU Tweaking
echo msm-adreno-tz > /sys/devices/soc/b00000.qcom,kgsl-3d0/devfreq/b00000.qcom,kgsl-3d0/governor
if grep -q 'ro.build.version.sdk=25' /system/build.prop; then
if grep -q 'ro.build.flavor=lineage_oneplus3-userdebug' /system/build.prop; then
echo 510000000 > /sys/class/kgsl/kgsl-3d0/max_gpuclk
else
echo 560000000 > /sys/class/kgsl/kgsl-3d0/max_gpuclk
fi
fi
if grep -q 'ro.build.version.sdk=24' /system/build.prop; then
if grep -q 'ro.build.flavor=lineage_oneplus3-userdebug' /system/build.prop; then
echo 510000000 > /sys/class/kgsl/kgsl-3d0/max_gpuclk
else
echo 560000000 > /sys/class/kgsl/kgsl-3d0/max_gpuclk
fi
fi
if grep -q 'ro.build.version.sdk=23' /system/build.prop; then
if grep -q 'ro.build.flavor=lineage_oneplus3-userdebug' /system/build.prop; then
echo 560000000 > /sys/devices/soc/b00000.qcom,kgsl-3d0/devfreq/b00000.qcom,kgsl-3d0/max_freq
else
echo 560000000 > /sys/devices/soc/b00000.qcom,kgsl-3d0/devfreq/b00000.qcom,kgsl-3d0/max_freq
fi
else
if grep -q 'ro.build.flavor=lineage_oneplus3-userdebug' /system/build.prop; then
echo 510000000 > /sys/devices/soc/b00000.qcom,kgsl-3d0/devfreq/b00000.qcom,kgsl-3d0/max_freq
else
echo 560000000 > /sys/devices/soc/b00000.qcom,kgsl-3d0/devfreq/b00000.qcom,kgsl-3d0/max_freq
fi
fi
sleep 1
echo ------------------------------------------------------------
echo 'Project Zhana v4.3' Successfully Applied!
echo "Project Zhana Battery" > /data/system/current_profile
echo You may now tweak them further
echo using EXKM or Kernel Adiutor
echo ------------------------------------------------------------
echo ""
echo " Done, this will be automatically closed..."
sleep 4
#################################################
#Modded by Asiier
#Please say thanks and give proper credits if you're using this profile.
#Credits
#*soniCron *Alcolawl *RogerF81 *Patalao *Mostafa Wael *Senthil360 and all of those that have share their profiles on Nexus 5X/6P Advanced Interactive Tweaks respective threads.
Important are:
Small Cores Tweaks.
echo 70 480000:65 556800:75 729600:82 960000:86 1036800:2 1228800:99 > /sys/devices/system/cpu/cpu0/cpufreq/interactive/target_loads
echo 220000 > /sys/devices/system/cpu/cpu0/cpufreq/interactive/timer_slack
echo 307200 > /sys/devices/system/cpu/cpu0/cpufreq/interactive/hispeed_freq
echo 100000 > /sys/devices/system/cpu/cpu0/cpufreq/interactive/timer_rate
echo 0 729600:76000 960000:99000 1228800:150000 1478400:170000 > /sys/devices/system/cpu/cpu0/cpufreq/interactive/above_hispeed_delay
echo 155 > /sys/devices/system/cpu/cpu0/cpufreq/interactive/go_hispeed_load
echo 22000 > /sys/devices/system/cpu/cpu0/cpufreq/interactive/min_sample_time
echo 0 > /sys/devices/system/cpu/cpu0/cpufreq/interactive/max_freq_hysteresis
echo 0 > /sys/devices/system/cpu/cpu0/cpufreq/interactive/ignore_hispeed_on_notif
echo 0 > /sys/devices/system/cpu/cpu0/cpufreq/interactive/boost
echo 0 > /sys/devices/system/cpu/cpu0/cpufreq/interactive/fast_ramp_down
echo 0 > /sys/devices/system/cpu/cpu0/cpufreq/interactive/align_windows
echo 1 > /sys/devices/system/cpu/cpu0/cpufreq/interactive/use_migration_notif
echo 0 > /sys/devices/system/cpu/cpu0/cpufreq/interactive/use_sched_load
echo 0 > /sys/devices/system/cpu/cpu0/cpufreq/interactive/boostpulse_duration
echo 0 > /sys/devices/system/cpu/cpu0/cpufreq/interactive/io_is_busy
if [ -e "/sys/devices/system/cpu/cpu0/cpufreq/interactive/enable_prediction" ]; then
chmod 644 /sys/devices/system/cpu/cpu0/cpufreq/interactive/enable_prediction
echo 0 > /sys/devices/system/cpu/cpu0/cpufreq/interactive/enable_prediction
fi
Big Cores Tweaks:
echo 65 940800:80 1036800:2 1401600:95 1824000:98 > /sys/devices/system/cpu/cpu2/cpufreq/interactive/target_loads
echo 140000 > /sys/devices/system/cpu/cpu2/cpufreq/interactive/timer_slack
echo 1401600 > /sys/devices/system/cpu/cpu2/cpufreq/interactive/hispeed_freq
echo 65000 > /sys/devices/system/cpu/cpu2/cpufreq/interactive/timer_rate
echo 32000 940800:85000 1248000:96000 1401600:88000 1632000:80000 > /sys/devices/system/cpu/cpu2/cpufreq/interactive/above_hispeed_delay
echo 99 > /sys/devices/system/cpu/cpu2/cpufreq/interactive/go_hispeed_load
echo 11000 > /sys/devices/system/cpu/cpu2/cpufreq/interactive/min_sample_time
echo 0 > /sys/devices/system/cpu/cpu2/cpufreq/interactive/max_freq_hysteresis
echo 1 > /sys/devices/system/cpu/cpu2/cpufreq/interactive/ignore_hispeed_on_notif
echo 0 > /sys/devices/system/cpu/cpu2/cpufreq/interactive/boost
echo 1 > /sys/devices/system/cpu/cpu2/cpufreq/interactive/fast_ramp_down
echo 0 > /sys/devices/system/cpu/cpu2/cpufreq/interactive/align_windows
echo 1 > /sys/devices/system/cpu/cpu2/cpufreq/interactive/use_migration_notif
echo 0 > /sys/devices/system/cpu/cpu2/cpufreq/interactive/use_sched_load
echo 0 > /sys/devices/system/cpu/cpu2/cpufreq/interactive/boostpulse_duration
echo 0 > /sys/devices/system/cpu/cpu2/cpufreq/interactive/io_is_busy
if [ -e "/sys/devices/system/cpu/cpu2/cpufreq/interactive/enable_prediction" ]; then
chmod 644 /sys/devices/system/cpu/cpu2/cpufreq/interactive/enable_prediction
echo 0 > /sys/devices/system/cpu/cpu2/cpufreq/interactive/enable_prediction
fi
#Enable Input Boost for LITTLE cluster @729MHz and for BIG cluster @729Hz for 100ms
echo Non-Lineage ROM detected
echo Applying appropriate values.
echo Enabling Input Boost at 729 MHz for the LITTLE cluster and at 0 MHz for the BIG Cluster
if [ -e "/sys/module/cpu_boost/parameters/input_boost_freq" ]; then
chmod 644 /sys/module/cpu_boost/parameters/input_boost_freq
echo 0:729600 1:0 2:0 3:0 > /sys/module/cpu_boost/parameters/input_boost_freq
chmod 644 /sys/module/cpu_boost/parameters/input_boost_ms
echo 77 > /sys/module/cpu_boost/parameters/input_boost_ms
else
echo "*Input Boost is not avalible for your Kernel*"
fi
#echo Tweaking HMP Scheduler for correcting BIG Cluster utilization
echo 2 > /proc/sys/kernel/sched_window_stats_policy
echo 85 > /proc/sys/kernel/sched_upmigrate
echo 62 > /proc/sys/kernel/sched_downmigrate
echo 5 > /proc/sys/kernel/sched_spill_nr_run
echo 100 > /proc/sys/kernel/sched_spill_load
echo 30 > /proc/sys/kernel/sched_init_task_load
it prefers Zen, if not available goes to noop or CFQ
Some Memory tweaks..
cho ·Memory Values
echo 0 > /proc/sys/vm/swappiness
echo 100 > /proc/sys/vm/vfs_cache_pressure
echo 80 > /proc/sys/vm/dirty_ratio
echo 20 > /proc/sys/vm/dirty_background_ratio
echo 4096 > /proc/sys/vm/min_free_kbytes
echo 100 > /proc/sys/vm/dirty_expire_centisecs
echo 250 > /proc/sys/vm/dirty_writeback_centisecs
echo 0 > /proc/sys/vm/oom_kill_allocating_task
echo 3 > /proc/sys/vm/page-cluster
tries to set TCP to westwood if not cubic.
echo msm-adreno-tz > /sys/devices/soc/b00000.qcom,kgsl-3d0/devfreq/b00000.qcom,kgsl-3d0/governor
Oh... and the whole zip is made for SDK25 or lower so not really O compatible.
So yeah... you'd better set the values you'd want manually instead of relying on a outdated all in one wonder script.
timbohobbs said:
Are you using stock elemental x settings or other ?
Click to expand...
Click to collapse
Stock
Haldi4803 said:
Important are:
Small Cores Tweaks.
echo 70 480000:65 556800:75 729600:82 960000:86 1036800:2 1228800:99 > /sys/devices/system/cpu/cpu0/cpufreq/interactive/target_loads
echo 220000 > /sys/devices/system/cpu/cpu0/cpufreq/interactive/timer_slack
echo 307200 > /sys/devices/system/cpu/cpu0/cpufreq/interactive/hispeed_freq
echo 100000 > /sys/devices/system/cpu/cpu0/cpufreq/interactive/timer_rate
echo 0 729600:76000 960000:99000 1228800:150000 1478400:170000 > /sys/devices/system/cpu/cpu0/cpufreq/interactive/above_hispeed_delay
echo 155 > /sys/devices/system/cpu/cpu0/cpufreq/interactive/go_hispeed_load
echo 22000 > /sys/devices/system/cpu/cpu0/cpufreq/interactive/min_sample_time
echo 0 > /sys/devices/system/cpu/cpu0/cpufreq/interactive/max_freq_hysteresis
echo 0 > /sys/devices/system/cpu/cpu0/cpufreq/interactive/ignore_hispeed_on_notif
echo 0 > /sys/devices/system/cpu/cpu0/cpufreq/interactive/boost
echo 0 > /sys/devices/system/cpu/cpu0/cpufreq/interactive/fast_ramp_down
echo 0 > /sys/devices/system/cpu/cpu0/cpufreq/interactive/align_windows
echo 1 > /sys/devices/system/cpu/cpu0/cpufreq/interactive/use_migration_notif
echo 0 > /sys/devices/system/cpu/cpu0/cpufreq/interactive/use_sched_load
echo 0 > /sys/devices/system/cpu/cpu0/cpufreq/interactive/boostpulse_duration
echo 0 > /sys/devices/system/cpu/cpu0/cpufreq/interactive/io_is_busy
if [ -e "/sys/devices/system/cpu/cpu0/cpufreq/interactive/enable_prediction" ]; then
chmod 644 /sys/devices/system/cpu/cpu0/cpufreq/interactive/enable_prediction
echo 0 > /sys/devices/system/cpu/cpu0/cpufreq/interactive/enable_prediction
fi
Big Cores Tweaks:
echo 65 940800:80 1036800:2 1401600:95 1824000:98 > /sys/devices/system/cpu/cpu2/cpufreq/interactive/target_loads
echo 140000 > /sys/devices/system/cpu/cpu2/cpufreq/interactive/timer_slack
echo 1401600 > /sys/devices/system/cpu/cpu2/cpufreq/interactive/hispeed_freq
echo 65000 > /sys/devices/system/cpu/cpu2/cpufreq/interactive/timer_rate
echo 32000 940800:85000 1248000:96000 1401600:88000 1632000:80000 > /sys/devices/system/cpu/cpu2/cpufreq/interactive/above_hispeed_delay
echo 99 > /sys/devices/system/cpu/cpu2/cpufreq/interactive/go_hispeed_load
echo 11000 > /sys/devices/system/cpu/cpu2/cpufreq/interactive/min_sample_time
echo 0 > /sys/devices/system/cpu/cpu2/cpufreq/interactive/max_freq_hysteresis
echo 1 > /sys/devices/system/cpu/cpu2/cpufreq/interactive/ignore_hispeed_on_notif
echo 0 > /sys/devices/system/cpu/cpu2/cpufreq/interactive/boost
echo 1 > /sys/devices/system/cpu/cpu2/cpufreq/interactive/fast_ramp_down
echo 0 > /sys/devices/system/cpu/cpu2/cpufreq/interactive/align_windows
echo 1 > /sys/devices/system/cpu/cpu2/cpufreq/interactive/use_migration_notif
echo 0 > /sys/devices/system/cpu/cpu2/cpufreq/interactive/use_sched_load
echo 0 > /sys/devices/system/cpu/cpu2/cpufreq/interactive/boostpulse_duration
echo 0 > /sys/devices/system/cpu/cpu2/cpufreq/interactive/io_is_busy
if [ -e "/sys/devices/system/cpu/cpu2/cpufreq/interactive/enable_prediction" ]; then
chmod 644 /sys/devices/system/cpu/cpu2/cpufreq/interactive/enable_prediction
echo 0 > /sys/devices/system/cpu/cpu2/cpufreq/interactive/enable_prediction
fi
#Enable Input Boost for LITTLE cluster @729MHz and for BIG cluster @729Hz for 100ms
echo Non-Lineage ROM detected
echo Applying appropriate values.
echo Enabling Input Boost at 729 MHz for the LITTLE cluster and at 0 MHz for the BIG Cluster
if [ -e "/sys/module/cpu_boost/parameters/input_boost_freq" ]; then
chmod 644 /sys/module/cpu_boost/parameters/input_boost_freq
echo 0:729600 1:0 2:0 3:0 > /sys/module/cpu_boost/parameters/input_boost_freq
chmod 644 /sys/module/cpu_boost/parameters/input_boost_ms
echo 77 > /sys/module/cpu_boost/parameters/input_boost_ms
else
echo "*Input Boost is not avalible for your Kernel*"
fi
#echo Tweaking HMP Scheduler for correcting BIG Cluster utilization
echo 2 > /proc/sys/kernel/sched_window_stats_policy
echo 85 > /proc/sys/kernel/sched_upmigrate
echo 62 > /proc/sys/kernel/sched_downmigrate
echo 5 > /proc/sys/kernel/sched_spill_nr_run
echo 100 > /proc/sys/kernel/sched_spill_load
echo 30 > /proc/sys/kernel/sched_init_task_load
it prefers Zen, if not available goes to noop or CFQ
Some Memory tweaks..
cho ·Memory Values
echo 0 > /proc/sys/vm/swappiness
echo 100 > /proc/sys/vm/vfs_cache_pressure
echo 80 > /proc/sys/vm/dirty_ratio
echo 20 > /proc/sys/vm/dirty_background_ratio
echo 4096 > /proc/sys/vm/min_free_kbytes
echo 100 > /proc/sys/vm/dirty_expire_centisecs
echo 250 > /proc/sys/vm/dirty_writeback_centisecs
echo 0 > /proc/sys/vm/oom_kill_allocating_task
echo 3 > /proc/sys/vm/page-cluster
tries to set TCP to westwood if not cubic.
echo msm-adreno-tz > /sys/devices/soc/b00000.qcom,kgsl-3d0/devfreq/b00000.qcom,kgsl-3d0/governor
Oh... and the whole zip is made for SDK25 or lower so not really O compatible.
So yeah... you'd better set the values you'd want manually instead of relying on a outdated all in one wonder script.
Click to expand...
Click to collapse
That would work if I knew how to set all those values. For me though I do not.
So i was checking this out and in the FAQ thread here: https://forum.xda-developers.com/showpost.php?p=69037152&postcount=3
Near the top it mentions the HTC10 with a link that explains why it doesn't work or doesn't work as well on an HTC device, linked here: https://forum.xda-developers.com/showpost.php?p=70815496&postcount=2864
The long and short of it is I guess HTC uses there own proprietary pnp manager. But it does go on to say that someone else took the work being done with AKT and made a unified kernel tweak, linked here: https://forum.xda-developers.com/htc-10/development/advanced-interactive-governor-tweaks-t3543589 Which i guess works for anything including HTC's stock kernel.
whew........ So i guess my question first of all is are you using AKT, or are you using Soilwork: Unified kernel-tweaks?
I guess the next question is those of us using modded kernel (cleanslate and Elemental X) Do those kernels have HTC's proprietary pnp manager turned on and they are just tweaking it, or do they shut it off completely and go there own route.
If they shut it off completely then it sounds like AKT is the way to go, but if they don't are are just tweaking HTC's pnp manager, it sounds like the Soilwork tweak is the way to go.
BTW i also use Leedoird, but i'm rocking the CleanSlate kernel atm.
Void4ever
void4ever said:
So i was checking this out and in the FAQ thread here: https://forum.xda-developers.com/showpost.php?p=69037152&postcount=3
Near the top it mentions the HTC10 with a link that explains why it doesn't work or doesn't work as well on an HTC device, linked here: https://forum.xda-developers.com/showpost.php?p=70815496&postcount=2864
The long and short of it is I guess HTC uses there own proprietary pnp manager. But it does go on to say that someone else took the work being done with AKT and made a unified kernel tweak, linked here: https://forum.xda-developers.com/htc-10/development/advanced-interactive-governor-tweaks-t3543589 Which i guess works for anything including HTC's stock kernel.
whew........ So i guess my question first of all is are you using AKT, or are you using Soilwork: Unified kernel-tweaks?
I guess the next question is those of us using modded kernel (cleanslate and Elemental X) Do those kernels have HTC's proprietary pnp manager turned on and they are just tweaking it, or do they shut it off completely and go there own route.
If they shut it off completely then it sounds like AKT is the way to go, but if they don't are are just tweaking HTC's pnp manager, it sounds like the Soilwork tweak is the way to go.
BTW i also use Leedoird, but i'm rocking the CleanSlate kernel atm.
Void4ever
Click to expand...
Click to collapse
Using AKT. And enabled through terminal.And no I didn't disable pnp mgr, I'm guessing it overrides it. And soilwork won't flash. Akt is working fine for me no reboots or massive drains or wakelocks.No excessive heat either running cool as a cucumber,so until pnp is updated I chose to use this route. I'm getting better averages than I was on Nougat. 4.5 hrs on screen currently 27% battery remaining and 16 hours off charger. Try it and see what you think.
mattie_49 said:
Using AKT. And enabled through terminal.And no I didn't disable pnp mgr, I'm guessing it overrides it. And soilwork won't flash. Akt is working fine for me no reboots or massive drains or wakelocks.No excessive heat either running cool as a cucumber,so until pnp is updated I chose to use this route. I'm getting better averages than I was on Nougat. 4.5 hrs on screen currently 27% battery remaining and 16 hours off charger. Try it and see what you think.
Click to expand...
Click to collapse
Hi, do you think this would work on Nougat? I have random reboots at 40% battery left.
NickDVS said:
Hi, do you think this would work on Nougat? I have random reboots at 40% battery left.
Click to expand...
Click to collapse
I'm sure. Try and see
I've done all of this before & it only helps slightly. The drain is related to HTC's framework & it's dialer, and the only way to truly stop the drain is to use airplane mode...which kind of defeats the purpose of it being a phone.
This battery issue is non-existent with LineageOS 15.1 & AOSiP 8.1, running on Oreo firmware. Both of those ROMs work fine, but still have bugs: bottom speaker barely works & Bluetooth issues.
mattie_49 said:
Using AKT. And enabled through terminal.And no I didn't disable pnp mgr, I'm guessing it overrides it. And soilwork won't flash. Akt is working fine for me no reboots or massive drains or wakelocks.No excessive heat either running cool as a cucumber,so until pnp is updated I chose to use this route. I'm getting better averages than I was on Nougat. 4.5 hrs on screen currently 27% battery remaining and 16 hours off charger. Try it and see what you think.
Click to expand...
Click to collapse
I am o. Leedroid 5.2 with stock kernel tweaked by leedroid, can I install a stock stock kernel and what rom do you have?
Is this AKT still work after reboot? Or we must re-enable it after reboot?
fresh777 said:
Is this AKT still work after reboot? Or we must re-enable it after reboot?
Click to expand...
Click to collapse
Must use a terminal emulator. Type su enter
Then type AKT then it's self explainable, choose your profile.
mattie_49 said:
Must use a terminal emulator. Type su enter
Then type AKT then it's self explainable, choose your profile.
Click to expand...
Click to collapse
Thanks for the reply. I mean after run AKT from terminal and done. For the next reboot, i must repeat the step or not?
fresh777 said:
Thanks for the reply. I mean after run AKT from terminal and done. For the next reboot, i must repeat the step or not?
Click to expand...
Click to collapse
No. All done till you wanna change profiles if at all. Terminal will tell you what profile is active after AKT enter
mattie_49 said:
No. All done till you wanna change profiles if at all. Terminal will tell you what profile is active after AKT enter
Click to expand...
Click to collapse
Thank you. I just use this in aosip 8.1 rom. Don't see any improvement for battery life. But for hot issue, i didn't got this issue when use AKT.
Ninja X said:
I am o. Leedroid 5.2 with stock kernel tweaked by leedroid, can I install a stock stock kernel and what rom do you have?
Click to expand...
Click to collapse
the stock kernel in leedroid is not tweaked, you either have the actual stock kernel or the cleanslate kernel.
Oooh.