FORUMS

HTC’s New Ad Campaign And What It Really Means

HTC has just released three new blind test adverts comparing app loading … more

XDA Picks: Best Apps of the Week (June 27 – July 4)

Apps are at the front and center of any smartphone experience, and with over a … more

HTC One M9 Developer Edition Android 5.1 OTA

The Developer Edition of the HTC One M9 is receiving an over-the-air update to Android 5.1. … more

Index Project For XDA Device Subforums

Another ambitious project from the collaborative efforts of Recognized Contributors and Forum … more

[APP][LESS BASIC] Transformer Battery Widget (V2.1.1 12/06/11)

387 posts
Thanks Meter: 72
 
By Highland3r, Senior Member on 6th June 2011, 10:01 AM
Post Reply Subscribe to Thread Email Thread
*Disclaimer*
The widget is very much a "beta"/"test". It come's as is. If it doesn't work/does weird stuff I'll try and investigate but won't make any promises.
Happy to listen to feature/improvement requests but they may not ever be implemented.
I'm new to Android Development (although not to java/development as a whole) so this is a learning exercise for personal knowledge gain.
*Disclaimer*

Now the excuses are out of the way, widget is attached.
Should be a case of installing and the widget will then be available. Some people have reported a reboot is required before the widget is visible

Tested against a ROOTED version of Prime! V1.4, also works fine on stock 3.1
Not working with clemsyn-blades cusom kernel (Widget reports dock as unplugged. Looks like a kernel issue rather than a widget/app problem)
Tested up to version 3.2 with no issues. Also working on ics (galaxy nexus)
Source code can be made available if anyone wants a laugh.

Added Configurable text size and color in V2.1
Enter a valid color (List - red, blue, green, black, white, gray, cyan, magenta, yellow, lightgray,darkgray) in the first box
Enter a valid textsize in the second. 20 is about right (was the default for v1.3 of widget)
There's some basic validation added, if you get a force close on config it's likely you've entered something wrong.
Planning on beefing up validation & available config shortly.



Downloads
Version 1.3
White - http://db.tt/DhjaUEA
Black - http://db.tt/RcPWpjq

Version 2.1.1
http://db.tt/8vAFlAh

--------------------------------
Code:
ChangeLog:
V1.3 - Initial Release
V2.0.1 - Added Basic Size & Color config.
            Added Shadow to Text
            Small change to Widget Sizes
V2.1    - Internal Modifications.
V2.1.1  - Fixed issues with preferences being lost
The widget is based off code from the following two sources -

Modifications were required to get the dock readout to work properly.
http://android-er.blogspot.com/2010/...ry-widget.html
http://www.tutorialforandroid.com/20...n-android.html
Last edited by Highland3r; 20th November 2011 at 09:56 AM. Reason: add ics compatibility info
The Following 37 Users Say Thank You to Highland3r For This Useful Post: [ View ]
 
 
6th June 2011, 11:29 AM |#2  
Senior Member
Thanks Meter: 15
 
More
Seems to work on stock UK 3.1 just fine.
The Following User Says Thank You to rilot For This Useful Post: [ View ]
6th June 2011, 12:27 PM |#3  
Mr.Clark's Avatar
Senior Member
Thanks Meter: 40
 
More
Awesome!

MoDaCo 3.1 ROM, I had to reboot after installing to get it to show up in the list of widgets, but it's there, it's resizable, it's really bloody useful!

Thanks!
6th June 2011, 01:58 PM |#4  
Senior Member
Thanks Meter: 17
 
More
Thumbs up
Great app! Resizeable at that! Makes you wonder why Asus took the feature out of the beta firmware that was released prior to the one that fixed the dock issues.

Thanks much Highland3r
6th June 2011, 02:34 PM |#5  
Senior Member
Flag Le Chesnay
Thanks Meter: 8
 
More
Using primordial 3.1 and clemsyn-blades kernel it shows "detached" for the dock
6th June 2011, 02:38 PM |#6  
OP Senior Member
Thanks Meter: 72
 
More
Quote:
Originally Posted by gniouki

Using primordial 3.1 and clemsyn-blades kernel it shows "detached" for the dock

Open terminal on your tablet and paste the following command:

Code:
logcat BatteryService:D *:S
Paste the output (or a few lines of it) back here.
6th June 2011, 02:50 PM |#7  
Senior Member
Flag Le Chesnay
Thanks Meter: 8
 
More
the command doesn't work

edit : ok I tried again and i get that :

Quote:

# export PATH=/data/local/bin:$PATH
# logcat BatteryService *:S
--------- beginning of /dev/log/system
D/BatteryService( 149): level:100 scale:100 status:5 health:2 present:true dock_status:1 dock_level:0 voltage: 8 temperature: 278 technology: Li-ion AC powered:true USB powered:false icon:17302721 invalid charger:0
D/BatteryService( 149): level:100 scale:100 status:5 health:2 present:true dock_status:1 dock_level:0 voltage: 8 temperature: 279 technology: Li-ion AC powered:true USB powered:false icon:17302721 invalid charger:0
D/BatteryService( 149): level:100 scale:100 status:5 health:2 present:true dock_status:1 dock_level:0 voltage: 8 temperature: 280 technology: Li-ion AC powered:true USB powered:false icon:17302721 invalid charger:0
--------- beginning of /dev/log/main
D/BatteryService( 149): level:100 scale:100 status:5 health:2 present:true dock_status:1 dock_level:0 voltage: 8 temperature: 281 technology: Li-ion AC powered:true USB powered:false icon:17302721 invalid charger:0

Last edited by gniouki; 6th June 2011 at 02:55 PM.
6th June 2011, 02:51 PM |#8  
OP Senior Member
Thanks Meter: 72
 
More
Quote:
Originally Posted by gniouki

the command doesn't work

Do you get any errors? What's the output when you attempt to run the command?
6th June 2011, 02:59 PM |#9  
Member
Thanks Meter: 8
 
More
just installed with no issues! Looks like it's running great, thanks man that helps out a ton.
6th June 2011, 03:00 PM |#10  
Senior Member
Flag Le Chesnay
Thanks Meter: 8
 
More
updated my post, juste quit an launch back terminal and it works
Post Reply Subscribe to Thread
Previous Thread Next Thread
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes