drivers: input: cap1203, rename to cap12xx
rename cap1203 to cap12xx to support 3 to 8 channels Signed-off-by: Lothar Felten <lothar.felten@gmail.com>
This commit is contained in:
parent
73a45a7012
commit
058f107089
7 changed files with 34 additions and 34 deletions
|
@ -7,7 +7,7 @@ zephyr_library_property(ALLOW_EMPTY TRUE)
|
|||
zephyr_library_sources_ifdef(CONFIG_INPUT_ADC_KEYS input_adc_keys.c)
|
||||
zephyr_library_sources_ifdef(CONFIG_INPUT_ANALOG_AXIS input_analog_axis.c)
|
||||
zephyr_library_sources_ifdef(CONFIG_INPUT_ANALOG_AXIS_SETTINGS input_analog_axis_settings.c)
|
||||
zephyr_library_sources_ifdef(CONFIG_INPUT_CAP1203 input_cap1203.c)
|
||||
zephyr_library_sources_ifdef(CONFIG_INPUT_CAP12XX input_cap12xx.c)
|
||||
zephyr_library_sources_ifdef(CONFIG_INPUT_CF1133 input_cf1133.c)
|
||||
zephyr_library_sources_ifdef(CONFIG_INPUT_CHSC6X input_chsc6x.c)
|
||||
zephyr_library_sources_ifdef(CONFIG_INPUT_CST816S input_cst816s.c)
|
||||
|
|
|
@ -8,7 +8,7 @@ menu "Input drivers"
|
|||
# zephyr-keep-sorted-start
|
||||
source "drivers/input/Kconfig.adc_keys"
|
||||
source "drivers/input/Kconfig.analog_axis"
|
||||
source "drivers/input/Kconfig.cap1203"
|
||||
source "drivers/input/Kconfig.cap12xx"
|
||||
source "drivers/input/Kconfig.cf1133"
|
||||
source "drivers/input/Kconfig.chsc6x"
|
||||
source "drivers/input/Kconfig.cst816s"
|
||||
|
|
|
@ -1,27 +0,0 @@
|
|||
# Copyright (c) 2022 Keiya Nobuta
|
||||
# SPDX-License-Identifier: Apache-2.0
|
||||
|
||||
menuconfig INPUT_CAP1203
|
||||
bool "CAP1203 3-cannel capacitive touch sensor driver"
|
||||
default y
|
||||
depends on DT_HAS_MICROCHIP_CAP1203_ENABLED
|
||||
select I2C
|
||||
help
|
||||
Enable driver for microchip CAP1203 3-cannel capacitive
|
||||
touch sensor.
|
||||
|
||||
if INPUT_CAP1203
|
||||
|
||||
config INPUT_CAP1203_POLL
|
||||
bool "Polling"
|
||||
help
|
||||
Enable polling mode when interrupt GPIO is not specified.
|
||||
|
||||
config INPUT_CAP1203_PERIOD
|
||||
int "Sample period"
|
||||
depends on INPUT_CAP1203_POLL
|
||||
default 10
|
||||
help
|
||||
Sample period in milliseconds when in polling mode.
|
||||
|
||||
endif # INPUT_CAP1203
|
27
drivers/input/Kconfig.cap12xx
Normal file
27
drivers/input/Kconfig.cap12xx
Normal file
|
@ -0,0 +1,27 @@
|
|||
# Copyright (c) 2022 Keiya Nobuta
|
||||
# SPDX-License-Identifier: Apache-2.0
|
||||
|
||||
menuconfig INPUT_CAP12XX
|
||||
bool "cap12xx 3-cannel capacitive touch sensor driver"
|
||||
default y
|
||||
depends on DT_HAS_MICROCHIP_CAP12XX_ENABLED
|
||||
select I2C
|
||||
help
|
||||
Enable driver for microchip cap12xx 3-cannel capacitive
|
||||
touch sensor.
|
||||
|
||||
if INPUT_CAP12XX
|
||||
|
||||
config INPUT_CAP12XX_POLL
|
||||
bool "Polling"
|
||||
help
|
||||
Enable polling mode when interrupt GPIO is not specified.
|
||||
|
||||
config INPUT_CAP1XX3_PERIOD
|
||||
int "Sample period"
|
||||
depends on INPUT_CAP12XX_POLL
|
||||
default 10
|
||||
help
|
||||
Sample period in milliseconds when in polling mode.
|
||||
|
||||
endif # INPUT_CAP12XX
|
|
@ -1,9 +1,9 @@
|
|||
# Copyright (c) 2022 Keiya Nobuta
|
||||
# SPDX-License-Identifier: Apache-2.0
|
||||
|
||||
description: CAP1203 3-channel capacitive touch sensor
|
||||
description: cap12xx 3-channel capacitive touch sensor
|
||||
|
||||
compatible: "microchip,cap1203"
|
||||
compatible: "microchip,cap12xx"
|
||||
|
||||
include: i2c-device.yaml
|
||||
|
||||
|
@ -15,4 +15,4 @@ properties:
|
|||
type: array
|
||||
required: true
|
||||
description: |
|
||||
Array of input event key codes (INPUT_KEY_* or INPUT_BTN_*).
|
||||
array of input event key codes (INPUT_KEY_* or INPUT_BTN_*).
|
|
@ -210,8 +210,8 @@
|
|||
rst-gpios = <&test_gpio 1 0>;
|
||||
};
|
||||
|
||||
cap1203@3 {
|
||||
compatible = "microchip,cap1203";
|
||||
cap12xx@3 {
|
||||
compatible = "microchip,cap12xx";
|
||||
reg = <0x3>;
|
||||
int-gpios = <&test_gpio 0 0>;
|
||||
input-codes = <0 1 2>;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue