|
Simone: a game of visual memory and speed
|
Structure to define the HW dependencies of a keyboard status. More...
#include <stm32f4_keyboard.h>
Data Fields | |
| const keyboard_t * | p_keyboard |
| GPIO_TypeDef ** | p_row_ports |
| uint8_t * | p_row_pins |
| GPIO_TypeDef ** | p_col_ports |
| uint8_t * | p_col_pins |
| bool | flag_key_pressed |
| bool | flag_row_timeout |
| uint8_t | col_idx_interrupt |
| uint8_t | current_excited_row |
Structure to define the HW dependencies of a keyboard status.
Because the rows and columns GPIO ports and pins are variable-length arrays depending on the keyboard layout, double pointers are used to define GPIOs (because GPIOs are defined as pointers of GPIO_TypeDef type) and pointers are used to define the arrays of rows and columns.
| uint8_t stm32f4_keyboard_hw_t::col_idx_interrupt |
Index of the column that provoked an interrupt
| uint8_t stm32f4_keyboard_hw_t::current_excited_row |
Current row being excited
| bool stm32f4_keyboard_hw_t::flag_key_pressed |
Flag to indicate that a key has been pressed
| bool stm32f4_keyboard_hw_t::flag_row_timeout |
Flag to indicate that the column scanning timeout has occurred
| uint8_t* stm32f4_keyboard_hw_t::p_col_pins |
Pointer to an array of pins/lines where the keyboard columns are connected
| GPIO_TypeDef** stm32f4_keyboard_hw_t::p_col_ports |
Pointer to an array of GPIO ports where the keyboard columns are connected
| const keyboard_t* stm32f4_keyboard_hw_t::p_keyboard |
Pointer to the keyboard structure
| uint8_t* stm32f4_keyboard_hw_t::p_row_pins |
Pointer to an array of pins/lines where the keyboard rows are connected
| GPIO_TypeDef** stm32f4_keyboard_hw_t::p_row_ports |
Pointer to an array of GPIO ports where the keyboard rows are connected