!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> » Getting Started -- Mobile Perspectives

Getting Started



By paul ~ March 1st, 2009. Filed under: Resources.

It’s been roughly two weeks since we’ve seriously embarked on this iPhone development project.  Along with about a million others, it seems.  It reminds me a bit of the ’49ers and the gold rush.  A recession, tales of AppStore wealth, and the desire to be part of a very "cool" transition in computing have lured many of us to leave what we know for a brave new frontier.

It’s definitely been a new frontier for me.  After years and years of large application development in the computer aided engineering fields on *NIX and Windows platforms, much is new:

  • The Mac development platform
  • Objective-C
  • 3D Graphics
  • Small, lightweight programs
  • Touch UI
  • A different kind of user

My bookshelves are full of books that are not relevant.  My office has 4 Windows machines and 2 Sun Ultra-Sparc Solaris computers.  I obviously have a major transition to make.  But, I know how to develop quality software.

To bootstrap ourselves, Dean and I did a lot of up-front reading.  There are many helpful blogs out there for newbs like ourselves.  One we found particularly useful is by Craig Hockenberry over on furbo.org .

Step 1 — Sign up on the Apple iPhone developer site and start reading.

This step was easy.  There is a wealth of information on the Apple Developer Connection web site.  I spent some serious time with the materials on the web site relevant to the Cocoa SDK, the iPhone software architecture, Objective-C, and XCode.  I’ve spent 20 years with C++ so Objective-C looks pretty weird, but I can certainly understand the motivation for some of the differences.  Apple has definitely built themselves an island with this one!  (Later I learned that I can use Objective-C++ and I now feel right at home.)

Step 2 — Buy a Mac.

After spending some serious time on eBay, I found a Buy It Now Macbook with 13" display, 2GHz, and 1GB of RAM for $650 with shipping.  I’m used to buying cheap Windows laptops, so the cost of a Macbook was a bit shocking (I saw a Macbook Pro that had had Gatorade spilled in it go at auction for over $700!) but $650 was certainly acceptable.  When I received the Macbook, it was nearly pristine.  In fact, I am so happy with the quality and rapid service that I want to put in a plug for Beta Macs in Denver.  Check out their eBay store as well if you’re looking for a Macbook to get started with.

I read that for development at least 2GB of memory was advised, so I picked up 4GB of RAM from Tiger Direct for $50 along with a 250GB 2.5" USB drive for extra storage and backups.

The Macbook was instantly loved at our house.  My 12 year old daughter now wants one, even though she has a Gateway dual-core X64 Windows laptop that she uses.  My 16 yr old son thinks it’s cool and likes Garage Band.  I like it, and I especially like having the Bash command-line and *NIX functionality at my fingertips without loading CygWin.  In fact, I’m totally in love with Mac OS-X for that reason.  Basing it on UNIX was brilliant.

Step 3 — Download the iPhone SDK and watch videos.

Downloading and installing the iPhone SDK was a breeze.  I also spent most of a day watching the iPhone tutorial videos on iTunes.  This is time well spent just to learn all the new terminology.

Step 4 — More Research.

One of the first applications I want to develop is a game where I’ll be employing some 3D graphics.  As I looked at OpenGL-ES and the rest of the SDK, it became apparent that the graphics SDK was pretty primitive (Cocoa has lots of the stuff you need for UI programming, but OpenGL is just a ‘C’ API and definitely needs some OO stuff around it.)  Before I tore off and re-invented the wheel, I did some research to see what others have done.  Here’s what I found:

  • OpenGL C++ Toolkit – A C++ library and toolkit for OpenGL.  Probably couldn’t be used "out of the box" but could probably be ported without too much trouble (if it hasn’t happened already).
  • Open Scene Graph – An Open Source scene graph SDK for OpenGL.  Looks very powerful and, again, could probably be ported in whole or in part.  Significant overkill for the applications I’m currently imagining.
  • Oolong iPhone Game Engine — Now we’re talking.  A 3D graphics toolkit over OpenGL ES, based on the PowerVR SDK , with the Bullet physics library integrated.  (Note that this effort is still pretty young, so there isn’t a lot of documentation with the kit, but it is usable.  Be sure to also download the PowerVR SDK for both the tools and documentation.)  The jury is out as to the performance of this beast on the device, but it is a great starting point.  I hope to contribute to the project over time.

With Oolong, I think I’ve found the giant I want to stand on.  I’d much rather contribute to an infant effort than re-invent the wheel.

Step 5 — Setup a web site.

This obviously doesn’t get us any closer to having an iPhone app, but Dean and I felt it important to get a blog, web site, and source code management system setup as early as possible.  We’re both most familiar with CVS (I’ve used it for over 15 years) but decided to go with Subversion for it’s features.  I can setup a CVS repository on a server in about 5 minutes.  Setting up Subversion took me a long time.  It seems to be working well, however, and we’ll see how things go long term.  We can always fall back to CVS if we need to.  If you need pointers on setting up Subversion on a Plesk managed server, maybe I can help.  It wasn’t as hard as I made it!  The XCode integration looks pretty good, and I dowloaded a trial copy of the SmartSVN client as well for it’s tag and branch features.

The web site is simple at this point.  We’ll be expanding it as we have applications to push and things to share.  This blog will be our primary means of communication.

Step 6 — Start coding.

Yeah!  Finally.  After some serious coding, I’ve decided I really like XCode.  I haven’t poked into everything yet, but I’m getting the hang of it and it’s working really well.  Most of the coding I’m doing right now is in C++ around OpenGL and Oolong.  Results are coming fast now, although I still have a whole lot to learn before I’ve got a complete application.

Next Step — Acquire a device.

Yep, haven’t done that yet.  Right now I’m running in the simulator which works pretty well but doesn’t give you the feel of the device at all, especially for accelerometer stuff.  Even the touch interactions are very different.  I’m particularly concerned about the performance of Oolong given all the floating point computations.  I should have a device (I’m starting with an iPod Touch) next weekend, and then I’ve got to pay my $99 and get the provisioning stuff together.

Lots to do, but I’m having a lot of fun!  Makes me feel young again.

paul

Comments are closed.