Reseting the Battery Fuel Gauge
#9
(01-23-2025, 10:05 AM)franzthiemann Wrote:
(01-20-2025, 11:04 AM)biketool Wrote:
(01-20-2025, 09:52 AM)franzthiemann Wrote:
(01-15-2025, 10:24 AM)biketool Wrote: I had to deal with this yesterday.  I recalled that if you reboot a few times it would reset, no, that doesn't work.

Seems like rebooting is not what resets the controller, but waiting out the calibration error time of the controller

how much time for it to timeout?

I would guess that the RK818 is configured to 16 min.
The value is configured via bits 4 and 5 in the GGCON_REG (according to the datasheet). Possible options are 8 min, 16 min, 32 min or 48 min.
To get the exact time, one would need to check the register. This brings us back to the beginning: How to communicate with this chip?

I have been looking into this. It's on an i2c bus. On FreeBSD for example, I can do this to read the GGCON_REG:

Code:
i2c -a 0x1c -f /dev/iic1 -o 0xb0 -d r -c 1

On Linux though, there isn't even /dev/iic or /dev/i2c devices (there's iio:device but not sure if that's the same). There is /sys/bus/i2c/.. but that doesn't seem to work with i2c-tools. I'm considering compiling the rk818 battery driver and then dynamically loading it with modprobe so that I can experiment with changes to some of it's settings.
  Reply


Messages In This Thread
RE: Reseting the Battery Fuel Gauge - by biketool - 01-15-2025, 10:24 AM
RE: Reseting the Battery Fuel Gauge - by biketool - 01-20-2025, 11:04 AM
RE: Reseting the Battery Fuel Gauge - by biketool - 01-24-2025, 07:19 AM
RE: Reseting the Battery Fuel Gauge - by teekay - 01-24-2025, 08:19 AM

Possibly Related Threads…
Thread Author Replies Views Last Post
  Experimental Mobian kernel patch for extended battery life teekay 13 10,174 09-23-2025, 10:29 PM
Last Post: teekay
  Battery Management on PinePhonePro: d50zesl0g@mozmail.com 4 2,226 03-02-2025, 11:52 AM
Last Post: d50zesl0g@mozmail.com
  Battery life thread: discussion, support and tips apink 12 9,347 03-01-2025, 10:39 AM
Last Post: d50zesl0g@mozmail.com
  [Mobian] : Battery consumption and OS compatibility freelectro 2 2,633 06-02-2023, 06:55 AM
Last Post: Fred Zyphal
  Phosh Updating - Battery Charge Indicator - Jittery Settings - Display Usability ArchiMark 4 3,711 05-28-2023, 07:00 AM
Last Post: ArchiMark
  Battery meter slowly reducing under keyboard charger robocone 1 2,625 12-26-2022, 09:37 AM
Last Post: robocone
Exclamation PPP Battery drain + hot CPU GPU Piotr 2 2,973 12-09-2022, 12:45 PM
Last Post: Piotr
  Battery status always "Charging" dabigjhall 2 3,236 03-16-2022, 03:14 PM
Last Post: maltee

Forum Jump:


Users browsing this thread: 1 Guest(s)