@echo off
set _ELAN_PS2_DEV="Elan_PS2"
set _SYNA_SMB_DEV="SYNA_SMB"
set _DRV_CUR_PATH="%~dp0%"
set _CUR_DRIVER_PATH=%_ELAN_PS2_DEV%

pushd %_DRV_CUR_PATH%
check_hwid.exe > nul
popd
if %ERRORLEVEL% == 0 goto ELAN_PS2
if %ERRORLEVEL% == 1 goto SYNA_SMB

goto exit

:ELAN_PS2
pushd %_DRV_CUR_PATH%
dpinst.exe /u %_ELAN_PS2_DEV%\AsusTP.inf /S /Q
popd
goto exit

:SYNA_SMB
pushd %_DRV_CUR_PATH%
dpinst.exe /u %_SYNA_SMB_DEV%\AsusTP.inf /S /Q
dpinst.exe /u %_SYNA_SMB_DEV%\SmbDrv.inf /S /Q
popd

goto exit



:exit