Using tp_smapi on Fedora 11 for battery charge levels
-
Dead1nside
- Senior Member

- Posts: 780
- Joined: Mon Jul 24, 2006 8:32 pm
- Location: Reading, UK
- Contact:
Using tp_smapi on Fedora 11 for battery charge levels
Hi,
I've found an akmod package for tp_smapi but I don't actually know how to use it to set the battery charge levels to start when under 20% and stop when at 80% -- I did try an echo command that I found but would appreciate it if anyone could point me in the right direction.
Thanks.
I've found an akmod package for tp_smapi but I don't actually know how to use it to set the battery charge levels to start when under 20% and stop when at 80% -- I did try an echo command that I found but would appreciate it if anyone could point me in the right direction.
Thanks.
T41p 2373-GHG / 1.5Ghz 'Banias' / NMB Keyboard
T61 14.1'' 7661-CTO / Vista Business / WXGA / T7300 / 2GB RAM / 80GB HDD / X3100 / 3945ABG / NMB KB /
T400 14.1'' 2768-CTO / Vista Business / WXGA / P8400 / 4GB RAM / 200GB 7200RPM / HD 3470 / 5300AGN / WWAN / NMB KB
T61 14.1'' 7661-CTO / Vista Business / WXGA / T7300 / 2GB RAM / 80GB HDD / X3100 / 3945ABG / NMB KB /
T400 14.1'' 2768-CTO / Vista Business / WXGA / P8400 / 4GB RAM / 200GB 7200RPM / HD 3470 / 5300AGN / WWAN / NMB KB
Re: Using tp_smapi on Fedora 11 for battery charge levels
To set the thresholds you simply need to enter the following:
You can check the status by using:
If you want to have the thresholds set at startup you can just add the echo lines to /etc/profile.
You said you used an echo command already; is it the same one I have above? If so, did it work? Do you have the tp_smapi kernel module running? I'm not familiar with akmod packages...does that mean you're using a custom kernel?
Code: Select all
# echo 20 > /sys/devices/platform/smapi/BAT0/start_charge_thresh
# echo 80 > /sys/devices/platform/smapi/BAT0/stop_charge_thresh
Code: Select all
# cat /sys/devices/platform/smapi/BAT0/*_charge_thresh
You said you used an echo command already; is it the same one I have above? If so, did it work? Do you have the tp_smapi kernel module running? I'm not familiar with akmod packages...does that mean you're using a custom kernel?
W510: i7-820QM / 8GB 1066 RAM/ 1 GB NVIDIA Quadro FX 880M / 500GB 7200rpm / 15.6" HD 1080 / Arch Linux
-
Dead1nside
- Senior Member

- Posts: 780
- Joined: Mon Jul 24, 2006 8:32 pm
- Location: Reading, UK
- Contact:
Re: Using tp_smapi on Fedora 11 for battery charge levels
Thank you for your reply.Superego wrote:To set the thresholds you simply need to enter the following:You can check the status by using:Code: Select all
# echo 20 > /sys/devices/platform/smapi/BAT0/start_charge_thresh # echo 80 > /sys/devices/platform/smapi/BAT0/stop_charge_threshIf you want to have the thresholds set at startup you can just add the echo lines to /etc/profile.Code: Select all
# cat /sys/devices/platform/smapi/BAT0/*_charge_thresh
You said you used an echo command already; is it the same one I have above? If so, did it work? Do you have the tp_smapi kernel module running? I'm not familiar with akmod packages...does that mean you're using a custom kernel?
I don't get any response from the former commands, which look an awful lot like the ones I used before. I am using them as root but I just get 'No such file or directory' for all of your commands.
An akmod is like a kmod package but it automatically recompiles itself when you install a new kernel instead of having to manually find a matching kmod.
T41p 2373-GHG / 1.5Ghz 'Banias' / NMB Keyboard
T61 14.1'' 7661-CTO / Vista Business / WXGA / T7300 / 2GB RAM / 80GB HDD / X3100 / 3945ABG / NMB KB /
T400 14.1'' 2768-CTO / Vista Business / WXGA / P8400 / 4GB RAM / 200GB 7200RPM / HD 3470 / 5300AGN / WWAN / NMB KB
T61 14.1'' 7661-CTO / Vista Business / WXGA / T7300 / 2GB RAM / 80GB HDD / X3100 / 3945ABG / NMB KB /
T400 14.1'' 2768-CTO / Vista Business / WXGA / P8400 / 4GB RAM / 200GB 7200RPM / HD 3470 / 5300AGN / WWAN / NMB KB
-
Dead1nside
- Senior Member

