kopia lustrzana https://github.com/espressif/esp-idf
fix: clear interrupt in touch sensor initialization
rodzic
48cda62bcf
commit
cfe59031a5
|
@ -896,6 +896,7 @@ static void touch_wakeup_prepare(void)
|
|||
if ((touch_num > TOUCH_PAD_NUM0) && (touch_num < TOUCH_PAD_MAX) && touch_ll_get_fsm_state()) {
|
||||
touch_ll_stop_fsm();
|
||||
touch_ll_clear_channel_mask(TOUCH_PAD_BIT_MASK_ALL);
|
||||
touch_ll_intr_clear(TOUCH_PAD_INTR_MASK_ALL); // Clear state from previous wakeup
|
||||
touch_ll_set_channel_mask(BIT(touch_num));
|
||||
touch_ll_start_fsm();
|
||||
}
|
||||
|
|
|
@ -19,7 +19,9 @@
|
|||
|
||||
void touch_hal_init(void)
|
||||
{
|
||||
touch_ll_stop_fsm();
|
||||
touch_ll_intr_disable();
|
||||
touch_ll_intr_clear();
|
||||
touch_ll_clear_channel_mask(TOUCH_PAD_BIT_MASK_ALL);
|
||||
touch_ll_clear_group_mask(TOUCH_PAD_BIT_MASK_ALL, TOUCH_PAD_BIT_MASK_ALL);
|
||||
touch_ll_set_trigger_mode(TOUCH_TRIGGER_MODE_DEFAULT);
|
||||
|
|
|
@ -20,7 +20,9 @@
|
|||
|
||||
void touch_hal_init(void)
|
||||
{
|
||||
touch_ll_stop_fsm();
|
||||
touch_ll_intr_disable(TOUCH_PAD_INTR_MASK_ALL);
|
||||
touch_ll_intr_clear(TOUCH_PAD_INTR_MASK_ALL);
|
||||
touch_ll_clear_channel_mask(TOUCH_PAD_BIT_MASK_ALL);
|
||||
touch_ll_clear_trigger_status_mask();
|
||||
touch_ll_set_meas_times(TOUCH_PAD_MEASURE_CYCLE_DEFAULT);
|
||||
|
|
|
@ -20,7 +20,9 @@
|
|||
|
||||
void touch_hal_init(void)
|
||||
{
|
||||
touch_ll_stop_fsm();
|
||||
touch_ll_intr_disable(TOUCH_PAD_INTR_MASK_ALL);
|
||||
touch_ll_intr_clear(TOUCH_PAD_INTR_MASK_ALL);
|
||||
touch_ll_clear_channel_mask(TOUCH_PAD_BIT_MASK_ALL);
|
||||
touch_ll_clear_trigger_status_mask();
|
||||
touch_ll_set_meas_times(TOUCH_PAD_MEASURE_CYCLE_DEFAULT);
|
||||
|
|
Ładowanie…
Reference in New Issue