![]() |
2012-03-13
, 01:54
|
Posts: 1,463 |
Thanked: 1,916 times |
Joined on Feb 2008
@ Edmonton, AB
|
#32
|
![]() |
2012-03-13
, 07:45
|
|
Posts: 560 |
Thanked: 423 times |
Joined on May 2010
@ Switzerland
|
#33
|
I've added the charge / discharge rate as well. Thank e-yes (nitdroid guy) as he shared some code that made this possible
The Following User Says Thank You to caco3 For This Useful Post: | ||
![]() |
2012-03-13
, 16:55
|
Posts: 1,463 |
Thanked: 1,916 times |
Joined on Feb 2008
@ Edmonton, AB
|
#34
|
Would you be willing to share this code snipped?
I would like to add it to BatteryGraph, but haven't yet found a way.
The Following User Says Thank You to Creamy Goodness For This Useful Post: | ||
![]() |
2012-03-13
, 21:16
|
|
Posts: 560 |
Thanked: 423 times |
Joined on May 2010
@ Switzerland
|
#35
|
Sure but 2 problems, this code is written in C and is relying on undocumented features so we can't guarantee stability in the future.
![]() |
2012-03-14
, 08:00
|
Posts: 1,463 |
Thanked: 1,916 times |
Joined on Feb 2008
@ Edmonton, AB
|
#36
|
I havent studied the code yet, but since C can access it, we could write a simple c program as a wrapper.
Or, if it only access system files/devices (what I home/expect), then we are also able to gain the data directly from the shell.
My BatteryGraph Daemon is currently just a bash script which fetch the data every 5 minutes.
The Following User Says Thank You to Creamy Goodness For This Useful Post: | ||
![]() |
2012-03-14
, 17:56
|
|
Posts: 560 |
Thanked: 423 times |
Joined on May 2010
@ Switzerland
|
#37
|
The Following User Says Thank You to caco3 For This Useful Post: | ||
![]() |
2012-03-14
, 18:12
|
Posts: 1,463 |
Thanked: 1,916 times |
Joined on Feb 2008
@ Edmonton, AB
|
#38
|
After studying the output of https://gitorious.org/harmattan-good...aster/bmecli.c in http://pastebin.com/RkRmT5FD I realize that there is already a tool (bmestat) on board, which reports the charging/discharging current.
Because of that, I am wondering why there is an extra tool needed?
Maybe I misunderstand something, but for just getting the charging/discharging rate, I do not need any extra tools, right?
(All the other information for BatteryGraph I gain from hal-device bme)
The Following User Says Thank You to Creamy Goodness For This Useful Post: | ||
![]() |
2012-03-14
, 18:26
|
|
Posts: 560 |
Thanked: 423 times |
Joined on May 2010
@ Switzerland
|
#39
|
Hmmm, I didn't know that. Talking to the server directly via a socket is way more efficient than launching a process and parsing the output though. Very important when I'm doing this 10-30 times per minute. I'll have to look at the bmestat output later, I forgot my phone at home today so I can't now
![]() |
2012-04-11
, 10:34
|
|
Posts: 4,365 |
Thanked: 2,467 times |
Joined on Jan 2010
@ Australia Mate
|
#40
|
Last edited by Creamy Goodness; 2012-03-03 at 19:59.