[PATCH] button: adc: set state to pressed when the voltage is closest to nominal
Tom Rini
trini at konsulko.com
Fri Feb 11 18:07:12 CET 2022
On Wed, Feb 02, 2022 at 01:04:04PM -0500, Peter Cai wrote:
> In the Linux implementation of adc-keys
> (drivers/input/keyboard/adc-keys.c), `press-threshold-microvolt` is not
> really interpreted as a threshold, but rather as the "nominal voltage"
> of the button. When the voltage read from the ADC is closest to a
> button's `press-threshold-microvolt`, the button is considered pressed.
>
> This patch reconciles the behavior of button-adc with Linux's adc-keys
> such that device trees can be synchronized with minimal modifications.
>
> Signed-off-by: Peter Cai <peter at typeblog.net>
Applied to u-boot/master, thanks!
--
Tom
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 659 bytes
Desc: not available
URL: <https://lists.denx.de/pipermail/u-boot/attachments/20220211/3b54e5d2/attachment.sig>
More information about the U-Boot
mailing list