Touch Element - Espressif ESP32-S2 Programming Manual

Table of Contents

Advertisement

Chapter 2. API Reference
TOUCH_PAD_FILTER_IIR_4 = 0
The filter mode is first-order IIR filter. The coefficient is 4.
TOUCH_PAD_FILTER_IIR_8
The filter mode is first-order IIR filter. The coefficient is 8.
TOUCH_PAD_FILTER_IIR_16
The filter mode is first-order IIR filter. The coefficient is 16 (Typical value).
TOUCH_PAD_FILTER_IIR_32
The filter mode is first-order IIR filter. The coefficient is 32.
TOUCH_PAD_FILTER_IIR_64
The filter mode is first-order IIR filter. The coefficient is 64.
TOUCH_PAD_FILTER_IIR_128
The filter mode is first-order IIR filter. The coefficient is 128.
TOUCH_PAD_FILTER_IIR_256
The filter mode is first-order IIR filter. The coefficient is 256.
TOUCH_PAD_FILTER_JITTER
The filter mode is jitter filter
TOUCH_PAD_FILTER_MAX
enum touch_smooth_mode_t
Level of filter applied on the original data against large noise interference.
Note On ESP32S2. There is an error in the IIR calculation. The magnitude of the error is twice the filter
coefficient. So please select a smaller filter coefficient on the basis of meeting the filtering requirements.
Recommended filter coefficient selection IIR_2.
Values:
TOUCH_PAD_SMOOTH_OFF = 0
No filtering of raw data.
TOUCH_PAD_SMOOTH_IIR_2 = 1
Filter the raw data. The coefficient is 2 (Typical value).
TOUCH_PAD_SMOOTH_IIR_4 = 2
Filter the raw data. The coefficient is 4.
TOUCH_PAD_SMOOTH_IIR_8 = 3
Filter the raw data. The coefficient is 8.
TOUCH_PAD_SMOOTH_MAX

2.2.21 Touch Element

Overview
Touch Element library provides a high level abstraction for building capacitive touch applications. The library's
implementation gives a unified and friendly software interface thus allows for smooth and easy capacitive touch
application development. The library is implemented atop the touch sensor driver (please see
API Reference
for more information regarding low level API usage).
Architecture
Touch Element library configures touch sensor peripherals via touch sensor driver. While some
necessary hardware parameters should be passed to
tomatically only after calling touch_element_start(), because it will make great influence on the run-time
system.
These parameters include touch channel threshold, waterproof shield sensor driver-level and etc. Touch Element
library sets touch sensor interrupt and esp-timer routine up and the hardware information of touch sensor (channel
Espressif Systems
touch_element_install()
418
Submit Document Feedback
Touch sensor driver
and will be configured au-
Release v4.4

Advertisement

Table of Contents
loading
Need help?

Need help?

Do you have a question about the ESP32-S2 and is the answer not in the manual?

Subscribe to Our Youtube Channel

Table of Contents

Save PDF