|
Zephyr API Documentation
2.7.0-rc2
A Scalable Open Source RTOS
|
KSCAN APIs. More...
Typedefs | |
| typedef void(* | kscan_callback_t) (const struct device *dev, uint32_t row, uint32_t column, bool pressed) |
| Keyboard scan callback called when user press/release a key on a matrix keyboard. More... | |
Functions | |
| int | kscan_config (const struct device *dev, kscan_callback_t callback) |
| Configure a Keyboard scan instance. More... | |
| int | kscan_enable_callback (const struct device *dev) |
| Enables callback. More... | |
| int | kscan_disable_callback (const struct device *dev) |
| Disables callback. More... | |
KSCAN APIs.
| typedef void(* kscan_callback_t) (const struct device *dev, uint32_t row, uint32_t column, bool pressed) |
#include <include/drivers/kscan.h>
Keyboard scan callback called when user press/release a key on a matrix keyboard.
| dev | Pointer to the device structure for the driver instance. |
| row | Describes row change. |
| column | Describes column change. |
| pressed | Describes the kind of key event. |
| int kscan_config | ( | const struct device * | dev, |
| kscan_callback_t | callback | ||
| ) |
#include <include/drivers/kscan.h>
Configure a Keyboard scan instance.
| dev | Pointer to the device structure for the driver instance. |
| callback | called when keyboard devices reply to to a keyboard event such as key pressed/released. |
| 0 | If successful. |
| Negative | errno code if failure. |
| int kscan_disable_callback | ( | const struct device * | dev | ) |
#include <include/drivers/kscan.h>
Disables callback.
| dev | Pointer to the device structure for the driver instance. |
| 0 | If successful. |
| Negative | errno code if failure. |
| int kscan_enable_callback | ( | const struct device * | dev | ) |
#include <include/drivers/kscan.h>
Enables callback.
| dev | Pointer to the device structure for the driver instance. |
| 0 | If successful. |
| Negative | errno code if failure. |