Visual studio 2013 未执行winusb设备驱动程序应用程序

Visual studio 2013 未执行winusb设备驱动程序应用程序,visual-studio-2013,usb,device-driver,winusb,Visual Studio 2013,Usb,Device Driver,Winusb,我正在开发WinUSB应用程序,它使用通用USB设备进行基本的中断端点读取。设备驱动程序安装良好。但是,当设备连接时,应用程序t_的主要功能根本没有被触发。它仅在VisualStudio调试器中触发,工作正常 我错过了什么?Winusbtrace检测设备并记录WinUSB_InitControlPipe和WinUSB_DOEntry的进入和退出。Windows/inf/*.log中的日志没有帮助,因为它们只记录安装。我可以参考其他日志吗 我非常感谢您的任何意见。提前谢谢。 下面是我的INF文件,

我正在开发WinUSB应用程序,它使用通用USB设备进行基本的中断端点读取。设备驱动程序安装良好。但是,当设备连接时,应用程序t_的主要功能根本没有被触发。它仅在VisualStudio调试器中触发,工作正常

我错过了什么?Winusbtrace检测设备并记录WinUSB_InitControlPipe和WinUSB_DOEntry的进入和退出。Windows/inf/*.log中的日志没有帮助,因为它们只记录安装。我可以参考其他日志吗

我非常感谢您的任何意见。提前谢谢。 下面是我的INF文件,我正在Win7 x64上使用visual studio 2013

;
; Test.inf
;
; Installs WinUsb
;

[Version]
Signature = "$Windows NT$"
Class     = USBDevice
ClassGUID = {88BAE032-5A81-49f0-BC3D-A4FF138216D6}
Provider = %ManufacturerName%
CatalogFile=Test.cat

; ========== Manufacturer/Models sections ===========

[Manufacturer]
%ManufacturerName% = Standard,NT$ARCH$

[Standard.NT$ARCH$]
%DeviceName% =USB_Install, USB\VID_0457&PID_0500

; ========== Class definition ===========

[ClassInstall32]
AddReg = ClassInstall_AddReg

[ClassInstall_AddReg]
HKR,,,,%ClassName%
HKR,,NoInstallClass,,1
HKR,,IconPath,%REG_MULTI_SZ%,"%systemroot%\system32\setupapi.dll,-20"
HKR,,LowerLogoVersion,,5.2

; =================== Installation ===================

[USB_Install]
Include=winusb.inf
Needs=WINUSB.NT

[USB_Install.Services]
Include=winusb.inf
AddService=WinUsb,0x00000002,WinUsb_ServiceInstall

[WinUsb_ServiceInstall]
DisplayName     = %WinUsb_SvcDesc%
ServiceType     = 1
StartType       = 3
ErrorControl    = 1
ServiceBinary   = %12%\WinUSB.sys

[USB_Install.HW]
AddReg=Dev_AddReg

[Dev_AddReg]
; By default, USBDevice class uses iProduct descriptor to name the device in
; Device Manager on Windows 8 and higher.
; Uncomment for this device to use %DeviceName% on Windows 8 and higher:
;HKR,,FriendlyName,,%DeviceName%
HKR,,DeviceInterfaceGUIDs,0x10000,"{2753294b-5128-4a42-be6a-d7818234ea9c}"

[USB_Install.Wdf]
KmdfService=WINUSB, WinUsb_Install

[WinUsb_Install]
KmdfLibraryVersion=1.9

[USB_Install.CoInstallers]
AddReg=CoInstallers_AddReg
CopyFiles=CoInstallers_CopyFiles

[CoInstallers_AddReg]
HKR,,CoInstallers32,0x00010000,"WdfCoInstaller$KMDFCOINSTALLERVERSION$.dll,WdfCoInstaller"

[CoInstallers_CopyFiles]
WdfCoInstaller$KMDFCOINSTALLERVERSION$.dll

[DestinationDirs]
CoInstallers_CopyFiles=11

; ================= Source Media Section =====================

[SourceDisksNames]
1 = %DiskName%

[SourceDisksFiles]
WdfCoInstaller$KMDFCOINSTALLERVERSION$.dll=1

; =================== Strings ===================

[Strings]
ManufacturerName="Test"
ClassName="Universal Serial Bus devices"
DiskName="Device Installation Disk"
WinUsb_SvcDesc="WinUSB Driver"
DeviceName="Test Device"
REG_MULTI_SZ = 0x00010000

winusb应用程序不是驱动程序。你必须告诉它什么时候跑。如果您试图在设备插入时让应用程序运行,您可以尝试将应用程序绑定到本文中描述的连接事件:

谢谢,我创建了一个单独的C#应用程序来侦听连接事件并执行基本读取