DocuSign for BlackBerry 10 in a Few Hours

Last week DocuSign engineering had a second internal hackathon (a nice collage resulting from the first one) and I built DocuSign for BlackBerry 10 in just a few hours (well, sort of).

Some of you might be wondering what BlackBerry is. It’s a mobile operating system that is actually in the process of surpassing Windows and Kindle, based on market share, according to this reputable study. Oh, and by the way, BB also has many loyal aficionados thanks to their years of being a mobile solo-provider to enterprises.

Luckily, DocuSign already had an app for Android and, based on my research, which consisted of looking at this page for a minute, and talking with our mobile dev manager, I figured out that I could just port the DocuSign for Android app to the BlackBerry OS. Porting is just a fancy word for re-writing something in a new language, or for a new platform, without changing functionality very much. It typically involves re-compiling, changing APIs, updating code and re-packaging.

It’s worth noting that RIM (the company behind BlackBerry) provides many other options for building BlackBerry 10 apps including:

  • Adobe AIR
  • Native
  • HTML5

This is probably done to boost the number of available offerings within their marketplace (BlackBerry World) and jump-start their development ecosystem, which is lagging far behind those of iOS and Android.

I have worked with Java and J2EE before. In addition, I was an Adroid guy for a long time prior to getting my first Apple product (MacBook Air): I remember that my very first smartphone (running buggy Android 1.6) had constant “Force Close” errors. However, up until this hackathon, all of my forays into mobile dev land consisted only of using HTML5 with the Jo and Sencha Touch frameworks. Awesome challenge! Or so I thought.

The goal was to use Android code, re-package it, and install it in the simulator (with or without changes). I decided to go with Android Studio vs. Eclipse, and downloaded these tools (download page):

The complete tutorials are available at Runtime for Android apps.

After downloading, literally, a few gigabytes of SDKs and packages, I was stuck with our code-base in Android Studio due to some Java exceptions regarding Gradle, so I resorted to using command-line tools.

These are the commands from the BlackBerry toolchain that I ended up using:

  • apk2barVerifier: to verify apk (Android) files for compatibility for bar (BlackBerry)
  • apk2bar: to re-package apk to bar
  • blackberry-deploy: to upload and install the app on a BlackBerry

It’s worth noting that for distributing BlackBerry 10 apps to the BlackBerry world, apps must be signed with a special token (tutorial). Obviously, I skipped this step for the hackathon.

Lo and behold, everything worked on the BlackBerry with 0 code changes (except where DocuSign tries to charge via Google Play). The end results were quite pleasing. Thank you BlackBerry for making it easier for us developers. I guess, I can now say that I develop native apps (yeah, right). :-)

DocuSign for BlackBerry 10: Homescreen
DocuSign for BlackBerry 10: Homescreen
DocuSign for BlackBerry 10: Sign a Document
DocuSign for BlackBerry 10: Sign a Document
DocuSign for BlackBerry 10: Main Menu
DocuSign for BlackBerry 10: Main Menu
DocuSign for BlackBerry 10: Document View
DocuSign for BlackBerry 10: Document View

In addition, I also found this neat but scammy-looking service called APK Downloader that allows us to install Android apps from the Google Play market directly onto the latest BlackBerry 10 systems. Simply enter the name of the app as a Java package, e.g., com.docusign.ink, (link). The real hack! I could have used it from the beginning and saved myself a few hours. Therefore, it’s vital to conduct proper up-front research prior to embarking on a project! ☺

Android to iOS or Why Guy Kawasaki Is Wrong

I jumped on the smartphone train a little bit later than most of my type (early adopters, geeks, etc.) because I didn’t like Apple, Inc. and its products. And I also had this notion that each device should do its own distinct function well rather than try to be a Swiss Army knife of gizmos.

I know that many of you perceive Guy Kawasaki as some sort of genius and visionary. Indeed, he’s published 11 (eleven!) books, worked with Steve Jobs, and has strong opinions. Not that long ago, I attended his talk at TheNextWeb event where he was promoting his new book APE: Author, Publisher and Entrepreneur. The book is about self-publishing woes. Although his tips and APE have come in very handy for my lean-pub edition of Rapid Prototyping with JS, I somewhat disagreed with Guy’s casual remarks about two Google products: Google Plus and Android. Mr.Kawasaki said that Google Plus is to Facebook, what Apple was to Windows: not many people use it, it’s better and everybody thinks it’ll die soon. :-) Then the acclaimed author half-jokingly said: “Android is for real men”. Seriously?! Here is my story of going from a hard-core Android user to an iOS fan in less than a year.


Guy Kawasaki about Android at TheNextWeb

I jumped on the smartphone train a little bit later than most of my type (early adopters, geeks, etc.) because I didn’t like Apple, Inc. and its products. And I also had this notion that each device should do its own distinct function well rather than try to be a Swiss Army knife of gizmos. For example, taking pictures with a photo camera, listening to music on an MP3 player, voice calls with a dumbcell phone, taking notes on a PDA and waking up to an alarm clock. ;-) Of course, my conservatism started to fade away as hardware and software improved. Slowly I’ve noticed that I’m watching videos on my 4“ MP3 player, reading books on my Dell Axim X51 and using an alarm clock ”app" in my Nokia cell phone.

I guess it was time for my first real smartphone. I’ve already used many Google web application so I went with T-Mobile’s myTouch 3G with Android 1.6. The device was slow and buggy like hell. The phone was unusable to the point that I had to root it, and to install an aftermarket firmware CyanogenMod to make the experience at least somewhat bearable. Despite all of that, what I’ve come to realize is that I really needed a smartphone in my life (surprise, surprise!). Boy, I was wrong when I thought that if I had a computer at home and one at work, then I didn’t need yet another one in my pocket. ;-)

Then, a few iterations of Android OS and a few devices later — I had an entry-level LG Optimus One and a gorgeous 4.5" display Samsung Infuse 4G — I really started to appreciate:

  • Seamless integration with my everyday apps: GMail, Google Docs, Calendar, Reader and Maps.
  • Abundance of free apps.
  • Customization done by device manufacturers and those I can do by using widgets and aftermarket firmware.

It wasn’t always roses and butterflies. Here are some of the problems I experienced using Android-powered devices (I also had a 7" Samsung tablet):

  • No Instagram-like hip apps when they’re already available at Apple App Store.
  • Phone barely lasted one day, despite multiple replacements and having an extended battery.
  • Constant “Force close” (analog of a blue window of death on Windows PCs) and the need to restart the device.

Nevertheless, I was blissful in my ignorance which was totally destroyed by my switch to Max OS X from Windows XP/7. The reason for this was that I had to sync data using 3rd party apps and adapt to new behaviors. I wasn’t happy. Because when I’m not happy I usually find way to fix it. :-) The perfect timing of iPhone 5 and sluggishness of Android 2.3 (I had over 100 apps installed) made the pre-order of iPhone 5 64Gb a no-brainer.

Things that I’ve come to enjoy and appreciate since then:

  • iPhotos, Photo Steam and Photo Roll are a simple and robust way to sync photos across Macs, iPads and iPhones. Also, seamless integration with iCloud and iTunes makes my life easier.
  • iPhone 5 battery life is amazing, on a typical day I use only 30–40% of a charge which means I can go for about two days without recharging.
  • iMessage/Messages is a superb feature with allows me to take conversations I’ve started on iPhone or iPad to my MacBook or vice versa.
  • Retina displays on both iPad and iPhone 5 are feasts for my eyes.
  • Last but not least, LTE is lightning fast compared to the fake 4G standard of HSPA+.

Again as with Win vs Mac, iPhone doesn’t make me think about unnecessary things like updating to a custom flavor of OS or about solving synching issues.

I know that Guy Kawasaki plays hockey, which is no doubt a manly recreation, but I think that he was wrong about Android. In my humble opinion, Android is similar to Windows because:

  • Android OS is loosely integrated with hardware (except for Google Nexus produced by HTC).
  • Google has a licensing revenue model which is similar to Microsoft selling a copy of Windows. By the way, Google licenses Android for $10 per device.
  • Android devices are very fragmented; there are dozens of companies, each with its own modified version of Android, and even with apps and entertainment stores, e.g., Samsung Hub.

All of these make apps development slower and introduce more challenges for developers while being less appealing products for end-users. As with Windows, the main advantage of the Android platform is its lower price and growing army of users!