Report battery % / charging
Updated by Victor Shilin about 1 month ago
The battery driver needs to use VF SOC register in order to report the charge percentage correctly (the following patch by Wolfgang Wiedmeyer made this work on Replicant 11: https://github.com/fourkbomb/linux/commit/7da07efcb2efc5df8fd7ab0be01a7b0b7a483998).
The charger driver reports "Discharging" (in the status sysfs node) even when the cable is connected (the "online" sysfs node, however, is showing the value "1").
I tried to force the "status" node to return "Charging" instead (whenever the "online" node reports value "1"), but this didn't help (need to investigate how exactly the healthd service detects charging).
Updated by Kurtis Hanna 27 days ago
Not sure if this helps at all, but here is a max17047 related commit from upstream that was added a few months ago. https://email@example.com/
Updated by Victor Shilin 21 days ago
healthd service detected device charging after setting the charger driver type from POWER_SUPPLY_TYPE_BATTERY to POWER_SUPPLY_TYPE_MAINS:
Not sure if this the correct way to resolve the issue, though.
smdk4412 kernel instead use "samsung_fake_battery" driver to create "usb" and "ac" power supplies: