網頁

2025年2月26日 星期三

解決windows server 2025安裝在筆電,觸控板無作用問題

因在windows 11安裝VMware Workstation 虛擬機,閒置後喚醒,執行行速度很慢很卡,才改裝windows server。請參考:VMware Workstation 虛擬機閒置後喚醒,執行行速度很慢很卡的解決方法

原本在筆電安裝windows server 2022,也碰到觸控板無作用問題,上網搜尋之後,有找到解決方案。測試在筆電改裝windows server 2025,觸控板無作用問題,仍存在。沿用windows server 2022的解決方案,有時候可以,有時候觸控板還是無作用問題。為了找出可重複性工序,就重灌windows server 2025,且備份已灌好的windows server 2025,每次測試不同工序時,都還原windows server 2025,從原始狀態,安裝驅動程式、導入註冊檔、複製hidi2c.sys,安裝hidi2c.inf。經過多次還原測試,找出可重複性工序之後,才撰寫本文。

以ASUS vivobook x1605va筆電,安裝windows server 2025例要準備的檔案:
從ASUS 網站下載vivibook x1605va晶片組驅動程式 Intel I2C 驅動程式。請依自己使用的筆電型號,從官方網站下載類似的Intel I2C 驅動程式。
I2C_DCH_Intel_Z_V30.100.2237.26Sub1_32096.exe 寫本文時下載的版本。
從windows server 2025對應的windows 11 24h2的install.wim或boot.wim檔內,windows\inf資料夾擷取hidi2c.inf,windows\system32\drivers資料夾擷取hidi2c.sys

windows server 2025對應的windows 11 24h2:
windows server 2025 24h2 26100

windows 11 24h2 26100,從windows 11 24h2install.wim或boot.wim檔內,windows\inf資料夾擷取hidi2c.inf,windows\system32\drivers資料夾擷取hidi2c.sys,以供解決windows server 2025安裝在筆電,觸控板無作用問題。


參考https://winraid.level1techs.com/t/i2c-on-windows-server/37949/3 網頁,開啟記事本建立a.reg、b.reg、c.reg、d.reg,(存檔時的編碼要選UTF-16LE)。
a.reg
Windows Registry Editor Version 5.00

[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\hidi2c]
"ImagePath"=hex(2):5c,00,53,00,79,00,73,00,74,00,65,00,6d,00,52,00,6f,00,6f,00,\
  74,00,5c,00,53,00,79,00,73,00,74,00,65,00,6d,00,33,00,32,00,5c,00,64,00,72,\
  00,69,00,76,00,65,00,72,00,73,00,5c,00,68,00,69,00,64,00,69,00,32,00,63,00,\
  2e,00,73,00,79,00,73,00,00,00
"Type"=dword:00000001
"Start"=dword:00000003
"ErrorControl"=dword:00000001
"Group"="Extended Base"
"Tag"=dword:00000018
"DisplayName"="@hidi2c.inf,%hidi2c.SVCDESC%;Microsoft I2C HID Miniport Driver"
"Owners"=hex(7):68,00,69,00,64,00,69,00,32,00,63,00,2e,00,69,00,6e,00,66,00,00,\
  00,00,00

[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\hidi2c\Parameters]
"WppRecorder_UseTimeStamp"=dword:00000001

[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\hidi2c\Parameters\Wdf]
"WdfMajorVersion"=dword:00000001
"WdfMinorVersion"=dword:0000000f

[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\hidi2c\SharedState]
"WppRecorder_TraceGuid"="{e742c27d-29b1-4e4b-94ee-074d3ad72836}"

[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\hidi2c\State]

[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\hidi2c\State\Wdf]
"TimeOfLastTelemetryLog"=hex(b):7a,04,46,aa,9b,a6,da,01

[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\hidi2c\Enum]
"Count"=dword:00000001
"NextInstance"=dword:00000001
"0"="ACPI\\ASUE1213\\1"

b.reg
Windows Registry Editor Version 5.00

