We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Hello,
I can´t get the battery to charge when connected to USB, unless I get back to Factory app
I'm using this code: lib: lewisxhe/XPowersLib @ ^0.2.6
#include <XPowersLib.h> extern XPowersPPM PPM; void setup() { // code code Wire.begin(8, 18); pmu_ret = PPM.init(Wire, 8, 18, BQ25896_SLAVE_ADDRESS); if(pmu_ret) { PPM.setSysPowerDownVoltage(3300); PPM.setInputCurrentLimit(3250); Serial.printf("getInputCurrentLimit: %d mA\n",PPM.getInputCurrentLimit()); PPM.disableCurrentLimitPin(); PPM.setChargeTargetVoltage(4208); PPM.setPrechargeCurr(64); PPM.setChargerConstantCurr(832); PPM.getChargerConstantCurr(); Serial.printf("getChargerConstantCurr: %d mA\n",PPM.getChargerConstantCurr()); PPM.enableADCMeasure(); PPM.enableCharge(); } // code code }
The text was updated successfully, but these errors were encountered:
Try examples/bq25896_test
examples/bq25896_test
The example uses the library lewisxhe/ XPowersLib@ ^0.2.4
After downloading this program, open the serial port;
Sorry, something went wrong.
I changed the library and tested with the example setup, didn´t work either..
it only worked afer add: ´´´ PPM.enableOTG(); PPM.disableOTG(); ´´´
the working code was:
bool pmu_ret = false; Wire.begin(8, 18); pmu_ret = PPM.init(Wire, 8, 18, BQ25896_SLAVE_ADDRESS); if(pmu_ret) { PPM.setSysPowerDownVoltage(3300); PPM.setInputCurrentLimit(3250); Serial.printf("getInputCurrentLimit: %d mA\n",PPM.getInputCurrentLimit()); PPM.disableCurrentLimitPin(); PPM.setChargeTargetVoltage(4208); PPM.setPrechargeCurr(64); PPM.setChargerConstantCurr(832); PPM.getChargerConstantCurr(); Serial.printf("getChargerConstantCurr: %d mA\n",PPM.getChargerConstantCurr()); PPM.enableADCMeasure(); PPM.enableCharge(); } PPM.enableOTG(); PPM.disableOTG();
thank you for your help.
No branches or pull requests
Hello,
I can´t get the battery to charge when connected to USB, unless I get back to Factory app
I'm using this code:
lib: lewisxhe/XPowersLib @ ^0.2.6
The text was updated successfully, but these errors were encountered: