From 4ada94d4db995ebf150dd3ecfc8efd3241a6ff84 Mon Sep 17 00:00:00 2001 From: Marvin Borner Date: Thu, 28 Nov 2019 21:26:22 +0100 Subject: Made font external module --- src/kernel/graphics/font.c | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) create mode 100644 src/kernel/graphics/font.c (limited to 'src/kernel/graphics/font.c') diff --git a/src/kernel/graphics/font.c b/src/kernel/graphics/font.c new file mode 100644 index 0000000..b2971ec --- /dev/null +++ b/src/kernel/graphics/font.c @@ -0,0 +1,17 @@ +#include +#include +#include +#include + +void font_install() { + uint8_t boot_drive_id = (uint8_t) (*((uint8_t *) 0x9000)); + if (boot_drive_id != 0xE0) { + uint32_t *font = (uint32_t *) kmalloc(0x18326); // High quality shit + marfs_read_whole_file(4, (uint8_t *) (font + 4096)); + + for (int i = 0; i < 10; i++) { + serial_write_hex(font[i]); + serial_write("\n"); + } + } +} \ No newline at end of file -- cgit v1.2.3