Active Topics

 


Reply
Thread Tools
Posts: 424 | Thanked: 196 times | Joined on Mar 2010 @ Sweden
#941
Hmm, dont know if this is right but this is how it looks like on my phone.
I run this:
Code:
stop bme
modprobe bq27x00_battery
modprobe bq2415x_charger
(im running CSSU-T, KP51r1, Thumb4).
 

The Following User Says Thank You to toxaris For This Useful Post:
Posts: 2,154 | Thanked: 8,464 times | Joined on May 2010
#942
@toxaris, it should be fixed now. Updated version of DEB package is on same URL.
 

The Following 10 Users Say Thank You to pali For This Useful Post:
Posts: 250 | Thanked: 126 times | Joined on Dec 2010
#943
Originally Posted by toxaris View Post
Hmm, dont know if this is right but this is how it looks like on my phone.
I run this:
Code:
stop bme
modprobe bq27x00_battery
modprobe bq2415x_charger
(im running CSSU-T, KP51r1, Thumb4).
Same problem here recently installed
CSSU-thumb here
EDIT: sorry reboot and itīs working great Thanks a lot (Iīve wroted before even seeing your reply!!

Last edited by guilledoc; 2012-11-07 at 14:49.
 
Posts: 2,154 | Thanked: 8,464 times | Joined on May 2010
#944
After installing/updating reboot phone. If after reboot still show -1, please upload ouput of "lshal" command.
 

The Following 2 Users Say Thank You to pali For This Useful Post:
Posts: 1,808 | Thanked: 4,272 times | Joined on Feb 2011 @ Germany
#945
Originally Posted by pali View Post
I created new battery status area plugin (based on old MAG version). It work with BME or with bq27x00_battery kernel driver. It is like original Nokia version, plus display percentage, remaining time and capacity.

Please test it and write if this can go to CSSU :-)

Source: https://gitorious.org/~pali/communit...applet-battery
DEB: http://atrey.karlin.mff.cuni.cz/~pal....0-1_armel.deb
Thanks pali. Could you also add i2cget to the pack? (for those who don't have bme nor use bq27x00_battery

How do you decide which one to use? user preference or priorities? (bme -> bq [ -> i2c ]).

Last edited by reinob; 2012-11-07 at 15:10.
 

The Following 2 Users Say Thank You to reinob For This Useful Post:
Posts: 2,154 | Thanked: 8,464 times | Joined on May 2010
#946
@reinob, not possible, becuase i2cget must be run under root.
 

The Following 3 Users Say Thank You to pali For This Useful Post:
Posts: 804 | Thanked: 1,598 times | Joined on Feb 2010 @ Gdynia, Poland
#947
@pali and others who may be interested

I played a little with bme and searched a bit on the Internet. I found: http://www.gossamer-threads.com/list...velopers/64917 which states:
Also, hald-addon-bme exposes the following signals under
com.nokia.bme.signal /com/nokia/bme/signal (unless otherwise specified,
these signals have no arguments)
charger_connected
charger_disconnected
charger_charging_failed
charger_charging_off
charger_charging_on
battery_full
battery_empty
battery_low
battery_state_changed (arguments for this are 2 uints, dbus type 'u',
unknown exactly what they are for)
battery_timeleft (arguments for this are 2 uints, dbus type 'u', first one
is for idle time, second is for active time)


The purpose of these signals should be self-explanatory for the most part.

Plus it exposes 2 dbus methods on com.nokia.bme.request. Both take no
parameters. The status_info_req method causes a method to be run that will
send the appropriate signals from the list above. The timeleft_info_req
method also causes the signals to be sent but it also sends a message to
BME to retrieve the relavent data for the timeout fields.
So what I did was open two terminals at the same time, in one I typed:
Code:
dbus-monitor --system
In the other (as found at https://garage.maemo.org/pipermail/p...ly/000060.html ):
Code:
dbus-send --system /com/nokia/bme/request com.nokia.bme.request.timeleft_info_req
In the first terminal, lots of info appeared after few moments, one of which was interesting for us:
Code:
signal sender=:1.8 -> dest=(null destination) serial=6836 path=/org/freedesktop/Hal/devices/bme; interface=org.freedesktop.Hal.Device; member=PropertyModified
   int32 1
   array [
      struct {
         string "battery.remaining_time"
         boolean false
         boolean false
      }
   ]
signal sender=:1.27 -> dest=(null destination) serial=48 path=/com/nokia/bme/signal; interface=com.nokia.bme.signal; member=battery_timeleft
   uint32 4260
   uint32 180
I'm not sure what these 4260 and 180 mean, but I guess this is the "real" value for idle and "busy" remaining time for battery in whatever unit.

On "hal-device bme" the value is always equal to one of (18000,10800,14400,7200,3600) for me and it changes with regard to some pattern which I completely don't understand... Maybe it's good to use this method for bme? (As soon as we aknowledge in what unit are these idle and active values reported)

Others: could you repeat my test and check values on your n900s?

Last edited by misiak; 2012-11-07 at 17:23. Reason: corrected some typos, posted this from my n900 while on the train and now i could read it on bigger screen and correct them
 

The Following 6 Users Say Thank You to misiak For This Useful Post:
Posts: 1,808 | Thanked: 4,272 times | Joined on Feb 2011 @ Germany
#948
Originally Posted by pali View Post
@reinob, not possible, becuase i2cget must be run under root.
Mine is setuid'd, so that I can use it from a DCE widget without su/sudo-magic.

Given the number of programs that add themselves to the sudoers list (without password), I guess setting the setuid bit for i2cget doesn't make it any less secure..

Anyway, it's your program [ and I'm happy with my DCE widget ]
 

The Following User Says Thank You to reinob For This Useful Post:
Posts: 2,154 | Thanked: 8,464 times | Joined on May 2010
#949
@misiak: this is already implemented in new hald-addon-bme
 
Posts: 804 | Thanked: 1,598 times | Joined on Feb 2010 @ Gdynia, Poland
#950
Originally Posted by pali View Post
@misiak: this is already implemented in new hald-addon-bme
I'm sorry, but I think I don't understand What is already implemented in new hald-addon-bme? I just wrote a way to fetch two values (idle + active) via dbus, which I found on the Internet. hald-device reports only one value, which is totally different than both these two (and for me seems a bit random as for battery remaining time value, but it should be treated only as my oppinion). If the method I pointed out in my previous post is already implemented in hald-addon-bme, why not use it instead of using the value you're using? (no offence intended, I just think I don't understand what you mean)
 

The Following 3 Users Say Thank You to misiak For This Useful Post:
Reply

Tags
cssu testing


 
Forum Jump


All times are GMT. The time now is 14:53.