x220 battery info

This situation piss me off a big time. And I don’t understand what’s wrong ! I’ve a 9 cell battery, but I’m not able to squeeze out of it more then 1.30 mins. And this is ridiculous considering that other people report 6 hs and more with an x220 and a 9 cell bat.

Well I’m putting here various info for reference… maybe I’ll find the culprit .

These info are obtained with this script: thinkpad-smapi.sh

    BATTERY 0 INFORMATION
    =====================

    Battery slot:
      Battery present: yes
      Battery state: discharging

    Embedded info:
      FRU P/N: 42T4940
      Barcoding: 1ZJRM1BHCDR
      Serial number: 13521
      OEM Manufacturer: SANYO
      Chemistry: LION
      Manufacture date: 2011-11-17
      Design capacity & voltage: 93240 mWh, 11100 mV

    Battery health:
      First use date: 2012-01-23
      Cycle count: 134
      Last full capacity: 93180 mWh
      Average current / power (past 1 minute): -1079 mA, -12077 mW

    Battery status:
      Remaining capacity: 78420 mWh (84 %)
      Remaining running time: 441 min
      Running current & power: -1054 mA, -11797 mW
      Temperature: 33400 mC
      Voltage: 11193 mV
      Remaining charging time: [not charging]

    Battery charging control:
      Start charging at: [unavailable] %
      Stop charging at: 85 %
      Prevent charging for: 0 min
      Force battery discharge: [unavailable]

Here I print out the output of ibam

$ibam --all
Bios percentage:            81 %
Battery percentage:         80 %
Soft low percentage limit:  4 %
Charge percentage:          81 %
Bios time left:              1:00:00
Battery time left:           6:33:59
Adapted battery time left:   6:33:59
Charge time left:            0:22:48
Adapted charge time left:    0:22:48
Total battery time:          8:11:12
Adapted total battery time:  8:11:12
Total charge time:           2:00:00
Adapted total charge time:   2:00:00
Profile logging enabled.
Current file: /home/abate/.ibam/profile-002-battery
$acpitool -B
  Battery #1     : present
    Remaining capacity : 75460 mWh, 80.98%, 06:09:21
    Design capacity    : 93240 mWh
    Last full capacity : 93180 mWh, 99.94% of design capacity
    Capacity loss      : 0.06435%
    Present rate       : 12258 mW
    Charging state     : Discharging
    Battery type       : Li-ion 
    Model number       : 42T4940
    Serial number      : 13521

And this is what upsets me the most. One moment the battery is at 74% one moment at 6% !!! I really don’t understand …

$ibam --all
Bios percentage:            70 %
Battery percentage:         72 %
Soft low percentage limit:  4 %
Charge percentage:          70 %
Bios time left:              5:37:45
Battery time left:           8:41:28
Adapted battery time left:  39:16:35
Charge time left:            0:36:00
Adapted charge time left:    0:07:58
Total battery time:         12:00:57
Adapted total battery time: 54:18:04
Total charge time:           2:00:00
Adapted total charge time:   0:26:33
Profile logging enabled.
Current file: /home/abate/.ibam/profile-003-battery

$ibam --all
Bios percentage:            6 %
Battery percentage:         2 %
Soft low percentage limit:  4 %
Charge percentage:          6 %
Bios time left:              0:33:45
Battery time left:           0:15:50
Adapted battery time left:   1:11:33
Charge time left:            1:52:48
Adapted charge time left:    0:24:58
Total battery time:         12:00:57
Adapted total battery time: 54:18:05
Total charge time:           2:00:00
Adapted total charge time:   0:26:33
Profile logging enabled.
Current file: /home/abate/.ibam/profile-003-battery

$ibam --all
Bios percentage:            6 %
Battery percentage:         2 %
Soft low percentage limit:  4 %
Charge percentage:          6 %
Bios time left:              0:28:46
Battery time left:           0:15:50
Adapted battery time left:   1:11:33
Charge time left:            1:52:48
Adapted charge time left:    0:24:58
Total battery time:         12:00:57
Adapted total battery time: 54:18:05
Total charge time:           2:00:00
Adapted total charge time:   0:26:33
Profile logging enabled.
Current file: /home/abate/.ibam/profile-003-battery

Update

