;===========================================================================
; (c) Copyright 2017 ams AG
;===========================================================================


[Version]
Signature="$WINDOWS NT$"
Class=visaUsbDevice
ClassGUID={36FC9E60-C465-11CF-8056-444553540000}
provider=%ams%
;---Uncomment and complete below to support WHQL submission---;
;CatalogFile=picoprog_v2_xp.cat
DriverVer=07/15/2013,2.2.0.0
;-------------------------------------------------------------;

[DefaultInstall]
CopyINF=picoprog_v2_xp.inf

[Manufacturer]
%MfgName%=ams

[ams]
; Entry point for the widget after firmware download and renumeration
%USB\VID_194E&PID_1003.DeviceDesc%=NIVIUSBK_Inst, USB\VID_194E&PID_1003
%USB\VID_194E&PID_1009.DeviceDesc%=NIVIUSBK_Inst, USB\VID_194E&PID_1009
%USB\VID_194E&PID_100A.DeviceDesc%=NIVIUSBK_Inst, USB\VID_194E&PID_100A
%USB\VID_194E&PID_100B.DeviceDesc%=NIVIUSBK_Inst, USB\VID_194E&PID_100B
%USB\VID_194E&PID_100C.DeviceDesc%=NIVIUSBK_Inst, USB\VID_194E&PID_100C
%USB\VID_194E&PID_100D.DeviceDesc%=NIVIUSBK_Inst, USB\VID_194E&PID_100D
%USB\VID_194E&PID_100E.DeviceDesc%=NIVIUSBK_Inst, USB\VID_194E&PID_100E
%USB\VID_194E&PID_100F.DeviceDesc%=NIVIUSBK_Inst, USB\VID_194E&PID_100F
%USB\VID_194E&PID_1010.DeviceDesc%=NIVIUSBK_Inst, USB\VID_194E&PID_1010
%USB\VID_194E&PID_1011.DeviceDesc%=NIVIUSBK_Inst, USB\VID_194E&PID_1011

[DestinationDirs]
NIVIUSBK.Files.Ext = 10,System32\Drivers
NIVIUSBK_Device_CopyFiles_Inf = 17


;===========================================================================
;   Class Installer
;===========================================================================

[ClassInstall32.nt]
AddReg=AddClass_AddReg

[AddClass_AddReg]
HKR,,,0,%DeviceClassString%
HKR,,Icon,,"-20"
HKR,,IconPath,0x00010000,"%11%\setupapi.dll,-20"

;===========================================================================

[NIVIUSBK_Inst]
CopyFiles=NIVIUSBK.Files.Ext
AddReg=NIVIUSBK_Inst_AddReg

[NIVIUSBK.Files.Ext]
NiViUsbK.sys

[NIVIUSBK_Inst.Services]
Addservice = NIVIUSBK, 0x00000002, NIVIUSBK_AddService

[NIVIUSBK_AddService]
DisplayName    = %NIVIUSBK.SvcDesc%
ServiceType    = %SERVICE_KERNEL_DRIVER%
StartType      = %SERVICE_DEMAND_START%
ErrorControl   = %SERVICE_ERROR_NORMAL%
ServiceBinary  = %12%\NIVIUSBK.sys
LoadOrderGroup = Base

[NIVIUSBK_Inst_AddReg]
HKR,,DevLoader,,*ntkern
HKR,,NTMPDriver,,NIVIUSBK.sys

;---------------------------------------------------------------;
[Strings]
ams="ams AG"
USB\VID_194E&PID_1003.DeviceDesc="ATMD-USB"
USB\VID_194E&PID_1009.DeviceDesc="picoprog v2.0 PS081 Production Programmer"
USB\VID_194E&PID_100A.DeviceDesc="picoprog v2.0 unprogrammed"
USB\VID_194E&PID_100B.DeviceDesc="picoprog v2.0 PCAP"
USB\VID_194E&PID_100C.DeviceDesc="picoprog v2.0 PS081"
USB\VID_194E&PID_100D.DeviceDesc="picoprog v2.0 GP21"
USB\VID_194E&PID_100E.DeviceDesc="picoprog v2.0 XU21"
USB\VID_194E&PID_100F.DeviceDesc="picoprog v2.0 PS09"
USB\VID_194E&PID_1010.DeviceDesc="picoprog v2.0 GP30"
USB\VID_194E&PID_1011.DeviceDesc="picoprog v2.0 GPX2"
DeviceClassString="NI-VISA USB Devices"
NIVIUSBK.SvcDesc="NI-VISA USB Driver"
NIVIUSBK.GUID="{2EA26C5E-5F35-45df-BA47-DE5FD5522202}"



;  *******Non Localizable Strings******* 
SERVICE_BOOT_START = 0x0 
SERVICE_SYSTEM_START = 0x1 
SERVICE_AUTO_START = 0x2 
SERVICE_DEMAND_START = 0x3 
SERVICE_DISABLED = 0x4 

SERVICE_KERNEL_DRIVER = 0x1 
SERVICE_ERROR_IGNORE = 0x0 
SERVICE_ERROR_NORMAL = 0x1 
SERVICE_ERROR_SEVERE = 0x2 
SERVICE_ERROR_CRITICAL = 0x3 

REG_EXPAND_SZ = 0x00020000 
REG_DWORD = 0x00010001 