Making G1 run at 528 MHz permanently (Haykuro's Builds only) - G1 Android Development

Run these commands as "su".
Code:
echo 528000 > /sys/devices/system/cpu/cpu0/cpufreq/scaling_max_freq
echo 528000 > /sys/devices/system/cpu/cpu0/cpufreq/scaling_min_freq
You can check the cpu speed by running the command below before and after.
Code:
cat /proc/cpuinfo
I have tested this on 5.0.2H and works flawlessly.
These settings will be lost after reboot.
On JF builds, you can make this run after reboot by including the two lines in "init.rc".
I do not know how to accomplish this in Haykuro's builds.
I am seeing much faster response times, but beware that the battery life will be reduced as the processor keeps running at 528 MHz even when the phone is in sleep mode.
Just wanted to add the reasoning.
If you type
Code:
cat /sys/devices/system/cpu/cpu0/cpufreq/scaling_available_governors
you will see a list of available profiles that can be used by the kernel to control the CPU.
By default, "ondemand" profile is used.
The "scaling_max_freq" and "scaling_min_freq" define the maximum and minimum frequencies the CPU can run at.
What gets used is governed by the profile in use.
"scaling_cur_freq" gives you the current CPU frequency.
The commands given just change these maximum and minimum frequencies.
Hope this clears some questions on how this works.
Update:
I tested by setting minimum to 64000, but the CPU did not clock below 122880 even in standby.
Update:
For now this will only work on Haykuro's builds.
This will NOT work on JF's builds as the system files are different.

good catch! I've been looking into this a lot myself but hadn't found that device. Props.
So, what daring person is gonna try 530000? lol

buttkicker said:
Run these commands as "su".
Code:
echo 528000 > /sys/devices/system/cpu/cpu0/cpufreq/scaling_max_freq
echo 528000 > /sys/devices/system/cpu/cpu0/cpufreq/scaling_min_freq
You can check the cpu speed by running the command below before and after.
Code:
cat /proc/cpuinfo
I have tested this on 5.0.2H and works flawlessly.
These settings will be lost after reboot.
On JF builds, you can make this run after reboot by including the two lines in "init.rc".
I do not know how to accomplish this in Haykuro's builds.
I am seeing much faster response times, but beware that the battery life will be reduced as the processor keeps running at 528 MHz even when the phone is in sleep mode.
Have fun.
Click to expand...
Click to collapse
Im on jf mod apps to sd card, and whenever I try this is says cannot create directory nonexistent

Joeriginal said:
Im on jf mod apps to sd card, and whenever I try this is says cannot create directory nonexistent
Click to expand...
Click to collapse
are you running it as root? I accidentally forgot that it doesn't start you out as superuser and tried to do it and got that exact error. Make sure you su before trying those lines.

There is no point in keeping it at 528Mhz all the time.
Setting the max scaling frequency to 528Mhz would be enough. The device would clock at it only when needed.

[email protected] said:
are you running it as root? I accidentally forgot that it doesn't start you out as superuser and tried to do it and got that exact error. Make sure you su before trying those lines.
Click to expand...
Click to collapse
Yeah, can you show me exactly what you did.

where after you enter
Code:
cat /proc/cpuinfo
does the cpu speed show?

AbsoluteDesignz said:
where after you enter
Code:
cat /proc/cpuinfo
does the cpu speed show?
Click to expand...
Click to collapse
I tried it on 5.01G and I don't see anything showing up in /proc/cpuinfo. Its the same before and after.
If I do a
cat /sys/devices/system/cpu/cpu0/cpufreq/scaling_max_freq
528000
It does show 528000, but I'm not noticing too big if any of a performance improvement, so I don't think it works on the G versions.

hmmm, well i can't really tell if its working, but it doesnt seem to be doing any harm
someone let me know when they go above 528000

it dont work. maybe something to do with app and data on the sd.

MoridinBG said:
There is no point in keeping it at 528Mhz all the time.
Setting the max scaling frequency to 528Mhz would be enough. The device would clock at it only when needed.
Click to expand...
Click to collapse
This. Also, cpuinfo_min_freq lists the cpu as capable of as low as 19.2 mhz, while scaling has the min frequency at 245 mhz. One could presumably prolong battery life on idle by reducing min frequency further, to e.g. 128mhz
Code:
echo 128000 > scaling_min_freq
I'm running at 128mhz-528mhz at the moment, not sure if it makes any significant difference though.

im currently using the 5.0.2h build by haykuro everything runs great the only issue im having is getting it to run on startup i have added it to the /init.rc using adb but even after doing that on reboot it goes back to the default frequency. anyone else having this issue?

AbsoluteDesignz said:
where after you enter
Code:
cat /proc/cpuinfo
does the cpu speed show?
Click to expand...
Click to collapse
I *think* it is the BogoMIPS part. When I just ran it (Haykuro 5.0.2H), I got 247.6 BogoMIPS. Setting JUST the max setting to 528, it remained at 247.6. Setting both the minimum and maximum put it at 527.15.
Performance? I don't have any apps installed to test this. But I will say that it does *seem* faster on the home screen. There is no delay on anything. It's snappy as all hell. Placebo? Maybe.
I'll play around with the init.rc when I get home tonight.
*More*
Just did a test. I dropped my minimum to 128. It showed 127.79 - I then started an MP3 song in the background and checked it (while it was playing) and it said 527.15. I paused the song and it went back to 127.79.
If BogoMIPS is what we're supposed to be looking at, it is working as far as scaling. Need a benchmark program of some sort to really test. I wonder how low we could go to save battery life...
Another way to test (without a benchmark app) is to lower it to 64 min and 64 max. See if the phone locks / is slow.

Ok it does work if I set min and max to 528 in 5.01G.
I guess if max is only set, it will just throttle up when needed.
there's definitely a performance improvement when browsing javascript heavy sites.
KyleK29 said:
I *think* it is the BogoMIPS part. When I just ran it (Haykuro 5.0.2H), I got 247.6 BogoMIPS. Setting JUST the max setting to 528, it remained at 247.6. Setting both the minimum and maximum put it at 527.15.
Performance? I don't have any apps installed to test this. But I will say that it does *seem* faster on the home screen. There is no delay on anything. It's snappy as all hell. Placebo? Maybe.
I'll play around with the init.rc when I get home tonight.
*More*
Just did a test. I dropped my minimum to 128. It showed 127.79 - I then started an MP3 song in the background and checked it (while it was playing) and it said 527.15. I paused the song and it went back to 127.79.
If BogoMIPS is what we're supposed to be looking at, it is working as far as scaling. Need a benchmark program of some sort to really test. I wonder how low we could go to save battery life...
Another way to test (without a benchmark app) is to lower it to 64 min and 64 max. See if the phone locks / is slow.
Click to expand...
Click to collapse

I really hope someone is testing the 128-min/528+max theory to see if it improves battery life. I'm frequently away from any kind of charger for 8+ hours with my phone idle for 90% of that, so if it did, it would be a godsend.

This works for me. If you want an easier way, instally my app that does exactly this. Its called openoverclocker and is on the market. Thanks for the idea buttkicker!

Powermaniac said:
I don't notice any difference. Are you guys sure BogoMips is supposed to really tell any kind of Proc speed?
http://en.wikipedia.org/wiki/BogoMips
Click to expand...
Click to collapse
Yes the BogoMips value is what you want to look out for. Since the haykuro build has dynamic scaling, it will adjust accordingly. =]

