summaryrefslogtreecommitdiff
path: root/board/hammer
diff options
context:
space:
mode:
authorNicolas Boichat <drinkcat@chromium.org>2017-12-22 10:56:01 +0800
committerchrome-bot <chrome-bot@chromium.org>2018-01-04 21:52:00 -0800
commit41af1bf27c0e983523a055d2567bc15e7814e289 (patch)
treed16f1c101c2f8658ec1998127fbe93c4f7258dc8 /board/hammer
parent113602c06e2fac46ca7d29433bb2a62864c633c5 (diff)
downloadchrome-ec-41af1bf27c0e983523a055d2567bc15e7814e289.tar.gz
wand: Make sure battery is cut-off when critical
Modify chipset_in_state to always say that the chipset is off, when we do not actually have a chipset (like on hammer): that makes sure the battery can actually be cut off (else the EC would just wait forever for the chipset to turn off). Also, wake the charger state on "AC" change, that is, when charging_allowed changes state, to make sure the charging loop is executed after lux tries to charge it (else the charging loop would wait until timeout expires, and wand would ask the battery to be cut off again). BRANCH=none BUG=b:65697962 TEST=Deplete wand battery, reboot without providing external power to it. After 30 seconds, battery is cut off: [1.354683 Low battery: 2%, 6866mV] [1.354888 charge warn shutdown due to critical battery] [31.381410 Low battery: 2%, 6865mV] [31.381643 charge force battery cut-off due to critical level] TEST=Upon providing power to wand, charging loop is executed regularly, and battery is charging. Change-Id: I7154b25bd852b8422a0ae3b506675a297a948132 Signed-off-by: Nicolas Boichat <drinkcat@chromium.org> Reviewed-on: https://chromium-review.googlesource.com/842742 Reviewed-by: Randall Spangler <rspangler@chromium.org>
Diffstat (limited to 'board/hammer')
-rw-r--r--board/hammer/board.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/board/hammer/board.h b/board/hammer/board.h
index 4c9675f312..0b04ced2cd 100644
--- a/board/hammer/board.h
+++ b/board/hammer/board.h
@@ -230,6 +230,7 @@
#define CONFIG_CHARGER_SENSE_RESISTOR_AC 20
#define CONFIG_CHARGER_DISCHARGE_ON_AC
+#define CONFIG_BATTERY_CRITICAL_SHUTDOWN_CUT_OFF
#define CONFIG_BATTERY_CUT_OFF
#define CONFIG_BATTERY_SMART