alcedo/kernel/kernel.nim

17 lines
406 B
Nim
Raw Normal View History

2017-11-08 02:36:35 +00:00
import tty, gdt, irq, serial
proc kernelMain() {.exportc: "kernel_main"}=
2017-11-08 02:36:35 +00:00
serial.init()
serial.write("Booting OS")
2017-11-06 21:44:17 +00:00
gdt.gdtInstall()
2017-11-08 02:36:35 +00:00
serial.write("GDT installed")
terminalInitialize()
terminalWrite("Hello World!\L")
terminalWrite("MAX_INT:")
terminalWrite(high(int))
terminalWrite("\LMIN_INT:")
terminalWrite(low(int32)+1)
for i in 0..22:
terminalWrite(i)
terminalWrite('\L')