maemo.org - Talk

maemo.org - Talk (https://talk.maemo.org/index.php)
-   Applications (https://talk.maemo.org/forumdisplay.php?f=41)
-   -   Pybattery - battery statusbar applet with candies (https://talk.maemo.org/showthread.php?t=24905)

412b 2009-01-14 21:57

Re: Pybattery - battery statusbar applet with candies
 
Quote:

Originally Posted by allnameswereout (Post 257637)
That is what I'm doing right now, but this is hard to do objectively because the usage paterns differ. :(

Can you post the output of
Code:

hal-device /org/freedesktop/Hal/devices/bme | grep reporting.design
command?

allnameswereout 2009-01-14 22:25

Re: Pybattery - battery statusbar applet with candies
 
stock battery,
battery.reporting.design = 1540 (0x604) (int)
mugen,
battery.reporting.design = 1546 (0x60a) (int)

BrentDC 2009-01-15 00:25

Re: Pybattery - battery statusbar applet with candies
 
Quote:

Originally Posted by 412b (Post 257642)
I'm still thinking about own time left algorithm (TLA)... On the one hand it would great not to deal with Nokia's time left stuff anymore, on the other hand... On the other hand AP is splitting into 2 packages:
- Advanced Power Monitor (APM) (a daemon (still written in Python, but C looks more and more attractive), which gets all the info and uses D-Bus to notify about changes and get values). Mainly for cross-project and cross-application usage. I want to keep APM lightweight as much as it can be using Python for such things.
- Advanced Power (GUI's statusbar item).
That splitting is my #1 at the moment. To my mind implementing a statistics based TLA is the thing to be done, but I'm not sure, if it gonna be in APM-0.3.5, may be in APM-0.3.6.
In fact ideas about other possible algorithms are welcomed ;)

Heh, kinda funny. Just the other day, in another thread, I have taken up the task of writing a better battery_level and time_left algorithm; it is being written in python, also.

At this point I just wrote a simple script that polls retu every minute and records the data into an Openoffice importable csv file (so I can graph results). All of this is for research purposes so I can better understand how the battery works so I can better predict how long it'll last.

I'll let you know if I come up w/something.

edit: here's the aforementioned mentioned thread: http://internettablettalk.com/forums/showthread.php?p=257324

pton 2009-01-15 03:58

Re: Pybattery - battery statusbar applet with candies
 
Hi, one feature suggestion. I would like to be reminded to charge the battery when it fall under a certain percentage, say 25%. If you could change the battery icon (say different color or something prominent), then it would be easy for me to tell whether its time to charge or not. :) Oh, it would be best if you could make the 'Reminder to charge' value changeable by end user.

davidgro 2009-01-15 04:17

Re: Pybattery - battery statusbar applet with candies
 
Quote:

Originally Posted by pton (Post 257717)
Hi, one feature suggestion. I would like to be reminded to charge the battery when it fall under a certain percentage, say 25%. If you could change the battery icon (say different color or something prominent), then it would be easy for me to tell whether its time to charge or not. :) Oh, it would be best if you could make the 'Reminder to charge' value changeable by end user.

Adding to this suggestion, I would prefer a loud sound -- it should even max out the volume temporarily -- and with repetitions if ignored (perhaps once every 5% drop unless I acknowledge it?). Most of the time my tablet is in a coat pocket, (which I am usually not even wearing) so sound is the only way to get attention.

Also, the icon color change would would hard to do for those of us using the other themes (Thank you 412b for that by the way, it works great - especially "Use GTK theme" which I noticed keeps the charging animations)

tso 2009-01-15 14:02

Re: Pybattery - battery statusbar applet with candies
 
one thing tho, from what i have noticed, the battery warning sound will basically not play while the screen is of, as that makes the applet sleep, and therefor not register battery changes...

Benson 2009-01-15 14:44

Re: Pybattery - battery statusbar applet with candies
 
Quote:

Originally Posted by davidgro (Post 257720)
Adding to this suggestion, I would prefer a loud sound -- it should even max out the volume temporarily -- and with repetitions if ignored (perhaps once every 5% drop unless I acknowledge it?). Most of the time my tablet is in a coat pocket, (which I am usually not even wearing) so sound is the only way to get attention.

If added, that had better be a configurable option. I'd hate to be listening to music on earphones with the volume set to ~20%, and have the tablet suddenly cranked up to max just to deliver an ear-shattering beep. And indeed, if I have my tablet muted, or turned way down, because I'm in a meeting, I might not want it screaming about it's battery through the speakers, either...

ciroip 2009-01-16 14:51

Re: Pybattery - battery statusbar applet with candies
 
Im completely new to the batteries business and relative tla algorithms (+ the tablet uses are probably really different from a traditional laptop and relative power optimizations), anyway I like the idea to have a graph (like brent). I already have a working graphic battery status with samples every minute in my flipclock (its lovely watch the consume patterns) but I was thinking to cross the battery numbas with the status of the cpu (I know the cpu% change too fast for a 1 minute samples but at least maybe it will enough to recognize a particular intensive tablet use (watching movie/listen audio/ streaming audio/gps,,, and so on), Ill keep you update.
I dont understand anyway why my battery % is always a bit different from the advpow. Im using the code from pybatterystatus and I didnt try to analyze it at all (just happy to have some numbers to show). Note that the actual version in garage just show some dummy numbers

412b 2009-01-16 23:46

Re: Pybattery - battery statusbar applet with candies
 
Quote:

Originally Posted by tso (Post 257776)
one thing tho, from what i have noticed, the battery warning sound will basically not play while the screen is of, as that makes the applet sleep, and therefor not register battery changes...

O_o
Just in inactive mode battery drain is much less and battery changes are not so frequent...

So... Summarizing all the things above...
|AP (Advanced Power) 0.3.6|
1. Gonna be added configurable battery alert notification:
- With turning alert on/off
- With choosing sound for playing
- With option to turn on/raise volume on battery alert (also with on/off option)
- Icon will be changed to appropriate, when AP alerts
2. (or 0.3.7) User controlled event handling (e.g what progs to run on charger in, battery low, some other...).
3. (or 0.3.7) Commands executing and creating shortcuts for commands.

|APM (Advanced Power Monitor) 0.4.1|
1. Perhaps, new experimental TLA (time left algorithm) for battery.
2. Some more info, perhaps.


AP 0.3.5 and APM 0.4.0 will be released in a hour.

412b 2009-01-17 00:56

Re: Pybattery - battery statusbar applet with candies
 
Advanced Power 0.3.5:
- ADDED: autoupdate for almost all updatable items
- FIXED: Some minor bugfixes
- ADDED: Light sensor support for N810

Advanced Power Monitor 0.4.0:
- Initial release.


All times are GMT. The time now is 12:08.

vBulletin® Version 3.8.8