This commit is contained in:
nub31
2025-09-02 17:39:25 +02:00
parent 8cd6bd185d
commit a5bd7ad9a6
7 changed files with 169 additions and 35 deletions

View File

@@ -4,7 +4,7 @@
#include "string.h"
#include "vga.h"
#include <stdarg.h>
#include <stddef.h>
#include "multiboot.h"
void handle_keypress(const keyboard_event_t* event)
{
@@ -14,12 +14,18 @@ void handle_keypress(const keyboard_event_t* event)
}
}
void kmain()
void kmain(multiboot_info_t* multiboot_info)
{
vga_clear();
pic_remap();
remap_pic();
if (cpu_has_apic())
{
disable_pic();
enable_apic();
}
enable_interrupts();
init_keyboard();
register_keypress_handler(handle_keypress);
kprintf("Welcome to nub OS\n");