Handhelds.org - Open source for handheld devices

UserPreferences

PalmTungstenCHowTo


Linux on Palm Tungsten C How-To

Home | Status | Hardware | Downloads | How-To | Bootloader

Introduction

This document describes how make a own GNU/Linux enviroment for the palm tungsten C. For binary files to download-and-run look at the download page. The document does not cover information on Palm OS/Programming or Linux. More details on the Palm PDA can be found at palm web site http://www.palm.com. Additional information on Linux can be found at http://www.google.com/linux?hl=en&lr=&q=about+linux&btnG=Search

Getting started

A palm tungsten C PDA is ofcourse required to start with. A PC running linux/windows that can transfer files onto PDA is also essential. The binaries/images that install and run Linux on the Palm TC are built on a PC running Linux, else the pre-built binaries can be utilized.

Setting up development environment

This is needed to build the kernel images and garux boot loader. If you are planning to use the pre-built kernel, you can skip to section 3.0.

Download and the install the following tools. For most of the tools this can be done by downloading and installing appropriate rpm.

  1. Tools for the prc, prc-tools v2.3-1, from http://prc-tools.sourceforge.net/

bash# rpm -ivvh prc-tools-2.3-1.i386.rpm

bash# rpm -ivvh prc-tools-arm-2.3-1.i386.rpm

SDK installs into /opt/palmdev.

bash# mkdir /opt/palmdev; cd /opt/palmdev; tar xjf TBD

Run palmdev-prep to setup the configs files, so that prc tools can use the SDK header files and lib files.

bash# palmdev-prep

bash# rpm -ivvh pilrc-3.2-1.i386.rpm

bash# rpm -ivvh arm-binutils-2.16-1.i386.rpm arm-gcc-3.4.4-1.i386.rpm arm-glibc-2.3.5-1.i386.rpm arm-kernel-2.6.10-1.i386.rpm

With the installation of cross compiler tool chain, development environment setup is complete. Next steps include downloading kernel, a root file system source, boot loader and building the same. If you have used the rpm based installations, make sure to set /usr/arm/bin/ in your PATH.

Building the kernel

Download the hack-n-dev kernel source from http://svn.sourceforge.net/viewcvs.cgi/hackndev/linux4palm/linux/trunk/

bash# svn co https://svn.sourceforge.net/svnroot/hackndev/linux4palm/linux/trunk

Use the default configuration for the kernel. The default config is set by building the palmtc_defconfig target.

bash# cd trunk

bash# make palmtc_defconfig

bash# make all

If make completes successfully, the kernel image will be at trunk/arch/arm/boot/zImage.

If you are using the toolchain from emdebian: gcc-3.3 won't work for compiling the kernel.

Building initramfs

Initrd can be developed from various distributions. Busybox was used for this port. The source for Busybox is at http://www.busybox.net/. TBD: show the cmds. Untar the source, run make menuconfig, select the required applications. Use the cross compiler option and build the busybox image. Follow the examples and scripts in busybox to create a compressed initrd file. On details how to build a initramfs, have a look at this: http://hackndev.com/node/623

Building GPE

TBD.

Building Garux

Download the garux boot loader from the sourceforge cvs repositry, http://sourceforge.net/cvs/?group_id=148181.

bash# cvs -d:pserver:anonymous@garux.cvs.sourceforge.net:/cvsroot/garux login}

bash# cvs -z3 -d:pserver:anonymous@garux.cvs.sourceforge.net:/cvsroot/garux co -P garux

Copy zImage and the compressed initrd files into the garux directory.

bash# cp trunk/arch/arm/boot/zImage garux

Next, build the garux.prc file

bash# cd garux

bash# make palmtc

Uploading Garux to PDA

Downloading garux into PDA is same as installing any other palmOS applications into your PDA. Load the 'garux.prc' file, either one that is build or pre-built binary (from section 5) into palmTC using one of your favourite palm desktop applications kpilot, gpilot-install-file or palm file installer.

Booting and Rebooting

Connecting to PDA over USBnet.

To connect to PDA over usbnet, you have to boot linux on PDA with PDA on the hotsync cradle. After Linux booted successfully, lift the PDA off the cradle and replace it back. If klog is enabled you should see message

usb0: full speed config #1: 100 mA, Ethernet Gadget, using CDC Ethernet Subset usb0: full speed config #1: 100 mA, Ethernet Gadget, using CDC Ethernet Subset

on the PDA console. Also a dmesg on your desktop should show up a message

usb0: register usbnet at usb-0000:00:1f.2-1, Linux Device usbcore: registered new driver usbnet

Downloading Summary