Implementing the "Windows XP Tablet PC Edition 2005 Single-Image Deployment Supplemental Guide" Process in MDT 2008 - Full Update

Since my original post on this topic back in May I have received a lot of useful feedback, encountered several issues with this process, and with help have found solutions for all of them.  There is also important new information about Window XP Service Pack 3 and this process.  Because of this I have decided to create this new post that is a full update so that all of this information can be found in one place.  I will leave the original post up for a while for people who are still using the old scripts.  However, I will be deleting the post content at some point.

Is this Really a "Single Image" Process?

Before I get into the details of this process, I want to address a topic that seems to frequently generate confusion when creating Sysprep images of Windows installations.  Unfortunately the title chosen for the "Single Image" Guide does not help matters.  Strictly speaking you cannot have a single image for Windows NT architecture operating systems before Windows Vista and Windows Server 2008 unless you have hardware on which Windows will use the same Hardware Abstraction Layer (or HAL) when Windows is installed from the installation media on that hardware.

The HAL is layer of software that hides (or abstracts) the details of the underlying hardware platform so that Windows services and applications do not have to deal with the hardware directly.  They will make calls to the Windows API for generic resources or functions (memory, etc.) and calls will be made to the HAL which will then interact with the hardware to accomplish this.  This makes it easier to write applications and operating system components.  It also make it easier to port Windows itself to other hardware platforms.

Unfortunately for versions of Windows before Window Vista and Windows Server 2008, you cannot create an image on hardware of one HAL type and deploy it to hardware of another HAL type (with a few exceptions).  Windows XP has six HAL types as follows:

  • Standard PC
  • MPS Uniprocessor
  • MPS Multiprocessor
  • Advanced Configuration and Power Interface (ACPI) PC
  • ACPI Uniprocessor
  • ACPI Multiprocessor

The two MPS HAL are compatible.  Therefore, an MPS Uniprocessor image can be deployed to an MPS Multiprocessor computer.  Likewise, an ACPI Uniprocessor image can be deployed to an ACPI Multiprocessor computer.  So if you had hardware of all HAL types, you would need a minimum of four XP Sysprep images to support them.  Luckily, nearly all modern computers are ACPI machines.  So for current deployments, if you had computers of all three ACPI HAL types you would need two XP images:

  • Advanced Configuration and Power Interface (ACPI) PC HAL
  • ACPI Uniprocessor HAL

(The second image could in theory have the ACPI Multiprocessor HAL, but it if you deploy an ACPI Uniprocessor image of XP to ACPI Multiprocessor hardware, the HAL will change automatically.  This does not happen the other way around.)  For your reference, the HAL options for XP and Windows Server 2003 are documented in Microsoft Knowledge Base article 309283.

So the term "Single Image" process for converting XP Pro to Tablet PC Edition really should be called something like the "Convertible Image" process.  It does not mean you will necessarily have only one one XP image to deploy.

(And even though Windows Vista and Windows Server 2008 no longer have this HAL dependency, you still need to have one image per PC architecture.  For example, you would need one image for x86, one for x64, and one for IA-64 for each Windows Server 2008 SKU if you had machines of all three architectures.)

2008-08-05 Update - "HAL Swapping"
As you can see from a few of the comments below, there are people who are doing scripted changes of the HAL using either direct file replacements, using the Sysprep.inf answer file entries, or some combination of the two. Direct HAL file replacements are always unsupported by Microsoft.  Any HAL replacement using the Sysprep.inf answer file entries using combinations not found in the About UpdateUPHal or About UpdateHal sections of Microsoft Knowledge Base article 309283 are also unsupported.  While doing this may appear to "work", if issues occur later that impact your users ability to work that can be traced to unsupported HAL changes you may have a new expensive redeployment project on your hands.  I am not speaking of a hypothetical situation here.  This has happened to customers who have done this.  The benefit of having a "single" image through HAL swapping is not worth the risk of possibly redeploying large numbers of machines.

Windows XP "Single Image" Process

