Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- BITS 16
- jmp 7c0h: __START__
- __START__:
- mov ax, cs
- mov ss, ax
- xor sp, sp
- mov ds, ax
- push 0b800h
- pop es
- xor di, di
- mov fs, di
- mov ax, 0003h
- int 10h
- cli
- mov ax, cs
- shl eax, 10h
- mov ax, isr09
- mov DWORD [fs:09h*4], eax
- sti
- _done:
- hlt
- jmp _done
- hex2s:
- push bx
- push ax
- mov bx, hex_digits
- mov ah, 0ch
- push ax
- shr al, 04h
- xlatb
- stosw
- pop ax
- and al, 0fh
- xlatb
- stosw
- pop ax
- pop bx
- ret
- hex_digits db "0123456789abcdef"
- isr09:
- in al, 60h
- call hex2s
- mov al, 20h
- out 20h, al
- iret
- TIMES 505-($-__START__) db 0
- dw 0aa55h
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement