Grab bios setting on Win 7 X64
I have the following script that grabs the bios setting for wakeonlan, lowpower and acpower. It is not working on x64. I'm looking for what I am missing.
:X86
REM On systems running x86 version of Windows changing directories and calling cctk to pull BIOS settings
REM then processing the txt file created to write the information from the file to the registry
cd "%PROGRAMFILES%"\dell\cctk\x86\
cctk.exe --lowpowers5 --wakeonlan --acpower > %log%\op.txt
for /f "tokens=1,2 delims==" %%G in (%log%\op.txt) DO reg add HKLM\HARDWARE\BIOS\Settings /v %%G /t REG_SZ /d %%H /f
GOTO CLEANUP
:X64
REM On systems running x64 version of Windows changing directories and calling cctk to pull BIOS settings
REM then processing the txt file created to write the information from the file to the registry
cd "%PROGRAMFILES(X86)%"\dell\cctk\x86_64\
cctk.exe --<parameter> > %log%\op.txt
for /f "tokens=1,2 delims==" %%G in (%log%\op.txt) DO reg add HKLM\HARDWARE\BIOS\Settings /v %%G /t REG_SZ /d %%H /f
GOTO CLEANUP
:UNK
REM If the batch is unable to determine the OS architecture there would be OS corruption present so the batch will abort.
ECHO ERROR: Unable to determine OS Architecture, check for software issues in OS.
GOTO CLEANUP
:CLEANUP
REM Removing the folder created for storing the BIOS configuration txt file and its contents
RD /S /Q %log%
:END
0 Comments
[ + ] Show comments
Answers (2)
Answer Summary:
Please log in to answer
Posted by:
ckubaska
11 years ago
cctk added to the system and the parameters added to the script. still doesn't seem to work. I'm wondering if I need to point to the x64 registry?
Comments:
-
I initially looked at that when I first read your question, but I didn't see a separate syswow3264node section for hardware; just software. - philologist 11 years ago
-
Turned out it worked as is except in the OS detection I needed to add AMD64. - ckubaska 11 years ago