Power manager
Power manager environment variables
Since 6.5.0:
On devices with a bq24195 PMIC (M-SoM, Muon, Boron, B-Series SoM, Tracker SoM, Electron, and E-Series), the input current limit and battery charge current can be overridden using environment variables, without changing your firmware:
PARTICLE_PMIC_INPUT_CURRENT: overridespowerSourceMaxCurrent(), in mA. Valid range: 500 to 1500.PARTICLE_PMIC_CHARGE_CURRENT: overridesbatteryChargeCurrent(), in mA. Valid range: 512 to 1500.
A value outside the valid range is ignored, and the value from SystemPowerConfiguration (or its default) is used instead. PARTICLE_PMIC_CHARGE_CURRENT is applied even if it's set higher than the effective input current limit; in that case the PMIC's VINDPM loop will throttle charging at runtime rather than the device enforcing the limit itself.
These overrides only affect what's applied to the PMIC. They do not change the stored SystemPowerConfiguration, so System.getPowerConfiguration() continues to report the values set (or defaulted) in your firmware. The overrides are applied when the Power Manager initializes at boot and whenever System.setPowerConfiguration() is called; changing the environment variables while running does not take effect until the next reset.
See Environment variables for more information on setting these variables.