sector read/write 
Author Message
 sector read/write


Quote:

> I need

Dl =80h+ drive # for hard drives
Quote:
> thanx.




Tue, 22 Jun 1999 03:00:00 GMT  
 sector read/write

I need to write/read from disk sectors to make an image of a hard
drive/disk.  My code works on desktop system (floppy and hard drive) and
on notebooks, but only floppy.  When I read a sector I get the errors

AH = 2 Bad Address mark; sector ID marking invalid or not found
AL = 7 Unknown media: disk format not reconized
I get this after calling INT 25h to read a dos logical sector. (I specify
the drive in al, # of sectors to read in cx, starting sector in dx, offset
to buffer in bx, and segment of buffer in ds).
This works fine on my desktop system (Compaq Deskpro 575) but not on my
notebook (Toshiba T4850CT).  The desktop system is running win95.  I have
tried the notebook with just boot disks and doesn't work.

As a work around I am trying to use the bios to do the disk read/write.
The following code only works for drives A and B (drive set to 0, 1
respectivly).  It doesn't work for drive C (drive=2). Why?
    mov ah, 08h //Get drive parameters
    mov dl, byte ptr drive
    int 13h
the carry flag is set and get
AH = 01 Bad Command

I need to get the geometry of the Hard drive but function 08h of int 13h
doesn't work for the hard drive. HELP!

thanx.



Tue, 22 Jun 1999 03:00:00 GMT  
 sector read/write


Quote:

> > I need
> Dl =80h+ drive # for hard drives

For drive number starting at 0.


Wed, 23 Jun 1999 03:00:00 GMT  
 
 [ 3 post ] 

 Relevant Pages 

1. IDE-HD sector read/write

2. sector read/write

3. Read/Write sectors in memory

4. Need help reading/writing boot sector (floppy disk)

5. Writing at boot sector to the first sector of a disk

6. Clarification: read/write slow, and TCPSocket and sys{read,write}

7. read/write slow, and TCPSocket and sys{read,write}

8. boot sector writing

9. Writing To Boot Sector

10. Write a boot sector

11. Writing specific bytes to a sector

12. Writing String to Sector?

 

 
Powered by phpBB® Forum Software