diff options
author | Marvin Borner | 2020-05-06 22:34:38 +0200 |
---|---|---|
committer | Marvin Borner | 2020-05-06 22:34:38 +0200 |
commit | 8083536f321ad8a12ad4668c2bf41a65c3e3b2f6 (patch) | |
tree | 427d7da11944b299bdce3041259bf8fd31971ede /src/shared | |
parent | d94ffac4a584dc7a4f6f2ec567b8caab05ce9253 (diff) |
Added event mapping driver
Diffstat (limited to 'src/shared')
-rw-r--r-- | src/shared/common.h | 39 |
1 files changed, 27 insertions, 12 deletions
diff --git a/src/shared/common.h b/src/shared/common.h index aa9b281..9680b1b 100644 --- a/src/shared/common.h +++ b/src/shared/common.h @@ -2,18 +2,33 @@ #define MELVIX_COMMON_H // Syscalls -#define SYS_HALT 0 -#define SYS_EXIT 1 -#define SYS_FORK 2 -#define SYS_READ 3 -#define SYS_WRITE 4 -#define SYS_EXEC 5 -#define SYS_GET_PID 6 -#define SYS_MALLOC 7 -#define SYS_FREE 8 +#define SYS_HALT 0 // Halt (debug) +#define SYS_EXIT 1 // Exit process +#define SYS_FORK 2 // Fork process +#define SYS_READ 3 // Read file +#define SYS_WRITE 4 // Write file +#define SYS_EXEC 5 // Execute file +#define SYS_GET_PID 6 // Get process id +#define SYS_MALLOC 7 // Allocate memory +#define SYS_FREE 8 // Free memory +#define SYS_GET 9 // Get kernel variable +#define SYS_MAP 10 // Map input to function -// Registration -#define REG_KEYBOARD 0 -#define REG_MOUSE 1 +// Get +#define GET_FRAMEBUFFER 0 + +// Mappings +#define MAP_KEYBOARD 0 +#define MAP_MOUSE 1 + +// Common event structs +struct keyboard_event { + int scancode; +}; + +struct mouse_event { + int mouse_x; + int mouse_y; +}; #endif
\ No newline at end of file |