Handhelds.org - Open source for handheld devices

UserPreferences

WadeGuthrie


Here, I'm going to try to do a log of my iPaq experience. Hopefully, it'll (eventually) be detailed enough to classify as a howto.

First, an introduction. I'm an old time Palm user and have had several devices up to my current Tungsten T3. I've developed a couple small applications for the Palm, mostly using [WWW]OnBoard C, a compiler that runs on the Palm. Since Palm's decided to work with Windows, I'm starting a move to the iPaq running some flavor of Linux.

New Organization

Check out my New Organization.

TODO

Break into following pieces:

As It Stands

Table Of Contents

  1. New Organization
  2. TODO
  3. As It Stands
  4. Current Questions
  5. Getting the Hardware and Software
        1. What Do I Want To Do?
        2. Handheld Software
        3. Handheld Hardware
        4. Host Software
        5. Handheld Software Installation
  6. Configure The Handheld
    1. Get a PPP Session Up
        1. Host Machine Setup (One-Time)
        2. Start PPP and Test Connection
    2. Do Some Basic Configuration
      1. Update The Software, Install Some Apps
      2. Backup The Handheld
      3. Get GpeSync Working
        1. MultiSync Installation On Host
        2. GPE-MultiSync Installation on Host
        3. Installation On Handheld
        4. Using GpeMultisync
    3. Get an SDCard mounted
    4. Develop Software
      1. gcc/GTK on Ubuntu
      2. gcc/GTK on iPaq
  7. Next Steps
    1. Basic Configuration
      1. Move Stuff Over From the Palm
        1. Install jpilot
        2. Sync the Palm to the Host
        3. Export the Databases
        4. Import the Files into the Applications
      2. learn how to use some apps
      3. Specific Applications
    2. Other Stuff

Current Questions

Well,...

Getting the Hardware and Software

What Do I Want To Do?

My goal is to:

In the process of all of this, I figured that it would be pretty cool to be able to port X-Windows applications over to the iPaq.

Handheld Software

My Choice: Familiar with GPE.

I wanted access to lots of apps and I wanted the ability to twiddle a little with the OS. Familiar seems the best solution for these requirements.

I decided to use GPE rather than Opie because I figured that it would be pretty cool to be able to port X-Windows applications over to the handheld.

Handheld Hardware

My Choice: iPaq h3955.

I started by looking in the SupportedHandheldSummary page for an idea of what handhelds would give me a good user experience. I also lurked on the [WWW]Familiar mailing list and (later, after I decided that I wanted GPE) the [WWW]GPE mailing list. It looked to me like the iPaq series was the most supported for fiddling (but the Zaurus makes a pretty good showing, as well).

I was looking for basic PDA functionality; especially, having an alarm/event in the Calendar wake-up, beep, and display the alarm. I was told that this was...

I decided on the most mature box that I *knew* supported the wake-up-to-play-alarm mode -- that was the h39xx. There seem to be 4 of those: 2 with Bluetooth and 2 without. Since I don't need BT (and decided that paying less was good for me), I elected to pick-up the h3955 (the h3950 seems to be the same box but sold outside the US).

I went onto [WWW]eBay and bid on numerous h3955s. Most of them sold for the $120 US, range but I got one for about $80 US. It might have been better if I'd held out for one with a CF sleeve since that's the only way I could get WiFi (there's no support SDIO, just support for SD memory cards) and because the sleeves go for about $55 on eBay.

Host Software

My Choice: Ubuntu Linux (Dapper Drake).

I started using Windows XP as the OS for my host machine (I wrote the flash and the OS with Windows, in fact). In reality, though, almost everybody uses Linux. Since nearly all of the examples are for a Linux Host, I decided that this would be the wise way to go. I decided on [WWW]Ubuntu as my Linux distribution because it was an easy install and that's what I'm using at work. It turns out that this is a great choice for host OS because it's a kissing cousin to Familiar/GPE. It's a Debian distro so the apt-get stuff is just like Familar's ipkg package manager (and you'll use both quite a bit). Also, they both use GTK for developing X applications. Sweet.

I setup my machine to dual-boot Ubuntu (Dapper Drake). It's a mind bogglingly simple install and it sets-up the dual-boot for you perfectly fine. I found some helper tutorials for this over on [WWW]BigPond and [WWW]PsychoCats (which has a pointer to a free program to burn iso images under WindowsXP).

This may not be necessary for the iPaq stuff but I wanted to mention it. Edit the '/etc/apt/sources.list' file to enable update via the web.

Handheld Software Installation

I installed [WWW]Familiar v0.8.2 according to the directions. The directions were fantastic -- they worked really well and I had no problems. I installed via the serial port from Windows XP.

Configure The Handheld

Get a PPP Session Up

You'll want to setup a PPP connection between the host and the handheld so that you can install packages and so that you can use your host's keyboard and monitor for things like software development.

I started with the PPPhowto guide and went from there. Since I need a serial connection to upgrade the OS on the iPaq and since I didn't want to crawl behind my host PC to swap between USB and serial cables, I elected to go with the slower serial cable. I may be sorry but, if so, I'll do this differently, later.

Host Machine Setup (One-Time)

Again, I'm using Ubuntu, Dapper Drake, (which is a Debian derivative).

I started by getting IP forwarding up. I did this by uncommenting the line that reads net/ipv4/ip_forward=1 in /etc/sysctl.conf and rebooting.

Next, I got PPP up and running by creating a file named /etc/ppp/peers/ipaq containing:

------ host file: /etc/ppp/peers/ipaq ------

-detach
noauth
nocrtscts
lock
user ppp
connect '/usr/sbin/chat -v -t3 ogin--login: ppp'
/dev/ttyS0
115200
192.168.1.100:192.168.1.101

Start PPP and Test Connection

On the host, in one terminal window, setup the PPP connection by typing (actually, I have this in a small shell script) do:

host$  sudo /usr/sbin/pppd /dev/ttyS0 115200 192.168.1.100:192.168.1.101 nodetach local noauth nocrtscts ms-dns 68.4.16.30 lock user ppp connect "/usr/sbin/chat -v -t3 ogin--ogin: ppp"

found interface eth0 for proxy arp
local  IP address 192.168.1.100
remote IP address 192.168.1.101

NOTE:

On the host, in another terminal window, type

host$  ssh root@192.168.1.101

This will be a terminal connection to your iPaq. What you type there is actually going on on the iPaq.

Alternatively to the ssh session; on the iPaq, do the following:

Now, on the iPaq, type:

ipaq$  ping www.google.com

64 bytes from 64.233.167.147: icmp_seq=0 ttl=239 time=97.0ms
64 bytes from 64.233.167.147: icmp_seq=1 ttl=239 time=90.1ms
64 bytes from 64.233.167.147: icmp_seq=2 ttl=239 time=90.1ms
...

Do Some Basic Configuration

Check out FamiliarSlimDownHowto and GPENewbie.

Update The Software, Install Some Apps

On the handheld (or in the ssh window), do the following:

ipaq$  ntpdate -b time.handhelds.org
ipaq$  ipkg update
ipaq$  ipkg upgrade 

I think you can find some applications to install by going to the [WWW]IpkgFind site but I think I still have some research to do on this one. Also, check out IpkgFeeds for feeds or just Ipkg for an idea of how to use this stuff.

Backup The Handheld

I was going to make a backup of the handheld but I would have to rebuild the kernel (at least, according to FamiliarBackupHowto) and I'm not there, yet. Okay, so I guess I'll fly blind for a little bit...

Get GpeSync Working

GpeSync is an add-on to the [WWW]MultiSync program (though, it seems that it may also work with [WWW]OpenSync, a newer program). This will install both MultiSync and GpeSync.

MultiSync Installation On Host

First, you want to get all the apps you need for the host.

host$  apt-get install multisync libmultisync-plugin-all libmimedir-gnome0 libmimedir-gnome0-dev

Then, if you don't already have one, you'll want to generate a public key...

host$  ssh-keygen -t 1024 -t dsa

...and copy that key to the handheld. You'll have to Start PPP, then...

host$  scp ~/.ssh/id_dsa.pub <username>@<ip of PDA>:/tmp
host$  ssh <username>@<ip of PDA>

...and, on the handheld, put the key in the right place...

ipaq$  mkdir ~/.ssh
ipaq$  cat /tmp/id_dsa.pub >> ~/.ssh/authorized_keys
GPE-MultiSync Installation on Host

