touch_pad_config vs touch_pad_set_thresh? No difference?

mezzynine
Posts: 12
Joined: Fri Feb 07, 2020 8:05 am

touch_pad_config vs touch_pad_set_thresh? No difference?

Postby mezzynine » Sun Sep 26, 2021 1:53 pm

Hi, what's the difference between touch_pad_config() and touch_pad_set_thresh()? They take the same parameters:

Code: Select all

esp_err_t touch_pad_config(touch_pad_t touch_num, uint16_t threshold)

esp_err_t touch_pad_set_thresh(touch_pad_t touch_num, uint16_t threshold)

mezzynine
Posts: 12
Joined: Fri Feb 07, 2020 8:05 am

Re: touch_pad_config vs touch_pad_set_thresh? No difference?

Postby mezzynine » Sun Sep 26, 2021 2:09 pm

The answer, from o-marshmallow
(https://github.com/o-marshmallow) on the ESP32 IDF github:
About touch_pad_thresh, its goal is to modify the threshold at runtime, whereas touch_pad_config is used for initialization. It does more than setting the threshold.

https://github.com/espressif/esp-idf/is ... -927284245

Who is online

Users browsing this forum: No registered users and 131 guests