|
Zephyr Project API
3.3.0
A Scalable Open Source RTOS
|
GPIO Keys Driver APIs. More...
Data Structures | |
| struct | gpio_keys_api |
Functions | |
| int | gpio_keys_enable_interrupt (const struct device *dev, gpio_keys_callback_handler_t cb) |
| Enable interrupt. More... | |
| int | gpio_keys_disable_interrupt (const struct device *dev) |
| Disable interrupt. More... | |
| int | gpio_keys_get_pin (const struct device *dev, uint32_t idx) |
| Get the logical level of GPIO Key. More... | |
GPIO Keys Driver APIs.
| int gpio_keys_disable_interrupt | ( | const struct device * | dev | ) |
#include <include/zephyr/drivers/gpio_keys.h>
Disable interrupt.
| dev | Pointer to device structure for the driver instance. |
| int gpio_keys_enable_interrupt | ( | const struct device * | dev, |
| gpio_keys_callback_handler_t | cb | ||
| ) |
#include <include/zephyr/drivers/gpio_keys.h>
Enable interrupt.
| dev | Pointer to device structure for the driver instance. |
| cb | Function callback to be invoked after GPIO key has been debounced |
#include <include/zephyr/drivers/gpio_keys.h>
Get the logical level of GPIO Key.
| dev | Pointer to device structure for the driver instance. |
| idx | GPIO Key index in device tree |
| 0 | If successful. |
| -EIO | I/O error when accessing an external GPIO chip. |
| -EWOULDBLOCK | if operation would block. |