feat: reformatted code base to be more standard
This commit is contained in:
30
include/myke/drivers/keyboard.h
Normal file
30
include/myke/drivers/keyboard.h
Normal file
@@ -0,0 +1,30 @@
|
||||
//
|
||||
// Created by rick on 23-03-20.
|
||||
//
|
||||
|
||||
#ifndef MY_KERNEL_KEYBOARD_H
|
||||
#define MY_KERNEL_KEYBOARD_H
|
||||
|
||||
#include <sys/types.h>
|
||||
|
||||
typedef struct KeyEvent_t {
|
||||
// KeyCode key;
|
||||
uint32_t scancode;
|
||||
char ascii_code;
|
||||
uint8_t is_release: 1;
|
||||
uint8_t shift: 1;
|
||||
uint8_t alt: 1;
|
||||
uint8_t ctrl: 1;
|
||||
} KeyEvent;
|
||||
|
||||
char getc();
|
||||
|
||||
void init_keyboard();
|
||||
|
||||
//const char *key_code_to_string(KeyCode key);
|
||||
|
||||
KeyEvent *get_next_event();
|
||||
|
||||
void free_event(KeyEvent *event);
|
||||
|
||||
#endif //MY_KERNEL_KEYBOARD_H
|
||||
Reference in New Issue
Block a user