Skip to content

Commit

Permalink
Optimize charging parameters Add charging completion identifier. Upda…
Browse files Browse the repository at this point in the history
…te firmware;
  • Loading branch information
ShallowGreen123 committed Jan 9, 2025
1 parent f15d77d commit f5ad853
Show file tree
Hide file tree
Showing 10 changed files with 1,128 additions and 327 deletions.
15 changes: 14 additions & 1 deletion examples/factory_test/factory_test.ino
Original file line number Diff line number Diff line change
Expand Up @@ -408,9 +408,22 @@ void setup(void)
Serial.printf("getChargerConstantCurr: %d mA\n",PPM.getChargerConstantCurr());
PPM.enableADCMeasure();
PPM.enableCharge();
// Turn off charging function
// If USB is used as the only power input, it is best to turn off the charging function,
// otherwise the VSYS power supply will have a sawtooth wave, affecting the discharge output capability.
// PPM.disableCharge();


// The OTG function needs to enable OTG, and set the OTG control pin to HIGH
// After OTG is enabled, if an external power supply is plugged in, OTG will be turned off

PPM.enableOTG();
PPM.disableOTG();
// pinMode(OTG_ENABLE_PIN, OUTPUT);
// digitalWrite(OTG_ENABLE_PIN, HIGH);
}

bq27220.reset();
bq27220.init();

if(lora_ret)
lora_init();
Expand Down
Loading

0 comments on commit f5ad853

Please sign in to comment.