How to Debug a Run-Time Image on a CEPC (Windows Embedded CE 6.0)

1/5/2010

When you run a Windows Embedded CE operating system (OS) on a Windows Embedded CE PC-based platform (CEPC), you can use the kernel debugger to debug the run-time image, if you include support for the debugger in the OS design. When you create an OS design, consider the ways in which you want to debug the run-time image. Before you build the run-time image, you must complete certain preparatory steps to achieve the level of support that you want for debugging.

Steps

Step Topic

1. Open an existing OS design that uses the CEPC board support package (BSP), or create a new OS design and select the CEPC: x86 BSP.

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

2. 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

3. To maximize debugging functionality, enable support for KITL in your OS design.

For more information about KITL, see Kernel Independent Transport Layer.

Supporting KITL in an OS Design

4. If you expect the size of either the debug or the release run-time image to exceed 32 MB, enable support for a large run-time image in the settings for the OS design.

Ee478427.note(en-US,WinEmbedded.60).gifNote:
Debug run-time images are typically larger than release run-time images. If you choose a debug configuration and the OS design contains many features, it is likely that the size of the run-time image will exceed 32 MB.

Enabling a Run-Time Image Size Larger Than 32 MB

5. Build the OS design into a run-time image.

Building a Run-Time Image

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

Build Error Debugging Process

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

Download Service Selection

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

Hardware Configuration

CEPC-based SDB Motherboard and Card Configuration

8. If the CEPC uses an ISA-based Ethernet card, specify values for NET_IRQ and NET_IOBASE in the Autoexec.bat file on the boot floppy disk for the CEPC.

Editing the Autoexec.bat File for an x86 SDB

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 requires a null-modem cable connected to a serial port, such as COM1.

Configuring HyperTerminal for BSPs

10. Turn on the CEPC 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 CEPC.

Choose the appropriate topic based on whether you have an Ethernet or a serial port connection between the development workstation and the CEPC.

Configuring an Ethernet Remote Connection

Configuring a Serial Remote Connection

12. Download the run-time image to the CEPC through the configured connection. Then, start the run-time image on the CEPC.

After the run-time image starts on the CEPC, the kernel debugger starts automatically, because you enabled kernel debugging in the settings for the configuration.

Downloading a Run-Time Image to a CEPC

13. View debug information from the CEPC in the IDE.

When the debugger is available, a Debug menu and a Debug window appear in the IDE. When the debugger is running, the text [run] appears in the caption for the IDE.

You can manually stop and start the debugger during the debugging process.

Stopping Kernel Debugging

Starting Kernel Debugging

14. Configure Platform Manager to connect to the CEPC.

Configuring the Connection to a Target Device Using Platform Manager

15. Connect a remote tool to the CEPC.

When the remote tool succeeds in connecting to a CEPC, the Connecting to device dialog box disappears, and information from the CEPC appears in the window for the remote tool. The type of information displayed differs for each remote tool.

Connecting to a Target Device with a Remote Tool

Remote Tools

See Also

Concepts

CEPC-based SDBs

Other Resources