[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Class\{745a17a0-74d3-11d0-b6fe-00a0c90f57da}]
"Class"="HIDClass"
"ClassDesc"="@%SystemRoot%\\System32\\hid.dll,-101"
"IconPath"=hex(7):25,00,53,00,79,00,73,00,74,00,65,00,6d,00,52,00,6f,00,6f,00,\
  74,00,25,00,5c,00,73,00,79,00,73,00,74,00,65,00,6d,00,33,00,32,00,5c,00,73,\
  00,65,00,74,00,75,00,70,00,61,00,70,00,69,00,2e,00,64,00,6c,00,6c,00,2c,00,\
  2d,00,32,00,34,00,00,00,00,00
"NoInstallClass"="1"

[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Class\{745a17a0-74d3-11d0-b6fe-00a0c90f57da}\0000]
"DriverDesc"="USB Input Device"
"ProviderName"="Microsoft"
"DriverDateData"=hex:00,80,8c,a3,c5,94,c6,01
"DriverDate"="6-21-2006"
"DriverVersion"="10.0.26100.1"
"InfPath"="input.inf"
"InfSection"="HID_Inst.NT"
"MatchingDeviceId"="USB\\Class_03&SubClass_01"

[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Class\{745a17a0-74d3-11d0-b6fe-00a0c90f57da}\0001]
"DriverDesc"="USB Input Device"
"ProviderName"="Microsoft"
"DriverDateData"=hex:00,80,8c,a3,c5,94,c6,01
"DriverDate"="6-21-2006"
"DriverVersion"="10.0.26100.1"
"InfPath"="input.inf"
"InfSection"="HID_Inst.NT"
"MatchingDeviceId"="USB\\Class_03"

[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Class\{745a17a0-74d3-11d0-b6fe-00a0c90f57da}\0002]
"DriverDesc"="HID-compliant consumer control device"
"ProviderName"="Microsoft"
"DriverDateData"=hex:00,80,8c,a3,c5,94,c6,01
"DriverDate"="6-21-2006"
"DriverVersion"="10.0.26100.1"
"InfPath"="hidserv.inf"
"InfSection"="HIDSystemConsumerDevice"
"MatchingDeviceId"="HID_DEVICE_UP:000C_U:0001"

c.reg
Windows Registry Editor Version 5.00

[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Enum\ACPI]

[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Enum\ACPI\ASUE1213]

[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Enum\ACPI\ASUE1213\1]
"Capabilities"=dword:00000030
"Address"=dword:00000001
"ContainerID"="{00000000-0000-0000-ffff-ffffffffffff}"
"HardwareID"=hex(7):41,00,43,00,50,00,49,00,5c,00,56,00,45,00,4e,00,5f,00,41,\
  00,53,00,55,00,45,00,26,00,44,00,45,00,56,00,5f,00,31,00,32,00,31,00,33,00,\
  00,00,41,00,43,00,50,00,49,00,5c,00,41,00,53,00,55,00,45,00,31,00,32,00,31,\
  00,33,00,00,00,2a,00,41,00,53,00,55,00,45,00,31,00,32,00,31,00,33,00,00,00,\
  00,00
"CompatibleIDs"=hex(7):41,00,43,00,50,00,49,00,5c,00,50,00,4e,00,50,00,30,00,\
  43,00,35,00,30,00,00,00,50,00,4e,00,50,00,30,00,43,00,35,00,30,00,00,00,00,\
  00
"ClassGUID"="{745a17a0-74d3-11d0-b6fe-00a0c90f57da}"
"Service"="hidi2c"
"UpperFilters"=hex(7):6d,00,73,00,68,00,69,00,64,00,6b,00,6d,00,64,00,66,00,00,\
  00,00,00
"DeviceDesc"="@hidi2c.inf,%hidi2c.devicedesc%;I2C HID Device"
"Driver"="{745a17a0-74d3-11d0-b6fe-00a0c90f57da}\\0005"
"Mfg"="@hidi2c.inf,%msft%;Microsoft"
"ConfigFlags"=dword:00000000
"ParentIdPrefix"="5&3855df62&0"

