So, I am kinda new to this OS development, I got caught two months ago, and I was starting with the bare bones 1 kernel. I fitted in the boot sector fine. Then it grew and I needed a bootloader. I got none of the bootloader work, I got frustrated, and left OS dev behind. Now I am starting again, this I got a bootloader to work (MikeOS bootloder) but now my kernel is not working. I am simply tring to print "Hello world" to the screen, but instead, it prints some garbage ( looping over and over).
It is so frustrating. One possible theory is that MikeOS bootloader doesnt work with my kernel, but its the only working bootloader.
My kernel code:
Code: Select all
[BITS 16]
mov si,msgHello
call Print_string
hlt
Print_string:
lodsb
or al,al
jz .done
mov ah, 0x0E
mov bh, 0x00
mov bl, 0x07
int 0x10
jmp Print_string
.done:
ret
msgHello db 0x0D, 0x0A, "Hello World", 0x0D, 0x0A, 0x00
TIMES 510-($-$$) DB 0