@echo off
@setlocal enableextensions
pushd %~dp0
rem @cd /d "%~dp0"
reg Query "HKLM\Hardware\Description\System\CentralProcessor\0" | find /i "x86" > NUL && set OS=32BIT || set OS=64BIT

if %OS%==32BIT ( 
	echo Installing 32-bit driver...
	cd x86
	dpinst32.exe
) 

if %OS%==64BIT (
	echo Installing 64-bit driver...
	cd x64
	dpinst64.exe
)

popd
