5,598,980 Members 31,429 Now Online
XDA Developers Android and Mobile Development Forum

Collin_ph Battery Tweak RC1 for Cyanogen / Darch Froyo roms (possibly others)

Tip us?
 
collin_ph
Old
(Last edited by collin_ph; 24th August 2010 at 06:17 AM.)
#1  
Senior Member - OP
Thanks Meter 18
Posts: 150
Join Date: May 2010
Default Collin_ph Battery Tweak RC1 for Cyanogen / Darch Froyo roms (possibly others)

UPDATE 8/24! Please go to the site and download the latest version RC1b which corrects 2 small bugs people have reported. It now sets the proper permissions on batt-diag so it runs, and it changes the way the program tries to SU so that you can choose to not have the program attempt to run SU if your rom has trouble running su from terminal;

---Original Below---
I decided to create a new forum for the latest battery tweak as so much has changed since the initial versions.

To get things started, I'll just say that collin_ph battery tweak is a collection of scripts designed to make the hero (for now) last longer on battery, run faster, and run better. The tweak includes CPU management, Battery Management, Disk Performance Boost, Scheduler Boost, LED Fix, Audio Quality boost and other features to improve the usability of your Hero.

Instructions: Go to http://www.primoweb.com/froyo to download the latest version and get the documentation.

Boot into recovery and flash the zip file.
After reboot, you may run batt-cfg from shell or terminal (Note, that the scripts will all request root access, so there's no longer a need to su before running them).

to run batt-cfg
go to terminal in the phone or use adb shell from your PC
once there, type
batt-cfg

It will pull up a menu of choices. For further info, see http://www.primoweb.com/froyo

You can load a 691 mhz default (most Cyanogen kernels now only support up to 691 mhz anyway), or, if you have an uncapped kernel, you can choose a 768 mhz setting. Note: Both settings actually run at 691 when on battery and only run higher when plugged in.

The basics of how the battery is extended is that this tweak causes your phone to scale down (to lower frequencies) faster and to scale up slower. In stock configuration, the cpu scales up when only under 70% load -- while part of this tweak causes it not to scale until it's at 95% load, avoiding unnecessary scaling and battery drain. A second (and arguably more important) feature, is that as the battery drains, it lowers the maxumum CPU frequency. So when you have 1% battery left, you may be running at 468mhz instead of 691. Another plus is that the phone runs in a "higher performance" mode while charging via AC, and another mode to make sure the phone is actually charging when connected bia USB, in addition to the settings mentioned above when the phone is on battery.The best part is that almost every parameter in the system is adjustable through terminal or adb shell using a program called batt-cfg -- just run it and you'll be presented with a menu of options.


I'm constantly updating the documentation, so please check back often as I'll update this thread until there's a final 3.0 version. We're already working on a 4.0 which will be available on the market. We'll post more info there as it happens at www.tweaktool.com

COMPATIBILITY NOTES:
This tweak only works with clockable kernels. A lot of ROMS have reclockable or overclockable kernels which should work. I recommend Froyo roms, but I have heard of the tweak running with 2.1 releases. The main incompatibility seems to be with the service startup-- on some roms, the service doesn't automatically start up.

to verify if your rom is compatible and that the tweak is working, reboot.
Then go to terminal or adb shell and type:
pidof batt.sh
if it returns a number, then the service is running. If not, you'll have to start it manually every time the phone reboots by going to terminal or adb shell and typing
batt-cfg
then choose the option to save and exit. This will manually start or restart the service. Note: if your rom does not start the service automatically, you'll have to do the above batt-cfg procedure after EVERY boot or battery tweak will not run.

If you're a ROM developer, you'll can probably make your ROM compatible by adjusting your rom (ramdisk) to call (import) /system/etc/init.local.rc from init.rc -- assuming your ROM has an overclockable kernel like fresh, darch, or others.

ROMS based on unclockable kernels like Damage Control, won't work without a kernel upgrade and may still not start the service automatically upon reboot.


Thanks to Decad3nce for testing and improving several parts of the battery tweak.
The Following 2 Users Say Thank You to collin_ph For This Useful Post: [ Click to Expand ]
 
krispuniq
Old
#2  
Senior Member
Thanks Meter 21
Posts: 327
Join Date: Oct 2008
So to flash this tweak and have it working on the latest Froyo nightly, do we need to flash overclockfix.zip ??

I had to flash this fix almost with ever nightly, coz the frequency list would not show up when i need to customize tweak settings.
 
LifeInTheGrey
Old
#3  
LifeInTheGrey's Avatar
Senior Member
Thanks Meter 230
Posts: 1,296
Join Date: Dec 2009
Location: Seattle

 
DONATE TO ME
I was reading the documentation and saw the CFS tweaks are disabled by default. Will this correct the GPS issue that was on beta 10?

Froyo Hero to the rescue
HTC Hero => HTC EVO 4G => Samsung Galaxy S III => Motorola Droid RAZR MAXX HD => Google Nexus 5 + LG GPad 8.3
 
Ezintn
Old
#4  
Senior Member
Thanks Meter 18
Posts: 206
Join Date: Aug 2010
Location: Johnson City
Thank you for all your work on this, got 12 hrs on 50% today with beta 10 and Decad3nse #8, 768 pre-set, most time I've ever gotten outa my Hero. Flashed your RC1 (with Darch's RC1) about 45mn ago and used custom settings to jack-up the max to 768 across the board, min.s and intervals stock. Thank you for explaining the 768 pre-set is really 691! Gonna sit on what I've got for a day and then try w/ Darch's "fix" kernel. Hope I can keep the max on batt @ 768 'cause it seems to make my Hero more responsive/less laggy.
 
greenmikey
Old
#5  
Junior Member
Thanks Meter 0
Posts: 12
Join Date: Mar 2010
I was not able to use the batt-diag in adb shell. I'll report back tomorrow how the tests go.
 
ToxicToastKatz
Old
#6  
Member
Thanks Meter 0
Posts: 34
Join Date: Apr 2008
What is the procedure for installing this if you're currently running Beta 10? Do you have to wipe, reflash, etc or can you just flash the update and reconfigure in adb?
 
churro7
Old
#7  
Senior Member
Thanks Meter 31
Posts: 2,023
Join Date: Jul 2010
it made my hero laggy!!!
 
tb87
Old
#8  
Senior Member
Thanks Meter 0
Posts: 111
Join Date: Apr 2010
Quote:
Originally Posted by ToxicToastKatz View Post
What is the procedure for installing this if you're currently running Beta 10? Do you have to wipe, reflash, etc or can you just flash the update and reconfigure in adb?
Follow the uninstall steps form the documentation

Quote:
How do I uninstall it?

adb shell
batt-rm.sh
Follow the prompts and the tweak will be uninstalled.
Then flash the new version, this is how I have been doing it.
Sprint
HTC EVO 4g LTE
 
LeftonJackman
Old
#9  
Member
Thanks Meter 2
Posts: 51
Join Date: Sep 2008
Excellent tweak! Used it through Beta and now enjoying the RC. Well done!
"Beer is proof that God loves us and wants us to be happy." - Ben Franklin
 
Big-O-Devil
Old
#10  
Big-O-Devil's Avatar
Senior Member
Thanks Meter 29
Posts: 567
Join Date: Jul 2010
Location: Miami
wow.. the way things are going i don't think i am going to jump into a evo... i am loving my hero so much.... thank you for all your hard work..

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes


TRENDING IN THEMER...