Kernel generic keyboard interface. More...
Go to the source code of this file.
Data Structures | |
| struct | keyboard_state |
| struct to hold state of the keyboard in terms of modifier keys More... | |
| struct | keyboard_event |
| struct that holds a keyboard event More... | |
Typedefs | |
| typedef bool(* | hal_poll_func_t) (void) |
| typedef for generic hal polling function pointer. | |
Functions | |
| int | keyboard_init (hal_poll_func_t poll) |
| function to initialize the kernel keyboard system | |
| bool | keyboard_poll () |
| function to poll the keyboard for available events | |
| bool | keyboard_pop_event (struct keyboard_event *event) |
| pop an event from the keyboard event queue. | |
| void | keyboard_push_event (struct keyboard_event event) |
| push event to the keyboard event queue | |
| struct keyboard_state * | keyboard_get_state () |
| get the current modifier state of the keyboard | |
Kernel generic keyboard interface.
| typedef bool(* hal_poll_func_t) (void) |
typedef for generic hal polling function pointer.
This allows us, when initializing the keyboard to pass a polling function (e.g. ps2_poll) dynamically.
| struct keyboard_state * keyboard_get_state | ( | ) |
get the current modifier state of the keyboard
| int keyboard_init | ( | hal_poll_func_t | poll | ) |
function to initialize the kernel keyboard system
| poll | generic HAL keyboard polling function |
| bool keyboard_poll | ( | ) |
function to poll the keyboard for available events
| bool keyboard_pop_event | ( | struct keyboard_event * | event | ) |
pop an event from the keyboard event queue.
| event | buffer to store new event data in |
| void keyboard_push_event | ( | struct keyboard_event | event | ) |
push event to the keyboard event queue
| event | event to push to the queue |