diff options
author | Kangheui Won <khwon@chromium.org> | 2020-08-07 08:50:56 +1000 |
---|---|---|
committer | Commit Bot <commit-bot@chromium.org> | 2020-08-07 09:36:40 +0000 |
commit | 56a23db4b0dfadaa6810f7185fea42cd0e1c1b4e (patch) | |
tree | bd8621495e9a4a976179cbc560c6ea3cecd9da46 /board | |
parent | ff12c670e1cfe05db2b3cc04d6aedf562bde91bb (diff) | |
download | chrome-ec-56a23db4b0dfadaa6810f7185fea42cd0e1c1b4e.tar.gz |
Vilboz: Add configuration for 57w battery
BUG=b:161470405
BRANCH=none
TEST=make buildall -j
Change-Id: I43ee0c265cf039413b910b9ef3a4b11ea38e9391
Signed-off-by: Kangheui Won <khwon@chromium.org>
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/2342177
Reviewed-by: Peter Marheine <pmarheine@chromium.org>
Diffstat (limited to 'board')
-rw-r--r-- | board/vilboz/battery.c | 87 | ||||
-rw-r--r-- | board/vilboz/board.h | 3 |
2 files changed, 90 insertions, 0 deletions
diff --git a/board/vilboz/battery.c b/board/vilboz/battery.c index b5cccdd9cf..f7b4f2cfb6 100644 --- a/board/vilboz/battery.c +++ b/board/vilboz/battery.c @@ -61,6 +61,35 @@ const struct board_batt_params board_battery_info[] = { }, }, + /* SMP L20M3PG1 */ + [BATTERY_SMP_1] = { + .fuel_gauge = { + .manuf_name = "SMP", + .device_name = "L20M3PG1", + .ship_mode = { + .reg_addr = 0x34, + .reg_data = { 0x0000, 0x1000 }, + }, + .fet = { + .reg_addr = 0x00, + .reg_mask = 0x0008, + .disconnect_val = 0x0000, + } + }, + .batt_info = { + .voltage_max = 13200, /* mV */ + .voltage_normal = 11520, /* mV */ + .voltage_min = 9000, /* mV */ + .precharge_current = 247, /* mA */ + .start_charging_min_c = 0, + .start_charging_max_c = 60, + .charging_min_c = 0, + .charging_max_c = 50, + .discharging_min_c = -20, + .discharging_max_c = 60, + }, + }, + /* LGC L19L3PG1 */ [BATTERY_LGC] = { .fuel_gauge = { @@ -90,6 +119,35 @@ const struct board_batt_params board_battery_info[] = { }, }, + /* LGC L20L3PG1 */ + [BATTERY_LGC_1] = { + .fuel_gauge = { + .manuf_name = "LGC2020", + .device_name = "L20L3PG1", + .ship_mode = { + .reg_addr = 0x34, + .reg_data = { 0x0000, 0x1000 }, + }, + .fet = { + .reg_addr = 0x00, + .reg_mask = 0x0008, + .disconnect_val = 0x0000, + } + }, + .batt_info = { + .voltage_max = 13200, /* mV */ + .voltage_normal = 11580, /* mV */ + .voltage_min = 9000, /* mV */ + .precharge_current = 256, /* mA */ + .start_charging_min_c = 0, + .start_charging_max_c = 60, + .charging_min_c = 0, + .charging_max_c = 50, + .discharging_min_c = -20, + .discharging_max_c = 73, + }, + }, + /* Celxpert L19C3PG1 */ [BATTERY_CEL] = { .fuel_gauge = { @@ -118,6 +176,35 @@ const struct board_batt_params board_battery_info[] = { .discharging_max_c = 70, }, }, + + /* SUNWODA L20D3PG1 */ + [BATTERY_SUNWODA] = { + .fuel_gauge = { + .manuf_name = "Sunwoda 2020", + .device_name = "L20D3PG1", + .ship_mode = { + .reg_addr = 0x34, + .reg_data = { 0x0000, 0x1000 }, + }, + .fet = { + .reg_addr = 0x00, + .reg_mask = 0x0008, + .disconnect_val = 0x0000, + } + }, + .batt_info = { + .voltage_max = 13200, /* mV */ + .voltage_normal = 11520, /* mV */ + .voltage_min = 9000, /* mV */ + .precharge_current = 250, /* mA */ + .start_charging_min_c = 0, + .start_charging_max_c = 60, + .charging_min_c = 0, + .charging_max_c = 50, + .discharging_min_c = -20, + .discharging_max_c = 60, + }, + }, }; BUILD_ASSERT(ARRAY_SIZE(board_battery_info) == BATTERY_TYPE_COUNT); diff --git a/board/vilboz/board.h b/board/vilboz/board.h index e6d89f3969..d558c289c3 100644 --- a/board/vilboz/board.h +++ b/board/vilboz/board.h @@ -77,8 +77,11 @@ enum adc_channel { enum battery_type { BATTERY_SMP, + BATTERY_SMP_1, BATTERY_LGC, + BATTERY_LGC_1, BATTERY_CEL, + BATTERY_SUNWODA, BATTERY_TYPE_COUNT, }; |