Monthly Archives: November 2013

I had an idea a couple of days ago while I was casting around for a way to make use of the promising abilities offered by the new PebbleJS feature of Pebble SDK 2.0. It essentially cuts out the ‘man in the middle’ apps needed for communication with the web, which can limit the audience if the developer (such as myself!) is only familiar with one platform, such as Android.

The idea I came up with was this: On the Transport for London website (, there is an HTML table that details the line status of all the different Underground lines. On a good business day these will all show ‘Good service’, and on a bad day/weekend a lot will show ‘Part closure’ or ‘Planned closure’. Wouldn’t it be great if this information was more readily available to a commuter or tourist if they happened to be equipped with a Pebble watch?

So that is what I set out to do, and with a little bit of JS wisdom, the result is PTubeStatus!

mockup2 The major challenges were parsing the data and sending all these strings over app message without causing buffer overflows or APP_MSG_BUSY errors. The solution was to chain the messages sent to the watch so that when one was ack’d, the next set of data was sent. When the second set was sent, the JavaScript signaled the watch to load it into a MenuLayer and show it.

You can download the app to try it for yourself from mypebblefaces, and if you find it useful and fancy making a donation, you can do so by purchasing the installer app for Android from Google Play, which I will update to let you know that the watch app also needs updating!

As usual, any feedback and bug reports are most welcome, and I will respond to each of them.


If you’re a user of my Watch Trigger or Watch Trigger + Pebble watch apps and also love the newest watch firmware, do not despair: They are both now 2.0 compatible!

The main thing about converting apps to the new SDK is that it is not hard, just time consuming. _init() calls are replaced by pointer-ifying the implicit argument and _create() instead. Also some structs are changed, such as BmpContainer to a BitmapLayer and GBitmap. It’s also much easier to manage layers, with window_get_root_layer() replacing &window->layer.layer for example.

I switched from AppSync to AppMessage as the new implementation was more clean and seems to work quite well.

The only other main difference is that both versions of the Android app work with just one watch app for simplicity. Existing users who have upgraded to the beta 2.0 firmware will need to go to Settings and re-install the appropriate watch-app.

So without further ado, go ahead and dive in! If you have any issues, please let me know!

Get it on Google Play

Download (+)
Get it on Google Play

Today saw the end of Team Pebble’s controversial radio silence, and replaced it with an absolutely huge announcement in the form of a live stream. You can get the details here. The salient points are:

  1. A huge overhaul of the 1.x SDK, changing a huge amount of how apps are written.
  2. New APIs for access to accelerometer and JS services.
  3. Upgraded and streamlined developer tools.

The main implications for this for me, my watch/phone apps/faces and my tutorials are this; When the SDK 2.0 exits beta and it generally released, all the watch faces and apps I’ve developed for 1.x will cease to work, unless I upgrade them.

My priority for upgrade will be Watch Trigger and Watch Trigger +, followed by all the watch apps available in Watch App Selector. Maybe that will require splintering into two pages for 1.x and 2.0, or multiple buttons.

After this, I’ll write updates to the SDK Tutorial pages, but I’m uncertain of the format I’ll be using for that. I’ll sort it out though. Maybe even start a fresh…

All these upgrades will have to be in my free time, which I have a lot less of now (4th year Masters degree year), but I’ll do my best to get it done as fast as I can.

As always, feel free to get in touch with comments/concerns!