From 8fee35522dee033863f68c1d2b45f5fe988de9eb Mon Sep 17 00:00:00 2001 From: Loic Guegan Date: Thu, 8 Apr 2021 19:06:44 +0200 Subject: Handle clock interrupt and cleaning code --- src/bringelle.c | 23 ++++++++++++++++------- 1 file changed, 16 insertions(+), 7 deletions(-) (limited to 'src/bringelle.c') diff --git a/src/bringelle.c b/src/bringelle.c index 9e17906..f6b099c 100644 --- a/src/bringelle.c +++ b/src/bringelle.c @@ -2,22 +2,31 @@ #include "utils/asm.h" #include "utils/pic.h" #include "utils/8042.h" -#include "utils/multiboot.h" +#include "boot/multiboot.h" extern char *name_addr; void bringelle(){ + clear(); + printc("Booting Bringelle...\n",GREEN); + pic_enable_interrupt(); - // clear(); - //print("Booting Bringelle..."); - //pic_enable_interrupt(); - print("Booting Bringelle..."); + // Search for bootloader informations MBI_TAG_BL_NAME bl_infos; if(!mb_load_bl_name(&bl_infos)){ print(bl_infos.name); - print(" detected!"); + print(" detected!\n"); } - while(1); } + +void clock(){ + static int tic=0; + static int sec=0; + tic++; + if(tic>=20){ + tic=0; + sec++; + } +} -- cgit v1.2.3