For just about as long as there has been Windows XP Tablet PC Edition, there has been a guide on the Microsoft web site for the process of taking a Sysprep image of Windows XP Professional and "transforming" it at deploy time into Tablet PC Edition.  This guide can currently be found here.  A few years ago, I scripted this process for one customer's home-grown deployment framework.  Last summer I ported this process over to BDD 2007 Lite Touch.  Finally, several months ago, I moved this process over to MDT 2008 for both Lite Touch and Zero Touch (SCCM) deployment.  In this post, I will review what needs to be done to prepare your Windows XP SP2 image to use this process and how to use the scripts (included in the Attachments link below) to implement this process with MDT LTI or MDT ZTI with SCCM.  (Note: This will likely work with BDD 2007 and/or SMS 2003 OSD, but I haven't tested this.  Let me know what happens if you try it by adding a comment to this post.)

To create an image with MDT that will support this process, you need to include the CMPNENTS folder from CD 2 of the Tablet PC Edition 2005 media in your Windows XP SP2 installation media.  (Please see the Windows XP Service Pack 3 Considerations section below for information on how SP3 affects this process.)  I will describe here how to do this with MDT Lite Touch.  After adding the Window XP SP2 installation media as an Operating System in the Deployment Workbench, use Windows Explorer to open the Distribution folder.  Copy the CMPNENTS folder from CD 2 of the Tablet PC Edition 2005 media into the Windows XP installation media folder at the same level as the i386 folder as shown in the figure below.  (For those needing to create XP SP3 images see the Windows XP Service Pack 3 Considerations section below.)


Once you have XP SP2 added as an Operating System and have added the CMPNENTS folder to it, you can then use MDT Lite Touch to build and capture your Sysprep image.  If you want to use an MDT Task Sequence in SCCM to build and capture your reference image, add the matching CMPNENTS folder to the Window XP SP2 installation media before importing it into SCCM as an Operating System Install Package.  This will ensure that the MDT scripts will place the CMPNENTS folder in the C:\Windows\Source folder in the image.  This is where the scripts expect to find it at deploy time.  (If you need to use an existing Windows XP image with this process, you will need to make some changes to ensure that it will work with this process.  See the section below for details.)

After your image has been updated in this manner, you must then update MDT.  There are two parts to this process.  The first part is determining whether the target computer is a Tablet PC and the second is executing the scripted changes to convert the OS to Tablet PC Edition if the target computer is a Tablet PC.  There are a numbers of ways to determine whether the target computer is a Tablet PC.  You could add a custom property to Make/Model detection called IsTablet (must have a value of True or False). If you are using CustomSettings.ini to store your Make/Model information, you would put a direct entry in the CustomSettings.ini Make/Models sections.  If you are using the MDT database, you could add an IsTablet field to the MakeModelIdentity table, populate the IsTalbet field of the Make/Model rows with True or False, and add a database query to CustomSettings.ini to retrieve the IsTalbet field.

However, I took another approach that I find simpler to maintain.  It involves detecting whether the target computer has Tablet digitizer hardware.  I add a custom property to CustomSettings.ini called TabletPnpIds.  In this property I placed a comma separated list of the Plug & Play Device ID's of the digitizer devices on all supported Tablet PC model.  Then a user exit script uses this list to determine if the target computer is a Tablet PC and sets the IsTablet property accordingly.

To update MDT to use my entire process, use the following steps (respecting any change management process or change windows you have, of course).  If you want to use your own method of setting IsTablet, then you can skip the Edit CustomSettings.ini for detecting Tablet PC hardware steps and implement you own method.

  • Add the Custom Scripts to the MDT Scripts:  First, extract the scripts from the attached ZIP file and add them to either your LTI Scripts folder or your SCCM MDT File package.  Be sure to update your MDT Files package and Distribution points in SCCM after doing this.

  • Edit CustomSettings.ini for Detecting Tablet PC Hardware:  You will need to add the following to CustomSetting.ini to use my method of determining whether the target computer is a Tablet PC (additions in blue).

    Priority=IsTabletCheck, Default
    Properties=MyCustomProperty, TabletPnpIds, IsTablet


