Handhelds.org - Open source for handheld devices

UserPreferences

RestoringPocketPc


Restoring Pocket PC

Assuming you need to go back to MS Pocket PC (aka Windows CE, Windows Mobile) on your iPAQ, these instructions describe how to do it. Please read and follow all instructions carefully. All liability is disclaimed for any consequences of using the instructions below. Note: this guide only covers older iPAQs - h3xxx and h5xxx.

Warning: if you receive any errors during the reflashing process, do not continue. Leave your iPAQ permanently powered and email ipaq@handhelds.org or france@handhelds.org with a description of the problem in detail, including any error messages.

Before You Begin

Power

Ensure you have a stable power supply for both the iPAQ (charged batteries, cradle or cable) and the PC you will be restoring from (UPS if you have one). You can take a chance here, but be aware that any interruption during restoring the boot loader may turn your iPAQ into a paperweight. Interruptions at any other time are usually recoverable, however.

bootldr Version

Ensure you have at least bootldr 2.18.01 or newer installed before proceeding. If you installed it yourself recently, this is most likely the case.

PocketPC Image

If you followed the instructions when you installed Linux, you will already have an image to restore. If you didn't make a backup or have lost the one you made, you can get one from http://handhelds.org/download/feeds/wince/. (Make sure you get the right image for your device if downloading from here.)

Alternatively, there is a way to extract a PocketPC Image in the original language from an HP software update. See [WWW]this site for details.

Preparing the Image (H39xx/H5xxx only)

If your iPAQ is an H39xx or H5xxx, and the PocketPC image was one you saved yourself using BootBlaster, then you will need to split it first. To do this you will need access to the gzip, gunzip and dd commands. Use cygwin or a bootable Linux live CD if you do not have Linux installed on your desktop. (Or you can use unix utility download from here: http://unxutils.sourceforge.net/UnxUtils.zip)

  1. Uncompress the backup image:

    gunzip wince_image.gz
    

  2. Cut out the portion of the image you need to restore:

    dd bs=1k count=32256 if=wince_image of=root_image
    
    The size of the root_image file should be 33,030,144 bytes.

  3. Re-compress the image with gzip:

    gzip -9 root_image
    

Method A: Restoring via Serial Cable

The standard restoration method is to use a serial cable. For this you will need a standard iPAQ serial cable or cradle, a serial port to plug it into on your PC (or alternatively, a USB-to-serial converter compatible with your PC's OS), and a terminal program such as HyperTerminal or minicom. The terminal program should be set to 115200 bps, 8N1 serial configuration, no flow control, no hardware handshaking.

Part I: Restore OS

  1. Hold down the centre of the joypad and press the reset button with the stylus

  2. Connect to the iPAQ using your terminal program.

  3. Press Enter a few times to ensure you have a boot> prompt

  4. Type load root and press Enter

  5. Upload the prepared image file using Ymodem

  6. When it is finished, type boot wince and press Enter. Make sure Pocket PC boots and runs correctly.

Part II: Restore boot loader

This part is optional - the handhelds.org boot loader will boot PocketPC just fine, but if you wish to restore the original boot loader, follow the instructions below. Important: DO NOT restore the boot loader until you have verified PocketPC works correctly!

If you want to upgrade/restore the original PocketPC firmware using the HP original updater, you must restore the original boot loader, otherwise the HP updater will not work.

  1. Reset the iPAQ again and reconnect using your terminal program

  2. Press Enter a few times to ensure you have a boot> prompt

  3. Type load bootldr and press Enter

  4. Upload the saved_bootldr.gz file using Ymodem.

Method B: Restoring via CompactFlash Card

Alternatively if you have a CompactFlash or PC card sleeve and a spare CF card, this is the fastest method of restoring PocketPC onto your iPAQ. You must have a CompactFlash sleeve, an original (non-removable battery) single-slot PC card sleeve or a dual-slot PC card sleeve (with appropriate CF-PC card adapter for the latter two). Note: you cannot use the newer HP PC Card Plus sleeve - it will not work for this purpose. Also, you cannot use this exact procedure on h5400/h5500 series iPAQs, but using a CF sleeve to reflash is possible using a serial cable to instruct bootldr.

  1. Make sure the battery in the sleeve is fully charged. You may need to do this by connecting the AC adapter to the sleeve directly if it allows it.

  2. Copy your prepared image file to an empty CF card formatted with vfat / FAT16 (as it comes from the factory). The instructions that follow assume it will be called root_image.gz - substitute the name you are using if you have called it something different.

  3. cd into the directory where the card is mounted, and then generate an md5sum of the image by running the following command:

    md5sum root_image.gz > md5sums
    

  4. Create a text file called reflash.ctl on the card with the following contents:

    WinCE root_image.gz md5sums root
    

  5. Unmount the card, remove it and insert it into your iPAQ's sleeve, with the iPAQ in the sleeve. If you are using the dual-slot PC Card sleeve, you will need to use the rear slot.

  6. Hold down the centre of the joypad and press the reset button with your stylus.

  7. When the boot loader screen appears, press the record button.

  8. Assuming the boot loader finds the image on the card, press down the joypad to select it.

  9. Once the image is verified correct, press the record button to confirm flashing.

  10. Once the flashing process is complete, press the joypad to restart.

  11. Check that the boot loader boots into PocketPC correctly.

  12. Lastly, if you wish to restore the original boot loader, use the serial method (Part II only) or use the alternative method below.

Alternative method of restoring original boot loader

Instead of sending the original boot loader through serial, you can copy BootBlaster onto your iPAQ and reload the original boot loader just as you did with the new one during the Familiar installation process.


This document was collected together from various sources, including documentation by Jamey Hicks, George France, Rocky Heckman, Phillip Davis and others. It is meant to be a simple but complete guide on restoring PocketPC, without too many technical details or outdated instructions. Please bear this in mind if you make any changes.