7 #include <esp_idf_version.h> 11 #include <driver/touch_sensor.h> 14 namespace esp32_touch {
16 class ESP32TouchBinarySensor;
34 #if defined(USE_ESP32_VARIANT_ESP32S2) || defined(USE_ESP32_VARIANT_ESP32S3) 52 void setup()
override;
60 #if defined(USE_ESP32_VARIANT_ESP32S2) || defined(USE_ESP32_VARIANT_ESP32S3) 65 return (this->
grade_ != TOUCH_PAD_DENOISE_MAX) && (this->
cap_level_ != TOUCH_PAD_DENOISE_CAP_MAX);
84 #if defined(USE_ESP32_VARIANT_ESP32S2) || defined(USE_ESP32_VARIANT_ESP32S3) 90 touch_pad_denoise_grade_t
grade_{TOUCH_PAD_DENOISE_MAX};
91 touch_pad_denoise_cap_t
cap_level_{TOUCH_PAD_DENOISE_CAP_MAX};
113 touch_pad_t touch_pad_{TOUCH_PAD_MAX};
114 uint32_t threshold_{0};
116 const uint32_t wakeup_threshold_{0};
const float DATA
For components that import data from directly connected sensors like DHT.
uint32_t setup_mode_last_log_print_
void on_shutdown() override
uint32_t get_threshold() const
friend ESP32TouchComponent
touch_filter_mode_t filter_mode_
void set_denoise_grade(touch_pad_denoise_grade_t denoise_grade)
bool iir_filter_enabled_() const
touch_smooth_mode_t smooth_level_
std::vector< ESP32TouchBinarySensor * > children_
touch_pad_denoise_cap_t cap_level_
void set_setup_mode(bool setup_mode)
bool filter_configured_() const
void dump_config() override
void set_debounce_count(uint32_t debounce_count)
uint32_t component_touch_pad_read(touch_pad_t tp)
float get_setup_priority() const override
void set_low_voltage_reference(touch_low_volt_t low_voltage_reference)
void set_measurement_duration(uint16_t meas_cycle)
uint32_t get_value() const
uint32_t get_wakeup_threshold() const
void set_denoise_cap(touch_pad_denoise_cap_t cap_level)
void register_touch_pad(ESP32TouchBinarySensor *pad)
touch_volt_atten_t voltage_attenuation_
void set_noise_threshold(uint32_t noise_threshold)
touch_pad_shield_driver_t waterproof_shield_driver_
void set_iir_filter(uint32_t iir_filter)
touch_high_volt_t high_voltage_reference_
uint32_t noise_threshold_
void set_waterproof_shield_driver(touch_pad_shield_driver_t drive_capability)
void set_filter_mode(touch_filter_mode_t filter_mode)
void set_jitter_step(uint32_t jitter_step)
touch_pad_t get_touch_pad() const
void set_sleep_duration(uint16_t sleep_duration)
void set_voltage_attenuation(touch_volt_atten_t voltage_attenuation)
Implementation of SPI Controller mode.
Base class for all binary_sensor-type classes.
void set_waterproof_guard_ring_pad(touch_pad_t pad)
void set_high_voltage_reference(touch_high_volt_t high_voltage_reference)
void set_threshold(uint32_t threshold)
bool denoise_configured_() const
Simple helper class to expose a touch pad value as a binary sensor.
bool waterproof_configured_() const
touch_pad_denoise_grade_t grade_
touch_low_volt_t low_voltage_reference_
touch_pad_t waterproof_guard_ring_pad_
void set_smooth_level(touch_smooth_mode_t smooth_level)