Hi there,
How I can I find out sector size of Hard disk or USB flash drive using Cocoa or OS API?
I wanted to use getPreferredBlockSize() method of IOMedia class, but IOMedia is an abstract class.
It is urgent.
Thanks so much in advance.
Pankaj
Another option you have is to use IOKit to enumerate through the kIOBlockStorageDriverClass instances in the IOService tree and grab the kIOMediaPreferredBlockSizeKey property for the ones you want. IIRC, this is the optimal block size of the device not necessarily the logical block size.