new screens

master
Your Name 5 years ago
parent 7b76929487
commit b6586c6a45

@ -2,12 +2,12 @@
[bits 16]
;cmp dl, 0x05
;je welcome
pre:
cmp ah, 0x0F
je welcome
mov [bootdev], dl ; Save boot device number
jmp welcome
; Use the boot drive number passed to us by BIOS in register DL
welcome:
xor ax,ax ; We want a segment of 0 for DS for this question
mov ds,ax ; Set AX to appropriate segment value for your situation
@ -15,9 +15,26 @@ welcome:
mov bx,0x8000 ; Stack segment can be any usable memory
mov ss,bx ; This places it with the top of the stack @ 0x80000.
mov sp,ax ; Set SP=0 so the bottom of stack will be @ 0x8FFFF
cld ; Set the direction flag to be positive direction
cld ; Set the direction flag to be positive direction
mov ah, 01h ;make cursor invisible
mov cx, 2607h
int 10h
mov ah, 06h ; Scroll up function
xor al, al ; Clear entire screen
xor cx, cx ; Upper left corner CH=row, CL=column
mov dx, 184FH ; lower right corner DH=row, DL=column
mov bh, 1Eh ; YellowOnBlue
int 10H ; execute interrupt
mov ah, 02h ;sets cursor to top to write
mov bh, 0h
mov dh, 2h
mov dl, 2h
int 10h
mov si, wolf_wel_msg
call wolf_print
@ -130,7 +147,7 @@ wolf_kernel_load db 'Loading program',0x0D,0x0A,0
wolf_error_msg db 'Program not found!',0x0D,0x0A,0
wolf_error_msg1 db 'Press any key to restart..',0
bootdev db 0 ; Boot device number
bootdev db 0x80 ; Boot device number
times 510-($-$$) db 0
dw 0xAA55

Binary file not shown.

Binary file not shown.

@ -55,6 +55,14 @@ start:
mov si, msg1
call print
mov si, msg2
call print
mov ah, 06h ;draw rect on background
mov cx, 0404h
mov dx, 113Dh
mov bh, 2Eh
int 10h
call wait_for_key
@ -78,7 +86,7 @@ print:
ret
exit_bootloader:
mov dl, 0x05
mov ah, 0x0F
jmp 0x0:0x7c00 ;jump back to bootloader init
hlt
@ -86,5 +94,5 @@ over:
jmp wait_for_key
msg1 db "TEST",0x0A,0
msg2 db "TEST",0x0D,0x0A,0
msg1 db "POETIC SOFTWARE",0x0A,0
msg2 db "testasdfjah lksjdhflkajshd lkjahs lkdjfhals khfdas ohne dieses wort und noch mehr whaaat",0x0D,0x0A,0

Binary file not shown.
Loading…
Cancel
Save