Switch to full style
Tools for hard drive diagnostics, repair, and data recovery
Post a reply

question about ATA command (WRITE SECTOR(S))

May 29th, 2012, 4:26

I tried to deliver a WRITE SECTOR(S) command to an ATA-DEVICE(NOT ATAPI).
I set REG_DEVICE: 0x40 | DEV REG_COUNT: 1 REG_LBA_LOW/REG_LBA_MID/REG_LBA_HIG: 0
At last I write 0x30(LBA28-WRITE SECTOR) to command register(0x1F7)
Then I poll Status Register and always get 0x58 even though the DATA-Length that I transmit to DATA-Register is larger than 512 bytes.
Someone could give me some hint ?

Thanks advance !

Re: question about ATA command (WRITE SECTOR(S))

May 29th, 2012, 7:37

did you "send" any data after you sent ATA OP Command...?

Re: question about ATA command (WRITE SECTOR(S))

May 29th, 2012, 21:21

Thank you very much !
I've solved this problem that caused due to my careless.

Re: question about ATA command (WRITE SECTOR(S))

May 30th, 2012, 18:53

No problem :)

Re: question about ATA command (WRITE SECTOR(S))

March 18th, 2013, 8:55

Can anyone please send me c code for sending 0x03(write sectors) ATA command!
Thanks in advance.
Post a reply