I know this method works.
You can download "Neocore" from Market and test it.
Neocore is an OpenGL graphics performance benchmark tool.
I'm posting the before and after screenshots for reference.
The benchmark was run without audio.
The CPU was overclocked to the following setting.
MAX = 528000
MIN = 128000

[email protected] said:
This works for me. If you want an easier way, instally my app that does exactly this. Its called openoverclocker and is on the market. Thanks for the idea buttkicker!
Click to expand...
Click to collapse
You are welcome and thanks for creating an app.

i tested neocore and my fps was 26.4 =]

Related

[APPS] Best SetCPU Settings

anyone got what they think is the best configuration for SetCPU?
stock configuration works great for me
min cpu = 225 (or something like that)
max cpu = 995 (again, or something like that)
????
Stock settings are:
Min: 245
Max: 998
CPU Governer: On demand
Charging 998/998
Sleep/Standby 499/245
Power < 25% 576/245
i concur about the stock clock settings, they work best for me. 998 high/245 low
i am opting for stock... im going to assume that htc/google did their research to give us the best blend of CPU speeds depending on what the phone is doing and what the battery power is...
if stock settings are 998 mhz why overclock it? can you get more from the processor than that?
*black*silva* said:
if stock settings are 998 mhz why overclock it? can you get more from the processor than that?
Click to expand...
Click to collapse
you probably can, but you'd just end up burning it out. what you can do is set the low a bit higher than 245. more battery drain will result.
So what are the out of the box settings on the CPU if you dont use setCPU?
Read this thread you will see them
No one has messed with this app?
I have mine set @ stock, but have also enabled a profile for when the phone is asleep. I set it at 300/245. Not really sure if it makes a difference in battery life.
Mine is set to the A1clock speed which is 768max and 245 min.. no lag when swippin and in act1 video player its still smooth..even a droids 550mhz stock speed. Also got it 245max/min when sleep, remember to exclude setcpu if you u wanna see results..
Goonzy said:
Mine is set to the A1clock speed which is 768max and 245 min.. no lag when swippin and in act1 video player its still smooth..even a droids 550mhz stock speed. Also got it 245max/min when sleep, remember to exclude setcpu if you u wanna see results..
Click to expand...
Click to collapse
What's a1clock?
I noticed that when using SetCPU and setting the minimum CPU speed to 245mhz, it seems like the CPU doesnt clock down to 245, but instead stays at 998. By setting the minimum to 328, it works.
Where can u see that?
Formel-LMS said:
Where can u see that?
Click to expand...
Click to collapse
I agree...where are all you guys/gals seeing/getting information like that off of the phone. What are the apps needed to monitor that information.
Also, exactly what is the stock CPU settings?
gururise said:
I noticed that when using SetCPU and setting the minimum CPU speed to 245mhz, it seems like the CPU doesnt clock down to 245, but instead stays at 998. By setting the minimum to 328, it works.
Click to expand...
Click to collapse
I noticed something similar.
When setting it to 998/245 and hit refresh 5 or 6 times you'll never see something under 998 at the top.
When setting min to something else than 245 but keeping 998 for max and hitting refresh 5 or 6 times you'll see the min value a few times when refreshing.
####################
where is the difference between on demand, user space and performance and what did you take? I took performace for some weeks and just set it to on demand (and 998/245)
so what settings would be proper to set to see a difference?

