SpinClock: My First iPhone App!
Not the first one I’ve downloaded. No, the first one I’ve
written! It’s on sale now in Apple’s App Store, and is the only
search hit for “SpinClock”, at least at present. It’s also a
big reason why this blog hasn’t been updated recently, since I was giving
the project all of my spare time since Christmas.
I’ve been programming professionally for about 20 years, and
I’ve done a little Mac OS X programming on my own Mac at home, using
Objective-C and Cocoa. So I expected that picking up the iPhone OS and Cocoa
Touch would be pretty simple, but the learning curve was steeper than I
expected. Apple has changed or removed some of the higher-level 2-D drawing APIs
(Application Programmer Interfaces) that I had been using, and there were new
animation APIs and conventions that I didn’t yet know (although I would
have, I think, if I’d been programming for Leopard rather than
Tiger).
There was also a lot to learn and set up regarding the
development environment, particularly the code signing and device provisioning.
Apple protects the iPhone platform pretty tightly, and I can see why: a rogue
application that was able to spread itself from phone to phone would ruin the
phone’s reputation. As a result, they use public-key encryption and
digital signatures to ensure that they know and have approved every developer
and every development device in the process. This doesn’t make the
development cycle itself any more difficult, but it did mean some new
prerequisites, like requesting electronic certificates from Apple which Xcode
needs to use so it can sign my app every time it builds it.
It also
turned out that my credit union account was insufficient for use as a developer
of a paid app, because it can’t easily accept wire transfers, so I needed
to set up a “sole proprietor” business account with a real
bank.
It’s been quite an adventure getting started on the
iPhone. Now that I’ve been all the way through the cycle (including making
one sale to Spain!), I’m looking forward to rolling out more apps this
year, and updates to SpinClock.
Posted: Sun - January 18, 2009 at 08:41 AM