Downgrading Panasonic Toughbook / Toughpad units from Tpm 2.0 to 1.2 to support Windows 7 Deployments

By | February 24, 2017
Share

1st You must query out Panasonic equipment and machines with Tpm 2.0 set.

WMI namespace: root\CIMV2\Security\MicrosoftTpm

WQL query: SELECT * FROM Win32_Tpm WHERE NOT SpecVersion LIKE “1.2”

2nd You MUST ensure that AC is connected, otherwise the Tpm downgrade will fail. Here is a script I made that tosses a prompt if off AC and loops until AC is plugged in.

https://github.com/brianfgonzalez/Scripts/blob/master/ZTICheckBattery.wsf

And lastly, run the TPMFUac64.exe with the -d argument to execute the downgrade of the Tpm chipset. This will require a reboot, which you can roll into the standard reboot that occurs after the OS is applied.

* TPMFUac64.exe must be requested from your local technical support team.

/BG

Environment Variables set during the “Update Media” processing of MDT

By | January 25, 2017
Share

At the end of running “Update Media” for the 1st run or on any run with the “-force” argument passed, an update script can be called via the “LitetouchPE.xml” file.

Here are the dynamic vars exposed that can be called via a custom script.

ADKPath | C:\Program Files (x86)\Windows Kits\10\Assessment and Deployment Kit
CONTENT | C:\Users\bg\AppData\Local\Temp\MDTUpdate.5808\LiteTouchPE_x86.iso
DEPLOYROOT | c:\DeploymentShareITP
RealPlatform | AMD64
STAGE | POSTISO
TEMPLATE | LiteTouchPE

/BG

Batch script to set the A1 button actions on a FZ-G1 Toughpad tablet

By | December 14, 2016
Share

Here is the batch, it’s fairly self-explanatory:

rem import default user's hive
reg load HKLM\ImportedHive "%SystemDrive%\Users\Default\NTUSER.DAT"

rem create batch that will be called by A1 button
echo "%ProgramFiles(x86)%\Panasonic\PCam\PCam.exe">%WinDir%\System32\A1Click_Mapping.bat
echo "%ProgramFiles(x86)%\Panasonic\TSModSel\tsmodsel.exe" -G>%WinDir%\System32\A1Hold_Mapping.bat

rem ties A1 to cmd.exe /c %WinDir%\System32\A1Click_Mapping.bat and A1Hold_Mapping.bat for the DEFAULT USER
Reg.exe add "HKLM\ImportedHive\Control Panel\TabletPC\ButtonMaps\0" /v "ButtonID" /t REG_DWORD /d "2" /f
Reg.exe add "HKLM\ImportedHive\Control Panel\TabletPC\ButtonMaps\0\PrimaryLandscape" /v "DefAction" /t REG_DWORD /d "2147483648" /f
Reg.exe add "HKLM\ImportedHive\Control Panel\TabletPC\ButtonMaps\0\PrimaryLandscape" /v "DefActionData" /t REG_BINARY /d "2500530079007300740065006d0052006f006f00740025005c00730079007300740065006d00330032005c0063006d0064002e0065007800650000002f0063002000220043003a005c00770069006e0064006f00770073005c00730079007300740065006d00330032005c004100310043006c00690063006b005f004d0061007000700069006e0067002e0062006100740022000000" /f
Reg.exe add "HKLM\ImportedHive\Control Panel\TabletPC\ButtonMaps\0\PrimaryLandscape" /v "DefHoldAction" /t REG_DWORD /d "2147483648" /f
Reg.exe add "HKLM\ImportedHive\Control Panel\TabletPC\ButtonMaps\0\PrimaryLandscape" /v "DefHoldActionData" /t REG_BINARY /d "2500530079007300740065006d0052006f006f00740025005c00730079007300740065006d00330032005c0063006d0064002e0065007800650000002f0063002000220043003a005c00770069006e0064006f00770073005c00730079007300740065006d00330032005c004100310048006f006c0064005f004d0061007000700069006e0067002e0062006100740022000000" /f
Reg.exe add "HKLM\ImportedHive\Control Panel\TabletPC\ButtonMaps\0\PrimaryPortrait" /v "DefAction" /t REG_DWORD /d "2147483648" /f
Reg.exe add "HKLM\ImportedHive\Control Panel\TabletPC\ButtonMaps\0\PrimaryPortrait" /v "DefActionData" /t REG_BINARY /d "2500530079007300740065006d0052006f006f00740025005c00730079007300740065006d00330032005c0063006d0064002e0065007800650000002f0063002000220043003a005c00770069006e0064006f00770073005c00730079007300740065006d00330032005c004100310043006c00690063006b005f004d0061007000700069006e0067002e0062006100740022000000" /f
Reg.exe add "HKLM\ImportedHive\Control Panel\TabletPC\ButtonMaps\0\PrimaryPortrait" /v "DefHoldAction" /t REG_DWORD /d "2147483648" /f
Reg.exe add "HKLM\ImportedHive\Control Panel\TabletPC\ButtonMaps\0\PrimaryPortrait" /v "DefHoldActionData" /t REG_BINARY /d "2500530079007300740065006d0052006f006f00740025005c00730079007300740065006d00330032005c0063006d0064002e0065007800650000002f0063002000220043003a005c00770069006e0064006f00770073005c00730079007300740065006d00330032005c004100310048006f006c0064005f004d0061007000700069006e0067002e0062006100740022000000" /f
Reg.exe add "HKLM\ImportedHive\Control Panel\TabletPC\ButtonMaps\0\SecondaryLandscape" /v "DefAction" /t REG_DWORD /d "2147483648" /f
Reg.exe add "HKLM\ImportedHive\Control Panel\TabletPC\ButtonMaps\0\SecondaryLandscape" /v "DefActionData" /t REG_BINARY /d "2500530079007300740065006d0052006f006f00740025005c00730079007300740065006d00330032005c0063006d0064002e0065007800650000002f0063002000220043003a005c00770069006e0064006f00770073005c00730079007300740065006d00330032005c004100310043006c00690063006b005f004d0061007000700069006e0067002e0062006100740022000000" /f
Reg.exe add "HKLM\ImportedHive\Control Panel\TabletPC\ButtonMaps\0\SecondaryLandscape" /v "DefHoldAction" /t REG_DWORD /d "2147483648" /f
Reg.exe add "HKLM\ImportedHive\Control Panel\TabletPC\ButtonMaps\0\SecondaryLandscape" /v "DefHoldActionData" /t REG_BINARY /d "2500530079007300740065006d0052006f006f00740025005c00730079007300740065006d00330032005c0063006d0064002e0065007800650000002f0063002000220043003a005c00770069006e0064006f00770073005c00730079007300740065006d00330032005c004100310048006f006c0064005f004d0061007000700069006e0067002e0062006100740022000000" /f
Reg.exe add "HKLM\ImportedHive\Control Panel\TabletPC\ButtonMaps\0\SecondaryPortrait" /v "DefAction" /t REG_DWORD /d "2147483648" /f
Reg.exe add "HKLM\ImportedHive\Control Panel\TabletPC\ButtonMaps\0\SecondaryPortrait" /v "DefActionData" /t REG_BINARY /d "2500530079007300740065006d0052006f006f00740025005c00730079007300740065006d00330032005c0063006d0064002e0065007800650000002f0063002000220043003a005c00770069006e0064006f00770073005c00730079007300740065006d00330032005c004100310043006c00690063006b005f004d0061007000700069006e0067002e0062006100740022000000" /f
Reg.exe add "HKLM\ImportedHive\Control Panel\TabletPC\ButtonMaps\0\SecondaryPortrait" /v "DefHoldAction" /t REG_DWORD /d "2147483648" /f
Reg.exe add "HKLM\ImportedHive\Control Panel\TabletPC\ButtonMaps\0\SecondaryPortrait" /v "DefHoldActionData" /t REG_BINARY /d "2500530079007300740065006d0052006f006f00740025005c00730079007300740065006d00330032005c0063006d0064002e0065007800650000002f0063002000220043003a005c00770069006e0064006f00770073005c00730079007300740065006d00330032005c004100310048006f006c0064005f004d0061007000700069006e0067002e0062006100740022000000" /f