App for logging CPU frequency to check SetCPU low frequency set on screen off

any app to check that the cpu frequencies are being set to low values that I selected from setCPU while the screen is off ?
how to check if I am at default, and not using any overclocking programs.
You know, SetCPU has a built in "log" feature that tells you how much time was spent at each CPU state. Just go to the Info tab and scroll down till you find the section labeled "Time in State" and it will list the frequencies and the time spent in each frequency.
There is no need, doesn't it have profile settings for when the screen is off? Do you not trust the application?
For the record I don't like this way of battery management because it over-rides the CPU scaling built into the kernel boot.img. SetCPU's primary function is to overclock, so it's best to keep the min at the bottom and the max to your overclock mhz.
evilkorn said:
There is no need, doesn't it have profile settings for when the screen is off? Do you not trust the application?
For the record I don't like this way of battery management because it over-rides the CPU scaling built into the kernel boot.img. SetCPU's primary function is to overclock, so it's best to keep the min at the bottom and the max to your overclock mhz.
Click to expand...
Click to collapse
it has one dedicated feature just for when screen is off. Then when you set it to throttle it does that while the screen is off as well
StDevious said:
any app to check that the cpu frequencies are being set to low values that I selected from setCPU while the screen is off ?
Click to expand...
Click to collapse
Your right to not blindly trust anything. If the kernel your using doesn't have the correct things set into the "frequency table" then regardless of what you have got SetCPU or OCwidget set to, it will most likely stay at the optimum, even when SetCPU shows otherwise.
There are adb commands you can run to verify it is doing as it has been told,....
I'll have a butchers to see if I can find them again.
EDIT....
adb shell
run "cat /proc/cpuinfo" to get the BogoMIPS
It states the frequency there.
ddotpatel said:
Your right to not blindly trust anything. If the kernel your using doesn't have the correct things set into the "frequency table" then regardless of what you have got SetCPU or OCwidget set to, it will most likely stay at the optimum, even when SetCPU shows otherwise.
There are adb commands you can run to verify it is doing as it has been told,....
I'll have a butchers to see if I can find them again.
EDIT....
adb shell
run "cat /proc/cpuinfo" to get the BogoMIPS
It states the frequency there.
Click to expand...
Click to collapse
thanks, does that command work even when the screen is off ?
StDevious said:
thanks, does that command work even when the screen is off ?
Click to expand...
Click to collapse
I think all adb commands should work regardless of whether the screen is on or off
ddotpatel said:
Your right to not blindly trust anything. If the kernel your using doesn't have the correct things set into the "frequency table" then regardless of what you have got SetCPU or OCwidget set to, it will most likely stay at the optimum, even when SetCPU shows otherwise.
There are adb commands you can run to verify it is doing as it has been told,....
I'll have a butchers to see if I can find them again.
EDIT....
adb shell
run "cat /proc/cpuinfo" to get the BogoMIPS
It states the frequency there.
Click to expand...
Click to collapse
c00ller said:
I think all adb commands should work regardless of whether the screen is on or off
Click to expand...
Click to collapse
ok, that command works with the screen off. But I got BogoMIPS as 526.5 which means the CPU wasn't downclocked when the screen was off.
StDevious said:
ok, that command works with the screen off. But I got BogoMIPS as 526.5 which means the CPU wasn't downclocked when the screen was off.
Click to expand...
Click to collapse
Which rom are you using? What frequencies have you set to for screen off?...
ddotpatel said:
Which rom are you using? What frequencies have you set to for screen off?...
Click to expand...
Click to collapse
I'm using xtrSENSE 3.1. I don't have any overclocking program. Whatever comes default in the ROM, is the speed of the CPU.
StDevious said:
I don't have any overclocking program. Whatever comes default in the ROM, is the speed of the CPU.
Click to expand...
Click to collapse
But in your original post you said
StDevious said:
any app to check that the cpu frequencies are being set to low values that I selected from setCPU while the screen is off ?
Click to expand...
Click to collapse
SetCPU is an overclocking program, and it overrides the frequencies of your ROM.
c00ller said:
But in your original post you said
Click to expand...
Click to collapse
since then I have moved on to having none on xtrSENSE 3.1 ROM. i've updated op, thanks.
ddotpatel said:
Your right to not blindly trust anything. If the kernel your using doesn't have the correct things set into the "frequency table" then regardless of what you have got SetCPU or OCwidget set to, it will most likely stay at the optimum, even when SetCPU shows otherwise.
There are adb commands you can run to verify it is doing as it has been told,....
I'll have a butchers to see if I can find them again.
EDIT....
adb shell
run "cat /proc/cpuinfo" to get the BogoMIPS
It states the frequency there.
Click to expand...
Click to collapse
Code:
adb shell cat /sys/devices/system/cpu/cpu0/cpufreq/scaling_cur_freq
Is another command you can run from your pc while your phone is connected.
It works with both the screen on and off.
nice tips.
adb shell cat /sys/devices/system/cpu/cpu0/cpufreq/scaling_cur_freq
this is more accurate.

