Debug WebOS Application

My posts have been lax.…  NO APOLOGIES!…  I’ve been spending my free time developing my Cell Stalker app for the Palm Pre and Palm Pixi. (Palm WebOS)

Compared to developing a .Net appliction, developing for WebOS is a real pain.…  It is Javascript and HTML however, there is no “Intellisense”, “Easy Debugging”, “Syntax Checker” or “Accurate Warning/Errors”.

With that being said, let me show you how to debug and WebOS and how to find WebOS Javascript Errors.

As always you first need…

  1. Java 6 (if you don’t already)
  2. Sun VirtualBox (This is where you run the Palm phone emulator on your PC)
  3. WebOS SDK (This is basically the virtual machine, application packager and a few more tools)

I don’t use Eclipse to program, I’ve been using Komodo Edit.…  I like Komodo Edit because it’s MUCH smaller and quicker than Eclipse.

  1. Komodo Edit (The IDE, the place where you type your code)
  2. Komodo Edit WebOS tools (This allows you to compile and run your program with the push of a button.…  It also has “Some” syntax checking.)

After ALL of that is installed, you create a new application.…  You should be able to run it in the emulator and get a test screen.…  Now if you want to debug it, or catch errors you need to use a tool called Putty that got installed with the SDK.

When your WebOS emulator/virtual machine is running go to a command prompt (or click Start —> Run) and run the following…

putty -ssh -P 5522 localhost -l root -pw ”

This connects you to the linux machine running on your virtual phone.…  Then to debug javascript or trap javascript errors type…


To add a point where you want to stop the program type…

break /var/usr/palm/applications/com.YourCompany.YourAppName/app/assistants/first-assistant.js:100

This will pause the application named “com.YourCompany.YourAppName” when it hits line 100 in the “first-assistant.js” file.

When it’s paused you can type things like…

print Variable1

This will print the contents of Variable1 (Up to the first 80 characters, if somebody knows how to print more, comment here, I’d love to know).

You can then type


To continue.


clear 1

To clear the first break point.



to finish off the application.

I couldn’t find an example of how to debug out there, so I hope this helps at least one person.

For more debugging commands check out Palm Debugger Commands.

10 thoughts on “Debug WebOS Application”

  1. Nice. Yea, don’t forget to mention you can type “log” as a quick log of your projects output.

    So busy lately, will be nice to get debugging support in one of these days.

    Yea, .NET development will always be miles ahead of other SDKs/Platforms. Just how it works.

  2. Are you doing any ppc and are your campaigns profitable?

    I was thinking about getting back in with azoolge after a 2 year layoff.

  3. This was great. I think I just trapped an on-device error and fixed it. Here’s hoping.

    I recommend Firebug for those parts of your app that our mojo free.

  4. Also coming from the .NET world this is so nasty. Even Firebug is better. You would think with palm wanting developers to adopt there platform they would come out with a visual debugger (that is better than the one in ares) and allow for offline development.

Leave a Reply

Your email address will not be published. Required fields are marked *

nine − 8 =

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>