rem ties A1 to cmd.exe /c %WinDir%\System32\A1Click_Mapping.bat and A1Hold_Mapping.bat for the CURRENT USER
Reg.exe add "HKCU\Control Panel\TabletPC\ButtonMaps\0" /v "ButtonID" /t REG_DWORD /d "2" /f
Reg.exe add "HKCU\Control Panel\TabletPC\ButtonMaps\0\PrimaryLandscape" /v "DefAction" /t REG_DWORD /d "2147483648" /f
Reg.exe add "HKCU\Control Panel\TabletPC\ButtonMaps\0\PrimaryLandscape" /v "DefActionData" /t REG_BINARY /d "2500530079007300740065006d0052006f006f00740025005c00730079007300740065006d00330032005c0063006d0064002e0065007800650000002f0063002000220043003a005c00770069006e0064006f00770073005c00730079007300740065006d00330032005c004100310043006c00690063006b005f004d0061007000700069006e0067002e0062006100740022000000" /f
Reg.exe add "HKCU\Control Panel\TabletPC\ButtonMaps\0\PrimaryLandscape" /v "DefHoldAction" /t REG_DWORD /d "2147483648" /f
Reg.exe add "HKCU\Control Panel\TabletPC\ButtonMaps\0\PrimaryLandscape" /v "DefHoldActionData" /t REG_BINARY /d "2500530079007300740065006d0052006f006f00740025005c00730079007300740065006d00330032005c0063006d0064002e0065007800650000002f0063002000220043003a005c00770069006e0064006f00770073005c00730079007300740065006d00330032005c004100310048006f006c0064005f004d0061007000700069006e0067002e0062006100740022000000" /f
Reg.exe add "HKCU\Control Panel\TabletPC\ButtonMaps\0\PrimaryPortrait" /v "DefAction" /t REG_DWORD /d "2147483648" /f
Reg.exe add "HKCU\Control Panel\TabletPC\ButtonMaps\0\PrimaryPortrait" /v "DefActionData" /t REG_BINARY /d "2500530079007300740065006d0052006f006f00740025005c00730079007300740065006d00330032005c0063006d0064002e0065007800650000002f0063002000220043003a005c00770069006e0064006f00770073005c00730079007300740065006d00330032005c004100310043006c00690063006b005f004d0061007000700069006e0067002e0062006100740022000000" /f
Reg.exe add "HKCU\Control Panel\TabletPC\ButtonMaps\0\PrimaryPortrait" /v "DefHoldAction" /t REG_DWORD /d "2147483648" /f
Reg.exe add "HKCU\Control Panel\TabletPC\ButtonMaps\0\PrimaryPortrait" /v "DefHoldActionData" /t REG_BINARY /d "2500530079007300740065006d0052006f006f00740025005c00730079007300740065006d00330032005c0063006d0064002e0065007800650000002f0063002000220043003a005c00770069006e0064006f00770073005c00730079007300740065006d00330032005c004100310048006f006c0064005f004d0061007000700069006e0067002e0062006100740022000000" /f
Reg.exe add "HKCU\Control Panel\TabletPC\ButtonMaps\0\SecondaryLandscape" /v "DefAction" /t REG_DWORD /d "2147483648" /f
Reg.exe add "HKCU\Control Panel\TabletPC\ButtonMaps\0\SecondaryLandscape" /v "DefActionData" /t REG_BINARY /d "2500530079007300740065006d0052006f006f00740025005c00730079007300740065006d00330032005c0063006d0064002e0065007800650000002f0063002000220043003a005c00770069006e0064006f00770073005c00730079007300740065006d00330032005c004100310043006c00690063006b005f004d0061007000700069006e0067002e0062006100740022000000" /f
Reg.exe add "HKCU\Control Panel\TabletPC\ButtonMaps\0\SecondaryLandscape" /v "DefHoldAction" /t REG_DWORD /d "2147483648" /f
Reg.exe add "HKCU\Control Panel\TabletPC\ButtonMaps\0\SecondaryLandscape" /v "DefHoldActionData" /t REG_BINARY /d "2500530079007300740065006d0052006f006f00740025005c00730079007300740065006d00330032005c0063006d0064002e0065007800650000002f0063002000220043003a005c00770069006e0064006f00770073005c00730079007300740065006d00330032005c004100310048006f006c0064005f004d0061007000700069006e0067002e0062006100740022000000" /f
Reg.exe add "HKCU\Control Panel\TabletPC\ButtonMaps\0\SecondaryPortrait" /v "DefAction" /t REG_DWORD /d "2147483648" /f
Reg.exe add "HKCU\Control Panel\TabletPC\ButtonMaps\0\SecondaryPortrait" /v "DefActionData" /t REG_BINARY /d "2500530079007300740065006d0052006f006f00740025005c00730079007300740065006d00330032005c0063006d0064002e0065007800650000002f0063002000220043003a005c00770069006e0064006f00770073005c00730079007300740065006d00330032005c004100310043006c00690063006b005f004d0061007000700069006e0067002e0062006100740022000000" /f
Reg.exe add "HKCU\Control Panel\TabletPC\ButtonMaps\0\SecondaryPortrait" /v "DefHoldAction" /t REG_DWORD /d "2147483648" /f
Reg.exe add "HKCU\Control Panel\TabletPC\ButtonMaps\0\SecondaryPortrait" /v "DefHoldActionData" /t REG_BINARY /d "2500530079007300740065006d0052006f006f00740025005c00730079007300740065006d00330032005c0063006d0064002e0065007800650000002f0063002000220043003a005c00770069006e0064006f00770073005c00730079007300740065006d00330032005c004100310048006f006c0064005f004d0061007000700069006e0067002e0062006100740022000000" /f

