Windows CE/Mobile/Embedded

Managed Code

.NET Compact Framework - Pocket Guide
xShort and concise, written as a quick start guide to using VS .NET to build applications in the compact framework for the CE.NET, Pocket PC and SmartPhone platforms. With the hints the book is definitely worth a read if you plan to do any CF development. Gives you a quick intro to Visual Studio and various aspects of the tool used to create applications. Covers the Forms Designer controls and those which are not applicable in the SmartPhone platform, plus design considerations to keep in mind when building apps for devices with limited real estate. Book completes with three example applications; a currency converter, a book ordering system and a bluetooth chat program.
(O'Reilly, 105 pages, 2002)
.NET Compact Framework Programming with C#
THUD, yeah that's the sound this book makes when you drop it on the floor. Worth its weight though and written in an easily readable format. I found this book to be helpful in learning more about the .NET environment as well even though its focus in on the Compact Framework. While the book does not come with a CD ROM, all of the examples are available as a free download from the authors web site. The two writers take you on a great tour of what you can and can not do with .NET CF. I found the examples to be excellent launching points if not complete solutions for developing CE.NET applications. For example the last chapter on printing from CE devices takes you on a tour of four possible ways to print from CE devices; using the GDI, direct output, an HP solution and a 3rd party tool by FieldSoftware. The book also confirms that a good understanding of the Win32 API is essential to developing .NET CF applications via platform invoke. The book covers: .NET CF background and architecture, the .NET type system. platform invoke, forms, mouse and keyboard input, controls, binding data to controls, obtaining dynamic information about controls, building custom controls, types of storage, ADO.NET (SQL Server CE, SQL Server 2000, Web Services), synchronization(Active Synch, RDA, Merge Replication), the remote API, type of graphics programming (raster, vector), text and fonts, and printing.
(Addison Wesley, 1379 pages, 2004) [Highly Recommended]
Programming the .NET Compact Framework 3.5
Note: the second edition is out and well worth the print. Slightly smaller but great coverage. With the 3.5 Compact Framework much ground has been covered from 1.0, platforming invoking was limited, no reflection .... While the CF is still only 1/4 of the full framework much more is here. The books examples are excellent and available as a free download. Topics covered: battery life, platform invoke, data binding [excellent], File I/O. Registry, ADO.NET, Web Services, LINQ, Data Sychronization (RDA, Merge Replication and Data Synchronization Services), Active Synch, RAPI and the object store, COM objects, DLL loading, WCF, graphics and text programming.
(Addison Wesley, 694 pages, 2009) [Highly Recommended]
.NET Compact Framework Kick Start
Published in 2004, leary of the book but it turned out to be a good source of information which some books never covered. This due in fact that both of the authors were on the .NET CF development team. Sections are now outdated in particular the chapter on cryptrography as it is now supported via the compact framework. The chapter on cryptrography explains good security design and shows you how to platform invoke to native calls to perform encryption/decryption. The books chapter on reflection is well worth purchasing the book. The book covers all of the basics of .NET CF development and is handy as a reference. Additionally the book has other valuable insights into the following: jitting and code pitching, how disabling the main menu will cause exceptions with the SIP [so that's why that happens], how track bars work, mutexes, thread pools, HTTP request examples, irDA, data relations, foreign key constraints, using commandtype.tabledirect for fast forward reads from a DB, parameterized commands for faster DB access, web services do not support typed datasets, CF XML does not support DTDs/XML:Schema/XMLValidation rules and XPath, rendering an XML file to a remote location, use XMLTextWriter.WriteFullCmdElement to emit both begin and ending XML tags, emitting XML comments, emitting XML CDATA, XML processing commands < ? >.
(SAMS, 578 pages, 2004) [Recommended]
Mobile Development Handbook
Released in 2007 the book covers some of the latest features in Mobile 5.0 Topics covered include: evolution of the compact framework, winforms GUI, SQL Server CE 2005, error handling and debugging, a complete chapter on performance optimzations, packaging and deployment, exchanging data withbackend servers, RDA, merge replication and subscriptions, Networks: irDA, Bluetooth, TCP, serial ports, security and the encryption APIs, threads, graphics programming [alpha blending], Direct3D, Building Custom Controls, Platform Invoking and Internationalization. The DirectX/Direct3D example is stunning. Source code examples are downloadable from the MSPress web site. Great coverage of features to use in a managed environment.
(Microsoft Press, 651 pages, Sample Code Downloadable, 2007) [recommended]
Smartphone Programming
Another 2007 publication this book covers all aspects of Smartphone programming. [Happily this platform is going away by being merged with the Mobile platform. Having a device with no touch capabilities is not good ] Topics covered include: Intro to Smartphone, .NET CF basics, development of SM apps and GUI aspects, SQL Server Mobile, Networks (tcp, udp), Email, SMS, PIM, XML and web services, platform invoking, exception handling and debugging, device and app security, data and communications security, (digital signatures, application signing) globalization/localization, graphics, and performance (counters). If you are doing smartphone development then this is a worthwhile read.
(Wiley/Wrox Press, 494 pages, 2007)
Microsoft SQL Server 2005 Compact Edition
Another 2007 publication, this is the latest on developing with SQL CE 2005. The database which most OEMs supply on ROM with devices along with the Compact Framework. One of the best enhancements SQL CE 2005 does now is run on the desktop and Tablet PC. [Similar to JET and SQL Express]. Integration with Visual Studio is there as well as with SQL Manager. The query analyzer on the CE device itself is a great workhorse and you can create DB's and tables, run queries, gather performance statistics ... Windows CE/Mobile was designed with a native database. In fact you can create and build your own database using these calls in a non .NET model. These Native DB calls are all in C. Developing with these APIs is not the path you would want to take most of the time. [For high performance components and products only, probably how Sybase and Oracle went with for their CE databases] With this kind of functionality you can see why the execution speed is so good. For example a query select on 30,000 records runs in 11 seconds. With CE SQL you have a runtime footprint of 4 MB with a maximum database size of 5 gigabytes. The book supercedes earlier books on this topic and covers the material quite well. Several chapters would be considered reference only, but are worth their print as that. Merge Replication and Remote Data Access each have a chapter dedicated to their implementation. Performance and database tuning is a welcome chapter as well as another plus of this book as it details development for speed and optimization specifically for Windows CE/Mobile. While ADO and databases are not my top priority, this is a nice way to revisit them. Its been a while since I developed an elaborate database with SQL and so much of it is still the same.
(SAMS, 601 pages, 2007) [Highly Recommended]
Building Solutions with the Microsoft .NET Compact Framework
Written for both the developer and manager in a condensed format. This book covers features and limitations of the .NET CF Framework. The .NET CF runtime is similar to a Java Virtual Machine which provides the ability to run "managed code", which is simply applications written in C# or the redesigned VB. CF.NET is roughly a 25% subset of the .NET functionality. So understanding the limitations is good thing. Interesting similarities to Java, for example to call external C DLLs .NET CF uses something called PInvoke, whereas Java uses JNI. This is a must read for those developing in the CF.NET Framework. Book covers platform evolution and architecture of .NET CF. Book then moves on to discuss all aspects of local data access; File I/O, XML, ADO.NET and GUI issues. Remote Data is next covering; Communications, Web Services, SqlClient, and Socket Programming. Further chapters cover Accessing and Administering SQLCE, ActiveSynch, SQLCE synchronization, RDA, Merge Replication, NLS, Security, Packaging, Deployment, Installation, Extensions and Performance Monitoring.
(Addison-Wesley, 367 pages, 2004) [Recommended]
Building ASP.NET Applications for Mobile Devices
Satan was here, complete with 666 pages of detail on creating applications with the ASP.NET Mobile Controls. This covers essentially all of the functionality of the renamed Mobile Internet Toolkit. This is a nice technology only if you are connected to a MAN or WLAN network 100% of the time. A good feature of this technology is that it supports a wide variety of devices such as HTML, cHTML, WML, XHTML browser enabled devices, so this includes a lot of phone and mobile based devices beyond those running Windows CE. When you build an application you create an abstaction of what the GUI will look like. At run time ASP.NET generates the layout for the devices browser dynamically. This does have its niche for application development. All of the examples are in C#. Topics covered; introduction, programming with the MIT, the standard controls, validation controls, list controls, downloadable controls, using CSS, customizing with property overrides/templates, advanced list control programming, database access, state management, performance enhancements, multilingual/multicultural development, XML Web services, testing debugging and tracing, packaging and configuration, application security, supporting new device clients, building reusable interfaces, custom controls, device adapters and building controls from scratch.
(Microsoft Press, 666 pages, 2003)
.NET Compact Framework
Skipping all of the appendices, only about 650 pages of detail on the .NET Compact Framework. All of the examples are in C#. The estimates are that the CF is 25% of the full desktop framework. As mobile hardware gets more advanced the gap should diminish to nothing. Although why they left out these features leaves me wondering; like input validation, serialization, reflection and remoting. Topics covered, Intro, class concepts, garbage collection, GUI development with different controls, testing debugging and tracing, distributing your application, collection classes, dates and strings, XML what you can and can not do, I/O, networking, security, ADO.NET, SQL Server, XML Web Services, SQL Server CE, creating custom controls, globalization and localization, multithreading, graphics programming, native code what you can and can not do including some useful explanations on interfacing with COM objects, and finally migrating existing applications VC++ or VB to .NET CF.
(Microsoft Press, 860 pages, 2003) [Dated]

Native Code

The Windows CE Technology Tutorial
Intro compares CE with Embedded NT. Also some discussion of the different CE platforms. Book then proceeds to cover the following technologies: ADO, COM, an Active-X control, DCOM, the command bar, the CE GUI model, the object store, more in depth coverage of ADO, pocket access files, RAS, ActiveSynch, TCP, IrDA, graphics sounds, a control panel applet, and help files. The author is the Windows CE liason for Siemens. Throughout the book he writes a Music CD application utilizing the above technologies. Design framework consists of building COM components and testing them via VB for CE. Worth mentioning as well a comparision of DCOM and Intrinsyc's DeviceCOM. There is also in depth coverage of creating installations for CE applications using MSI (Microsoft Installer) as well as making a CE app Logo compliant. (Addison-Wesley, 592 pages, CD-ROM) [Read this or Windows CE 3.0 Application Programming]
Programming Windows CE.NET / Programming Windows Embedded CE 6.0
One of the better books out on developing programs with Windows CE. This book in its second edition takes the reader on a survey on all of the functionality which CE provides to the user including; keyboard IO, touch, menus, windows, dialog boxes, memory management, file access, processes, threads, exceptions, serial communications, networking, IrSock, ActiveSynch, notifications, GAPI, extensions, and device drivers. Examples complete with source code are an excellent way to pick up the features of this OS. Engaging writing style as well. Note: the 3rd edition is now out, it covers a few more topics like creating a service within CE.NET, using OBEX to share data, the Compact Framework, using the native database APIs (note: not SQLCE, RDA or Merge Replication), SmartPhone, Bluetooth and COM. Note: 4th Edition now out which reduced the size of the book, so the 3rd edition is recommended over the 4th. Not much changed in 6.0 for the end user: some issues with memory models, processes threads and fibers are covered as well as the storage manager in the file system. The SM allows one to work with storage devices and their partitions as well as repartition and format devices and partitions.  (Microsoft, 1224 pages, CD ROM) [Highly Recommended]
Windows CE 3.0 Application Programming
Covers the following topics: files, object store, directory, networks, data bases, registry, processes and threads, thread synchronization and notifications, TCP, UDP, ICMP, IrDA, HTTP, serial communications, RAPI (remote API), TAPI (telephone API), RAS (Remote Access Services), memory management, system Information and power management, COM and Active-X, MS Message Queue (MSMQ), ADOCE and SQL Server, and ActiveSynch. This book covers some of the newer functionality which CE 3.0 provides. The ADOCE coverage features smart-pointers, dynamic SQL and COM APIs. The ActiveSynch chapter explains how to develop a desktop to client device synchronizing application. The examples here are in depth. (Prentice-Hall, 508 pages, CD ROM) [Read this or The Windows CE Technology Tutorial]
Pocket PC Network Programming
For native applications which utilize networks this is a great reference. All sample source is in C/C++. Topics: winsock, wininet (http, https, ftp), IP Helper APIs (adapter, router, stats, ARP, ICMP), network redirector, serial & irDA, Remote Network Access Dialer, the connection manager, phone API, SIM Manager, SMS, RAPI, file filters, synchronization providers, desktop, POOM (pocket outlook plugins), MAPI - a whole chapter on email APIs, (sessions, objects, notifications) and finally a chapter on the .NET CF. As the CF gets bigger it will render the native C/C++ implementations of this book obsolete but for now it is quite useful for specific network interfaces. (Addison-Wesley, 632 pages)
Windows CE Application Programming
Covers all of the basics of application development including: the standard controls, dialog boxes, command band, command bar, menus, custom controls, persistant storage, the object store, registry, and the native CE database. Two chapters cover building synchronization managers and clients as well as other methods like file filters and RAPI. Book covers some destinct topics such as how the program the HTML, voice and rich ink controls. Another unique topic on Palm size PC input techniques, now defunct but can be applied to current mobile platforms. Additional coverage on power and memory management. (Wiley, 460 pages, CD ROM)
Windows CE Application Programming for the Handheld PC
Published in 1997 a year after the release of HHPC, this book covers all of the basics of application development. The books unique offerings are 1) the HHPC specific information and 2) good coverage of the help system which is HTML based. The author also builds a travel log application to illustrate various features. The entire source code for the application is included on the CD ROM. Topics covered: HHPC OEMs and devices, IDE via C++, general architecture of HHP CE, hello world program, basic user interfaces, controls, input and output, the registry, file system, help system and files, application loader, file filters, and RAPI. (Macmillan, 466 pages, CD ROM)
Making Win32 Applications Mobile
Published in 2002 this books focuses on making Win32 native apps run on WinCE HPC, Palm and PPC platforms. The books covers some of the basic aspects of WinCE such as stylus input methods, dialogs, and controls. What is interesting are the insights on porting strategies. For example layout and redesign of applications for smaller "real estate" devices using property pages and tabbing. The book also covers some lesser known aspects of WinCE such as the SHxxxx() functions which are unique to programming the WinCE shell. Shell items can include shortcuts, start menu, running in full screen mode [kiosk]. Other topics covered include the rich ink control, bitmap types, code and data organization for memory efficiency, the registry, file use, the CE native database, RAPI, the HTML control, and debugging tools. (Wiley/Gearhead Press, 540 pages, Source Code Downloadable)


