Export (0) Print
Expand All

Windows CE Console Debug Shell Tool

Windows CE .NET

The Windows CE Console Debug Shell tool (Cesh.exe) downloads raw binary format (.rbf) files to a target device.

Shell.exe is the device-side executable. Messages are sent to Shell.exe on the device by adding commands to the Fsauxin file in %_FLATRELEASEDIR%. Shell.exe periodically polls this file and executes the commands it finds. The PPFS Service allows any file in %_FLATRELEASEDIR% to be accessed from the device.

The following table shows the Cesh.exe features installed on the development workstation during Platform Builder installation.

Feature Description
Cesh.exe Downloads binary files from the development workstation to the target device by using a parallel or serial port connection.

The file is in %_WINCEROOT%\Public\Common\Oak\Bin\i386.

Cesh.exe registry settings Specifies profiles for Cesh.exe and the parallel download service.

The Cesh.exe registry settings are in HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\ppsh.

Edbg.dll Provides an interface to the Windows Sockets API (Winsock) for all Ethernet services on the development workstation in order to control the target device through an Ethernet connection. This version must match the version for Cesh.exe.

The file is located in <Platform Builder installation path>\Cepb\Bin.

Ppshell.sys Supports Cesh.exe and the parallel port connection.

The file is installed into %Systemroot\System32\Drivers by the Ppshell.vbs installation script.

Use of the following Cesh.exe functions depends on the connection being used by the development workstation and target device.

Cesh [-s] [-p Profile] [-log] [-a "NK Args"]
[-com{1 | 2 | 3 | 4}] 
[{-wf .BinInputFile | -wp .RbfInputFile} |
{-we | -we128 | -we256 .RbfInputFile] 
{-re128 | -re256 .RbfInputFile 
 [-test] [InputFile] [-b] [-h] [-?]


Causes Cesh.exe to use fewer microprocessor resources. This option is slower, but it creates a more reliable connection if other applications or other instances of Cesh.exe are running on the development workstation.
-p Profile
Specifies a registry profile to use. The default profile is Default. For example, when downloading to a target device over the default parallel port, use CEPC_LPT1 for Profile.
Generates a log of file server calls in Nk.log.
-a "NK Args"
Passes a parameter string, Args, to the kernel at initialization time.
-com{1 | 2 | 3 | 4}
Specifies the serial port connection that is used by Cesh.exe.
Reads a byte from and writes a byte to the parallel port.
Specifies a particular type of file — for example, an absolute binary data format file (.abx) file — to download to the target device. If a file is not specified, the default file (Nk.bin) is used.
Boots without the bidirectional link.
-h or -?
Displays Cesh.exe command syntax.

Error Messages

ppsh: Eprom Programming: error setting EEPROM polarity
After the initial startup of Cesh.exe, the following message may appear on the development workstation:
dwReadDebounceCount 3
dwWriteDebounceCount 3
IO Delay 0
Flags 0
Assuming 256kbit EPROM size (from RBF file size of 149134).
Setting Serial EEPROM polarity.
ppsh: Eprom Programming: error setting EPROM polarity.

To resolve this error, end Cesh.exe; then, restart it.

No Cesh.exe debug shell prompt (Windows CE>) appears
If the Cesh.exe prompt (Windows CE>) does not appear after downloading and running the OS image, verify that the Shell.exe and ToolHelp.dll files are included in the OS image or are present in %_FLATRELEASEDIR%. These files must exist in order for Cesh.exe to start.


The following code example shows how to use Cesh.exe to write Test.bin to flash memory on a target device. In addition, all file server calls are copied to Nk.log.

Cesh -log -wf test.bin


Cesh.exe acts as virtual ROM when executing binary files on the target device. Because Windows CE includes demand-paging features, do not delete, rename, or alter binary files or applications that Cesh.exe is using. Specifically, avoid rebuilding projects or executable files while Cesh.exe runs.

See Also

Platform Debugging and Testing | Windows CE Build Environment Tool | PPFS Service

 Last updated on Friday, October 08, 2004

© 1992-2003 Microsoft Corporation. All rights reserved.

© 2015 Microsoft