summaryrefslogtreecommitdiff
path: root/board/glados/board.h
diff options
context:
space:
mode:
authorAlec Berg <alecaberg@chromium.org>2015-06-05 14:25:47 -0700
committerChromeOS Commit Bot <chromeos-commit-bot@chromium.org>2015-06-06 02:55:41 +0000
commitea07b1851b0fef035a253ab2ab4e788228a06a19 (patch)
tree9f6eb428e806a22bbf5ae0757868622d8ed062c5 /board/glados/board.h
parent58719e30730e6420533514dabd27c188e60ae607 (diff)
downloadchrome-ec-ea07b1851b0fef035a253ab2ab4e788228a06a19.tar.gz
glados: enable ADC channels
Enable ADC channels on Glados. For now only VBUS is scaled accurately into mV, the rest are ADC counts. BUG=none BRANCH=none TEST="adc" from EC console and verify VBUS measurement matches for zinger at 20V and donette at 5V. Change-Id: I1af70df5b851ba654c8feb7c97d190d393421a29 Signed-off-by: Alec Berg <alecaberg@chromium.org> Reviewed-on: https://chromium-review.googlesource.com/275685 Reviewed-by: Shawn N <shawnn@chromium.org>
Diffstat (limited to 'board/glados/board.h')
-rw-r--r--board/glados/board.h11
1 files changed, 11 insertions, 0 deletions
diff --git a/board/glados/board.h b/board/glados/board.h
index 44db0f5a3c..4f1eb3dd50 100644
--- a/board/glados/board.h
+++ b/board/glados/board.h
@@ -9,6 +9,7 @@
#define __BOARD_H
/* Optional features */
+#define CONFIG_ADC
#define CONFIG_BATTERY_SMART
#define CONFIG_BUTTON_COUNT 2
@@ -68,6 +69,16 @@
#include "gpio_signal.h"
#include "registers.h"
+/* ADC signal */
+enum adc_channel {
+ ADC_BATT_TEMP,
+ ADC_VBUS,
+ ADC_AMON_BMON,
+ ADC_PSYS,
+ /* Number of ADC channels */
+ ADC_CH_COUNT
+};
+
/* power signal definitions */
enum power_signal {
X86_RSMRST_L_PWRGD = 0,