FORUMS
Remove All Ads from XDA

[MOD][XPOSED][4.0+] CPUFreq in Statusbar

34 posts
Thanks Meter: 36
 
By coax75ohm, Member on 27th August 2014, 02:26 PM
Post Reply Email Thread
While playing around with governor settings I wanted something to display CPU frequency. Rather than start from scratch I looked around and found m11kkaa's CpuTemp in Statusbar module, so many thanks to him. Using that as the base I then simply tweaked it to display CPU frequency.

Screenshots:






Version 1.1 changes:
* fixed preference initialization
* added font size option
* added vertical alignment option
* text display tries to set a minimum (fixed) width, requires kernel cpufreq with scaling_available_frequencies or stats/time_in_state
* doesn't run update when status bar is hidden (requested by aness zurba)
* removed theme override
* added custom icon
* added logging option
* misc small tweaks and clean up


Source: https://github.com/coax75ohm/CPUFreqStatusbar
Download: http://dl-count.xposed.info/modules/..._v2_57c2a1.apk
The Following 19 Users Say Thank You to coax75ohm For This Useful Post: [ View ] Gift coax75ohm Ad-Free
 
 
27th August 2014, 02:39 PM |#2  
exodius48's Avatar
Senior Member
Flag Yori's Heart
Thanks Meter: 633
 
Donate to Me
More
Some screenies would be nice.
27th August 2014, 04:25 PM |#3  
coolhof's Avatar
Senior Member
Flag Brabant.
Thanks Meter: 308
 
More
Great.
It's working.
Only if I select left, it stays right.
And on absolute left its moving to the left but chances the font.
Maybe it conflicts with other xposed apps, I have a bunch of them.
S3 i9300
Jb 4.3

Edit:
Font issue fixed.
Only left stays richt.
27th August 2014, 05:08 PM |#4  
Senior Member
Flag Bushbuckridge
Thanks Meter: 125
 
More
Tested it on Note 10.1. I can confirm it's working well, wonderful man

---------- Post added at 06:08 PM ---------- Previous post was at 06:00 PM ----------

A question though, is it possible to make it not sure the frequency as a number not rounded to 100 ' s as mine just keeps on showing 1000M, 700M, 500M etc. Nothing like maybe 734M or 553M. I hope you get what I mean
27th August 2014, 10:35 PM |#5  
Member
Thanks Meter: 17
 
More
works perfectly

thanks a lot !!!
28th August 2014, 03:33 AM |#6  
coax75ohm's Avatar
OP Member
Thanks Meter: 36
 
More
Quote:
Originally Posted by Skhulile

A question though, is it possible to make it not sure the frequency as a number not rounded to 100 ' s as mine just keeps on showing 1000M, 700M, 500M etc. Nothing like maybe 734M or 553M. I hope you get what I mean

Hmm, there's no rounding function used. Could you tell me if you're using cpuinfo_cur_freq or scaling_cur_freq, and the output of the following command:
Code:
cat /sys/devices/system/cpu/cpu0/cpufreq/scaling_available_frequencies
28th August 2014, 02:18 PM |#7  
Senior Member
Flag Bushbuckridge
Thanks Meter: 125
 
More
Quote:
Originally Posted by coax75ohm

Hmm, there's no rounding function used. Could you tell me if you're using cpuinfo_cur_freq or scaling_cur_freq, and the output of the following command:

Code:
cat /sys/devices/system/cpu/cpu0/cpufreq/scaling_available_frequencies

I'm using cpuinfo_cur_freq and this is the output I get, don't know if I typed something wrong:

127|[email protected]:/ $ cat /sys/devices/system/cpu/cpu0/cpufreq/scaling_available_frequencies
/system/bin/sh: cat: /sys/devices/system/cpu/cpu0/cpufreq/scaling_available_frequencies: No such file or directory
1|[email protected]:/ $
28th August 2014, 03:42 PM |#8  
coax75ohm's Avatar
OP Member
Thanks Meter: 36
 
More
Quote:
Originally Posted by Skhulile

I'm using cpuinfo_cur_freq and this is the output I get, don't know if I typed something wrong:

127|[email protected]:/ $ cat /sys/devices/system/cpu/cpu0/cpufreq/scaling_available_frequencies
/system/bin/sh: cat: /sys/devices/system/cpu/cpu0/cpufreq/scaling_available_frequencies: No such file or directory
1|[email protected]:/ $

To quote the kernel docs "There is a round-off error associated with the cpuinfo_cur_freq value. Since the driver obtains the current frequency as a "percentage" (%) of the nominal frequency". My kernel only provides scaling_cur_freq so I can't really test that. Though it's odd that your /sys directory has a different layout, thought it was pretty standard for cpufreq. Would you try this:
Code:
find /sys -name cpuinfo_max_freq -print -exec cat {} \;
28th August 2014, 06:43 PM |#9  
Senior Member
Flag Bushbuckridge
Thanks Meter: 125
 
More
Quote:
Originally Posted by coax75ohm

To quote the kernel docs "There is a round-off error associated with the cpuinfo_cur_freq value. Since the driver obtains the current frequency as a "percentage" (%) of the nominal frequency". My kernel only provides scaling_cur_freq so I can't really test that. Though it's odd that your /sys directory has a different layout, thought it was pretty standard for cpufreq. Would you try this:

Code:
find /sys -name cpuinfo_max_freq -print -exec cat {} \;

Here you go:

[email protected]:/ $ find /sys -name cpuinfo_max_freq -print -exec cat {} \;
/sys/devices/system/cpu/cpu0/cpufreq/cpuinfo_max_freq
1400000
[email protected]:/ $
28th August 2014, 09:46 PM |#10  
coax75ohm's Avatar
OP Member
Thanks Meter: 36
 
More
Quote:
Originally Posted by Skhulile

/sys/devices/system/cpu/cpu0/cpufreq/cpuinfo_max_freq
1400000

Ok, so it looks like you have the standard cpufreq path, but not scaling_available_frequencies. For the rounding issue, it must just be lots of zeroes in your max_freq combined with the percentage basis of cpuinfo_cur_freq.
28th August 2014, 09:49 PM |#11  
Senior Member
Flag Bushbuckridge
Thanks Meter: 125
 
More
Quote:
Originally Posted by coax75ohm

Ok, so it looks like you have the standard cpufreq path, but not scaling_available_frequencies. For the rounding issue, it must just be lots of zeroes in your max_freq combined with the percentage basis of cpuinfo_cur_freq.

Anyway I can change it? So it does not round it off
Post Reply Subscribe to Thread

Guest Quick Reply (no urls or BBcode)
Message:
Previous Thread Next Thread
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes