Hi,
I have this on my code:
if (PMIC.chargeStatus() > 0) {
SendChargeNotification(PMIC.chargeStatus()); //satus: 32 - in charge...
//disable everything
DisableGsmModule();
GPS.standby();
while (PMIC.chargeStatus() != 0) {
//charging......
LowPower.sleep(1000);
};
//not charging......
if (PMIC.chargeStatus() == 0) {
SendChargeNotification(PMIC.chargeStatus());
}
}
So, PMIC change from 32 while device is in charging and change to 0 if run in battery..
How I can save the max energy while in charge mode ?
DeepSleep stop everithing.. sleep(1000) to check the value is the best option ?
I need a solution to replace this:
while (PMIC.chargeStatus() != 0) {
//charging......
LowPower.sleep(1000);
};
And save the max energy monitoring only the PMIC Change Status() from PMIC lib.
Thanks