*/
If you have a PH account, you can customize your PH profile.
*/

View \GETDISK.ASM

Read the bootsector of a floppy disk

Submitted By: WEBMASTER
Rating: (Not rated) (Rate It)


; GETDISK.ASM: Get the active disk drive
; Pascal definition is
;       Function GetDisk: Integer; External;

code segment byte public
        assume cs:code
        public GetDisk

; Entry
GetDisk  Proc Near
        push    bp
        mov     bp, sp
; Use Dos fcn 19h
        mov     ah, 19h
        int     21h
; Note : Dos returns drive in al, which is right for Pascal
        xor     ah, ah
        mov     sp, bp
        pop     bp
        ret     0
GetDisk  EndP     
code        EndS
                End

corner
© 1996-2008 CommunityHeaven LLC. All rights reserved. Reproduction in whole or in part, in any form or medium without express written permission is prohibited.
Violators of this policy may be subject to legal action. Please read our Terms Of Use and Privacy Statement for more information.
North American business development: Nicolai Wadstrom. Publisher: Lars Hagelin.