请问如何得到usb设备的固件版本号(firmware)等相关的usb信息,有相关的api吗?我主要是想知道有没有相关的api能够获得usb的信息。希望有知道的大虾说得详细一些,分不是问题!

解决方案 »

  1.   

    HidD_GetHidGuid
     hid.dll
     Obtain the GUID for the HID class
     
    SetupDiGetClassDevs
     setupapi.dll
     Return a device information set containing
     
     
      
     all of the devices in a specified class.
     
    SetupDiEnumDeviceInterfaces
     setupapi.dll
     Return information about a device in the
     
     
      
     device information set.
     
    SetupDiGetDeviceInterfaceDetail
     setupapi.dll
     Return a device pathname.
     
    SetupDiDestroyDeviceInfoList
     setupapi.dll
     Free resources used by SetupDiGetClassDevs.
     
    CreateFile
     kernel32.dll
     Open communications with a device.
     
    HidD_GetAttributes
     hid.dll
     Return a Vendor ID, Product ID, and Version Number.
     
    HidD_GetPreparsedData
     hid.dll
     Return a handle to a buffer with information about the
     
     
      
     device's capabilities.
     
    HidP_GetCaps
     hid.dll
     Return a structure describing the device's capabilities.
     
    HidD_FreePreparsedData
     hid.dll
     Free resources used by HidD_GetPreparsedData.
     
    WriteFile
     kernel32.dll
     Send an Output report to the device.
     
    ReadFile
     kernel32.dll
     Read an Input report from the device.
     
    HidD_SetFeature
     hid.dll
     Send a Feature report to the device.
     
    HidD_GetFeature
     hid.dll
     Read a Feature report from the device.
     
    CloseHandle
     kernel32.dll
     Free resources used by CreateFile.