From: zak100 <zul...@ya...> - 2009-06-29 09:45:43
|
Hi, I have written the following program to be exeuted when my system boots up using int 10h. But its not printing any mesg. Can somebody plz. help me with this?? Zulfi. org 7C00h; starting the program at 7C00H. Address generated at reset section .text section .text; why twice???? call overdata ; Call? WTF? Don't worry, we pop the. ; return address off to get initial IP. ; Note that "call" is longer than ; nop ; "jmp short", so we don't want the nop. At 7C00H we have to make a jmp where our actual code starts db 'MyOS ' ; OEM id - space-padded to 8 bytes dw 200h ; bytes/sector db 1 ; sectors per cluster dw 1 ; sectors before FAT db 2 ; number of FATs dw 0E0h ; max rootdir entries dw 0B40h ; total sectors db 0Fh ; media descriptor dw 9 ; sectors per FAT dw 12h ; sectors per track dw 2 ; number heads times 0Ah db 0 db 29h db 0EFh db 7 db 10h db 24h db 'LINUX BOOT FAT12 ' ; guess where I ; cribbed this from ;----------------------------writing a mesg on screen at startup. We cant use int 21h overdata: xor di,di mov ds,di mov ax,0B800h mov es,ax ; should probably set up a sane stack here, too. ;mov ah,03h ;xor bh, bh ;int 10h ;---------------------------- mov cx, 15 mov bh,0 mov bl,0011_1011b mov bp, msg mov ax,1301h mov dl,10 mov dh,7 int 10h blackhole: jmp blackhole msg db "We be bootin2'!",0 times 510-($-$$) db 0 db 55h, 0AAh ; ??????I know times is like dup.But what is ($-$$) and 55h and 0AAh ; boot sector signature -- View this message in context: http://www.nabble.com/prob-with-bios-int-10h-tp24251227p24251227.html Sent from the nasm-users mailing list archive at Nabble.com. |