Introducing XDA:DevCon – A Conference For Developers By Developers
XDA Developers Android and Mobile Development Forum
Forgot your password?
 
Post Reply+
Tip us?
 
heydabop
Old
#1  
heydabop's Avatar
Senior Member - OP
Thanks Meter 31
Posts: 148
Join Date: Jan 2011

 
DONATE TO ME
Default [Q] 1% Battery in Status Bar

bandroidx and I have been looking at this without much success so far. Anyone know how to get the system and thus OS to read 1% battery increments? The information exists on the phone, at least in /sys/class/power_supply/battery/charge_counter but I'm not sure how to get the status bar/system to update with that information. I've checked framework-res.apk XML files and the icons are there with my theme if the system would report 1% increments.

Any ideas?
 
zachthepack
Old
#2  
Senior Member
Thanks Meter 2
Posts: 114
Join Date: Jan 2011
I've wanted this since I got the phone. I never really saw the point in the large increments.

Sent from my MB520 using XDA Premium App
 
TPR300C
Old
#3  
Senior Member
Thanks Meter 4
Posts: 145
Join Date: Apr 2010
Location: Anaheim
Might want to reach out to some of the Droid developers. Many roms on their phones show the 1% increment when the phone doesn't when its stock. I've seen most Moto phones are like that. Maybe they know what can help.
 
jorgonv
Old
#4  
jorgonv's Avatar
Senior Member
Thanks Meter 136
Posts: 241
Join Date: Sep 2010
All you have to do is edit the the stat_sys_battery.xml and the stat_sys_battery_charge.xml. Then you have to create 100 (or however many increments you want) battery icons (.pngs). Look at the decompiled xmls and the framework-res.apk from a rom with 1% increments.
Attached Files
File Type: zip DecompiledBatteryXmls.zip - [Click for QR Code] (1.9 KB, 21 views)
File Type: apk SmoothBatteryframework-res.apk - [Click for QR Code] (5.44 MB, 20 views)

Custom Nexus Wallpaper Chooser App
 

Galaxy Nexus LTE PARANOIDANDROID 2.99.7

 
sdrawkcab3
Old
#5  
Senior Member
Thanks Meter 17
Posts: 133
Join Date: Feb 2008
Minimalistic text can report battery by 1% intervals on bravo. Maybe get in touch with the dev of that?
 
heydabop
Old
#6  
heydabop's Avatar
Senior Member - OP
Thanks Meter 31
Posts: 148
Join Date: Jan 2011

 
DONATE TO ME
Quote:
Originally Posted by jorgonv View Post
All you have to do is edit the the stat_sys_battery.xml and the stat_sys_battery_charge.xml. Then you have to create 100 (or however many increments you want) battery icons (.pngs). Look at the decompiled xmls and the framework-res.apk from a rom with 1% increments.
I already looked at those, I've got files and icons for it, the problem is that whatever value the system uses to determine what file to show only goes in 10% increments.
 
rdannar
Old
#7  
rdannar's Avatar
Senior Member
Thanks Meter 986
Posts: 1,442
Join Date: Sep 2009

 
DONATE TO ME
did you try system apk some of the apk affect status bar

Sent from my MB520 using XDA App
 
mikiemc73
Old
#8  
mikiemc73's Avatar
Senior Member
Thanks Meter 14
Posts: 111
Join Date: Jun 2009
Default info from the battery

I have a battery monitor widget app on my bravo(stock ROM) that reports 1% increments, but it doesn't show up in the status bar.
"https://market.android.com/details?id=ccc71.bmw"
You will have to copy and paste, cause I haven't posted enough. But I will fix that soon.
 
rdannar
Old
#9  
rdannar's Avatar
Senior Member
Thanks Meter 986
Posts: 1,442
Join Date: Sep 2009

 
DONATE TO ME
Just have to edit XML file in frameworkres to match the lib androidserver.so

Sent from my MB520 using XDA App

 
Post Reply+
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Go to top of page...

XDA PORTAL POSTS

Job Interview Prep: Phone Screen Part 1 – XDA Developer TV

XDA Developer TV Producer Jayce has been very busy creating videos to help … more

Auto Test Your Android Apps with Robotium

You’ve just finished coding your very first app, but before you release it to the wild, you … more

Open Source CPU Info App for Windows

So you’re playing with your shiny new Windows 8 tablet PC, when one of your like-minded geeky … more

Guide to Using Adobe Air on Android

When writing an app with performance in mind, you most likely want to write it native code using the … more