[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Enum\ACPI\ASUE1213\1\Device Parameters]
"EnhancedPowerManagementEnabled"=dword:00000001
"DeviceResetNotificationEnabled"=dword:00000001
"LegacyTouchScaling"=dword:00000000
"FirmwareIdentified"=dword:00000001

[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Enum\ACPI\ASUE1213\1\Device Parameters\e5b3b5ac-9725-4f78-963f-03dfb1d828c7]
"D3ColdSupported"=dword:00000001

[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Enum\ACPI\ASUE1213\1\Device Parameters\Interrupt Management]

[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Enum\ACPI\ASUE1213\1\Device Parameters\Interrupt Management\Affinity Policy]

[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Enum\ACPI\ASUE1213\1\Device Parameters\Interrupt Management\Affinity Policy - Temporal]
"TargetGroup"=dword:00000000
"TargetSet"=hex(b):ff,ff,00,00,00,00,00,00

[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Enum\ACPI\ASUE1213\1\LogConf]
"BasicConfigVector"=hex(a):68,00,00,00,0f,00,00,00,00,00,00,00,00,00,00,00,00,\
  00,00,00,00,00,00,00,00,00,00,00,01,00,00,00,01,00,01,00,02,00,00,00,00,84,\
  00,00,00,00,00,00,02,01,00,00,01,00,00,00,00,00,00,00,00,00,00,00,00,00,00,\
  00,00,00,00,00,00,02,01,00,00,00,00,00,28,00,00,00,28,00,00,00,02,00,00,00,\
  00,00,00,00,00,00,00,00,00,00,00,00
"BootConfig"=hex(8):01,00,00,00,0f,00,00,00,00,00,00,00,01,00,01,00,02,00,00,\
  00,84,00,00,00,02,01,00,00,01,00,00,00,00,00,00,00,00,00,00,00,02,01,00,00,\
  28,00,00,00,28,00,00,00,ff,ff,ff,ff,00,00,00,00

[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Enum\ACPI\ASUE1213\1\Properties]

[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Enum\ACPI\ASUE1213\1\Properties\{540b947e-8b40-45bc-a8a2-6a0b894cbda2}]

[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Enum\ACPI\ASUE1213\1\Properties\{540b947e-8b40-45bc-a8a2-6a0b894cbda2}\0007]
@=hex(ffff0012):68,00,69,00,64,00,69,00,32,00,63,00,2e,00,69,00,6e,00,66,00,3a,\
  00,41,00,43,00,50,00,49,00,5c,00,50,00,4e,00,50,00,30,00,43,00,35,00,30,00,\
  2c,00,68,00,69,00,64,00,69,00,32,00,63,00,5f,00,44,00,65,00,76,00,69,00,63,\
  00,65,00,2e,00,4e,00,54,00,00,00

[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Enum\ACPI\ASUE1213\1\Properties\{540b947e-8b40-45bc-a8a2-6a0b894cbda2}\000A]
@=hex(ffff0012):5c,00,5f,00,53,00,42,00,2e,00,50,00,43,00,30,00,30,00,2e,00,49,\
  00,32,00,43,00,31,00,2e,00,45,00,54,00,50,00,44,00,00,00

[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Enum\ACPI\ASUE1213\1\Properties\{80497100-8c73-48b9-aad9-ce387e19c56e}]

[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Enum\ACPI\ASUE1213\1\Properties\{80497100-8c73-48b9-aad9-ce387e19c56e}\0006]
@=hex(ffff0007):00,00,00,00

[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Enum\ACPI\ASUE1213\1\Properties\{83da6326-97a6-4088-9453-a1923f573b29}]

