Quote:
>Does anyone know how I can make a call (probably Int13) in order to read
>a disk sector into qbasic,
>ie getsector (C,H,S) Cylinder,Head,Sector or
> getsector(physical sector)
I haven't coded it in QBasic, but here's a start on the function:
You will find this capability in Int 25H Absolute Disk read and Int 26H
Absolute Disk Write.
AL Drive: 0=A, 1=B, etc.
CX Number of sectors to read/write
DX Starting logical sector number
DS:BX Segment:offset of buffer
Return: Carry clear Successful
Carry set Unsuccessful (AX = error code)
Notes: All registers except segment register may be destroyed.
When these function return, the CPU flags originally stored
on the stack by the INT 25H/26H instruction are STILL on the
stack. The stack must be cleared by a POPF or ADD SP,2.
Logical sector numbers are obtained by numbering each disk
sector sequentially from track 0, head 0, sector 1.
The head number is incremented before the track number.
The additional details are too long for me to type here, but you should be
able to find them in a reference, now that you know what to look for.
You also might want to check into Int 21H, Function 44H, Subfunction 0DH,
Minor codes 61H (read) and 41H (write).
The expression "shoot your foot off" definitely comes to mind here. :-)
--
Sun Valley Systems http://www.sunvaley.com
"For God so loved the world that He gave His only begotten Son, that
whoever believes in Him should not perish but have everlasting life."