[ltp] T4x Battery Conditons Survey

Eric Van Buggenhaut linux-thinkpad@linux-thinkpad.org
Sat, 17 Dec 2005 22:45:39 +0100


On Sat, Dec 17, 2005 at 07:46:58PM +0200, Shem Multinymous wrote:
> Yet another shameless plug:
> 
> On 12/17/05, Marius Gedminas <mgedmin@b4net.lt> wrote:
> > I do not know how to determine the number of charge cycles in Linux.
> 
> Download tp_smapi [1],
> # rmmod hdaps
> # tar xzvf tp_smapi-0.12.tgz
> # cd tp_smapi-0.12
> # make load
> # cat /sys/devices/platform/smapi/BAT0/cycle_count
> and, for best effect, update the model-specific status at ThinkWiki [2].

I'll update the wiki. Here are the detailed results:

T42-2378DXU linux 2.6.14.2 - tp_smapi 0.12

All

# cat /sys/devices/platform/smapi/BAT0/installed # cat 
# /sys/devices/platform/smapi/BAT0/state       # 
# idle/charging/discharging # cat 
# /sys/devices/platform/smapi/BAT0/cycle_count # cat 
# /sys/devices/platform/smapi/BAT0/current_now # instantaneous current 
# # cat /sys/devices/platform/smapi/BAT0/current_avg # last minute 
# average # cat /sys/devices/platform/smapi/BAT0/power_now   # 
# instantaneous power # cat /sys/devices/platform/smapi/BAT0/power_avg   
# # last minute average # cat 
# /sys/devices/platform/smapi/BAT0/last_full_capacity # cat 
# /sys/devices/platform/smapi/BAT0/remaining_capacity # cat 
# /sys/devices/platform/smapi/BAT0/design_capacity # cat 
# /sys/devices/platform/smapi/BAT0/voltage # cat 
# /sys/devices/platform/smapi/BAT0/design_voltage # cat 
# /sys/devices/platform/smapi/BAT0/manufacturer # cat 
# /sys/devices/platform/smapi/BAT0/model # cat 
# /sys/devices/platform/smapi/BAT0/serial # cat 
# /sys/devices/platform/smapi/BAT0/barcoding # cat 
# /sys/devices/platform/smapi/BAT0/chemistry # cat 
# /sys/devices/platform/smapi/ac_connected

work fine

Both

atto:/# echo 1 > /sys/devices/platform/smapi/BAT0/force_discharge1
atto:/# echo 1 > /sys/devices/platform/smapi/BAT0/force_discharge2

work, but only

atto:/# cat /sys/devices/platform/smapi/BAT0/force_discharge1
1

responds.

atto:/# cat /sys/devices/platform/smapi/BAT0/force_discharge2
cat: /sys/devices/platform/smapi/BAT0/force_discharge2: Input/output 
error

fails

start_charge_thresh works:

# cat /sys/devices/platform/smapi/BAT0/start_charge_thresh 
10

but not 

cat: /sys/devices/platform/smapi/BAT0/stop_charge_thresh: Function not 
implemented

# cat /sys/devices/platform/smapi/BAT0/inhibit_charge_minutes
1

> 
> [1] http://sf.net/project/showfiles.php?group_id=1212&package_id=171579
> [2] http://thinkwiki.org/wiki/SMAPI_support_for_Linux
> --
> The linux-thinkpad mailing list home page is at:
> http://mailman.linux-thinkpad.org/mailman/listinfo/linux-thinkpad

-- 
Eric VAN BUGGENHAUT
Eric.VanBuggenhaut@AdValvas.be