Olpc-logbat: Difference between revisions

From OLPC
Jump to navigation Jump to search
(New page: {{G1G1 Support FAQ}} '''olpc-logbat''' is a bash script that logs various parameters of the battery subsystem. It must be run from the "Terminal Activity". At a [[Terminal Activity]...)
 
mNo edit summary
Line 38: Line 38:
;Voltage : Battery voltage in microVolts ( x 10E-6 ) The resolution does not really go down to microVolts but its easier not to do floating point math in the kernel driver. The above example shows a voltage of 6.90 and 6.91 volts.
;Voltage : Battery voltage in microVolts ( x 10E-6 ) The resolution does not really go down to microVolts but its easier not to do floating point math in the kernel driver. The above example shows a voltage of 6.90 and 6.91 volts.
;Current : Signed number indicating the current into or out of the battery. Value in microAmps. The above charging example shows a charge current into the battery of 1.58 amps. The discharging example shows a draw current out of the battery of .895 to .899 amps or 895 to 899 miliAmps.
;Current : Signed number indicating the current into or out of the battery. Value in microAmps. The above charging example shows a charge current into the battery of 1.58 amps. The discharging example shows a draw current out of the battery of .895 to .899 amps or 895 to 899 miliAmps.
;Battery Temp : Temperature of the battery in 100's of degree Centigrade. The above example is 27.3 to 27.7 degrees C. The battery can get fairly warm during charge and discharge in a normal 25 degree room its not uncommon to see values up in to the 30 C range.
;Battery Temp : Temperature of the battery in 100's of degree Centigrade. The above example is 27.3 to 27.7 degrees C. The battery can have quite a bit of rise above ambient temperature during charge and discharge. In a normal 25 degree room its not uncommon to see values up in to the 30 C range.
;Accumulated Current Register (ACR) : ACR is a 16-bit 2's complement value that counts up or down depending on the amount of charge into or out of the battery. The value is in units of the counter inside the battery but it can be converted to milliAmpHours (mAh) by multiplying by .4167. A single value does not tell you much but the difference between any 2 readings gives you the net charge during that period. The above charging example delivered 26.6 mAh into the battery. (1715-1651)*.4167
;Accumulated Current Register (ACR) : ACR is a 16-bit 2's complement value that counts up or down depending on the amount of charge into or out of the battery. The value is in units of the counter inside the battery but it can be converted to milliAmpHours (mAh) by multiplying by .4167. A single value does not tell you much but the difference between any 2 readings gives you the net charge during that period. The above charging example delivered 26.6 mAh into the battery. (1715-1651)*.4167
;Status : "Charging", "Not Charging", or "Discharging". "Not Charging" occurs when the battery is full but you are on external power.
;Status : "Charging", "Not Charging", or "Discharging". "Not Charging" occurs when the battery is full but you are on external power.

Revision as of 06:58, 5 February 2008

This page is part of the XO Support FAQ.     Support Index | Print This Page
<imagemap>

Image:Support-banner-square.png|173px|community support pages rect 0 0 135 204 [1] rect 135 0 345 204 Support FAQ rect 0 205 135 408 [2]

  1. Comment : there's some whitespace here:

rect 135 205 345 408 Other support

  1. maybe desc none is better. testing.

desc none

</imagemap>

olpc-logbat is a bash script that logs various parameters of the battery subsystem. It must be run from the "Terminal Activity".

At a Terminal Activity command prompt, enter

olpc-logbat

Every 10 seconds you will see a line printed to the screen that looks similar to the following:

1199878696,93,6464170,-895442,2796,6993,Discharging,Full
1199878706,93,6464170,-899739,2798,6987,Discharging,Full
1199878716,92,6462340,-899479,2797,6981,Discharging,Normal
1199878726,92,6464780,-898828,2798,6975,Discharging,Normal

If you are charging a battery then the output will look similar:

1200047276,17,6905200,1585286,2730,1651,Charging,Normal
1200047286,17,6907030,1583072,2734,1662,Charging,Normal
1200047296,17,6908860,1586458,2743,1673,Charging,Normal
1200047306,17,6910080,1586067,2752,1683,Charging,Normal
1200047316,18,6911910,1584635,2760,1694,Charging,Normal
1200047326,18,6914350,1586458,2769,1705,Charging,Normal
1200047337,18,6913740,1581770,2772,1715,Charging,Normal

In addition to writing these values to the screen olpc-logbat writes the data to a file. Every time you run olpc-logbat it creates a file in the current directory (normally /home/olpc) that looks like 'bat-<nickname>-<date>-

The legend for the values is:

<Timestamp>,<SOC>,<Voltage>,<Current>,<Bat Temp>,<ACR>,<Status>,<Overall Level>

Timestamp
POSIX time stamp of number of seconds since Jan 1, 1970
SOC
State of Charge. A % number between 0 and 100% indicating how charged your battery is. This number is normally between 7% and 97%. Due to variations from battery to battery its difficult to get an exact measurement down to 1%. Therefor low is anything less than 15% and full is anything greater than 93%.
Voltage
Battery voltage in microVolts ( x 10E-6 ) The resolution does not really go down to microVolts but its easier not to do floating point math in the kernel driver. The above example shows a voltage of 6.90 and 6.91 volts.
Current
Signed number indicating the current into or out of the battery. Value in microAmps. The above charging example shows a charge current into the battery of 1.58 amps. The discharging example shows a draw current out of the battery of .895 to .899 amps or 895 to 899 miliAmps.
Battery Temp
Temperature of the battery in 100's of degree Centigrade. The above example is 27.3 to 27.7 degrees C. The battery can have quite a bit of rise above ambient temperature during charge and discharge. In a normal 25 degree room its not uncommon to see values up in to the 30 C range.
Accumulated Current Register (ACR)
ACR is a 16-bit 2's complement value that counts up or down depending on the amount of charge into or out of the battery. The value is in units of the counter inside the battery but it can be converted to milliAmpHours (mAh) by multiplying by .4167. A single value does not tell you much but the difference between any 2 readings gives you the net charge during that period. The above charging example delivered 26.6 mAh into the battery. (1715-1651)*.4167
Status
"Charging", "Not Charging", or "Discharging". "Not Charging" occurs when the battery is full but you are on external power.
Overall Level
"Low", "Normal" , or "Full". A basic indicator of where your charge level is.