Important Notes - Those of you that have used the scripts for this process from my original post, please notice that several things have changed:

    • The Plug & Play IDs used in the TabletPnpIds entry no longer need the trailing backslash.  However, if you forget to remove them it will still work.  I have put code in the new script to check for this and remove them from the variable in memory if found.

    • The name of the UserExit script has changed.  The old script was called ZTI-DetectTabletExit.vbs.  The new script, ZTI-DetectHardwareExit.vbs, was designed to allow general purpose hardware detection.  See the section later in the post for details.

    • The name of the procedure called from the UserExit script has changed.  The old one was called DetectTablet and it took no arguments.  The new one, DetectDevices, takes the Plug & Play ID list as its input argument.

You will need to populate TabletPnpIds property with the digitizer Device ID's for your Tablet PC models.  To determine the Plug & Play Device ID's of the digitizer devices, you will need one of each supported Tablet PC model with Windows XP SP2 or higher or Windows Vista already installed and the digitizer driver installed.  On each PC, open Device Manager and find the entry for the digitizer device.  This will likely be under the Human Interface Devices category and will likely have the word "Pen" or "Digitizer" in its name.  Right click on the device and select Properties.  On the Details tab, select Device Instance Id (or Device Instance Path on Vista) from the drop down list. 

DeviceMgr     DeviceID 

In the case of the "Wacom Penabled MiniDriver" shown above, the Device Instance Id is ACPI\WACF004\4&2F7DB942&0.  The portion of this ID up to the last backslash, ACPI\WACF004, is the Device ID.  The portion after the last backslash, 4&2F7DB942&0, is the Instance ID for this device.  The Device ID is one of several hardware ID's embedded in the device by the manufacturer to be used for Plug & Play detection.  The Instance ID is a unique identifier assigned to a particular device by Windows when it is detected.  The Instance ID allows Windows to uniquely identify a device when there is more than one of the same device present in the system (for example, two of the same model network card).  The part we are interested in is the Device ID.  Put the Device IDs, excluding a trailing backslash, in the TabletPnpIds entry separated by commas.

You can also use ID's found under the Hardware Ids or Compatible Ids it you want to "generalize" the detection to a set of devices that share a common Hardware Id or Compatible Id.  (The Device ID determined above should be the first Hardware ID listed)  Items from these properties should be used as they appear in the dialog box (i.e. there is no Instance ID to remove).


The last two entries in the IsTabletCheck section tell the MDT Gather task to run ZTI-DetectHardwareExit.vbs and set the IsTablet custom property to the result of the DetectDevices function in the script.

  • Edit CustomSettings.ini for Setting the Tablet PC Edition Volume License Key:  The next changes to CustomSetting.ini set a custom property called XPTabletProductKey to your Tablet PC Edition Volume License Key.  If you do not have one and you are a Select License, Enterprise Agreement, and Enterprise Subscription Agreement customer, then see the Notes section in the Single Image Deployment Guide to obtain one.

    Add the following changes to CustomSetting.ini so that XPTabletProductKey will have a value when IsTablet is true.  Replace AAAAA-BBBBB-CCCCC-DDDDD-EEEEE with your Tablet PC Edition Volume License Key.  (Additions for this part in green):

    Priority=IsTabletCheck, ByTabletType, Default
    Properties=MyCustomProperty, TabletPnpIds, IsTablet, XPTabletProductKey




    If you are using SCCM, remember to update your Settings Package with the updated CustomSetting.ini.

  • Edit the Task Sequence to Add a Step to Run ZTI-XPTabletSingleImage.wsf:  The next step is to edit the Lite Touch or SCCM MDT Task Sequence to run ZTI-XPTabletSingleImage.wsf during the middle of the PostInstall phase.  The picture below shows this for an SCCM MDT Task Sequence. 


    For an SCCM MDT Task Sequence, be sure to check the Package box and select your MDT Files package.

  • Import Digitizer Drivers:  This should go without saying but you must import digitizer drivers into the Deployment Workbench for LTI or into the Drivers library and add them to Driver Package(s) for SCCM.  The Single Image Deployment Guide shows how to extract the "in the box" digitizer drivers.  But if you don't have any devices that need them, use the PC manufacturer's drivers instead.  You do not need to place any drivers in the C:\Sysprep\i386\Digitizer folder as shown in the Guide.  Use the Deployment Workbench Out-of-Box Drivers or SCCM Driver Packages to handle drivers instead.

