mirror of
https://github.com/Tom-on64/kern.git
synced 2026-11-03 18:22:22 +00:00
More minor changes
This commit is contained in:
@@ -22,5 +22,8 @@ cat build/calc.bin build/edit.bin > build/files.bin
|
||||
# Final binary
|
||||
cat build/bootloader.bin build/kernel.bin build/files.bin > build/kern.bin
|
||||
|
||||
# Cleanup
|
||||
rm build/*[!kern].bin
|
||||
|
||||
# Run QEMU
|
||||
qemu-system-x86_64 -drive format=raw,file="./build/kern.bin",index=0,media=disk -m 256M
|
||||
|
||||
+4
-2
@@ -11,9 +11,8 @@ launch:
|
||||
mov si, controlsMsg
|
||||
call drawString
|
||||
|
||||
xor cx, cx
|
||||
mov di, hexCode
|
||||
|
||||
xor cx, cx ; Clear counter
|
||||
getHexCh:
|
||||
xor ax, ax
|
||||
int 0x16
|
||||
@@ -44,6 +43,7 @@ getHexCh:
|
||||
stosb
|
||||
mov dx, [hexByte]
|
||||
call printHexByte
|
||||
inc byte [codeLen]
|
||||
xor cx, cx
|
||||
mov al, ' '
|
||||
mov ah, 0x0e
|
||||
@@ -51,6 +51,7 @@ getHexCh:
|
||||
jmp getHexCh
|
||||
.backspace:
|
||||
mov byte [hexByte], 0
|
||||
dec byte [codeLen]
|
||||
xor cx, cx
|
||||
cmp di, hexByte ; Check if there's anything to delete
|
||||
je getHexCh ; If not, ignore
|
||||
@@ -116,6 +117,7 @@ backChars: db 8,8,8,' ',8,8,0
|
||||
|
||||
hexByte: db 0
|
||||
|
||||
codeLen: db 0
|
||||
hexCode: times 256 db 0 ; Code buffer
|
||||
ret
|
||||
|
||||
|
||||
+1
-1
@@ -4,7 +4,7 @@ start:
|
||||
; Save the drive number from stack
|
||||
mov byte [driveNumber], dl
|
||||
|
||||
mov bx, 0x8000
|
||||
mov bx, 0x2000
|
||||
mov es, bx
|
||||
xor bx, bx
|
||||
|
||||
|
||||
@@ -0,0 +1,5 @@
|
||||
;
|
||||
; Loads a file from the filetable into a memory location
|
||||
;
|
||||
loadFile:
|
||||
|
||||
Reference in New Issue
Block a user