Attach to the Application Debugger (Compact 2013)

3/26/2014

Before you can debug applications, both managed and native, you need to attach to the application debugger. The steps for attaching the applications to the debugger, provided in this topic, are slightly different for managed and native applications.

Attaching an Application to the Debugger

To attach a managed application to the application debugger

  1. Copy the device-side Core Connectivity binary files from the Application Builder installation folder, for example C:\Program Files (x86)\Common Files\Microsoft Shared\Embedded Tools\CoreCon\11.0\Target\wce800. If you are targeting ARM, copy the entire contents of the armv7 folder. If you are targeting x86, copy the entire contents of the x86 folder. You will see the following device side binary list:

    1. clientshutdown3.exe
    2. CMAccept3.exe
    3. ConmanClient3.exe
    4. DeviceAgentTransport3.dll
    5. eDbgTL3.dll
    6. TcpConnectionA3.dll
  2. Set the SYSGEN_NETUTILS variable in your OS design to include Ipconfig.exe. This setting will allow you to provide the IP address to the remote tools shell on the desktop.

  3. Create an application. For more information, see Create Your First Application.

  4. Deploy the application on the device.

  5. Set the following Registry entry on the device:

    HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\.NETCompactFramework\Managed Debugger AttachEnabled=1 

  6. On the Debug menu, select Attach, and then open the Attach to Process window.

  7. Under the Transport field, select Windows Embedded Compact Managed Debugger.

  8. Enter the IP address of the device in the Qualifier text box, and then click Enter.

  9. A list of running processes is displayed.

  10. Select the process that you want to debug, and then click Attach.

To attach a native application to the application debugger

  1. Copy the device-side Core Connectivity binary files from the Application Builder installation folder, for example C:\Program Files (x86)\Common Files\Microsoft Shared\Embedded Tools\CoreCon\11.0\Target\wce800. If you are targeting ARM, copy the entire contents of the armv7 folder. If you are targeting x86, copy the entire contents of the x86 folder. You will see the following device side binary list:

    1. clientshutdown3.exe
    2. CMAccept3.exe
    3. ConmanClient3.exe
    4. DeviceAgentTransport3.dll
    5. eDbgTL3.dll
    6. TcpConnectionA3.dll
  2. Set the SYSGEN_NETUTILS variable in your OS design to include Ipconfig.exe. This setting will allow you to provide the IP address to the Remote Tools shell on the desktop.

  3. Create an application. For more information, see Create Your First Application.

  4. Copy the device-side CoreCon binary files from the Application Builder installation folder, for example C:\Program Files (x86)\Common Files\Microsoft Shared\Embedded Tools\ 11.0\Debugger\Target\wce800. If you are targeting ARM, copy the entire contents of the armv7 folder. If you are targeting x86, copy the entire contents of the x86 folder. You will see the following device side binary list:

    1. 1033\vsdebugeng.impl.resources.dll
    2. DeviceAgentTransport3.dll
    3. eDbgTL3.dll
    4. edm3.exe
    5. MSDIA110.dll
    6. MSVCP110.dll
    7. MSVCR110.dll
    8. msvsmon.exe
    9. msvsmon.exe.config
    10. VSDebugEng.dll
    11. vsdebugeng.impl.dll
  5. Deploy the application on the device.

  6. Run msvsmon on the device with the following parameters:

    #noauth#anyuser#nosecuritywarn

    Note

    The msvsmon command needs to be run once only. You do not have to run it for subsequent sessions of debugging.

  7. On the Debug menu, select Attach, and then open the Attach to Process window.

  8. Under the Transport field, select Remote (no authentication).

  9. Enter the IP address of the device in the Qualifier text box, and then click Enter.

    Note

    If port(:4016) is in the contents of the field, remove it.

  10. A list of running processes is displayed.

  11. Select the process that you want to debug, and then click Attach.