HDD GURU FORUMS
http://forum.hddguru.com/

Sector 0
http://forum.hddguru.com/viewtopic.php?f=7&t=6633
Page 1 of 1

Author:  aimtrading [ January 20th, 2007, 9:48 ]
Post subject:  Sector 0

I noticed something odd. When I open my drive with for example Hex Workshop, it shows the first sector (on which the MBR is) as sector 0. I also read somwhere on the internet that the first sector on a HDD is sector 0.

However, when I send an ATA command to read sector 0, it returns with an error. If I send an ATA command to read sector 1, it returns with that MBR ! So I'm a bit confused here, should the first sector be numbered 0 or 1 ?

Author:  vlaszlo [ January 20th, 2007, 12:02 ]
Post subject: 

T13/1153D revision 18
Page 20
3) Logical sectors on the device shall be linearly mapped with the first LBA addressed sector (sector 0)
being the same sector as the first logical CHS addressed sector (cylinder 0, head 0, sector 1).
Irrespective of the logical CHS translation currently in effect, the LBA address of a given logical
sector does not change. The following is always true for LBA numbers less than or equal to
16,514,064 for devices supporting the current CHS translation:
LBA = ((cylinder *heads_ per_ cylinder +heads) *sectors_ per_ track) + sector -1

maybe you mixed the lba address with number of sectors or you are using chs mode

Author:  Dmitry Postrigan [ January 20th, 2007, 23:44 ]
Post subject: 

...most likely you forgot to switch to LBA mode in the sixth's register (the same register where you set master/slave) :D

Author:  aimtrading [ January 21st, 2007, 10:16 ]
Post subject: 

I did, thanks for the replies, makes sense :D

Page 1 of 1 All times are UTC - 5 hours [ DST ]
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group
http://www.phpbb.com/