[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Enum\ACPI\ASUE1213\1\Properties\{83da6326-97a6-4088-9453-a1923f573b29}\0003]
@=hex(ffff0012):68,00,69,00,64,00,69,00,32,00,63,00,2e,00,69,00,6e,00,66,00,3a,\
  00,64,00,62,00,30,00,34,00,61,00,31,00,36,00,63,00,62,00,35,00,31,00,37,00,\
  32,00,64,00,30,00,63,00,3a,00,68,00,69,00,64,00,69,00,32,00,63,00,5f,00,44,\
  00,65,00,76,00,69,00,63,00,65,00,2e,00,4e,00,54,00,3a,00,31,00,30,00,2e,00,\
  30,00,2e,00,32,00,36,00,31,00,30,00,30,00,2e,00,31,00,3a,00,41,00,43,00,50,\
  00,49,00,5c,00,50,00,4e,00,50,00,30,00,43,00,35,00,30,00,00,00

[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Enum\ACPI\ASUE1213\1\Properties\{83da6326-97a6-4088-9453-a1923f573b29}\000A]
@=hex(ffff0012):50,00,43,00,49,00,5c,00,56,00,45,00,4e,00,5f,00,38,00,30,00,38,\
  00,36,00,26,00,44,00,45,00,56,00,5f,00,35,00,31,00,45,00,39,00,26,00,53,00,\
  55,00,42,00,53,00,59,00,53,00,5f,00,31,00,37,00,34,00,33,00,31,00,30,00,34,\
  00,33,00,26,00,52,00,45,00,56,00,5f,00,30,00,31,00,5c,00,33,00,26,00,31,00,\
  31,00,35,00,38,00,33,00,36,00,35,00,39,00,26,00,30,00,26,00,41,00,39,00,00,\
  00

[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Enum\ACPI\ASUE1213\1\Properties\{83da6326-97a6-4088-9453-a1923f573b29}\001A]
@=hex(ffff1003):00

[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Enum\ACPI\ASUE1213\1\Properties\{83da6326-97a6-4088-9453-a1923f573b29}\0064]
@=hex(ffff0010):7a,04,46,aa,9b,a6,da,01

[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Enum\ACPI\ASUE1213\1\Properties\{83da6326-97a6-4088-9453-a1923f573b29}\0065]
@=hex(ffff0010):7a,04,46,aa,9b,a6,da,01

[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Enum\ACPI\ASUE1213\1\Properties\{83da6326-97a6-4088-9453-a1923f573b29}\0066]
@=hex(ffff0010):18,6b,59,aa,9b,a6,da,01

[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Enum\ACPI\ASUE1213\1\Properties\{83da6326-97a6-4088-9453-a1923f573b29}\0067]

[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Enum\ACPI\ASUE1213\1\Properties\{a45c254e-df1c-4efd-8020-67d146a850e0}]

[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Enum\ACPI\ASUE1213\1\Properties\{a45c254e-df1c-4efd-8020-67d146a850e0}\0025]
@=hex(ffff2012):41,00,43,00,50,00,49,00,28,00,5f,00,53,00,42,00,5f,00,29,00,23,\
  00,41,00,43,00,50,00,49,00,28,00,50,00,43,00,30,00,30,00,29,00,23,00,41,00,\
  43,00,50,00,49,00,28,00,49,00,32,00,43,00,31,00,29,00,23,00,41,00,43,00,50,\
  00,49,00,28,00,45,00,54,00,50,00,44,00,29,00,00,00,00,00

[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Enum\ACPI\ASUE1213\1\Properties\{a8b865dd-2e3d-4094-ad97-e593a70c75d6}]

[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Enum\ACPI\ASUE1213\1\Properties\{a8b865dd-2e3d-4094-ad97-e593a70c75d6}\0002]
@=hex(ffff0010):00,80,8c,a3,c5,94,c6,01

[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Enum\ACPI\ASUE1213\1\Properties\{a8b865dd-2e3d-4094-ad97-e593a70c75d6}\0003]
@=hex(ffff0012):31,00,30,00,2e,00,30,00,2e,00,32,00,36,00,31,00,30,00,30,00,2e,\
  00,31,00,00,00

[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Enum\ACPI\ASUE1213\1\Properties\{a8b865dd-2e3d-4094-ad97-e593a70c75d6}\0004]
@=hex(ffff0012):49,00,32,00,43,00,20,00,48,00,49,00,44,00,20,00,44,00,65,00,76,\
  00,69,00,63,00,65,00,00,00

