-
Notifications
You must be signed in to change notification settings - Fork 7.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
interrupt from touch TO non-touch (release)? (IDFGH-5837) #7539
Comments
Hello @mahesh2000 , The documentation for Touch Sensor states that it is possible to trigger the interrupt when your sensor goes below your threshold. Here is the function:
So you can call it with:
This will let you detect when a release has occurred |
hi @o-marshmallow, thank you. i will try this. |
@o-marshmallow, that WORKED!! i used pin code snippets below. works on Arduino, too.
more details:
|
@mahesh2000 Glad it worked! |
@o-marshmallow, that's too bad. .Also, I didn't quite understand SET1 and SET2 in touch. Are there actually 20 touch inputs, and you can select one or the other? What would be the benefit of that? Also, is there any difference between touch_pad_config(...) and touch_pad_thresh(...)? Thanks! |
@mahesh2000 Explanations:
For the given values, Set1 only contains touch sensor 2 (GPIO2), whereas Set2 contains touch sensor 0 (GPIO4). It is possible to have multiple sensors within one set, so it is possible to have the Then, it is possible to configure which set(s) must be touched to wake up the device, two possibilities: set1 only or both sets. Another note, About |
Thanks for reporting, feel free to reopen. |
hi, is there a way to trigger an interrupt if the touch sensor goes from touch to release of touch? the reverse of normal operation? thanks!
esp-idf/examples/peripherals/touch_pad_interrupt/main/esp32/tp_interrupt_main.c
Line 1 in dd491ee
The text was updated successfully, but these errors were encountered: