Starting with The PlayBook

Back around the end of March, I posted on Twitter that I wouldn’t be able to develop for the BlackBerry PlayBook because I simply couldn’t afford a device. It interested me, much in the same way webOS interested me. The PlayBook is a 7-inch tablet that never gained traction in the market, but it’s still a device running an interesting operating system: QNX.1 Interesting means I want to code for it. But there’s the cost. So, following that tweet, two folks from RIM contacted me and asked for my address. Not long afterward, they shipped me a PlayBook, and since then I’ve fiddled with it and its developer tools.

The PlayBook itself is much nicer than I’d expected. RIM knew how to create a nice OS and a nice tablet, at least. In particular, it doesn’t feel cheap. My HP Touchpad suffered from creaky plastic, it felt cheap, but the PlayBook avoids this. The device has a back coated in some rubber-ish material which makes it pleasant to hold. The power button, despite what reviews have said about difficulty using it, seemed easy enough to press. Overall, it’s a very nice piece of hardware and remarkably comfortable in the hand.

The only complaint I have about the device itself is its bezel: RIM printed “BlackBerry” across the bezel. If I pick up the device and hold it at any orientation other than the text’s, it looks stupid. The iPad benefits here from having really no markings on its front aside from the home button, and that doesn’t demand a proper orientation. If I pick up my iPad and start to use it upside down, the screen will reorient itself. It doesn’t look stupid, it just works. It accommodates the user. I’m not sure why RIM feels it must remind the user they’re holding a BlackBerry device, but, again, it looks stupid.

The PlayBook ships with a number of apps and their quality varies, which I expect. Most apps are reasonably nice, but slow. I just expect scroll lag in non-iOS software now. webOS suffers from it, Android suffers from it, and QNX, the PlayBook’s OS, suffers from it. It’s especially noticeable, of all places, in App World, RIM’s app store. When I attempt to scroll through applications in App World, it stutters through a small list of applications, frustrating me. This is curious, but I assume it’s a side-effect of certain applications using either Adobe AIR or WebWorks (essentially HTML/JS apps). AIR apps all seem to suffer performance issues. I haven’t seen many WebWorks apps, but I assume they suffer the same – browser performance on these devices just isn’t there. The iOS can’t handle it, and my own little tests with WebWorks seem to show the PlayBook can’t either. Maybe future browsers and devices will make web apps appear equal to native apps, but until then it’s a bad idea.

This presented a problem for me when I decided to look at how a developer might make a fairly normal GUI app. Currently, you have two options: Adobe AIR and WebWorks. Again, these suffer from performance issues. The WebWorks route is simple, but RIM offers developers very little assistance. There is no usable GUI framework via JavaScript. You’re very much on your own there, which is fair enough for web apps, but makes it difficult to create apps that fit in with the rest of the OS.

AIR offers a GUI framework of sorts, but the performance issues are so frustrating that I can’t imagine subjecting a user to them (and yet RIM has done just that). In addition to that, I find the entire development process for AIR apps frustrating. While WebWorks keeps the process simple, AIR seems built only for developers using Adobe’s wonderfully overpriced software rather than command-line tools. So, if you’re not willing to pay anywhere from $250 the $700 USD, you might as well ignore AIR altogether.

Your third option2 for app development is the NDK: C and C++, not much else. You get your common libraries for these devices, including OpenGL, APIs for the OS and its windowing system, and other expected libraries. That’s about it. This should change with the next version of the OS, apparently BlackBerry 10, as RIM introduces Qt and Cascades, the latter a framework used by The Astonishing Tribe (TAT). To put into perspective how important that last bit is, let me just say that the applications that seem most apparently built by TAT are also those that never experience lag. Never. Their apps, however, are also about as useful as toys, so make of that what you will. Currently, however, Cascades and Qt are not exactly ready. You can demo them now, but I don’t imagine you’ll make a PlayBook app using either.

The NDK, despite its lack of a GUI framework, is actually the nicest of the three options for application development. Game developers in particular seem pretty well off here. RIM provides some utility code to create an EGL context, render text, handle orientation changes, and so on. It’s not much, but it reduces the amount of code one has to write. Additionally, one can inspect the code to see that it’s not doing anything funny and otherwise just learn how RIM expects developers to handle things. I think RIM knew what they were doing here, so it’s a shame that they didn’t put more into it. AIR and WebWorks are, by comparison, garbage. AIR in particular offers the most tortuous route to application development. WebWorks is nice but it’s too early to view HTML apps as competitive with native apps. For someone like me, the NDK is really the only good option for PlayBook development.

I’ll probably continue writing some posts about this, but this should serve as a sort of introductory post for future writing on the PlayBook. If there’s something in particular someone is curious about, I’ll be glad to divert some focus to that as well. Personally, I’d rather write about development, so now that my semester is over and I have a summer’s worth of time to do some work, I’ll try to offer some sort of commentary on development for the PlayBook and other devices.

  1. Officially, I believe RIM refers to the OS as “BlackBerry Tablet OS.” Not the marketing department’s finest work. Later, they’ll probably refer to it as “BlackBerry 10” when that’s released. That said, I prefer “QNX.” It’s simple. [return]
  2. There is a fourth option for application development, but I cannot in good faith ever recommend it to anyone: Android development. The PlayBook ships with some bits of Android, but the results are terrifyingly bad. All Android ports for the PlayBook feel cheap and look completely out-of-place on the device. This might appeal to developers who don’t care about the PlayBook, but otherwise you should avoid this option like the creepy doll in your attic. And trust me, that creepy doll lives in your attic. You just don’t want to remember. [return]