Query state of button (pressed: yes/no?)
Posted: Wed Aug 02, 2017 4:14 pm
How can i ask/query the state of a button? Like digitalread, if gpio == ghigh, etc in Arduino IDE? I found the gpio test example
https://github.com/espressif/esp-idf/bl ... pio_test.c
but i cant see how i can query the state of the button (which lines, searching simple example)? only thing i know is
to define my button as output.
https://github.com/espressif/esp-idf/bl ... pio_test.c
but i cant see how i can query the state of the button (which lines, searching simple example)? only thing i know is
Code: Select all
gpio_set_direction(BLINK_GPIO, GPIO_MODE_OUTPUT)