Windows Mobile Data Synchronization
Written for the network/system administration who is deploying SQL Server and SQL Server Compact Edition. One of the interesting things about merge replication is for a base case very little coding is required to make this possible. Only 2 or 3 function calls and one page of code. The book covers how to configure distributions and publications to make merge relication happen. (Hood Canal Press, 200 pages)
Mobile Applications - Architecture, Design and Development
Good book for the general description and layout of mobile technologies and solutions. Great book for an introduction to the technologies, not of too much value for the experienced pro. The three case studies at the end of the book give you a good idea of how the technology is deployed on HP Ipaqs. Book covers the always, partially and never connected models, one to N-Tier models, web server models, device types, data transfer, device GUIs, fat and thin clients, security, deployment and project management, There is an interesting example of a web server which runs directly on a CE device. (HP/Prentice-Hall, 340 pages)

Pro Service Oriented Smart Clients with .NET 2.0
SOA with Smart Clients, some interesting reading. Smart Clients are not only Mobile applications but are adaptive applications which can operate in either a connected or disconnected (buffered) mode. The are roughly three categories for Smart Clients: Windows Forms SC, Windows Office SC, and Mobile SC. Under Office Smart Clients fall into two sub categories, those developed with VSTO Visual Studio Tools for Office and IBF, the Information Bridge Framework. VSTO SCs work with Word and Excel and allow one to embed .NET assemblies developed with Visual Studio into these documents. IBF focuses integrating Line of Business documents developed with Word, Excel, Outlook or InfoPath with Web Services which are developed with Visual Studio. The book covers other aspects of SC's such as No Touch or One Touch deployment.  In a nutshell Smart Clients usually are updated via HTTP over the web, but operate as a Fat Client providing the ability to operate and cache data and possibly even state during network outages. They may intelligently select which network to operate over i.e. cellular, satellite, WiFi, or wired. [yes, this is something you can do with the latest mobile devices] Smart Clients utilize DISCO or UDDI to register their services and converse with each other via SOAP (XML) Other areas covered here detail offline support, architecture, and testing.

