mirror of
https://github.com/Telecominfraproject/OpenCellular.git
synced 2026-01-04 22:11:41 +00:00
Fix a bug in battery temperature cut off
When battery temperature is too low, charging should be paused. BUG=none TEST=none Change-Id: I0de87143f5da810cee70c14ee3c52614b5cf3d3b Reviewed-on: https://gerrit.chromium.org/gerrit/26380 Reviewed-by: Rong Chang <rongchang@chromium.org> Tested-by: Vic Yang <victoryang@chromium.org> Commit-Ready: Vic Yang <victoryang@chromium.org>
This commit is contained in:
@@ -34,7 +34,7 @@ static const struct battery_info info = {
|
||||
*
|
||||
* The temperature values below should be deci-Kelvin
|
||||
*/
|
||||
.temp_charge_min = 0,
|
||||
.temp_charge_min = 0 * 10 + 2731,
|
||||
.temp_charge_max = 45 * 10 + 2731,
|
||||
.temp_discharge_min = -20 * 10 + 2731,
|
||||
.temp_discharge_max = 60 * 10 + 2731,
|
||||
@@ -89,6 +89,7 @@ void battery_vendor_params(struct batt_params *batt)
|
||||
batt->temperature <= info.temp_charge_min) {
|
||||
batt->desired_voltage = 0;
|
||||
batt->desired_current = 0;
|
||||
return;
|
||||
}
|
||||
|
||||
/* Vendor provided charging method
|
||||
|
||||
Reference in New Issue
Block a user