LPC SPI Firmware and Driver Prototype

OK so I checked the lsmod list, no dice. I found what looks like the driver in a folder called misc, reform2-lpc.ko, but I can’t load it. I get an invalid module error from insmod. Maybe that’s the wrong one?

I tried also with the other method I found, modprobe, but that gives an exec format error.

Oh whoops, I’ll look into it. Thank you for the error report!

I cannot reproduce your problem. The module is not in a folder called misc but here:


It is also not named reform2-lpc.ko but reform2_lpc.ko (underscore instead of dash). Maybe you have some leftovers from a manual installation?

Can you try to apt update and apt install reform2-lpc-dkms to get the latest version of the package?

I also just built reform-system-image locally and flashed the result on my SD-Card. The module gets loaded automatically upon boot:

$ lsmod | grep lpc
reform2_lpc      16384  0

I have updated my system and gotten the latest update to the reform-tools, and the lpc module seems to be correctly loaded. However, both Sway and KDE report the battery as 0%. Plugging in the power does not change that.

The oled screen shows the correct values.

❯ dpkg -l | grep reform-tools
ii  reform-tools                                  1.11                               all          MNT Reform System Tools
❯ dpkg -l | grep lpc
ii  reform2-lpc-dkms                              1.11                               all          dkms driver sources for reform2 lpc
❯ lsmod | grep lpc
reform2_lpc            16384  0

I just installed the firmware a minute ago and it’s working for me in Sway. Your log shows that you have the packages and modules, but you did flash the firmware too, right?

I must say i did not update the new firmware, after I did that, i get a proper reading on the battery level in sway.

It seems that the information is now independent from the information from what the OLED is showing. That is still showing ??? because I’ve just reset the LPC but sway is showing a correct number.

I experienced that too, my guess is it’s the same reason the system controller battery percentage (when it does display one) is not identical to the Waybar/KDE/Gnome battery percentage described by nanocodebug earlier in the thread.

Updating the lpc firmware (or resetting the lpc) clears the full/empty battery charge info. It will take a charge cycle for it to be correct again on the lpc display.

Your desktop environment can be applying its own full/empty charge state logic to the battery indicator as well. I don’t think it will be possible to get these to sync perfectly, but they should generally be within a few percent of each other if everything is working properly.

Really weird…I just ran upgrade again and now I have it, loaded automatically. I wonder why I didn’t get the update sooner! So it worked immediately since everything else was in place.

Has anyone else gotten into a state where the battery percentage is no longer being reported? I forget what triggered it for me (I think I did Circle + R to reset the system controller) but now KDE shows a brightness control where the battery taskbar icon used to be and Sway doesn’t show battery percentage. The tooltip on the KDE brightness control says “No Batteries Available.”

Did you have the kernel module installed manually before and then installed the reform2-lpc-dkms package via the new reform-tools package? Recently on IRC there was a similar situation which solved itself magically: 2022-09-29.log

No, but I did notice that the reform2_lpc module no longer gets loaded, even though reform-tools and reform2-lpc-dkms packages are still installed.

Update: reinstalling reform2-lpc-dkms and rebooting got the module loaded again and battery status is being reported as it was before.

1 Like

FYI I just did a full upgrade after a while away from Reform and the battery status was gone again. Ran sudo apt reinstall reform2-lpc-dkms and cleared that right up.


I was running the 20210925 version of the LPC firmware and with the upgrade to the v6.0 kernel, I lost the battery status info in gnome. Reinstalling the reform2-lpc-dkms didn’t help. I flashed the latest version of the LPC firmware just now and that restored the battery status info in gnome. The LPC firmware version is now reported as 20220621.