bringelle/src/bringelle.c

42 lines
612 B
C
Raw Normal View History

2021-04-09 10:29:23 +02:00
#include "libc/stdio.h"
2021-04-06 15:55:30 +02:00
#include "utils/pic.h"
#include "boot/multiboot.h"
2021-04-09 18:18:15 +02:00
#include "utils/mem.h"
char show_tics=0;
void utask(){
while(1);
}
2021-04-04 11:19:55 +02:00
void bringelle(){
clear();
2021-04-09 18:18:15 +02:00
printc("Booting Bringelle...\n",GREEN);
2021-04-09 10:29:23 +02:00
// Kernel boot sequence
pic_enable_interrupt();
2021-04-09 18:18:15 +02:00
print("Interrupts enabled!\n");
2021-04-09 18:18:15 +02:00
// Utask
memcpy((void*)utask,(void*)0x300000, 100); // 100 bytes seems reasonable to load utask
print("Kernel started ");
show_tics=1;
2021-04-04 11:19:55 +02:00
while(1);
}
void clock(){
static int tic=0;
static int sec=0;
tic++;
if(tic>=20){
tic=0;
sec++;
2021-04-09 18:18:15 +02:00
if(show_tics)
putchar('.');
}
}
2021-04-09 18:18:15 +02:00