I got the download from http://handhelds.org/~florian/multisync/gpe-multisync.tar.gz and extracted it into a temp directory. I then copied those files (.../temp/*) into their ultimate locations (/*).

Then, you'll want to configure MultiSync. Bring-up MultiSync on the host from the menubar as follows:

Applications->Accessories->MultiSync

Then, do the following:

Installation On Handheld

Setup the IP connection (for me, that's done with PPP, but without starting a terminal). Then, do the following.

ipaq$  ipkg update
ipaq$  ipkg install ipkg
ipaq$  ipkg install nsqld
Using GpeMultisync

Bring-up MultiSync on the host from the menubar as follows:

Applications->Accessories->MultiSync

Then, hit the 'Sync' button.

Get an SDCard mounted

SdCardHowto and MountingSDandMMCon3900 describe mounting an SD card to /media/card:

ipaq$  modprobe mmc_asic3

Unmounting it is like this:

ipaq$  umount /media/card
ipaq$  rmmod mmc_asic3

This all works fine for me.

Develop Software

According to the [WWW]X-client development HowTo and DevelopmentCompilation, the three choices for application development are (in preferential order).

The [WWW]GPE Documentation and [WWW]GPE Development Manual favor the cross compilation route.

Either way, Neal Walfield suggested (the really cool idea of) developing on and for a Linux box (see GpeNativeDevelopment) and, only after getting it working, do the ARM-targeted compile. So that's the route I'm taking.

gcc/GTK on Ubuntu

My current thought is to do native [WWW]GTK+ development (see their [WWW]tutorial). So, to install the GTK development system, I did the following:
host$  sudo apt-get update
host$  sudo apt-get install build-essential
host$  sudo apt-get install libgtk2.0-dev

NOTE: I had considered developing with [WWW]wxWidgets (or wxGPE) but I thought the support for GTK programmers would be better. Besides, GTK has a Windows version so it's at least somewhat portable.

gcc/GTK on iPaq

Gcc is so big that you can't put it in flash. Since I've got a machine that handles and SD card, I decided to put it there. The card needs to be formatted with an ext2 partition and I was having a hard time doing this on the handheld. Therefore, I did the format on the host. To do this, I stick the SD card in the host's card reader and

host$  sudo umount /dev/sda1
host$  sudo mkfs -t ext2 /dev/sda1
host$  mount -l

/dev/sda1 on /media/usbdisk type ext2 (rw,nosuid,nodev)

Now, I

Next, I *THINK* I should PPP, then edit /etc/ipkg.conf. Add to the bottom of that file, the Familiar unstable feed...

------ iPaq file: /etc/ipkg.conf ------

...
src/gz unstable http://handhelds.org/distributions/familiar/feeds/unstable/packages/armv4l

...then add the gtk+ development system to the handheld:

ipaq$  ipkg update
ipaq$  ipkg install -d card gtk+-dev

Next Steps

This is where I am, today. Going forward, I need to get the following done:

Basic Configuration

Move Stuff Over From the Palm

I decided to convert the databases via vCards as an intermediate format. I did this as follows:

Install jpilot

[WWW]J-Pilot is a replacement to Palm Desktop for Linux. You can install it under Ubuntu as follows:

host$  apt-get install jpilot

There's a web page over on [WWW]clasohm that explains configuring the USB port by creating a file named /etc/udev/rules.d/10-visor.rules that contains the following:

------ host file: /etc/udev/rules.d/10-visor.rules ------

BUS="usb", SYSFS{product}="Palm Handheld*", KERNEL="ttyUSB[13579]", SYMLINK="pilot"

I did this but I'm not sure it was necesary. The reason I say this is that the file was supposed to make the USB device available without pushing the hotsync button. I didn't see this effect. On the other hand, I did create the file and the USB sync did eventually work -- I never tried to connect without having installed this file.

Configure jpilot by:

Sync the Palm to the Host

Do the following:

Export the Databases
Import the Files into the Applications

NOTE: you may want to edit the files if they are large -- importing gigantic files can really honk-up your iPaq.

learn how to use some apps

Specific Applications

Then, build some applications:

Other Stuff

For this, I *THINK* I should do an:

ipaq$  ipkg -d card install perl

CategoryHomepage