Subscribe by Email

Your email:

Contact Us

AVAI Mobile Solutions Blog

Current Articles | RSS Feed RSS Feed

An iPhone Developer’s First Blackberry Application

  | Share on Twitter Twitter | Share on Facebook Facebook | Submit to Digg digg it |  Add to delicious  delicious |  Submit to StumbleUpon StumbleUpon |  Share on LinkedIn LinkedIn |  Share On Technorati Technorati | Submit to Reddit reddit 

I recently attempted to write my first Blackberry application.  I knew that I would have to learn some new skills but, with my background in mobile development and my roots as a Java developer, I was up to the challenge.

I didn't start with anything too complicated.  I found the tutorials section of Blackberry's developers site (http://na.blackberry.com/eng/developers/resources/tutorials.jsp#tab_tab_development) and started working my way through the getting started tutorials.

           Now I've used the Eclipse IDE in the past, so I was ecstatic to learn that not only is there a Blackberry plug-in for Eclipse, but it's the recommended approach.   I also learned that the plug-in is not compatible with my Mac OS X.  Now I wasn't excited about this, but I can adapt, so I hopped over to the Eclipse homepage to download the newest version and installed it in my Windows VM.   After, not too much time I have Eclipse up and running and return to Blackberry to download the plug-in.  They have an easy to use installer, so I download that, hit install and I'm ready to go.  Of course, nothing can ever be that simple.  The install doesn't take and I have no message explaining why.  I double check the requirements only to realize that the newest version of Eclipse is not supported.  I have to head back to Eclipse and download an older version.  Great, I haven't even finished the setup, and I've already made a mistake.  But a simple mix up over the wrong version isn't huge, and I have been assured that Blackberry development is easy, so I'm not giving up yet.  

           I must say after I installed the correct version of Eclipse and ran the Blackberry Plug-In installer one more time, the install went off without a hitch.  I opened my brand new copy of Eclipse, create a workspace, create a new project, and there in front of me is the option to create a Blackberry project. Score!  At this point, I must admit I am excited.  I love Eclipse.  I really do.  And after all the time I've spent fighting XCode, I'm finally back to an IDE that doesn't fight me.  From this point on the process seems very simple.  I follow RIM's very understandable Writing Your First Blackberry Application tutorial.   The code makes sense, the RIM libraries appear easy to use, and within an hour I've written a very basic "Hello World" app.  Now granted Blackberry has an unfair advantage over iPhone in this respect.  When I wrote my first iPhone application I had never seen Objective C code before and the syntax was completely different than anything I had ever written before.  However, I did appreciate that Blackberry development allowed me to use both a language and an IDE I was already familiar with.

           Running the application in the simulator also seemed quite easy.  Aside from the fact that it didn't automatically launch my application as the iPhone simulator does, the simulator seemed relatively easy to use with enough options to test various states my real Blackberry phone could be in while running an application.

           With the great success I had had writing, compiling, and running my app in the Simulator I was ready to see it on a phone.  This was the step I had most anticipated, not only because it always feels great to see my application in its final state, but because I had heard that putting an application on the Blackberry is a much easier process than putting an application on the iPhone.  I still get a sour taste in my mouth when I think back to the struggles I had with my first several iPhone apps and making sure my code signing settings were just right and all my certificates in place and never being exactly sure what was wrong when XCode gave me one more cryptic error each time it failed to put the app on my phone.  But this was not going to be a problem on the Blackberry.  I connect my Blackberry and begin looking for the "Build to device" option.  I can't find one.  I return to my tutorial.  Surely the tutorial's writer anticipated that the next logical step any developer would want to take would be to put their application on an actual Blackberry device.  I scroll to the bottom, but all I see are suggestions as to other things I can add to my application and instructions on how to exit Eclipse.  Thanks RIM. 

           I scan through Blackberry's list of tutorials and find one entitled "How to Deploy and Distribute Applications."  Surely this must be it.   Again I find another series of useful steps explaining how to deploy my application through the Desktop Manager.  Great.  I install the Desktop Manager update to the latest version, follow all the appropriate steps and I'm ready to go and I get an error when I attempt to install the app.  I double check everything, make a few changes, try again, this time a different error.  I try several different configurations, nothing seems to work.  After several attempts, I resolve to give up on the Desktop Manager.  Reading through the rest of the document I discover the javaloader deployment method.  Apparently, the Blackberry JDE comes bundled with this easy to use command prompt tool.  A simple call to "javaloader -u load yourfilename.cod", and my program is loaded on the phone!  I find my application in the Downloads section (like the Simulator, it doesn't seem to automatically run it) and soon I'm staring at the familiar "Hello World" screen. 

        All in all, I must say Blackberry development was only a little more complicated than I anticipated.  At the time I remember cursing Blackberry and complaining that this was not in any way easier than beginning iPhone development, but looking back, I can see that Blackberry development does have its advantages.  From my limited experience with the platform I can already begin to see that it is well thought out and I'm eager to learn more.  I won't say my first Blackberry app was easier or harder than my first iPhone app, but it was different.  But different is good.  While Blackberry and iPhone are both smart phones, they are very different, and they both deserve my share of respect as a developer.

Comments

Currently, there are no comments. Be the first to post one!
Post Comment
Name
 *
Email
 *
Website (optional)
Comment
 *

Allowed tags: <a> link, <b> bold, <i> italics