Oct 25

After some research I’ve settled on the FatSecret Platform API for the WebService I’m going to use. FatSecret is a webapp that does much of what I want to do on the desktop. In fact, it seems solid enough that a partnership in the future could be beneficial. However, until that magical day, I’m simply going to make use of their Food Database.

There are a couple bits of technology that I’ll be with here, REST (Cocoa libraries for it) and oauth. All REST requests are signed via oauth and provide the ability to store data on their server (they provide capabilities for tracking your food, exercise, etc). I won’t be making use of that functionality (possibly in the future), but even to gain access to the Food DB, I need to use oauth.

oauth was started by Blaine Cook and Chris Messina as a way to provide a mechanism to obtain secure data without having to provide information about their identity. Its intention is to allow access to multiple Web Services without logging into them all, but using a single oauth credential. Think Web Service Mashups.

So, I had two requirements to obtain some food data. I need to communicate with a Web Service via REST and authorize requests via oauth. After searching for my options, I came across MPOAuthConnection for Cocoa. I downloaded the project from Google Code and set off down the path.

Tagged with:
Oct 25

For a long time, I’ve been wanting to start a side project. Typically, this desire has led to Game ideas that never really got anywhere. So, I needed something that had an aspect that would drive me forward. Watching my wife go through her nightly routine of counting her calories, analyzing her meals for the day and her exercise/workout routine, it dawned on me. I started googling for Nutrition apps for monitoring these things and found that there weren’t a whole lot, and what was there was not terribly clean and a simpler way was needed. So, that is my goal. Write an app for my wife to keep track of her calorie intake and allow for advanced analysis when desired, but keeping the interface clean, simple and easy to use. Think Mint for Nutrition.

Additionally, I really want to write an application for the Mac OS X platform. I’ve been on a Mac for two years now, and really have enjoyed it. I’ve decided that it is something that I’ve wanted to delve into, and have lately been playing with iPhone development. With the introduction of Snow Leopard there are a number of technologies that I really want to look at that are not on the iPhone. Primarily, Grand Central Dispatch. Therefore, I made the decision to write this nutritional app for OS X and probably extend it with an iPhone App in the future.

So, her is the first public announcement of Celery. The Nutrition application for everyone. (I found it’s best to announce before a line of code has been written).

The requirements for Celery are few:

  • Make use of a solid Web API for obtaining Nutritional Information.
  • Create a clean and elegant UI for inputting daily values.
  • Provide a mechanism to graph historical data in an attractive manner.
  • Make something my wife wants to use.

I will be chronicling the development of Celery here, until completion or I quit in defeat (a public defeat will be bitter).

Tagged with:
Jul 05

Amazingly, Xcode comes built with a Unit Test suite and an Application Test suite. However, it took a bit of trying to fully understand how to set it up. The key element is adding a new Build Target.

XcodeScreenSnapz001

Set the new target as “Unit Test Bundle” and you’re done. Now, you can add new class files using the “Objective-C test case class” as the template and write Unit Tests. Now, make sure you set the only build target of this new class as the Unit Test target you created previously (that’s very important).

Now, when you want to run your unit tests, simple switch your build target and hit the build button.

XcodeScreenSnapz002

Tagged with:
Jul 03

One of the key elements for iPhone development is a machine running OS X. There are currently no development tools to allow iPhone development on any other operating system. I’ve been a fan of Apple’s computers for a couple years now and already had a MacBook Pro. Fortunately, this allowed me to get started relatively quickly and easily.

Where to buy? I recommend moving next to an Apple employee and getting a 25% discount. That’s what I did and it worked out well. However, that’s not terribly practical for most people. I have bought refurbished Macs before and have been very happy. You can easily save a couple hundred dollars.

FirefoxScreenSnapz005

The above is from the Refurbished Store as of the writing, and shows that they have the “latest and greatest” available. Apple provides fantastic support for refurbished machines, treating them as new. I highly recommend going this route.

Once, I had my machine, I found out that OS X loves memory. Its memory model will allow it to take advantage of all the memory you can physically put into the machine. I upgraded my Mac’s RAM to 4GB (purchased from newegg.com as Apple’s memory prices are absurd). After putting the new modules in, I noticed a marked speed improvement. Applications are much faster to load, switching between is very fast. My machine is now a year old, and I still feel like it’s a better machine than most brand new computers I come across.

FirefoxScreenSnapz004

Many people have reported being very happy buying a basic Mac Mini for iPhone development. This is certainly a cost effective way doing so, especially if you don’t plan on using a Mac for your basic computing needs.

Once you have the machine you want, update to the latest OS X version and install the Apple Developer Tools.

Tagged with:
Jul 02

Garage development is back. The days of two guys staying up late, hacking away at code with dreams of fortune and fame are back. No longer do you require a $50 million budget to make a AAA title that will scarcely make enough money to pay back the development costs. Enter the iPhone, our savior of development. Now, anybody can throw their hat in the ring and barely make enough money to pay back development costs. But, this time development costs are very low!

This blog will chronicle my journey down the development of simple iPhone applications. As I learn, I will log it here. Including setting up and educating myself on the tools, Obj-C, Cocoa Touch and anything else I find along the way.

Tagged with:
preload preload preload