diff options
author | Kevin K Wong <kevin.k.wong@intel.com> | 2015-10-02 22:53:14 -0700 |
---|---|---|
committer | chrome-bot <chrome-bot@chromium.org> | 2015-10-06 00:00:00 -0700 |
commit | 2cf4269683c78c88a4cd3c211770816ecf55f5d2 (patch) | |
tree | 6bbd9bce5922476aac225f5d1c9e40a93b143a76 | |
parent | 217e72d700257057801ea6ba3620a368a89f9cbd (diff) | |
download | chrome-ec-2cf4269683c78c88a4cd3c211770816ecf55f5d2.tar.gz |
kunimitsu: Correct ADC calculation for VBUS.
According to MEC1322 datasheet, ADC VREF is 3V.
With the voltage divider on Kunimitsu, R1=180K and R2=20K,
so full ADC is equal to 30V if ADC VREF is 3V.
BUG=none
BRANCH=none
TEST=Checked value returned by adc console cmd.
20xxx mV is returned by Zinger.
14xxx mV is returned by Apple charger.
Change-Id: I155ce03e3c840740c1dc3a985a1d5cfcf3b40c30
Signed-off-by: Kevin K Wong <kevin.k.wong@intel.com>
Reviewed-on: https://chromium-review.googlesource.com/304192
Reviewed-by: Shawn N <shawnn@chromium.org>
-rw-r--r-- | board/kunimitsu/board.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/board/kunimitsu/board.c b/board/kunimitsu/board.c index 580c5b13a8..a487b6418c 100644 --- a/board/kunimitsu/board.c +++ b/board/kunimitsu/board.c @@ -98,8 +98,8 @@ BUILD_ASSERT(ARRAY_SIZE(power_signal_list) == POWER_SIGNAL_COUNT); /* ADC channels */ const struct adc_t adc_channels[] = { - /* Vbus sensing. Converted to mV, full ADC is equivalent to 33V. */ - [ADC_VBUS] = {"VBUS", 33000, 1024, 0, 1}, + /* Vbus sensing. Converted to mV, full ADC is equivalent to 30V. */ + [ADC_VBUS] = {"VBUS", 30000, 1024, 0, 1}, /* Adapter current output or battery discharging current */ [ADC_AMON_BMON] = {"AMON_BMON", 1, 1, 0, 3}, /* |