Chapter 2. API Reference
Enumerations
enum touch_slider_event_t
Slider event type.
Values:
TOUCH_SLIDER_EVT_ON_PRESS
Slider on Press event.
TOUCH_SLIDER_EVT_ON_RELEASE
Slider on Release event.
TOUCH_SLIDER_EVT_ON_CALCULATION
Slider on Calculation event.
TOUCH_SLIDER_EVT_MAX
API Reference - Touch Slider
Header File
•
components/touch_element/include/touch_element/touch_matrix.h
Functions
esp_err_t
touch_matrix_install(const
Touch matrix button initialize.
This function initializes touch matrix button object and acts on all touch matrix button instances.
Return
• ESP_OK: Successfully initialized touch matrix button
• ESP_ERR_INVALID_STATE: Touch element library was not initialized
• ESP_ERR_INVALID_ARG: matrix_init is NULL
• ESP_ERR_NO_MEM: Insufficient memory
Parameters
• [in] global_config: Touch matrix global initialization configuration
void touch_matrix_uninstall(void)
Release resources allocated using touch_matrix_install()
Return
• ESP_OK: Successfully released resources
esp_err_t
touch_matrix_create(const
Create a new touch matrix button instance.
Note Channel array and sensitivity array must be one-one correspondence in those array
Note Touch matrix button does not support Multi-Touch now
Return
• ESP_OK: Successfully create touch matrix button
• ESP_ERR_INVALID_STATE: Touch matrix driver was not initialized
• ESP_ERR_INVALID_ARG: Invalid configuration struct or arguments is NULL
• ESP_ERR_NO_MEM: Insufficient memory
Parameters
• [in] matrix_config: Matrix button configuration
• [out] matrix_handle: Matrix button handle
esp_err_t touch_matrix_delete(touch_matrix_handle_t
Release resources allocated using touch_matrix_create()
Return
• ESP_OK: Successfully released resources
• ESP_ERR_INVALID_STATE: Touch matrix driver was not initialized
Espressif Systems
touch_matrix_global_config_t
touch_matrix_config_t
touch_matrix_handle_t
*matrix_handle)
matrix_handle)
439
Submit Document Feedback
*global_config)
*matrix_config,
Release v4.4
Need help?
Do you have a question about the ESP32-S2 and is the answer not in the manual?
Questions and answers