A Pocket PC running on a robot.
Programming
the Pocket PC
by Walter O. Krawec
Atypical Pocket PC sports a 200 MHz
CPU along with 64 MB of RAM
and a 65,000 color LCD — all within a
case designed to fit in the palm of your
hand. Additionally, these devices
usually run a version of Windows CE
as their operating system, making it
easy for us to develop applications for
them, given the right tools.
A sample development environment.
What follows is a brief introduction to the free “eMbedded Visual
Tools SDK” (no that ‘M’ is not a typo),
along with some information on how
to perform certain tasks on your PPC,
like accessing the serial port. Please
keep in mind that this is not a tutorial
on the C++ language, so it is assumed
that you have at least some knowledge of C/C++, and also knowledge
of basic Windows programming
would probably be helpful.
What You’ll Need
Really, all you’ll need to begin
developing applications for the Pocket
PC is the free eMbedded Visual Tools
SDK. This includes not only a compiler and IDE, but also an emulator so
that even if you don’t own a “real”
58 June 2006
PPC, you can still test and debug your
programs all from your desktop. If
you’re looking to buy a PPC, then you
can usually find a new one for $200-
$500 through your usual retail stores.
You could also probably find a decent
used one for even cheaper if you look
around (eBay, etc.).
eMbedded Visual Tools
Before writing software for a
Pocket PC, we’ll need a compiler of
some sort that is capable of creating
executables that the processor inside
a PPC can understand. Microsoft has
released an entire SDK just for this
purpose known as “eMbedded Visual
Tools” (this is a completely free download — you can find the URL in the
Web Links sidebar). Once installed,
you will have access to a C++ and
Visual Basic compiler, along with a
powerful emulator. Of course, with
this also comes some documentation
and several example programs —
everything you need to begin developing applications for a PPC!
As mentioned earlier, the
eMbedded Visual Tools SDK includes
two different compilers: C++ and
Visual Basic. You can, of course, use
either one, however, since I have no
knowledge of VB programming, this
article will focus on the C++ side of
things. If you want to use the VB compiler, that’s great. However, I doubt
that this article will aid you much on
your quest. I suggest if VB is your
choice, you simply skip ahead a few
pages to the next great article in this
magazine (or skip back a few pages if