04-04-2022, 11:43 AM
You can manually control how much current each battery gets. The kb battery has a current limit exposed in sysfs,
/sys/class/power_supply/ip5xxx-charger/constant_charge_current
By default it is 2.3 amps, which seems to be about all the usb interace can muster. If you lower it to something like 1.5amps, then you can raise the limit on the internal battery, and the current will be shifted the the internal battery. If you don't feel like doing this manually I've written a daemon that manages the interaction between the main battery and the kbd battery, available here https://github.com/estokes/pinephone-kbpwrd
/sys/class/power_supply/ip5xxx-charger/constant_charge_current
By default it is 2.3 amps, which seems to be about all the usb interace can muster. If you lower it to something like 1.5amps, then you can raise the limit on the internal battery, and the current will be shifted the the internal battery. If you don't feel like doing this manually I've written a daemon that manages the interaction between the main battery and the kbd battery, available here https://github.com/estokes/pinephone-kbpwrd