hello world
This commit is contained in:
21
boot.asm
21
boot.asm
@@ -1,7 +1,28 @@
|
||||
; yoinked from osdev.org
|
||||
mov ax, 0x07C0
|
||||
mov ds, ax
|
||||
|
||||
mov si, msg
|
||||
cld
|
||||
|
||||
ch_loop:
|
||||
lodsb
|
||||
; hang if at null terminator
|
||||
or al, al
|
||||
jz hang
|
||||
|
||||
; BIOS interrupt prints al
|
||||
mov ah, 0x0E
|
||||
mov bh, 0
|
||||
int 0x10
|
||||
|
||||
jmp ch_loop
|
||||
|
||||
hang:
|
||||
jmp hang
|
||||
|
||||
msg db 'Hello World', 0
|
||||
|
||||
times 510-($-$$) db 0 ; 2 bytes less now
|
||||
db 0x55
|
||||
db 0xAA
|
||||
|
||||
Reference in New Issue
Block a user