Created
July 22, 2017 01:21
-
-
Save Jacajack/c689b579cf0c85cbc3d146e019a74a04 to your computer and use it in GitHub Desktop.
Display all characters from BIOS font
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[org 0x7c00] | |
[bits 16] | |
;Stack setup | |
mov bp, 0xfffe | |
mov sp, bp | |
;Switch into mode 13h | |
mov ah, 0x00 | |
mov al, 0x13 | |
int 0x10 | |
mov al, 0 | |
mov dl, 0 | |
hor_loop: | |
cmp dl, 11 | |
jae hor_loop_end | |
call pcol | |
inc dl | |
add al, 25 | |
jmp hor_loop | |
hor_loop_end: | |
jmp $ | |
;al - start char | |
;dl - col | |
pcol: | |
pushf | |
pusha | |
pcol_loop: | |
cmp dh, 25 | |
jae pcol_end | |
mov ah, 2 | |
mov bx, 0 | |
int 0x10 | |
mov ah, 0xe | |
mov bx, 0x0007 | |
int 0x10 | |
inc al | |
inc dh | |
jmp pcol_loop | |
pcol_end: | |
popa | |
popf | |
ret | |
times 510 - ( $ - $$ ) db 0 | |
dw 0xaa55 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment