Palm Pre

This page is about the Palm Pre Device Palm starting selling in 2009. Since I got hand of my own device time by time I had to make some changes and in total this summed up to a shit lot of changes.

In order to handle those troubles and maybe to give some guidance back I’ll put these modifications on this page.

If you don’t root it, you don’t own it…

To Root the device means to get full access over the operating system and being able to make all changes you want. Or the one you don’t want to make and then to fuck up the system.

  1. You need to install at least the Java SDK 6 or higher.

  2. Download the Palm Pre SDK (Web OS SDK) from http://www.palm.com which contains all the core files you need to emulate and hack your palm pre.

  3. Download the Novacom application from the same source as well.

  4. Once you’ve installed all the 3 things mentioned above, go to your Palm Pre then do the following:

  5. Type upupdowndownleftrightleftrightbastart in the Launcher area where you can see all the apps.

  6. Once you do that, you will see a Developer Mode Enabler menu pop up like this:

  7. Simply click on it and enable it, the phone will ask you to reset the phone so say yes and reset your phone.

  8. Once your phone has reset, open up a command prompt.

  9. Now, connect your phone to your computer via the USB cable.

  10. Once connected, type this on your command prompt that’s still open:

    $ novacom -t open tty://
    
  11. You should get a terminal with e.g.root@castle as the prompt.

  12. That’s it. You’re now on your machine.

For changes of the file system it might be necessary to remount the file system. If you get a message like Filesystem is read-only, then you definitely have to. Just do a simple remount

$ mount -o remount,rw /

Install Preware

Via command line:

$ cd /tmp
$ wget http://bit.ly/preware-bootstrap
$ sh preware-bootstrap

Auto-correction and Text-Replacement

By default the device will auto-correct words in the language that has been configured during the setup and replace certain terms with others,

For the English language…

typing      replacement
----------------------
certian     certain
u           you

This functionality is mainly based on a simple procedure:

  1. Identify a string for replacement based on a catalog of string

  2. Replace it accordingly with a different or similar string

In practice this means the device is constantly comparing all text you’re typing into it to a collection of phrases and words. If you’re typing on word that matches to one of the words in these collection it will be replaced with the one that has been assigned for replacement. On one hand this can be used to auto-correct typical mistyping (like “certian” instead of “certain”) or to provide shortcuts for quicker typing in e.g. SMS messages or emails. This second feature makes it quite handy for lazy people to define a long range of shortcuts to save time while typing or even to store information, which usually needs to be looked up each time you need it (e.g. addresses).

Fortunately the dictionary the device it using isn’t a database, it’s a simple text file instead. It’s located /etc/palm/autoreplace/<language>/text-edit-autoreplace

Depending on the language you’ve chosen during the first setup of the device you are ending up in a different subdirectory. For me - chosen GB-English, the subdirectory is en_gb.

So if you want to modify this file just stick to syntax you can already see in the file:

Wrong word | replacement word

It’s getting a bit tricky when it comes to words which contain special character by default (probably every language besides English contains character like this). So my procedure to get those characters into the files where this:

  1. Make a backup of the original file.

  2. Copy the file from /etc/palm/autoreplace/.... to /media/internal/... via console on the Palm.

  3. Mount the Palm via USB and edit the file until all changes are in there.

  4. Unmount the Storage, get back to the console and verify that the file on /media/internal/... still contains the correct characters on the console.

  5. Replace the original file with the modified one and verify again, that the character-set is valid.

    The tricky part is to get the characters from your local system to the Device. If you can read your characters at the original location on the device via console, than you’ve been successful.

Some additional shortcuts I’ve added are:

mytel|<my telephone number>
myaddr|<my address>
myemail|<my emailaddress>
.....

Activate Device privacy

Unfortunately during the last years the phone manufacturers developed the tendency to implement surveillance and phoning-home functions. This is more than annoying from the customers perspective and after Apple also Palm jumped onto the train and doesn’t supply their customers with any possibility to switch it of. So the device periodically uploads information to Palm, Inc. The first thing sent is intended to be the GPS location. It’s the same location you get if I open the map application the Pre. Not very accurate in this case, but I’ve seen it be accurate enough to find my house before.

{ "errorCode": 0, "timestamp": 1249855555954.000000, "latitude": 36.594108, "longitude": -82.183260, " horizAccuracy": 2523, "heading": 0, "velocity": 0, "altitude": 0, "vertAccuracy": 0 }

Here they can tell every WebOS app you use, and for how long.

{"appid": "com.palm.app.phone", "event":"close", "timestamp": 1250006362 }
{"appid": "com.palm.app.messaging", "event": "launch", "timestamp": 1250006422 }
{"appid": "com.palm.app.messaging", "event": "close", "timestamp": 1250006446 }

It sends the above info on a daily basis.

2009-08-10t09:15:10z upload /var/context/pending/1249895710-contextfile.gz.contextlog ok rdx-30681971
2009-08-11t09:15:10z upload /var/context/pending/1249982110-contextfile.gz.contextlog ok rdx-31306808

Shame on you Palm, shame on you. If it wouldn’t be possible to disable, I would definitely return the device. Palm is using here customers Bandwidth and Battery-Power

There is also some info that is recorded when a WebOS app crashes. Now, I’ve seen WebOS crash hard a time or two, but it turns out apps are crashing fairly frequently behind the scenes, and each such crash is logged and a system state snapshot taken. At least some of these are uploaded, though if things are crashing a whole lot it will be throttled.

2009-08-09T17:01:22Z upload /var/log/rdxd/pending/rdxd_log_59.tgz OK RDX-30246857
2009-08-09T17:05:36Z upload /var/log/rdxd/pending/rdxd_log_26.tgz OK RDX-30249465
2009-08-09T17:09:11Z upload /var/log/rdxd/pending/rdxd_log_56.tgz OK RDX-30252374
2009-08-09T17:11:46Z upload /var/log/rdxd/pending/rdxd_log_70.tgz OK RDX-30253958
2009-08-09T17:16:29Z upload /var/log/rdxd/pending/rdxd_log_67.tgz ERR_UPLOAD_THROTTLED_DAILY
2009-08-09T17:17:28Z upload /var/log/rdxd/pending/rdxd_log_51.tgz ERR_UPLOAD_THROTTLED_DAILY
2009-08-09T17:20:40Z upload /var/log/rdxd/pending/rdxd_log_21.tgz ERR_UPLOAD_THROTTLED_DAILY

Each tarball contains a kernel dmesg, syslog, a manifest.txt listing all installed pkg packages (including third-party apps), a backtrace of the crash, a df and ps -f output listing all processes owned by root (but not by you). The uploading is handled uploadd, which reads /etc/uploadd.con

[SERVER=rdx] RepositoryURL=https://<HOST>/palmcsext/prefRequest? prefkey=APPLICATIONS,RDX_SRV UploadURL=https://<HOST>/palmcsext/RDFileReceiver
[SERVER=context] RepositoryURL=https://<HOST>/palmcsext/prefRequest? prefkey=APPLICATIONS,RDX_SRV UploadURL=https://<HOST>//palmcsext/RDFileReceiver

The HOST this is sent to via https is ps.palmws.com. The approach to disable this, which may not stick across WebOS upgrades, was to comment out the ‘exec’ line in /etc/event.d/uploadd and reboot. However, then you’ll notice a contextupload process running. This is started by dbus, so the best way to disable it seems to be: rm /usr/bin/contextupload

Note

BTW, since Palm has lawyers, they have a privacy policy, which covers their ass fairly well regarding all this, without going into details or making clear that the above data is being uploaded. WebOS upgrades do re-enable the spyware; this has to be repeated after each upgrade.


Applications

By daily use I prefer the following applications installed additionally to the default installation:

  • Accu Weather

  • Cloud Tasks

  • Critical Mass

  • drPodder

  • Geocaching for webOS

  • Google Calendar Search

  • Ideal Weight

  • IM+ lite

  • Leo Dictionary

  • Music Player (Remix)

  • MyNotification

  • My Tether

  • News Feed

  • Preware

  • ShopList

  • Wapedia: Enclyclopedia


Exporting SMS

For exporting your SMS stored on you Palm Pre Device you need to extract the SMS/Conversations from the Pre-Database. All SMS are stored in /var/luna/data/dbdata /PalmDatabase.db3

You either manually copy that file on the shell to the internal USB-Drive and grep it from there, or you use e.g. the application Internalz Pro to get hand on that file. However in addition you need to script files to

  1. Get the ID of the user you’d like to extract (getPalmDBID.pl)

  2. Get the SMS related messages from an to that user. (getPalmDBSMS.pl)

Run the scripts in the same folder as you’ve stored the file PalmDatabase.db3. A description of how to use the scripts and the syntax to use you’ll find when you follow the links.


Patches

To be honest: The App Store of Palm isn’t that big yet and doesn’t contain so many useful applications. On the other hand: How many do you really need, I mean: Really?

So you might be interested in Preware which gives you another quite comfortable way of installing third party applications (AFAIK Apple doesn’t even allow that) and patches and so enhance the device operating system.

So I went through the lists of available patches, figured out that they change a couple of things which annoyed me and even improved some stuff I haven’t thought about yet.