Smart Clients are not a particular niche technology but better described as toolkits and evolving guidelines developed within the increasingly interoperable product lines.
(Apress, 321 Pages)

Platform Builder, Embedded, Driver Development

Windows CE From the Ground Up
One of the first in depth books out on WinCE development. All examples are in C++. While outdated it covers some of the OEM aspects of quite well. Anyone working in this platform still ends up diving into native code or using COM objects once in a while. [For example configuring 802.11 programatically, there is no standard managed interface]. Book topics: WinCE architecture, development platforms, building WinCE images, building WinCE apps, bootloader, OEM adaption layer, device drivers [stream, native], explanation of 12 common drivers, Sysgen for configuration, processes and threads, virtual memory, the Grasphics, Windowing and Events subsystem, object store, file system, communications, desktop connectivity, C++ classes, document view model, drawing, input, dialogs and property sheets, controls, the CE shell, porting to WinCE, VB, WinCE profiling, c++ Overview, Control Styles, Control Notifications. (Annabooks 1999, 838 pages) [Historical]
Building Powerful Platforms with Windows CE
This is written for the EE who is designing hardware or generating the CE system software for a device. You could read this book twice, once before and once after completing a CE project. Parts of this book are so detailed they will put you to sleep, but then this is the kind of info you need to accomplish the task. The book covers in detail, Platform Builder which is a superset of the Embedded C++ Compiler. Featured topics, CE Architecture, managing a CE PB project, designing and building a CE boot loader, OAL development, writing stream interface, native, USB and NDIS device drivers, implementing and debugging device drivers, the build process, a sample CE project, the DDK, testing tools Kato and Tux, and display drivers. There are some good insights into thread processing, and memory access between drivers and applications. (Addison-Wesley, Muench, 595 pages, CD-ROM) [For EEs]
Windows Embedded CE 6.0 Fundamentals
Too short but a good general introduction to developing systems and applications for embedded CE. [Read this and then read the above platform book by Muench], Topics: introduction, visual studio and the platform builder toolkit, development and performance monitoring tools, the OS architecture, [CE 6.0 supports up to 32,000 user processes and up to 2 GB per active process.] memory management, threads and fibers, sysgen builds, board support package, kernel independent transport layer, drivers: user mode and kernel mode, the OS bootup process, the whole process of building devices, application development, and testing system images. (Microsoft Press, Pavlov/Belevsky, 253 pages)
Professional Microsoft Windows Embedded CE 6.0
A good general introduction to developing systems and applications for embedded CE. [Read this and then read the above platform book by Muench] Covers the variety of development hardware better! Topics: introduction, development tools, board support package building a CE runtime image, connecting to targer devices [tcp, serial...] debugging and debugging tools, the boot loader, testing with the CETK, application development, VB applications, native code applications, autolaunch applications [kiosks], customizing the UI, thin client applications, home automation applications, robotic applications, deploying a CE 6.0 device. Appendix contains links to sample applications. Nice diverse coverage of what you can do with WinCE especially if you are developing along with a hardware platform. (Wrox, Phung, 448 pages)
Windows CE Developers Kit
One of the first books out and covers all aspects of the OS. This contains a CD as well as four separate books: Communications Guide, User Interface Services Guide, Device Driver Kit, and Programmer's Guide. The comm guide covers all of the regular features, Serial, Telephony, WinSock, WNet, Inet, security support provider interface, cryptography, and wireless services. [Worth it for the SSPI and the cryptography details]. The UI Guide covers all of the controls and gives good guidelines on how to use them. Other topics include resources, user input, sound, graphics, and windows messages. The Programmers Guide covers processes, threads, program memory, object store, database, registry, help system, RAPI, File Filters, Notifications, and CE Services. CEutils are covered which are used for synchonization, file filters, partnership settings and custom menu items. Other topics: installing applications using the CAB wizard, Unicode and NLS. Interesting coverage of bitmasks and how to handle the packing of 1,2,4,8,24 and 32 bit displays. The DDK guide has general coverage of writing drivers for native, stream, audio, display, USB, NDIS, and Block devices. The DDK Guide was worthwile as well. (Microsoft Press, 1440 pages)
Embedded Programming with the .NET Micro Framework
This is an interesting technology one could compare with JavaCard. 20 to 30 percent of the full OS [CE or Embedded XP] has been ported to support a small subset of the CLR which runs directly on top the hardware. This moves the runtime footprint from megabytes to kilobytes resulting in very small and cost effective hardware platforms. The target devices are small devices with a USB slot as an interface and perhaps a small display screen 1/2 inch by 2 inches. An examples is sideshow, the simple monographic display screen on some laptops which shows email and power status. The book tours through several projects which are downloadable. The SDK is a free download as well which integrates with the Visual Studio IDE. The sample apps can be developed and run via an emulator on your desktop. [Sound familar !] Since clock speeds are slow some recommendations on how to optimize and write efficient C# code which uses less clock cycles is illustrated which is good fodder for WinCE devices running managed applications via .NET as well. Many CE devices run at slow clock speeds to prolong life between battery swap outs, but at the expense of code execution. For example: Managed applications with databases and SQL CE are a notorious culprit on 500 to 600 MHz devices]. For the .NET Micro Framework You can order hardware kits from various OEMs, a popular example is the iRobot vacuum. (Microsoft Press, 268 pages, Source Code Downloadable) [For EEs and Code Slingers]
Programming the Windows Driver Model
Read perhaps eight of the sixteen chapters. Why is this under CE books, well it is a distant cousin, and if you are using platform builder then it is worthwhile task. The  author, Walter Oney has been writing drivers for windows throughout its evolution. This is his third book on driver development. If you are doing any real time programming with CE then the chapter on programming techniques is excellent. There is a well written section on Structured Exception Handling (SEH) which is worth the price of the book. There is a whole chapter on the inards of a USB device driver. After programming the Multimedia APIs and also the Audio Compression Manager in CE I decided that I needed to get a little more insight on how windows drivers operate. (Especially after opening, enumerating and querying all of the audio codecs dynamically under CE, arghhh!). Since CE development can be quite hardware specific this book will round out your knowledge. You may at some point in the future need to write a filter driver which lets you intercept data to and from a device. This book will show you how. Topics covered; introduction and history of drivers in 98/ME/NT/XP. the WDM Driver Model, Synchronization, the I/O Request Packet, Plug and Play Function Drivers, Reading and Writing Data, Power Management, I/O Control Operations, Windows Based Management Instrumentation , USB Drivers, Human Interface Devices, Distributing Device Drivers, and Filter Drivers. WBMI could be quite useful in CE devices, a notification framework for device drivers. There are also some good tips on getting your drivers verified and logo'ed via the Microsoft WHQL program. The included CD rom comes complete with sample drivers. (Microsoft Press, 846 pages, CD-ROM) [For EEs]