This is a part of my bootloader's code (boot.bin)
Code: Select all
read:
mov ax,1000h
mov es,ax
mov bx,0
mov ah,2 ;load to es:bx
mov al,1 ;load 1 sector
mov ch,1 ;cylinder 0
mov cl,2 ;sector 2
mov dh,0 ;head 0
mov dl,0 ;drive A
int 13h
jc read ;error ->read
jmp 1000h:0000
Code: Select all
[BITS 16]
[ORG 1000h:0]
mov ax, 0000h
mov ds, ax
mov ah, 0Eh
mov al, 'a'
mov bh, 0
mov bl, 07h
mov cx, 10
int 10h
hang:
jmp hang
times 512-($-$$) db 0
partcopy.exe C:\nasm\boot.bin 0 200 -f0
partcopy.exe C:\nasm\proc.bin 0 200 -f0 200
partcopy.exe -f0 0 400 1.44
What am I doing wrong? I looked bochs's log and there was these lines
00002397930i[FDD ] read() on floppy image returns 0
00002431656p[CPU ] >>PANIC<< prefetch: RIP > CS.limit
00002431656i[SYS ] Last time is 1112372637
00002431656i[CPU ] real mode
Does this mean the CS value is too big or something like that? Or can't it read the floppy?
P.S I'm sorry about those long code examples.
P.S.S I'm noobie