- Posts: 780
- Joined: Mon Jul 24, 2006 8:32 pm
- Location: Reading, UK
- Contact:
Re: Using tp_smapi on Fedora 11 for battery charge levels
Edit: I've written an article on how to get it to work on Fedora 14, with akmods.
http://www.jonathanpritchard.com/blog/h ... ora-14-271
I've got it to work now after I upgraded to Fedora 12.
You can find a pre-built akmod package for Fedora (although not the latest release, it doesn't matter) here http://izhar.fedorapeople.org/tp_smapi-kmod/ .
There is a good guide on akmods here, http://fedorasolved.org/Members/zcat/akmods .
You need the akmod and kmod tools from the repositories, trying to install the akmod with the following, will provide you with the relevant warnings telling you what else you need:
You will need the relevant kernel-devel package for your kernel, if you're using a PAE kernel make sure you get the kernel-PAE-devel.
Once it is installed do as root:
This will rebuild all akmods and should report a success.
You can now check that the package is installed as a kernel module by doing:
It should be on that list.
Now you can restart, or load tp_smapi manually with:
I have noticed that you need to actually switch to root and not use sudo if you want to use the echo style commands to change the battery levels, apart from that it appears to work, I have not tested it though.
http://www.jonathanpritchard.com/blog/h ... ora-14-271
I've got it to work now after I upgraded to Fedora 12.
You can find a pre-built akmod package for Fedora (although not the latest release, it doesn't matter) here http://izhar.fedorapeople.org/tp_smapi-kmod/ .
There is a good guide on akmods here, http://fedorasolved.org/Members/zcat/akmods .
You need the akmod and kmod tools from the repositories, trying to install the akmod with the following, will provide you with the relevant warnings telling you what else you need:
Code: Select all
rpm -ivh akmod-tp_smapi-0.40-1.fc11.i686.rpm
Once it is installed do as root:
Code: Select all
# service akmods restart
You can now check that the package is installed as a kernel module by doing:
Code: Select all
modprobe -l
Now you can restart, or load tp_smapi manually with:
Code: Select all
# modprobe tp_smapi
T41p 2373-GHG / 1.5Ghz 'Banias' / NMB Keyboard
T61 14.1'' 7661-CTO / Vista Business / WXGA / T7300 / 2GB RAM / 80GB HDD / X3100 / 3945ABG / NMB KB /
T400 14.1'' 2768-CTO / Vista Business / WXGA / P8400 / 4GB RAM / 200GB 7200RPM / HD 3470 / 5300AGN / WWAN / NMB KB
T61 14.1'' 7661-CTO / Vista Business / WXGA / T7300 / 2GB RAM / 80GB HDD / X3100 / 3945ABG / NMB KB /
T400 14.1'' 2768-CTO / Vista Business / WXGA / P8400 / 4GB RAM / 200GB 7200RPM / HD 3470 / 5300AGN / WWAN / NMB KB
-
- Similar Topics
- Replies
- Views
- Last post
-
-
Brand New Oem X230 Battery Losing Full Charge Capacity Fast!
by TheMagicT410 » Sat Feb 11, 2017 12:58 pm » in ThinkPad X230 and later Series - 5 Replies
- 826 Views
-
Last post by TheMagicT410
Sat Feb 25, 2017 3:04 pm
-
-
- 3 Replies
- 267 Views
-
Last post by Temetka
Wed Apr 12, 2017 1:28 am
-
-
What operatings systems are y'all using on your vintage ThinkPads?
by goldeneagle » Thu Jan 05, 2017 4:00 pm » in ThinkPad Legacy Hardware - 15 Replies
- 2398 Views
-
Last post by w0qj
Sat Mar 11, 2017 9:12 am
-
-
-
USB 3.0 using WWAN slot or PCExpress54?
by PurpleMelbourne » Sat Mar 25, 2017 11:55 pm » in ThinkPad T6x Series - 12 Replies
- 1408 Views
-
Last post by dr_st
Fri Mar 31, 2017 12:17 am
-
Who is online
Users browsing this forum: No registered users and 0 guests