[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Enum\ACPI\ASUE1213\1\Properties\{a8b865dd-2e3d-4094-ad97-e593a70c75d6}\0005]
@=hex(ffff0012):68,00,69,00,64,00,69,00,32,00,63,00,2e,00,69,00,6e,00,66,00,00,\
  00

[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Enum\ACPI\ASUE1213\1\Properties\{a8b865dd-2e3d-4094-ad97-e593a70c75d6}\0006]
@=hex(ffff0012):68,00,69,00,64,00,69,00,32,00,63,00,5f,00,44,00,65,00,76,00,69,\
  00,63,00,65,00,2e,00,4e,00,54,00,00,00

[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Enum\ACPI\ASUE1213\1\Properties\{a8b865dd-2e3d-4094-ad97-e593a70c75d6}\0008]
@=hex(ffff0012):41,00,43,00,50,00,49,00,5c,00,50,00,4e,00,50,00,30,00,43,00,35,\
  00,30,00,00,00

[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Enum\ACPI\ASUE1213\1\Properties\{a8b865dd-2e3d-4094-ad97-e593a70c75d6}\0009]
@=hex(ffff0012):4d,00,69,00,63,00,72,00,6f,00,73,00,6f,00,66,00,74,00,00,00

[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Enum\ACPI\ASUE1213\1\Properties\{a8b865dd-2e3d-4094-ad97-e593a70c75d6}\000E]
@=hex(ffff0007):00,20,ff,00

[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Enum\ACPI\ASUE1213\1\Properties\{a8b865dd-2e3d-4094-ad97-e593a70c75d6}\0010]
@=hex(ffff2012):70,00,63,00,69,00,2e,00,69,00,6e,00,66,00,00,00,00,00

[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Enum\ACPI\ASUE1213\1\Properties\{f0e20f09-d97a-49a9-8046-bb6e22e6bb2e}]

[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Enum\ACPI\ASUE1213\1\Properties\{f0e20f09-d97a-49a9-8046-bb6e22e6bb2e}\0002]
@=hex(ffff1003):01,00,00,00,00,00,00,00,00,00,00,00,81,00,00,00,08,00,00,00,02,\
  00,00,00,00,00,00,00,00,00,00,00,ff,ff,00,00,00,00,00,00,00,00,00,00,00,00,\
  00,00,00,00,00,00,00,00,00,00,00,00,00,00,00,00,00,00,28,00,00,00,00,00,00,\
  00,00,00,00,00,00,00,00,00,00,00,00,00,00,00,00,00,00,00,00,00,00,00,00,00

[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Enum\ACPI\ASUE1213\1\Control]
"FilteredConfigVector"=hex(a):d0,00,00,00,0f,00,00,00,00,00,00,00,00,00,00,00,\
  00,00,00,00,00,00,00,00,00,00,00,00,02,00,00,00,01,00,01,00,03,00,00,00,01,\
  80,03,00,00,00,00,00,01,00,00,00,00,00,00,00,00,00,00,00,00,00,00,00,00,00,\
  00,00,00,00,00,00,00,84,00,00,00,00,00,00,02,01,00,00,01,00,00,00,00,00,00,\
  00,00,00,00,00,00,00,00,00,00,00,00,00,01,02,01,80,00,00,00,00,28,00,00,00,\
  28,00,00,00,02,00,00,00,00,00,00,00,00,00,00,00,00,00,00,00,01,00,01,00,02,\
  00,00,00,00,84,00,00,00,00,00,00,02,01,00,00,01,00,00,00,00,00,00,00,00,00,\
  00,00,00,00,00,00,00,00,00,00,00,02,01,00,00,00,00,00,28,00,00,00,28,00,00,\
  00,02,00,00,00,00,00,00,00,00,00,00,00,00,00,00,00
"AllocConfig"=hex(8):01,00,00,00,0f,00,00,00,00,00,00,00,01,00,01,00,02,00,00,\
  00,84,00,00,00,02,01,00,00,01,00,00,00,00,00,00,00,00,00,00,00,02,01,00,00,\
  28,00,00,00,28,00,00,00,ff,ff,ff,ff,00,00,00,00

