Partager via


How to Connect to a Target Device for Debugging (Windows Embedded CE 6.0)

1/5/2010

You can establish a connection from Platform Builder to a Windows Embedded CE–powered device to debug the target device.

If the run-time image includes the Kdstub.dll library for the kernel debugger, you can use the kernel debugger on the target device.

Steps

Step Topic

1. Use the Windows Embedded CE OS Design Wizard to select a design template and the initial components for the OS design.

Creating an OS Design with the Windows Embedded CE OS Design Wizard

2. Familiarize yourself with the level of support for debugging in each configuration that Windows Embedded provides.

Build Configurations

3. Choose a Debug or Release configuration to target when Platform Builder builds the OS design into a run-time image.

To use the kernel debugger, make sure that support for the kernel debugger is enabled.

Levels of Debugging Support

Building a Run-Time Image From a Debug Configuration

Building a Run-Time Image From a Release Configuration

4. Build an OS design into a run-time image.

Building a Run-Time Image

5. In the Output window, on the Output tab, verify that the build contains no errors.

Build Error Debugging Process

6. In Platform Builder, open the run-time image created in step 4.

Opening a Run-time Image for Debugging

7. Choose a download service appropriate for the connection hardware. The download service will download a run-time image to the target device.

Download Service Selection

8. Set up and configure the connection hardware required for the download service. That hardware connects the target device to the development workstation, on which Platform Builder is installed. Examples of connection hardware include cables, a hub, or Ethernet network adapters.

Hardware Configuration

9. If you selected Serial Download Service in step 7, configure the HyperTerminal terminal emulation application to display the serial debug output from the serial port on the target device.

This configuration requires a null-modem cable connected to a serial port, such as COM1.

Configuring HyperTerminal for BSPs

10. Turn on the target device so that it becomes active on the Ethernet network or over the serial connection, and Platform Builder can discover it.

Not applicable

11. Configure the connection to the target device.

Choose the appropriate topic based on whether the development workstation and the target device are connected by an Ethernet network or a serial port connection.

Configuring an Ethernet Remote Connection

Configuring a Serial Remote Connection

12. Download the run-time image to the target device through the configured connection.

Downloading a Run-Time Image

13. Verify that the kernel debugger connects to the target device.

When the kernel debugger connects, debug messages appear in the Output view of the Output window in Platform Builder.

After you establish a connection between Platform Builder and the target device, the kernel debugger collects data from the target device.

Debugger Execution Control

Viewing Debug Information in the Debug Windows

Breakpoints

See Also

Other Resources

Debugging and Testing How-to Topics
Diagnostics and Debugging for Mobile and Embedded Development