diff options
author | Ben Lok <ben.lok@mediatek.com> | 2015-10-16 12:12:15 +0800 |
---|---|---|
committer | chrome-bot <chrome-bot@chromium.org> | 2015-11-03 09:08:00 -0800 |
commit | 59fd91317ce966d713b4ec077b39f385e6029e18 (patch) | |
tree | 6f6788dfb743c331f68638bba40d256bfe27999b | |
parent | 2ea7b194d928950db1aed87097975a8ffb9df2ac (diff) | |
download | chrome-ec-59fd91317ce966d713b4ec077b39f385e6029e18.tar.gz |
oak: Adding 2S and 3S battery support
The default battery type of Oak is 3S, in order to compatible to
2S battery, set the minimum voltage of battery to 6V rather than 9V.
BRANCH=none
BUG=chrome-os-partner:46540
TEST=manual
1. connect 2S battery to rev4
2. check the battery info with EC command:
> battery
3. confirm the voltage of battery is match to setting of battery_info.
Change-Id: Ieb7e39817bb0cefa523f73039b68943adb50f045
Signed-off-by: Ben Lok <ben.lok@mediatek.com>
Reviewed-on: https://chromium-review.googlesource.com/306381
Tested-by: Rong Chang <rongchang@chromium.org>
Reviewed-by: Rong Chang <rongchang@chromium.org>
-rw-r--r-- | board/oak/battery.c | 8 |
1 files changed, 2 insertions, 6 deletions
diff --git a/board/oak/battery.c b/board/oak/battery.c index 844765a5ac..a3fe0cd452 100644 --- a/board/oak/battery.c +++ b/board/oak/battery.c @@ -15,17 +15,13 @@ #define PARAM_CUT_OFF_HIGH 0x00 static const struct battery_info info = { -#if (BOARD_REV > OAK_REV3) - .voltage_max = 13050, - .voltage_normal = 11400, - .voltage_min = 9000, -#elif (BOARD_REV == OAK_REV3) +#if (BOARD_REV >= OAK_REV3) .voltage_max = 13050, .voltage_normal = 11400, /* * TODO(crosbug.com/p/44428): * In order to compatible with 2S battery, set min voltage as 6V rather - * than 9V temporarily. Should set voltage_min to 9V, when 2S battery + * than 9V. Should set voltage_min to 9V, when 2S battery * phased out. */ .voltage_min = 6000, |