d.reg
Windows Registry Editor Version 5.00

[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\EventLog\System\hidi2c]
"EventMessageFile"=hex(2):25,00,53,00,79,00,73,00,74,00,65,00,6d,00,52,00,6f,\
  00,6f,00,74,00,25,00,5c,00,53,00,79,00,73,00,74,00,65,00,6d,00,33,00,32,00,\
  5c,00,49,00,6f,00,4c,00,6f,00,67,00,4d,00,73,00,67,00,2e,00,64,00,6c,00,6c,\
  00,3b,00,25,00,53,00,79,00,73,00,74,00,65,00,6d,00,52,00,6f,00,6f,00,74,00,\
  25,00,5c,00,53,00,79,00,73,00,74,00,65,00,6d,00,33,00,32,00,5c,00,44,00,72,\
  00,69,00,76,00,65,00,72,00,73,00,5c,00,68,00,69,00,64,00,69,00,32,00,63,00,\
  2e,00,73,00,79,00,73,00,00,00
"TypesSupported"=dword:00000007

1.cmd
REM 以系統管理員身分執行批次檔
REM 資料來源 https://stackoverflow.com/questions/7044985/how-can-i-auto-elevate-my-batch-file-so-that-it-requests-from-uac-administrator%E3%80%91%EF%BC%8C
@echo off
CLS
cd /d "%~dp0"
ECHO.
ECHO =============================
ECHO Running Admin Shell
ECHO =============================

:init
setlocal DisableDelayedExpansion
set "batchPath=%~0"
for %%k in (%0) do set batchName=%%~nk
set "vbsGetPrivileges=%temp%\OEgetPriv_%batchName%.vbs"
setlocal EnableDelayedExpansion

:checkPrivileges
NET FILE 1>NUL 2>NUL
if '%errorlevel%' == '0' ( goto gotPrivileges ) else ( goto getPrivileges )

:getPrivileges
if '%1'=='ELEV' (echo ELEV & shift /1 & goto gotPrivileges)
ECHO.
ECHO **************************************
ECHO Invoking UAC for Privilege Escalation
ECHO **************************************

ECHO Set UAC = CreateObject^("Shell.Application"^) > "%vbsGetPrivileges%"
ECHO args = "ELEV " >> "%vbsGetPrivileges%"
ECHO For Each strArg in WScript.Arguments >> "%vbsGetPrivileges%"
ECHO args = args ^& strArg ^& " "  >> "%vbsGetPrivileges%"
ECHO Next >> "%vbsGetPrivileges%"
ECHO UAC.ShellExecute "!batchPath!", args, "", "runas", 1 >> "%vbsGetPrivileges%"
"%SystemRoot%\System32\WScript.exe" "%vbsGetPrivileges%" %*
exit /B

:gotPrivileges
setlocal & pushd .
cd /d %~dp0
if '%1'=='ELEV' (del "%vbsGetPrivileges%" 1>nul 2>nul  &  shift /1)

::::::::::::::::::::::::::::
::START
::::::::::::::::::::::::::::

copy hidi2c.sys C:\Windows\System32\drivers /y
start /wait regedit /s a.reg
start /wait regedit /s b.reg
start /wait regedit /s c.reg
start /wait regedit /s d.reg
shutdown /r /t 5 /c "windows server 2025 筆電觸控板啟用設定完成,5秒後重開機"  

檔案準備齊全之後,執行次序如下:
在hidi2c.inf上按滑鼠右鍵->安裝。

複製hidi2c.sys至windows\system32\drivers資料夾

執行1.bat導入a.reg、b.reg、c.reg、d.reg後,自動重開機。
安裝Intel I2C 驅動程式 I2C_DCH_Intel_Z_V30.100.2237.26Sub1_32096.exe(依自己筆電型號執行類似驅動程式)。
重開機之後,windows server 2025安裝在筆電,觸控板無作用問題,大致可以獲得解決。

沒有留言:

張貼留言