How to setup debugging and deploying from VS.NET to a Windows CE device over ActiveSync

To get the ActiveSync connection you must:

  1. Open the ActiveSync program on your development machine
  2. Start your Windows CE device
  3. Choose File/Get Connected on the ActiveSync program on your development machine while the device is starting.
  4. You must have the Windows CE Utilites installed which you can get from here:

To ensure that the device and your machine have an open connection to talk through you must:

  1. Copy the ConManClient.exe and all .dlls from C:\Program Files\Microsoft Visual Studio .NET 2003\CompactFrameworkSDK\ConnectionManager\Target\wce400\{YOUR DEVICE TYPE HERE} into the \Windows folder on your WinCE device.
  2. Copy SDAuthUtilDevice.exe from C:\Program Files\Microsoft Visual Studio .NET 2003\CompactFrameworkSDK\WinCE Utilities\Authentication Util\WinCE4\{YOUR DEVICE TYPE HERE} into the \Windows folder on your WinCE device.
  3. Copy CryptoAPIWrapper.dll from C:\Program Files\Microsoft Visual Studio .NET 2003\CompactFrameworkSDK\WinCE Utilities\Authentication Util into the \Windows folder on your WinCE device.
  4. On the device, run the ConManClient.exe program and connect
  5. On the device, run SDAuthUtilDevice.exe and start an IP address which is visible from your development machine.
  6. On the development machine, run SDAuthUtil.exe and set up the device with the same IP address that you entered into SDAuthUtilDevice.exe on the device.
  7. Repeat step 1.  For some reason the ConManClient.exe seems to stop and either vanish or morph into a non-CE program file!
  8. From VS.NET 2003 got Tools/Connect To Device; select WinCE Device and connect.

NOTES:

  1. When deploying from VS.NET to the device, you will always have to deploy twice because, the first time, it fails to deploy.
  2. These steps will often fail.  When they fail, reboot the device and start afresh from Step 1.  I call this: Plug-and-Pray debugging.

No Comments