Interesting post : http://zbz.ca/X220/thinkpad_x220_linux.html

Update 2

I finally managed to get a new battery and BAM ! 8 hrs on a charge. I feel really unlucky with this new laptop …


Audio codec hwC0D0: Conexant and powertop

If you have an intel sound card and you are concerned about battery life, probably you have seen this in the powetop output…

100.0%                      Device         Audio codec hwC0D0:

Conexant

After much duck-duck-ing around I found this enlightening comment on the lesswatt mailing list. It turns out that to enable power management on this device, the device must be open first. Something like

echo -n | aplay

in your rc.local script should do the trick.

hopefully this will give me few more minutes of battery time. Still no clue for the other device :

100.0%                      Device         Audio codec hwC0D3:

Intel

This page has plenty of good tips, most of them already integrated in the laptop-mode package in debian…

I added a couple of lines to my /etc/sysfs.conf file :

module/snd_hda_intel/parameters/power_save=1
module/snd_hda_intel/parameters/power_save_controller=Y

but the Audio codec hwC0D3: Intel is still there hanging with 100% :(


new thinkpad x220

This summer my beloved thinkpad x301 died in a cloud of smoke. It was exactly 3 years and 20 days old while my warranty was valid only for 3 years. Now, don’t tell me this is a coincidence. Anyway. After about 5 months, I finally managed to convince my employer to get me a new thinkpad, the x220. My specs includes a 128G SSD , 4G of RAM, 2.4Gz processor, camera and fingerprint reader.

It’s a pity that the x300 series is not in production anymore. They were light, with a solid battery and a large screen. The X1 just don’t cut it. Even though it can be consider the successor of the x300, its battery life is just not enough for my needs. On the other hand, the x220 is a very nice machine : the screen is a bit smaller then the X300, but it is light, with a very powerful processor, good battery and it feels very solid. In my opinion lenovo should have packed the new hw of the x220 in the chassis of the x300, maybe with small compromise on the battery life (I got the big battery and I can squeeze almost 7 hs with a single charge) but clearly this was not a good business choice…

Installing debian on this laptop is not immediate because none of the official debian installers are shipped with a recent kernel (as in 3.x series). Since with the official debian installer I cannot have neither the driver for the Ethernet card or the driver for the wirelles card, I opted to use a custom installer built by kmuto (http://kmuto.jp/debian/d-i/ ) . Using this installer the ethernet card is recognized immediately and it’s easy to proceed with the installation as usual. Another option would have been to add the binary blog for the wireless chip, but apparently the deb installer supports only WEP auth, while all my access point are WPA. I didn’t spend too much time on the wireless setup, so it might well be that is indeed possible to install using a WPA access point.

Last time I installed a laptop, I used the automatic partition option to have lvm on top of a lucks encrypted partition, only to discover later that the default dimensions of the partitions were a bit too small for me. For example, by default the boot partition is only 256Mb. This is plenty if you want to have only one kernel image installed at each given time, but if you want more then one kernel, memtest and for example a grml rescue iso, it’s easy to run out of space.

So I proceed to manually partition the disc creating a boot partition of 512M, and using the rest as a luks encrypted device with lvm on top and 3 logical volumes : sys (15G), swap (4G) and home (the rest). For my daily use having 15G on my laptop for /usr, /var, etc should more the enough…

Next step was to install the system. Since in recent times I got extremely pissed off with gnome 3, I’ve decided to dump it completely and go back to awesome. But since awesome all by itself is a bit sad, I paired it up with xfce. Everything works, except the automount, and I’m still trying to figure out how to make it work. Apparently is a consolkit problem… I’ll write another post about the xfce4 + awsome setup soon…

Today I’ve also started playing with the finger print reader. It seems working, but I haven’t managed yet to use it in conjunction with pam for authentication … more to come.

And… On last closing remark : during the last 5 months I’ve used a dell latitude e6410 … Gosh. I feel I’m on anther planet. The keyboard of a thinkpad give you pleasure, not pain, from 2 to 4G of RAM is a big jump and from a conventional HD to a SSD … well… it seems I’m flyinggggg :) I’ve the impression my productivity just went up 50% !!!

If you work with your laptop everyday get a good laptop. It is well worth the investment …

Update

Now debian can be installed on this model using the stock installation images.