Wrong Battery Charge Level Displayed - How to Fix
#6
Many thanks, @acid andy  Your research and work solved a tough problem.

For Mobian and Manjaro Phosh, I had a difficult time compiling upowerd (I'm generally terrible at compiling), starting with the issue that the compiling programs/libs have different names in Debian and Manjaro. But I finally got to the end and the attached upowerd runs successfully on both my Debian and Manjaro setups.

As acid andy already warns, it is very important to back up your original upowerd. Then, operating on assumption that compiled upowerd is in your home directory, move the file. In Mobian:

Code:
$ sudo mv /usr/libexec/upowerd /usr/libexec/upowerd.orig
$ sudo cp /home/mobian/upowerd /usr/libexec/
$ sudo chmod +x /usr/libexec/upowerd

For Manjaro, the directory is different:

Code:
$ sudo mv /usr/lib/upowerd /usr/lib/upowerd.orig
$ sudo cp /home/manjaro/upowerd /usr/lib/
$ sudo chmod +x /usr/lib/upowerd

If the compiled upowerd doesn't work, the fallout is non-fatal: slow boot, no access to Settings, question mark in place of battery percentage. Just delete the compiled upowerd, rename the saved original back to upowerd, and reboot.

Again, hats off to acid andy, and I hope the attached upowerd saves people some hassle, but buyer beware and all that.


Attached Files
.zip   upowerd.zip (Size: 260.86 KB / Downloads: 89)
  Reply


Messages In This Thread
RE: Wrong Battery Charge Level Displayed - How to Fix - by jakfish - 02-28-2023, 03:08 PM

Possibly Related Threads…
Thread Author Replies Views Last Post
  Increasing battery life slondr 8 3,322 03-19-2024, 02:15 PM
Last Post: aular
  Genode OS Now Live (finally a battery friendly PP OS?) PineFone 0 1,507 02-04-2023, 09:38 AM
Last Post: PineFone
  Interested in learning OS-level programming 8453sixtyfour 6 6,512 04-30-2022, 05:10 PM
Last Post: TRS-80
  Megapixels 1.3.0 - colors feels wrong hashfactory 0 1,149 09-11-2021, 09:26 AM
Last Post: hashfactory
  Pine phone Battery life vs operating system bcnaz 19 21,727 08-27-2021, 09:35 PM
Last Post: bcnaz
  Battery Charge Status not reporting correctly? (KDE Community Edition) Gregorius Techneticies 11 9,032 02-12-2021, 01:01 PM
Last Post: Giddyup
  Battery life for various OS & UI lat 8 9,806 12-21-2020, 08:20 PM
Last Post: ryo
  Low Battery indication (Manjaro/PostmarketOS with phosh) MamlinAV 3 4,534 12-16-2020, 03:44 AM
Last Post: dukla2000
  theoretical battery life on Pinephone hiimtye 6 6,903 12-12-2020, 01:48 AM
Last Post: jmorris

Forum Jump:


Users browsing this thread: 1 Guest(s)