feat(touch): support touch driver on p4 (soc)

This commit is contained in:
laokaiyao
2023-08-25 16:52:05 +08:00
committed by Kevin (Lao Kaiyao)
parent dd5b091a8b
commit f35ec64a0b
27 changed files with 1237 additions and 1190 deletions

View File

@@ -895,9 +895,9 @@ config SOC_TIMER_GROUP_TOTAL_TIMERS
int
default 4
config SOC_TOUCH_VERSION_2
bool
default y
config SOC_TOUCH_SENSOR_VERSION
int
default 2
config SOC_TOUCH_SENSOR_NUM
int
@@ -911,13 +911,9 @@ config SOC_TOUCH_PROXIMITY_MEAS_DONE_SUPPORTED
bool
default y
config SOC_TOUCH_PAD_THRESHOLD_MAX
hex
default 0x1FFFFF
config SOC_TOUCH_PAD_MEASURE_WAIT_MAX
hex
default 0xFF
config SOC_TOUCH_SAMPLER_NUM
int
default 1
config SOC_TWAI_CONTROLLER_NUM
int

View File

@@ -357,13 +357,12 @@
#define SOC_TIMER_GROUP_TOTAL_TIMERS (4)
/*-------------------------- TOUCH SENSOR CAPS -------------------------------*/
#define SOC_TOUCH_VERSION_2 (1) // Hardware version of touch sensor
#define SOC_TOUCH_SENSOR_VERSION (2) // Hardware version of touch sensor
#define SOC_TOUCH_SENSOR_NUM (15) /*! 15 Touch channels */
#define SOC_TOUCH_PROXIMITY_CHANNEL_NUM (3) /* Sopport touch proximity channel number. */
#define SOC_TOUCH_PROXIMITY_MEAS_DONE_SUPPORTED (1) /*Sopport touch proximity channel measure done interrupt type. */
#define SOC_TOUCH_PAD_THRESHOLD_MAX (0x1FFFFF) /*!<If set touch threshold max value, The touch sensor can't be in touched status */
#define SOC_TOUCH_PAD_MEASURE_WAIT_MAX (0xFF) /*!<The timer frequency is 8Mhz, the max value is 0xff */
#define SOC_TOUCH_SAMPLER_NUM (1U) /*!< The sampler number in total, each sampler can be used to sample on one frequency */
/*-------------------------- TWAI CAPS ---------------------------------------*/
#define SOC_TWAI_CONTROLLER_NUM 1UL