@echo off

set currentpath=%cd%
cd %~dp0
echo Installing All Drivers 

echo %cd%
cd Drivers

echo **************
echo Install MBI driver
set foldername=MBI
set infname=MBI.inf
cd %foldername% 
pnputil -i -a %infname%
cd ..

echo ****************
echo Install IO driver
set foldername=I2C
set infname=iai2ce.inf
cd %foldername% 
pnputil -i -a %infname%
cd ..

echo **************
echo Install GPIO driver
set foldername=GPIO
set infname=iagpioe.inf
cd %foldername% 
pnputil -i -a %infname%
cd ..

echo **************
echo Install UART driver
set foldername=UART
set infname=iauarte.inf
cd %foldername% 
pnputil -i -a %infname%
cd ..

echo **************
echo Install SPI driver
set foldername=SPI
set infname=iaspie.inf
cd %foldername% 
pnputil -i -a %infname%
cd ..

echo **************
echo Install PMIC driver
set foldername=PMIC
set infname=pmic.inf
cd %foldername% 
pnputil -i -a %infname%
cd ..

echo **************
echo Install ISH driver
set foldername=ISH\HECI_ISH
set infname=ISH.inf
cd %foldername% 
pnputil -i -a ISH.inf
cd ..\Bus
pnputil -i -a ISH_BusDriver.inf
cd ..\Miniport
pnputil -i -a HID_PCI.inf
cd ..\HidEventFilter
pnputil -i -a HIDEventFilter.inf
cd ..\AdvSensorHIDClassDriver
pnputil -i -a AdvSensorClassDriver.inf
cd ..\AdvSensorHIDClassDriverV2
pnputil -i -a AdvSensorHIDClassDriverV2.inf
cd ..
cd ..

echo **************
echo Install DPTF driver
set foldername=DPTF
set infname=esif_manager.inf
cd %foldername% 
pnputil -i -a esif_manager.inf
pnputil -i -a dptf_acpi.inf
pnputil -i -a dptf_cpu.inf
pnputil -i -a dptf_pch.inf
cd ..

echo **************
echo Install TXEI driver
set foldername=TXEI
set infname=TXEI.inf
cd %foldername% 
pnputil -i -a %infname%
cd ..

echo **************
echo Install Audio driver
set foldername=Audio
set infname=ES8316AudCodec.inf
cd %foldername% 
pnputil -i -a %infname%
pnputil -i -a isstrtc.inf
cd ..

echo **************
echo Install PSS driver
set foldername=PSS
set infname=MonzaX.inf
cd %foldername% 
pnputil -i -a %infname%
cd ..

echo **************
echo Install graphic driver .... 
echo 
set foldername=Graphics
set infname=igdlh64.inf
cd %foldername% 
pnputil -i -a %infname%
cd ..

echo **************
echo Install Camera driver
set foldername=Camera\iacamera64
set infname=iacamera64.inf
cd %foldername% 
pnputil -i -a %infname%
cd ..\iaisp64
pnputil -i -a iaisp64.inf
cd ..

cd ..\..

echo All drivers are installed !
