> 
> > ...but it doesn't work, except for occasional "Hard disk error".
> 
>   You should examine what error number is returned by INT 13 call. The
> error number is stored in %ah.

The INT13 seems to work OK:

;; Load bootsector
        mov ah, 2       ; Function 2 = read
        mov al, 1       ; One sector
        mov bx, 0x7c00  ; Buffer 
        mov cl, 1       ; Sectornumber
        mov ch, 0       ; Cylinder 0
        mov dl, 0x80    ; HD
        mov dh, 0       ; Head 0
        int 0x13

        ;; Check for error value
        cmp ah, 0
        jz noerror

        ;; Print B
        mov ah, 0x2
        mov dl, 0x42
        int 0x21
                
noerror:        

        ;; Print C
        mov ah, 0x2
        mov dl, 0x43
        int 0x21

...gives no B. I've also tried printing out some bootsector contents, and
verified the values. 

There must be some other problem, like wrong stackpointers etc. 

/Peter Astrand <[EMAIL PROTECTED]>

Reply via email to