SAMPLE: GetAddr.exe Demonstrates IOCTL_SCSI_GET_ADDRESS

ID: Q182148


The information in this article applies to:


SUMMARY

GetAddr.exe is a sample Win32 console-mode application that demonstrates IOCTL_SCSI_GET_ADDRESS functionality.


MORE INFORMATION

The following file is available for download from the Microsoft Software Library:

~ GetAddr.exe

For more information about downloading files from the Microsoft Software Library, please see the following article in the Microsoft Knowledge Base:

Q119591 How to Obtain Microsoft Support Files from Online Services


This is a sample Win32 console mode application that demonstrates how to retrieve the SCSI address information (ScsiPort number, Path ID, Target ID, and LUN) for the specified device. You etrieve this information by calling DeviceIoControl with the IoControlCode parameter set to IOCTL_SCSI_GET_ADDRESS. See the sample for specific parameter issues.

To run the GetAddr.exe:

  1. Build the Win32 application. See the DDK documentation for details on creating Win32 applications from the DDK Build Environment.


  2. Copy the executable to a location that is in your path.

    When building in the Free Build Environment, the executable is created in \ddk\lib\i386\free.

    When building in the Checked Build Environment, the executable is created in \ddk\lib\i386\checked.


  3. From a command prompt, type "gettaddr X:", where X: is the SCSI device with the SCSI address information you want to display.



Keywords          : kbfile kbsample 
Version           : WINNT:3.51,4.0
Platform          : winnt 
Issue type        : 

Last Reviewed: March 4, 1999