That completes the setup.  When you deploy this XP Task Sequence to a Tablet PC, your Windows XP Professional Image should magically transform into Windows XP Tablet PC Edition 2005.  If you want to test this process and don't have any Tablet PC's handy or you want to test using Virtual Machines (Virtual PC, Virtual Server, Hyper-V, VMWare, etc.) then use the following trick.  Pick a device on your target computer (it's not really important which one it is) and place it's Device ID, or one of it's Hardware Ids or Compatible Ids in the TabletPnpIds list.  This will cause the IsTablet property to evaluate to True for this machine and it will result in Tablet PC Edition being installed on this non-Tablet computer.

Windows XP Service Pack 3 Considerations

-----Important Information!-----

In my post on May 22, I mentioned how I slipstreamed Service Pack 3 into an XP SP2 installation source that had the CMPNENTS folder from CD2 in the same location.  Well, I have some good news and some bad news about this (unfortunately mostly bad).  I can't go into any details about why what I'm about to write is the way it is or why I only just found out about this until an official knowledge Base article is released.

First the bad news.  The teams involved in creating Service Pack 3 have decided that neither slipstreamed nor integrated media (i.e. what you would download from the volume licensing site) will be supported for Tablet PC Edition or Media Center components for Service Pack 3 (even though you can make the slipstream media successfully as I have shown).  This is not currently documented publicly or anywhere that the Microsoft Services people would have found it.  I would not have blogged about the slipstreaming process if I had know it was not going to be supported.

That means to create a supported installation of Windows XP Tablet PC Edition 2005 Service Pack 3, you have to do the following:

  1. Install Tablet PC Edition from Service Pack 2 media
  2. Then install the Service Pack 3 Update

What does that mean for the Single Image process?  Since there is no supported way to obtain an SP3 version of the CMPNENTS folder, you cannot use an XP Pro SP3 image with the Single Image process.  Therefore, to deploy XP SP3 and Table PC Edition you will have to do one of the following:

  • Deploy an XP Pro SP2 image (converting to Tablet PC Edition as needed) and update to SP3 as part of the task sequence
  • Deploy separate Pro and Tablet PC Edition SP3 images

Unfortunately, this greatly reduces the value of the Single Image process if you want to deploy XP SP3.  In fact, my customer and I have decided that for their deployment we will deploy separate Pro and Tablet PC Edition SP3 images (at least until we decide whether a Design Changed Request has any chance of success).  And it will actually have to be four images since they have hardware of both ACPI HAL types.

So you might ask "Could there possibly be good news about this?"  Well, the good new is that in an upcoming post I will show you how to create a single WIM file that contains all four images with a single MDT Lite Touch Task Sequence (rerun four times).  And I will show you how you can deploy these images from that WIM file onto the correct target hardware using either a single MDT Lite Touch Task Sequence or a single MDT Zero Touch Task Sequence in SCCM.

Using Windows XP Images that were not Built with MDT

If you build your Windows XP Professional image with an MDT Lite Touch Task Sequence, it will ensure that the following things are done so that the scripts for this process will work correctly:

  • Copy the Windows XP installation files (i386 folder) to C:\Windows\Source folder.
  • Copy the Tablet PC CMPNENTS folder (must be of the same Service Pack version as the Windows XP installation files) to C:\Windows\Source folder.
  • Set the SourcePath & ServicePackSourcePath Registry string values in HKLM\Software\Microsoft\Windows\CurrentVersion\Setup to point to C:\Windows\Source.

I recommend that you add these step to your image build process and then build and capture a new version of you image.  However, if you have an existing Windows XP Professional SP2 WIM image, you can use ImageX to mount the WIM image, copy the required folders into the C:\Windows\Source folder, load the offline Software Registry hive, edit SourcePath & ServicePackSourcePath entries, unload the hive, and commit the changes.  This WIM image will then be useable with this process.  Since this is really a new "version" of your image, update any image version tattoo (Registry, file, etc.) in the image as well. (I don't usually recommend manually updating WIM files since it can lead to bad image version management habits)

Thanks to Rich Coulter of Pella Corporation for pointing out that I did not have enough detail in my original post on this topic and for finding the misspelling of the word Detect in the old ZTI-DetectTabletExit.vbs script name (ZTI-DectectTabletExit.vbs).  I used copy and paste when using the script name, so the same misspelling was everywhere and it worked.  Rich had the audacity to actually type the script name into his CustomSettings.ini, so it didn't work, of course.  J

Issues with the .NET Framework

Another Microsoft Consultant (Barry Hartmann of MCS Federal, thanks Barry!) encountered an issue with this process if you have the .NET Framework installed in your Windows XP Professional image. The XP Pro to Tablet PC Edition conversion uses a rather unintelligent, brute force installation process to install .NET Framework 1.0 (which is required by some Tablet PC Edition components).  If a newer version of the .NET Framework is installed in your image, this process will downgrade shared files and registry values.  This essentially breaks the newer version of the .NET Framework. 

Barry encountered this problem when he tried to install Project 2003 on a machine deployed with the "single image" process that had the .NET Framework 3.5 installed in the original XP Pro image.  The Project installation fails with the .NET Framework in this state.

The one obvious solution (the one my customer has chosen) is to not include the .NET Framework in the XP Pro image.  My customer will be installing .NET Framework 3.5 as an operating system specific post deployment item in the SCCM Task Sequence.  The other thing that seems to correct this if the .NET Framework is in the image, according to Barry's testing, is to initiate a repair on the highest version of the core Framework installed (1.1 or 2.0) after the deployment/conversion process.

These blog posts referenced below contain the command lines you should be able to use to repair the .NET Framework 2.0 RTM and 2.0 SP1:

Issues with Digitizer Drivers when Building the Reference Image in a Virtual Machine

While working with my current customer, we found that when we deployed XP to their Tablet PC models, we would see the OS convert to Tablet PC Edition just fine but the built-in keyboard, pointing devices, and digitizers would not work except for about one out of every 10 or 20 deployments.  At that point we had added the INF based drivers for all these devices (that were not "in the box" drivers) to the SCCM driver packages.  The devices would show up in Device Manager banged out as disabled with driver startup problems.  We tried a whole bunch of things to correct the issue: disabling the Single Image conversion, changing driver versions, switching to using driver "installers" in the State Restore phase, running the driver "installers" from cmdlines.txt, etc.  Nothing changed the outcome.  Oddly enough, if we deleted the devices from Device Manager and restarted, Plug & Play would reinstall them and they would work fine.

We were about to point the finger at the PC and/or digitizer vendor when fortune smiled on us.  Someone named Mark posted a comment to the original blog entry complaining of similar problem.  Luckily, Mark was apparently smarter than I am because he used the Dependency Walker from the Support Tools on wacompen.sys on one of his tablets. It showed that hidclass.sys was missing.  It turns out that when you build your image in a virtual machine (I was using Hyper-V and Mark was using VMWare ESX) without USB devices, the Human Interface Device (HID) drivers do not get installed (as they would when building on any modern physical machine).  Since the Wacom digitizer drivers have a dependency on the HID drivers, the Wacom drivers fail to load during Minisetup and the devices are marked disabled.

The work around to this problem involves copying the HID driver files referenced in the Reinstall any missing files section of KB 315973 to C:\Windows\System32\Drivers during the image build.  I have included a script, LTI-CopyXpHidDrivers.wsf, in the attachment below that can be used with the MDT Lite Touch Installation image build process.  Run this script in the State Restore phase before Sysprep and image capture.

Many thanks got out to Mark for figuring this out.  It would have taken us much longer to get around this blocker without your help.

Issues with the Win32_PnpEntity WMI Class

When I was testing the scripts original post with my customer we ran into an issue with the Lenovo X61 computers.  Sometimes the computer would correctly convert to Tablet PC Edition and sometimes it would not.  While I was investigating, I found that if we started a refresh from a running operating system, IsTablet would evaluate to True and the conversion would work fine.  However, when I kicked off a bare metal installation by PXE booting into WinPE, IsTablet would evaluate to False and the conversion would not happen.

So I booted the machine with a generic WinPE 2.1 CD.  The Lenovo X61 that we were testing with had the Wacom multi-touch digitizer device (DeviceID - WACF008).  Since my script that looked for the digitizer PnP ID uses the Win32_PnpEntity WMI class, I decided to use the WMI Command Line (WMIC) to see if this device was reported by querying this class.  When I issued the following command it returned No Instance(s) Available.

wmic path Win32_PnpEntity where (DeviceID like "ACPI\\WACF008\\%")

Running the same command in a full OS like XP or Vista returned the device information

I had added Devcon.exe from the Windows Server 2003 Support Tools to the WinPE CD.  Devcon is a command line version of Device Manager and can be used to query and configure devices.  Devcon uses the device management API to do this.  Using the following Devcon command did return the digitizer.

X:\>devcon hwids ACPI\WAC*

Hardware ID's:

So it turned out that the root cause appears to be a bug in the Win32_PnpEntity class in WMI when running in WinPE.  I exchanged e-mails with Michael Niehaus of the MDT Team about this.  It turns out that they had encountered this same problem with other devices as well.  Because of this, they do not use this WMI class for device detection.  They wrote their own utility (Microsoft.BDD.PnpEnum.exe) that uses the same API’s as Devcon to enumerate the HardwareID’s and CompatibleID’s for the devices in the machine and outputs this as XML.  Look at ZTIDrivers.wsf to see an example of how to use it in an MDT script.  So I rewrote my script (ZTI-DetectHardwareExit.vbs) to use their utility.  It now work correctly 100% of the time.

Using ZTI-DetectHardwareExit.vbs for General Device(s) Detection in MDT

While I was rewriting the Tablet device detection script to use Microsoft.BDD.PnpEnum.exe I realized that the script could be used as a general purpose device detection script.  You can define any set of Hardware Ids or Compatible Ids in one variable (comma separated list) and set a variable that will be set to True if any of the devices in the list are present.  Just set a new custom variable to hold the PNP ID list (e.g. IntelGigabitNicPnpIds or NVidiaDisplayAdapterIds) and then set a variable for the returned result like this: 

HasIntelGigabitNic = #DetectDevices("%IntelGigabitNicPnpIds%")#

Use the CustomSettings.ini section above as a guide.


So to sum up, if you follow the process as outlined in the first section and account for the .NET Framework issue and the HID driver issue when building images in a virtual machine you will be able to use this process successfully with Service Pack 2.  Unfortunately, the lack of support for using this process with Service Pack 3 has greatly diminished it's usefulness.

Hopefully this post will be my final word on this topic.  It would be nice to post about another topic.  :-)

Please post comments with any feedback, suggestions, or issues.

Disclaimer: The information on this site is provided "AS IS" with no warranties, confers no rights, and is not supported by the authors or Microsoft Corporation. Use of included script samples are subject to the terms specified in the Terms of Use .

This post was contributed by Michael Murgolo, a Senior Consultant with Microsoft Services - U.S. East Region.

MDT XP Pro-Tablet Single Image_full