Underclock processor to save battery?
Is there any app or an easy way to underclock processor speed as and when needed (not always) to save battery?
Edit: I use Intex Aqua Fish running on 2.0.2.51
We have moved to a new Sailfish OS Forum. Please start new discussions there.
Is there any app or an easy way to underclock processor speed as and when needed (not always) to save battery?
Edit: I use Intex Aqua Fish running on 2.0.2.51
Which device do you have? Either way the answer is the same:
It already does this. You have a CPU governor that clocks down or up the CPU depending on load. You can experiment with this to conserve some power at the expense of performance (make it more reluctant to scale up with load) but in general the savings will be small.
If you have developer mode activated you can in the terminal check the governor in use like this:
# devel-su
# cat /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor
This may have several values, for example ondemand or interactive. for more info see the kernel documentation or specifically the additions for the interactive governor.
And there are several applications in the Jolla store to check the current frequency, AIDA64 is one example.
Hello! Scaling down or using a power_save_governor sounds like "energy saving" but in practive this is often not the case. If you slow down your processor, it will take more time to fullfill it tasks and therefore more time until it can go into a deep sleep states. A well known example is the p_state driver from Intel, basically it let the processor decide upon the tasks pending, current power consumption and used cores how much voltage and clockspeed it wants. It aim is it, to finish the work as fast as possible without wasting to much energy and then go to sleep and stay there as long as possible.
There are better ways to save energy:
Reduce display brigthness, turn off bluetooth or wifi, avoid using GPS and prefer cell-tower based services for location, turn off Android-Support...
Hence I guess deep sleep state entering / exiting should perhaps be done at full speed ?
tortoisedoc ( 2016-11-11 14:46:33 +0200 )editAs stated in my answer, I have made the observation myself that there is not much effect in using the governor. My benchmark has always been over-night flight mode. The value of ~8% drainage per night was not changed at all on my JollaC, and the likewise 1~2% of my Jolla1 still never have been reached on JollaC yet, whatever measures I took.
lakutalo ( 2016-11-11 16:35:46 +0200 )editWhether underclocking would save energy depends on the nature of the wakeup. If all activities are done on device and are CPU bound, you probably are right. If your device woke up to check emails and do some other things that require longer wait for I/O, underclocking could be a wise choice. In flight mode, probably most activities are local - hence your results.
rinigus ( 2016-11-14 08:56:16 +0200 )editHowto change "scaling_governor" and "scaling_min_freq" (idea is posted here)
Create the backup of
"/system/etc/init.qcom.post_boot.sh"
Change "/system/etc/init.qcom.post_boot.sh" in the case for MSM8909 like this:
case "$target" in
"msm8909")
...
# disable thermal core_control to update scaling_min_freq
...
echo "ondemand" > /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor
echo 200000 > /sys/devices/system/cpu/cpu0/cpufreq/scaling_min_freq
...
# Bring up all cores online
...
echo 1 > /sys/module/lpm_levels/parameters/sleep_disabled
Restart your phone.
Check:
cat /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor
cat /sys/devices/system/cpu/cpu0/cpufreq/scaling_min_freq
You can find a how-to in answers
https://together.jolla.com/question/140203/202x-battery-drain/
There seems to be a possibility to change settings of the cpu scaling governor, but I am not sure if this really works, as I have not been able to test it positively.
A very interesting thread on this issue can be found here: https://together.jolla.com/question/139036/intex-aqua-fish-battery-life/?answer=139079#post-id-139079
This thread is public, all members of Together.Jolla.Com can read this page.
Asked: 2016-11-11 13:42:31 +0200
Seen: 2,179 times
Last updated: Nov 14 '16
phone loses battery charge or suddenly turns off [duplicate]
Why does my battery last for max 5 hours? [not relevant]
indiegogo for a new Jolla battery ?
Energy consumption. [answered]
The phone will not stay on with a flat battery even with charger connected [answered]
[BUG?] Taking picture with flash in low charge state causes shutdown
Update 1.0.3.8 - battery fix means new specs?
All of a sudden: battery drain [not relevant]
Immediate battery level drop from more than half- charged to empty
Powersave mode does that.
objectifnul ( 2016-11-11 14:20:16 +0200 )edit@objectifnul, where do you set Powersave mode yourself?
lakutalo ( 2016-11-11 16:37:28 +0200 )edit@lakutalo You may use this
objectifnul ( 2016-11-11 16:51:01 +0200 )edit