[DEV] Power Management

Hi devs
I found something interesting about Android power management..maybe it will help us
http://developer.android.com/reference/android/os/PowerManager.html
http://www.netmite.com/android/mydr...s/power_management.html#androidPowerWakeLocks
and here is a app for users http://forum.xda-developers.com/showthread.php?t=1179809
I found some more things for power management
devs check pls
Enabling system for hitting OFF
#echo 1 > /debug/pm_debug/enable_off_mode
By default sleep_while_idle is set to false and enable_off_mode is set to true
CPU Dynamic Voltage Frequency Scaling settings
Enabling ondemand frequency governor
The ondemand governor enables DVFS(frequency/OPP) transitions based on CPU load.
#echo ondemand > /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor
Enabling performance frequency governor
The performance governor keeps the CPU always at the highest frequency.
#echo performance > /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor
Enabling powersave frequency governor
The powersave governor keeps the CPU always at the lowest frequency.
#echo powersave > /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor
Enabling userspace frequency governor
Once this governor is enabled, DVFS( frequency) transitions will be manually triggered by a userspace application by using the CPUfreq sysfs interface
#echo userspace > /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor
See all the available operating points
#cat /sys/devices/system/cpu/cpu0/cpufreq/scaling_available_frequencies
Application can select any of the available frequency from the above
#echo <Desired Frequancy> > /sys/devices/system/cpu/cpu0/cpufreq/ scaling_setspeed
Checking CPU IDLE states usage
There are seven power states introduced by CPU Idle
The usage and time count for these different states can be checked via
#cat /sys/devices/system/cpu/cpu0/cpuidle/state*/time
#cat /sys/devices/system/cpu/cpu0/cpuidle/state*/usage
Enabling system for hitting OFF
#echo 1 > /debug/pm_debug/enable_off_mode
By default sleep_while_idle is set to false and enable_off_mode is set to true
CPU Dynamic Voltage Frequency Scaling settings
Enabling ondemand frequency governor
The ondemand governor enables DVFS(frequency/OPP) transitions based on CPU load.
#echo ondemand > /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor
Enabling performance frequency governor
The performance governor keeps the CPU always at the highest frequency.
#echo performance > /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor
Enabling powersave frequency governor
The powersave governor keeps the CPU always at the lowest frequency.
#echo powersave > /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor
Enabling userspace frequency governor
Once this governor is enabled, DVFS( frequency) transitions will be manually triggered by a userspace application by using the CPUfreq sysfs interface
#echo userspace > /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor
See all the available operating points
#cat /sys/devices/system/cpu/cpu0/cpufreq/scaling_available_frequencies
Application can select any of the available frequency from the above
#echo <Desired Frequancy> > /sys/devices/system/cpu/cpu0/cpufreq/ scaling_setspeed
Checking CPU IDLE states usage
There are seven power states introduced by CPU Idle
The usage and time count for these different states can be checked via
#cat /sys/devices/system/cpu/cpu0/cpuidle/state*/time
#cat /sys/devices/system/cpu/cpu0/cpuidle/state*/usage
source: http://processors.wiki.ti.com/index.php/Android_Devkit_Power_Management_Porting_Guide
this is very interesting also:
Saving battery time for mobile devices has been a goal for the industry for many years. With the
advent of smartphones, reduction of energy consumption is even more important since they
consume a lot more energy than the generation of mobile phones before them. Consumers are
demanding longer battery life and greener electronics. One way to meet these demands is to
reduce energy consumption.
In order to make the mobile operating system utilize the Central Processing Unit (CPU) more
efficiently, applications should have different reservations based on how much they need to use
the CPU. A challenge the industry is facing is its lack of knowledge of the behavior of third
party applications. Especially since they are an increasing portion of the applications run on
smartphones. Without knowledge of how third party applications behave, it is hard to make
good reservations for them. If there was a way to dynamically make reservations for the
applications with adequate performance while they are running, the system could use this
information to reduce battery consumption by e.g. clocking down the CPU when a high clock
frequency is not needed. In this master thesis project, an open source resource manager called
ACTORS Resource Manager (ACTORS RM) [5][6] for desktop Linux [57] is ported to the
Android [37] operating system. The resource manager is also optimized for the applications
being run there. A power management patch to the Linux kernel was also used to get greater
control over the CPU’s frequency changes.
source: https://rapidshare.com/files/3398178110/Resource_reservation_and_power_management_in_Android.pdf
let's spy on HD2 kernel ?
feature:
AB: Audio Boost
AXI: AXI frequency tweak
BFQ: BFQ IO scheduler (default CFS)
BFS: BFS cpu scheduler (default CFS)
HAVS: Hybrid Adaptive Voltage Scaling (Static Voltage Scaling - SVS is default)
OC: OverClock
UV: UnderVolt
OC, UV and AXI features are the standard feature for EVO based kernel.
EBAT: Extended battery
http://forum.xda-developers.com/showthread.php?t=777921
Edit: after some more research i found out that we are in BIG $h|t,until the f**** HTC will unlock the bootloader and/or update Radio for us
What REALLY improves Android battery life on the HD2
So after all that rambling, the answer is: radio ROM version. When I installed Android, I installed the latest radio ROM available at the time (still the latest I think); i.e. 2.15.50.14, from http://forum.xda-developers.com/showthread.php?t=611787. After pulling my hair out trying all the above, I flashed the radio ROM with 2.12.50.02_2, and as if by magic, current draw under similar conditions to above is about 7mW; i.e. 10% of what it was, and an overnight period as above goes from 100% to 96%. Much better
source:http://forum.xda-developers.com/showpost.php?p=13397376&postcount=1
currently our phones use 150-200 mA (even in standby,and with setCPU on :O)...measured with Current Widget available on Market.
Edit2: Another thing that REALLY improves Android battery life on the HD2 is dumping your girlfriend.
Before, I needed to charge it almost twice a day. Lots of calls and messages.
Now, I can easily get two days of standby. LOL
The radio version on hd2 is a bit tricky. Its very different from people to people. Some people say that its related to your region too.
I dont know if its the same on HD Mini.
But some people here say the dont have battery drain. It would be nice to know what radio version they use and at what region they are.
tzacapaca said:
currently our phones use 150-200 mA (even in standby,and with setCPU on :O)...measured with Current Widget available on Market.
Click to expand...
Click to collapse
But if turn off wifi, gps and phone, consumption almost does not decrease.
Maybe this consumption of sdcard, because its slot is always hot.
ROM-Version (Vodafone)Switzerland German: 1.41.166.1, (10904) Radio:0.63.05.41
Strong battery drain is only after the first boot. after the third boot is the battery drain same as in wi-mo.. same experience with cm6(derefas) ,134++(schlund)
i don't really agree.
under android, the maximum we can expect is to get as much battery life as under winmo.
today, the phone consume too much battery when on sleep, because something prevents it to go sleep.
schlund has a fix for this battery drain, I tested it, it is really efficient.
it will be released in next release, be patient ;-)
regarding the android apps that tells you how much current you have:
it wont work if the phone is really sleeping, because all the apps would be put on sleep.
so you will never know how much your phone consumes when on sleep ;-)
I should say: after the third boot is the battery drain almost the same as in wi-mo , but the truth is that there is a big difference between the first and third boot in battery drain.
New battery Fix, I'm glad to hear.
I understand that it takes time to create something, I have patience but I think it is unfair to announce a new release for the end of the week and then change mind and do not give any explanation. I hope you'll accept this criticism. Thank you
codiak said:
The radio version on hd2 is a bit tricky. Its very different from people to people. Some people say that its related to your region too.
I dont know if its the same on HD Mini.
But some people here say the dont have battery drain. It would be nice to know what radio version they use and at what region they are.
Click to expand...
Click to collapse
well,telling region and radio version won't help with anything,I will not move from my city to get better signal and HTC won't make a new radio only for me too
btw,it's impossible to don't have battery drain when phone use 200mA
i guess people were talking about CM6 of derefas,but his version is based on r146 kernel,which still has battery issues...
p.s. since u own a HD2 also do u mind to test for me with Current Widget and tell me the values in standby and on?I read some guys had 6-7 mA in standby and i think around 60 while it was on
DmK75 said:
But if turn off wifi, gps and phone, consumption almost does not decrease.
Maybe this consumption of sdcard, because its slot is always hot.
Click to expand...
Click to collapse
i'm not an expert but i really think it's impossible sdcard will use 150-200mA,if it was so then we will have 5-6 hours battery life in WM
Edit: after little research i found this ->
Metric NAND SD
Idle (mW) 0.4 1.4
Read
throughput (MiB/s) 4:85 2:36
efficiency (MiB/J) 65.0 31.0
Write
throughput (KiB/s) 927:1 298:1
efficiency (MiB/J) 10.0 5.2
so SD cards use around 1,4 mW when idle and 2,36 mW when read from it(our case)
and to convert mW to mA-> http://www.ehow.com/how_8627497_convert-mw-ma.html
source: http://www.usenix.org/events/usenix10/tech/full_papers/Carroll.pdf
-r0bin- said:
i don't really agree.
under android, the maximum we can expect is to get as much battery life as under winmo.
today, the phone consume too much battery when on sleep, because something prevents it to go sleep.
schlund has a fix for this battery drain, I tested it, it is really efficient.
it will be released in next release, be patient ;-)
regarding the android apps that tells you how much current you have:
it wont work if the phone is really sleeping, because all the apps would be put on sleep.
so you will never know how much your phone consumes when on sleep ;-)
Click to expand...
Click to collapse
i'm not really agree with u too
Current Widget runs as a process,and processes are on even if Android is in suspended,no?for ex clock,alarm,etc
15MA1L said:
ROM-Version (Vodafone)Switzerland German: 1.41.166.1, (10904) Radio:0.63.05.41
Strong battery drain is only after the first boot. after the third boot is the battery drain same as in wi-mo.. same experience with cm6(derefas) ,134++(schlund)
Click to expand...
Click to collapse
lol I think that's placebo or else why would number of boots/reboots will improve the battery life?
tzacapaca said:
well,telling region and radio version won't help with anything,I will not move from my city to get better signal and HTC won't make a new radio only for me too
btw,it's impossible to don't have battery drain when phone use 200mA
i guess people were talking about CM6 of derefas,but his version is based on r146 kernel,which still has battery issues...
p.s. since u own a HD2 also do u mind to test for me with Current Widget and tell me the values in standby and on?I read some guys had 6-7 mA in standby and i think around 60 while it was on
Click to expand...
Click to collapse
I get about 3-7 mA with all on (GPS, BT, 3G etc). Sometimes there are peaks to around 60 mA that are related to mailcheck etc. Its roundabout 1-2% per Hour what is fine to me
codiak said:
I get about 3-7 mA with all on (GPS, BT, 3G etc). Sometimes there are peaks to around 60 mA that are related to mailcheck etc. Its roundabout 1-2% per Hour what is fine to me
Click to expand...
Click to collapse
u see?
this is what i'm talking about,u can't compare 3-7 mA to 150-200 mA..so i can't understand guys who said they have power usage same as on WM...
btw,that was in suspend or while display was on?
Thats with display off. When using it the value is very variable depending on what you are doing. From ~120 to ~350 mA.
tzacapaca said:
u see?
this is what i'm talking about,u can't compare 3-7 mA to 150-200 mA..so i can't understand guys who said they have power usage same as on WM...
btw,that was in suspend or while display was on?
Click to expand...
Click to collapse
lol ok
i read somewhere that the sdcard was using 10 to 50mA max, i dont think it uses so much. maybe someone using HD2 with Haret (on sdcard) could lighten us?
which application are they using to get those values, and how to read those values if screen is off?
codiak said:
Thats with display off. When using it the value is very variable depending on what you are doing. From ~120 to ~350 mA.
Click to expand...
Click to collapse
ok,thanks
what about when with display on and doing nothing?
I used an SD build on my HD2 before using the NAND Rom. The values where nearly the same. So I dont think sdcard has a big impact on battery.
I use this App from the Market. It logs to a file and you can view the history
tzacapaca said:
what about when with display on and doing nothing?
Click to expand...
Click to collapse
Then its around 120 mA.
But remember, HD2 has a BIG display
I don`t know, maybe it will be usefull for developers. I tested CM6 r146 releace from derefas.
All night in sleep mode it takes 10-15% of accum. Then I use it for maybe 4-5 hours, and android said that charge is needed (it was near 15%). Putting on charge, don`t bring any result, I wait for half an hour, no persets where moving.
Then I reboot the device i n WinMo and it shows me 70%, after it i use winmo for 2 days without charging...
It seems to me that the problem is with indicator... in my situation there was a good accum, but android don`t see it...
P.S. Sorry, if i am talking silly things

CM10.1 CPU frequencies not sticking

I'm currently using CM10.1 AOSP [KANG] from the thread here -- http://forum.xda-developers.com/showthread.php?t=2115520. In essence, I cannot raise either the minimum or maximum CPU speeds above 384MHz.
I just tried restoring my phone using a RUU recovery.exe file, then re-rooted, S-OFF'd, unlocked the bootloader and then updated the firmware. Right after flashing CM10.1, I am still having issues with changing the CPU speed. The maximum and minimum CPU speeds I can choose are either 192MHz or 384MHz. I can go into settings > performance then change the maximum CPU speed to anything higher than that, but almost instantly after I select it the maximum CPU speed drops back down to 384 MHz. The same goes for trying to raise the minimum CPU speed above 384MHz. It makes the phone nearly unusable, as it takes multiple seconds to open almost any application and also reboots randomly quite often. Is there any way I can fix this?
Thanks!
Anyone have ideas/insight? Sorry to bump this!
Right. Here's what I did last time. I used something called SetCPU. Ticked the Set On Boot then it worked. But I unticked the ones in the Performance option.
This is what I do. Hope I help.
if you want do this also
go to system>etc>init.qcom.post_boot.sh and put this line(you can edit with simple text editor)
echo the value > /sys/devices/system/cpu/cpu0/cpufreq/scaling_max_freq
do the same for cpu1 if you want to have the same frequency in both cpu

*ROOT ONLY* Honor 5X Marsmallow battery tweak.

Im not responsible for any behavior like the Note 7, if its explodes while applying the tweak its not my fault!
This tweak will edit a simple file so that the minimum cores get decreased and we wont get unnecessary battery drain
ROOT ONLY!
Manual Guide:
1. Make sure your device has root acces,
2. Install Root Browser from the playstore.
3. Open the app and navigate to > sys/devices/system/cpu/cpu0/core_ctl
4. Search for the file min_cpus make sure the permissions are set to rw-r-r (it showsup under the file name).
5. Open min_cpus and change the number '4' to '0', This will say to the CPU that a minimal of 1 cpu core is needed to be active instead of 4 all the time.
6. Save the file and navigate back to > sys/devices/system/cpu/cpu0/core_ctl and change the permissions back to r-r-r.
7. Your device will still run 'smooth' and safe some battery! You have to apply this every single reboot or need to make a init.d script and make it run every single reboot..
You can also use the provided script in the "Attached Files" section. If you use a script runner you dont have to follow the Manual guide everytime you boot.
Share what you think, any feedback is appreciated!
Thanks, so i did the steps 1 to 6, and the contents of that folder disappear, is that normal? I restart the phone and the files appear and i did the same steps the files disappear again.
danino22000 said:
Thanks, so i did the steps 1 to 6, and the contents of that folder disappear, is that normal? I restart the phone and the files appear and i did the same steps the files disappear again.
Click to expand...
Click to collapse
What content? Im not sure what you mean..
Demian3112 said:
What content? Im not sure what you mean..
Click to expand...
Click to collapse
The files inside core_ctl folder disappear.
danino22000 said:
The files inside core_ctl folder disappear.
Click to expand...
Click to collapse
It shouldnt what device do you have Kiw l21? MM or LP? Open kernel adiutor or something else and see how the cores behave make sure battery settings is on Performance. Not much what i can do other wise..
Kiw l24 MM last update from honor UK support page. For example in kernel adiutor if i want to change the min frequency to 200mhz or any other, the settings won't apply, it return to the original frequency after few secs.
SOT ?? @Demian3112
danino22000 said:
Kiw l24 MM last update from honor UK support page. For example in kernel adiutor if i want to change the min frequency to 200mhz or any other, the settings won't apply, it return to the original frequency after few secs.
Click to expand...
Click to collapse
You cant set big cluster. For small cluster go to sys/devices/system/cpu/cpu4/cpufreq/ and look for min freq set permissions to rw-r-r open it change value 800000 to 200000 save it change permissions back to r-r-r
kartrikpal said:
SOT ?? @Demian3112
Click to expand...
Click to collapse
Havent measured. I safe about 3-8% in an hour doing the same stuff youtube, google, whatsapp and facebook etc. It really depends on what you are doing.
Little cluster runs idle 800mhz with the tweak 200mhz
Big cluster has 8 cores active all the time, with this tweak 0 in idle/simple tasks. It only enables when needed
Just try it out yourself. If you dont like it remove kernal adiutor restart device and tweaks are undone
doesn't seem like little clusters settings are sticking in Kernel aduiter. When changes to 200mhz, it automatically get changed back to 800mhz min
halfacannoli said:
doesn't seem like little clusters settings are sticking in Kernel aduiter. When changes to 200mhz, it automatically get changed back to 800mhz min
Click to expand...
Click to collapse
Make site battery manager is on performance.. i dont Have this issue and i Just upgrades to B330
Demian3112 said:
Make site battery manager is on performance.. i dont Have this issue and i Just upgrades to B330
Click to expand...
Click to collapse
Thanks for the fast response. However, that did not work for me initially. I was able to resolve the issue and it looks like I was able to set the frequency for the big cores as well. As a preface, I have the L24 and updated to MM EMUI 4 through the zip that was found on the hihonor UK website. After the update I did a factory reset. I am just letting you know because some of things you described didn't work while other things did.
What did work was setting the Mincpu to 0, so that when idle only 1 core is running. This worked great, so thanks for that! However, in Kernel Aduiter, I had to set the governor to Interactive for it to use the other Big cores when I am using the phone. If I set it to ondemand, the other 3 big cores does not activate, only core 1 is used along with the 4 little cores.
What did not work per your instructions were setting the min frequencies for the little cores. Yes, I changed the Power option to performance, but every time I exited the kernel auditer, it would revert back to a min frequency of 800mhz.
After tinkering with the phone for a couple of days, I was able to set the min frequency to 200mhz for BOTH big cores and little cores and it seems that both settings are sticking. Throughout the 2 days, I did many changes so I have yet to narrow it down to what changes I did that made both changes stick. When I have some time I will try to reproduce the results and post on how I got it to work. I would also like to give it a few days to make sure that the changes stick.
---------- Post added at 10:22 PM ---------- Previous post was at 10:13 PM ----------
danino22000 said:
The files inside core_ctl folder disappear.
Click to expand...
Click to collapse
it disappears because permission was changed to r-r-r which is read only. change permission to include w (write) and execute, and you'll see it again
halfacannoli said:
doesn't seem like little clusters settings are sticking in Kernel aduiter. When changes to 200mhz, it automatically get changed back to 800mhz min
Click to expand...
Click to collapse
Got to battery manager and set it to performance.
Can someone make an script to keep this installed upon boot? Thanks.
Robertleehadley said:
Can someone make an script to keep this installed upon boot? Thanks.
Click to expand...
Click to collapse
If i have time i will do it!
Nice tweak on changing 4 to 0 at min_cpus but Root Browser (w/Root and Grant) refused to save it so i used X-plore by Michal Baclk Version: 3.86.02 Build Date: 7/16/16 and it took perfectly!
Thanks for the other kernel adjustments too.
anyone ever make that bat file?
And has anyone tried setting CPU4 the same way as suggested for CPU0? By default, it is set to 1.
I'm also a little concerned I may not have understood the directions properly...
From what I read, it looks like you are ignoring the large cores and only modifying the little ones? Am I understanding that correctly?
And why can't we just tick the 'use this on boot' in kernel aduitor? Why does it need to be reset upon every boot? I mean, we are doing these steps with ROOT access, are we not? Shouldn't the file stay modified? I am quite confused... but very eager to get more battery life out of this... was shocked to see that all 8 cores are always on... and my device NEVER hit deep sleep or any of the slower frequencies all day!
No wonder I can drop to 85% within an hour. Sheesh... this blows.
Ok, I played with it some more...
Looks like Root access has nothing to do with modifying that file. Yes, you need root to modify it... but it never stays changed after a reboot. This tells me that this area must be a hardware toggle area. Meaning, there's some place with the default value stored, and is loaded from there to this location during boot.
I did my best to follow all these steps.
upon reboot, every single thing I put in is lost. Kernel Aduitor seems to lose my settings even if I check 'apply on boot'.
furthermore, all 8 cores are still on.
True, I *do* now see that all the big cores aren't *always* on... but it isn't very different from before doing these steps (at least now I can see a core or 2 shutoff for all of about a tenth of a second)
The little cores... they looked like they took the settings the best... until I closed Kernel Aduitor and reopened it... all the settings reverted.
Yep, waiting with anticipation for some guru who is best at putting something together to set all those freq.'s and such that will apply all of them and keep settings.
Very useful battery mod if it can be made to apply and hold up after restarts.
Yes the hotplug drivers and govenors change it back this is something within the kernal thst you cant edit without needing to flash another rom.. Im on CM13 and batttery has improved quite a bit.. Just give it a try its my daily driver now and its smooth as hell..
Demian3112 said:
Yes the hotplug drivers and govenors change it back this is something within the kernal thst you cant edit without needing to flash another rom.. Im on CM13 and batttery has improved quite a bit.. Just give it a try its my daily driver now and its smooth as hell..
Click to expand...
Click to collapse
Without or before flashing a better ROM, did this item ever get worked out whether by another way to make settings stick or a Huawei small update? Thanks for any advice.
Sent from my MT2L03 using Tapatalk

Categories

Resources