rem unload default user's hive
reg unload HKLM\ImportedHive

 

2 Unattend.xml settings I specify in all of my Windows 10 installations.

By | December 14, 2016
Share

  

There are others, but these are 2 I include in all of my Unattend.xml files.

  1. Disable the First run animation from displaying:
    reg add HKLM\Software\Microsoft\Windows\CurrentVersion\Policies\System /v EnableFirstLogonAnimation /t REG_DWORD /d 0 /f
  2. Prevent the Network Selection box from appearing.
    reg add HKLM\System\CurrentControlSet\Control\Network\NewNetworkWindowOff /F
....
<RunSynchronousCommand wcm:action="add">
	<Description>disable firstlogon animation for win10</Description>
	<Order>5</Order>
	<Path>reg add HKLM\Software\Microsoft\Windows\CurrentVersion\Policies\System /v EnableFirstLogonAnimation /t REG_DWORD /d 0 /f</Path>
</RunSynchronousCommand>
<RunSynchronousCommand wcm:action="add">
	<Description>disable firstlogon animation for win10</Description>
	<Order>6</Order>
	<Path>reg add HKLM\System\CurrentControlSet\Control\Network\NewNetworkWindowOff /F</Path>
</RunSynchronousCommand>
...

/BG

Setting the Wallpaper and Lockscreen in Windows 10

By | December 4, 2016
Share

Finally! I found a failsafe way to set a desired image to both the default wallpaper and lockscreen in Windows 10.

Place a Wallpaper.jpg into your MDT “scripts” folder, add Powershell support to your WinPE (you will need to also add .NET support).  Then use this command line after applying the image:

powershell.exe -ExecutionPolicy "ByPass" -Command "Get-ChildItem \"%OSDISK%\Windows\img*.jpg\" -Recurse | % { Copy-Item \"%SCRIPTROOT%\Wallpaper.jpg\" $_.FullName -Force -Verbose }"

I basically am replacing ALL of the built-in Out of box wallpapers with my wallpaper.  Using LGPO, registry, or replacing files after Windows is loaded just didn’t work for me.  This worked 100% of the time.

wallpaper-replace-in-task-sequence

pe-features

set-wallpaper

/BG