diff options
author | Ben Chen <ben.chen2@quanta.corp-partner.google.com> | 2020-09-25 16:54:54 +0800 |
---|---|---|
committer | Commit Bot <commit-bot@chromium.org> | 2020-09-29 22:58:54 +0000 |
commit | 133c6096ffd81cf5e7d62334ccc12d67e14e7830 (patch) | |
tree | bcba788b4c644fd9ed2125edb337bfaf70089319 /include/button.h | |
parent | f366710eb8076fb45609ca4a3878cf6f7796c1e5 (diff) | |
download | chrome-ec-133c6096ffd81cf5e7d62334ccc12d67e14e7830.tar.gz |
button: presss volume button detected by adc
supports volume up/dwon pressed by adc buttons config
BUG=b:167319238
BRANCH=master
TEST=make buildall pass
Change-Id: Ide3522b4af3c92df906bafb1f944f138a822280a
Signed-off-by: Ben Chen <ben.chen2@quanta.corp-partner.google.com>
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/2431310
Reviewed-by: Aseda Aboagye <aaboagye@chromium.org>
Commit-Queue: Aseda Aboagye <aaboagye@chromium.org>
Tested-by: Aseda Aboagye <aaboagye@chromium.org>
Diffstat (limited to 'include/button.h')
-rw-r--r-- | include/button.h | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/include/button.h b/include/button.h index 381e650550..ec0a7afdc2 100644 --- a/include/button.h +++ b/include/button.h @@ -87,4 +87,18 @@ int button_disable_gpio(enum button button_type); */ void button_interrupt(enum gpio_signal signal); +/* + * determined which buttons connected ADC + * + * @param signal Signal which triggered the interrupt. + */ +int button_is_adc_detected(enum gpio_signal gpio); + +/* + * distinct which buttons determined by ADC voltage + * + * @param signal Signal which triggered the interrupt. + */ +int adc_to_physical_value(enum gpio_signal gpio); + #endif /* __CROS_EC_BUTTON_H */ |