lewisxhe / XPowersLib

Arduino,CircuitPython,Micropython, esp-idf library for x-powers power management series
MIT License
71 stars 22 forks source link

Is there an equivalent to AXP192's getBatteryChargeCurrent and getVbusCurrent in AXP2101? #12

Closed HouzuoGuo closed 12 months ago

HouzuoGuo commented 1 year ago

Hey! I'm porting my ttgo t-beam's code to run on the newer model with AXP2101. For AXP192 I've got these lines of code reading the current consumption:

status.batt_milliamp = pmu->getBatteryChargeCurrent();
status.batt_milliamp = -pmu->getBattDischargeCurrent();
status.power_draw_milliamp = pmu->getVbusCurrent();

Is there an equivalent for AXP2101?

Thanks.

lewisxhe commented 12 months ago

AXP2101 does not have this function, only AXP192 has it