title: ATA commands to USB drive
body: <p>Windows 7<br>
  C Programming<br>
  Visual C++ 2008 (in a VMWare) </p>
  
  <p>I'd like to send some ATA commands (IDENTIFY DEVICE, READ NATIVE MAX ADDRESS, SET MAX ADDRESS) with <code>DeviceIOContro</code>l to a USB hard drive. Therefore I have some questions.</p>
  
  <p>As I understood, USBSTOR cannot handle ATA-commands directly (with <code>IOCTL_ATA_PASS_THROUGH</code>). I tried this and it worked with the native IDE hard drive but not with USB.</p>
  
  <ol>
  <li><p>Is it correct that applications send SCSI-commands to the device and they are forwarded to the device? So I need to create a SCSI command with the respective ATA command encapsulated? </p></li>
  <li><p>With what <code>dwIoControlCode</code> can I do that? I tried it with <code>IOCTL_SCSI_MINIPORT</code> but the error was <code>ERROR_NOT_SUPPORTED</code>. Could it work with minport? Is miniport still up to date?</p></li>
  </ol>