Librem 14 Failed to charge SOLVED

Hi Kieran, I have ran those commands and hopefully it works now.

Thank for your help.

1 Like

This is the only real hurdle I see to Linux adoption. Adding repos from other distros, and understanding all that this means is not easy.

Using the Pure OS repo on Mint might break your distro, or upgrade packages to be incompatible with Mint. However, I’m not sure you can add a repo and lock it only one file from that repo?

It would be great if Purism separated Coreboot into its own repo this way, you would have no problem updating it on whatever distro you used. (Perhaps Purism already does this, for this very reason. I don’t know.)

2 Likes

How can I check to see what my firmware version is?

On Librem 14 | PureBoot Boot Menu go to System Info i get PureBoot-Release-17.1

You can use sudo dmidecode: https://www.linuxnix.com/how-to-get-bios-firmware-and-installed-drivers-details/

3 Likes

Ah dang, I thought Coreboot was separated out into it’s own repo. Ah well! Would I be able to boot up a live USB of PureOS and update Coreboot that way?

You should have a kernel with this version: 5.10.0-7-amd64 at least

This is because the driver is not yet in the Debian repos. We are working on that.
You can get it from here: https://software.pureos.net/package/bin/byzantium/librem-ec-acpi-dkms

But again check your kernel version as well

1 Like

You can use this command t check your firmware version:

sudo dmidecode | grep -m1 "Version"

How do I check this?

You can check System Monitor (or whatever PureOS calls it) in the Menu, or go to the Update Manager and View Kernels (one will be indicated as active/installed/in use, etc.

Or dpkg --list | grep linux-image in the terminal. (That lists all installed.)
uname -r indicates which is active (or uname -mrs)

1 Like

Great thank you I’m good then.

There is a script that Purism made you can use, which will use wget to pull down the source, and then compile it on your local machine regardless of the distro. Just search ‘coreboot script’ on this forum and you’ll find the thread on it.

If you do not have PureOS installed, then boot from a PureOS live ISO with Byzantum:

https://downloads.pureos.net/byzantium/gnome/2021-07-05/pureos-10~devel-gnome-live-20210705_amd64.iso

And folow the instructions here to update Pureboot/coreboot

1 Like

Hello,

I have the same problem using Fedora 34 (kernel 5.12.14-300) so I can not install librem-ec-acpi-dkms using apt.

I tried to clone then build the source, but I encountered the following error.

sudo dnf groupinstall "Development Tools" "Development Libraries"
git clone https://source.puri.sm/nicole.faerber/librem-ec-acpi-dkms.git
cd librem-ec-acpi-dkms
sudo make all

arch/x86/Makefile:126: *** Recursive variable 'KBUILD_CFLAGS' references itself (eventually).  Stop.
make[1]: *** [Makefile:1860: arch/x86] Error 2
make[1]: Leaving directory '/usr/src/kernels/5.12.14-300.fc34.x86_64'
make: *** [Makefile:5: all] Error 2

I don’t know what to do. Also, I am a bit suprised that the computer not charging when it is off, so maybe this is not a software issue in my case?

Hello @nicole.faerber, I am sorry to ping you, but I didn’t received any feedback on this issue (not even from the support) and I feel stuck here. Should I open an issue on the repository instead? Let me know how can I help. Thank you.

Hi, may I suggest a different approach to try to install the driver in Fedora.

You can try to convert the DEB package into a an RPM package that you can install with dnf.

To do this:

  • Install the package alien in Fedora:

sudo dnf install alien

  • Download a copy of the deb package from here:

https://repo.pureos.net/pureos/pool/main/libr/librem-ec-acpi/librem-ec-acpi-dkms_0.9.1-1~pureos1_all.deb

  • To convert the package into an RPM package, from the same directory to where you downloaded the deb package, run the command:

sudo alien -r --scripts librem-ec-acpi-dkms_0.9.1-1~pureos1_all.deb

  • This will generate the package:

librem-ec-acpi-dkms-0.9.1-2.noarch.rpm

  • That you can install using dnf;

sudo dnf install ./librem-ec-acpi-dkms-0.9.1-2.noarch.rpm

And then reboot. Then please list here the files under:

/sys/class/power_supply/BAT0/

I tried this method in a VM with fedora 34 latest kernel. And the driver installed.

But since it was not a baremetal install there was no battery settings for me to check

1 Like

Thank you @joao.azevedo for your help.

I have followed your instructions, the package seems to be correctly installed.

sudo dnf list --installed | grep librem
librem-ec-acpi-dkms.noarch        0.9.1-2        @@commandline 

But after reboot, I still don’t have the charge_control_start_threshold file.

ls -l /sys/class/power_supply/BAT0/
total 0
-rw-r--r--. 1 root root 4096 Jul 29 13:56 alarm
-r--r--r--. 1 root root 4096 Jul 29 13:51 capacity
-r--r--r--. 1 root root 4096 Jul 29 13:56 capacity_level
-r--r--r--. 1 root root 4096 Jul 29 13:51 charge_full
-r--r--r--. 1 root root 4096 Jul 29 13:51 charge_full_design
-r--r--r--. 1 root root 4096 Jul 29 13:51 charge_now
-r--r--r--. 1 root root 4096 Jul 29 13:51 current_now
-r--r--r--. 1 root root 4096 Jul 29 13:56 cycle_count
lrwxrwxrwx. 1 root root    0 Jul 29 13:56 device -> ../../../PNP0C0A:00
drwxr-xr-x. 3 root root    0 Jul 29 13:51 hwmon1
-r--r--r--. 1 root root 4096 Jul 29 13:51 manufacturer
-r--r--r--. 1 root root 4096 Jul 29 13:51 model_name
drwxr-xr-x. 2 root root    0 Jul 29 13:56 power
-r--r--r--. 1 root root 4096 Jul 29 13:51 present
-r--r--r--. 1 root root 4096 Jul 29 13:51 serial_number
-r--r--r--. 1 root root 4096 Jul 29 13:51 status
lrwxrwxrwx. 1 root root    0 Jul 29 13:51 subsystem -> ../../../../../../class/power_supply
-r--r--r--. 1 root root 4096 Jul 29 13:51 technology
-r--r--r--. 1 root root 4096 Jul 29 13:51 type
-rw-r--r--. 1 root root 4096 Jul 29 13:51 uevent
-r--r--r--. 1 root root 4096 Jul 29 13:51 voltage_min_design
-r--r--r--. 1 root root 4096 Jul 29 13:51 voltage_now

After installing acpi… I’m having those 2 files.
I changed to 45 and 95 but I’m stuck at 69 % all the time [with charger in it … if I’ll remove the charger then it will go down]

I have done all the fixes, and the settings as directed by Purism support, and mine charges now just fine. I will note however that even though the upper threshold says 95, it will always charge to 100% if allowed.

I am having the same problem with my new L14. If I follow these steps from a PureOS live disk, will these settings be carried over to my Qubes installation (i.e. are the /sys files updated on the firmware itself when I apply the fix)?