Saturday, September 4, 2010

Tech Used in Documenting My Mt. Washington Hike

A couple of weeks ago my girlfriend and I hiked Mt. Washington (in New Hampshire) for the first time. I have to say that the hike was 10X harder than I expected but 10X cooler and prettier than I expected. It took us 7 hours to get up and down the mountain and at certain points involved crawling over huge boulders on all fours. It was no joke! The temperature was 80 degrees at the base and 30 at the summit.

Not too long before the trip I received my iPhone 4 and knew I wanted to use it to document the hike. The iPhone 4 camera is much improved over the last generation and actually supports capturing 1080p HD videos. It can also run Apple's new iMovie for iPhone app that supposedly makes it easy to create and share movies right from the device.

The first problem I knew I had to solve upfront was battery life. As you probably know the iPhone battery drains quickly and Apple designed it to be non-removable so you can't carry a charged spare battery even if you wanted to. I ended up buying a Kensington Travel Battery Pack and Charger which is the next best thing. At $70 it is far from cheap but it worked well and kept my phone charging in my backpack for the entire trip.

Over the course of the weekend I took well over a hundred pictures and a handful of short videos. The day we got back I went to work. The first thing I did was purchase a mushy love song I thought my girlfriend would like. I bought Hey Soul Sister by Train for 99 cents on iTunes right from my phone (OK fine, I like the song too).

Next I started a new project in iMovie for iPhone but immediately realized it wasn't going to work. It doesn't let you import more than one picture at a time and it takes a few seconds per picture to import. It would have taken far too long with the number of pictures I had. Instead I moved to the desktop version of iMovie which proved much more efficient. It ended up taking me a few hours to create and edit the movie to my liking.

Once it was done I needed to share it and YouTube is the obvious place for video sharing right? I went to upload the video and it quickly became apparent that I had a new problem. YouTube was asking me if I had permission from all copyright owners to publish this video. Until then I hadn't given much thought to the fact that I was embedding high quality audio from one of the top songs on the charts. I was seriously conflicted about what to do here. I spent so much time working on the video and only a few friends would be watching it but clearly I didn't have the copyright permission from Train. After thinking about it for a while I decided to just go for it and see what happens next. After uploading the video YouTube notified me that it auto detected copyrighted material and knew the exact song name and artist. It then told me that it was actually OK for me to publish because YouTube and the content owner, in this case Sony music, had a deal in place. My video would be shown (in most countries) but it would have a small advertisement below it. The ad would identify the song name and artist and include a link to purchase it.

Awesome!

I believe this was the first time I've every been pleasantly surprised by anything related to copyright issues. Thank you YouTube, Sony, and Train!

If you are interested in seeing my directorial debut, check out the HD version of the video here as the embed below is getting cut off by Blogger. You may also want to change the video quality option from 360p to 720p. I changed my YouTube settings to "Always play HD when switching to fullscreen (when available)" so it always chooses this option when available.


Toy Car

Last night I came across a car parked in my neighborhood that was covered with hundreds of plastic toys. Pretty much every person that walked took one or more pictures. Check these out:







Sunday, July 25, 2010

Benefiting From Your Credit Card

Credit card debt is a huge problem for millions of Americans. Some put the blame for this on the credit card companies and their "deceptive business practices." I would certainly agree that the credit card companies do some pretty shady stuff and should be better regulated but I more strongly believe in personal responsibility. It wasn't the credit card company that made you buy that flat screen TV now was it?

I know about this all too well because starting in college and for a few years after graduation I carried far too much debt. It all began when I charged my first major purchase for $2300. It was a Dell computer with a 233 MHz processor and a 3.2GB hard drive (worse specs than my current cell phone). I spent years paying off that thing. Back then the only attribute of a credit card that I was (properly) concerned with was interest rate.

I am happy to report that I have long ago paid these cards off and now use them for convenience purposes only.

If you have no debt and pay your cards off each month than, contrary to most people, you are in an excellent position to really benefit from credit cards. There are hundreds if not thousands of different cards out there with a wide range of benefits. Choosing the right one depends on matching up your personal spending habits (e.g. do you buy mostly gas & groceries?) with cards that reward those habits with what you want (e.g. travel discounts?).

Over the last few weeks I decided to finally investigate a good rewards card for myself. After quite a bit of research I ultimately decided to go with the American Express Blue Cash card. Below are some of the benefits of the card and reasons I choose it.

  • Earn cash back
    • It has a very simple cash back reward program. Many rewards cards are "point" based which require you to redeem the points at specific locations. With this card you just earn straight up cash back at rates of between .5% and 5% depending on the type of purchase and how much you use the card.
    • The reward is given as an automatic cash credit to your account once a year. Other cards I found make you jump through hoops (call and request) the reward or issue you gift cards instead of cash.
    • NOTE: You can earn these cash back rewards by paying your recurring bills (gym membership, phone bills, etc..) with American Express Automatic Bill Pay.
  • No annual fee
    • Many other cash back cards (and many other AMEX cards) have an annual fee but this one does not.
  • Purchase Protection on your purchases
    • Covers theft or damage (whether by accident or vandalism) of your purchases for up 90 days.
    • NOTE: Pays up to $1000 per incident with a $50,000 maximum per calendar year.
  • Extended warranty on your purchases
    • Extends the length of the original manufacturer's warranty on purchases by up to one additional year. So no need to buy one year extended warranties from places like BestBuy.
    • NOTE: Pays up to $10,000 per item with a $50,000 maximum per calendar year.
  • Return protection on your purchases
    • If a store won't take an item back within 90 days of purchase AMEX will refund you the full purchase price.
    • NOTE: Pays up to $300 per item with a $1000 maximum per calendar year.
  • Car rental insurance
  • Roadside assistance
  • Global assist hotline
    • Provides 24/7 emergency medical, legal, and financial assistance, and more, when you're more than 100 miles away from home.

It is very important to realize though that these cards usually have a much higher interest rate than you could otherwise get so if you don't pay them off in full each month the benefits you may earn will be completely outweighed by the interest rate payments you make. So don't bother with these cards until you can pay them off in full each month.

P.S. I want to thank American Express for sponsoring my blog this week. Just kidding. I did all this research and figured I'd share what I found with everyone.

Saturday, July 17, 2010

Managing Multiple Installations of Xcode

If you are developing for the iPhone you will quickly discover the need to support multiple installations of Xcode. The most common case is when you want to install the latest "beta" SDK to try out the hot new features while maintaining the latest "official" SDK for production purposes.

Supporting side by side installations is relatively simple but may not be immediately obvious if you haven't done it before. Several screens into the Xcode installation wizard, on the "Installation Type" page, there is a subtle drop down dialog for Location that lets you choose where to install. The default is /Developer but you can change it to what ever you like.

Many developers choose to always install the latest official release in the default location /Developer and the latest beta release in something such as /DeveloperBeta. Each time a new version is put out they upgrade the appropriate one.

I started out doing it this way but occasionally found it limiting to not have the older SDKs:

  1. Can't rebuild an old release of your product that was made with an old SDK
  2. Can't test using an old version of the simulator
  3. Can't compare differences in behavior between older SDKs / simulators
  4. Apple may release a broken SDK or you may not realize the consequences of upgrading the SDK. That may result in you needing to spend time uninstalling the new and reinstalling the old.
Starting tonight I'm trying out a new installation scheme. I'm now installing each new version (whether it is release or beta) to /iSDKs/[version_number]/ and simply ignoring the default /Developer location.

One point worth noting is that it turns out not all of the developer tools get placed in the location you choose! The fine print of the installer says that "System Tools" and "Unix Development" can only be installed once and are always installed to /Developer and the boot volume.

One important implication of this is that when you uninstall the version at /Developer you may also remove the single installations of "System Tools" and "Unix Development" which could cause problems with your other installations or build scripts. This is exactly what I did tonight and immediately discovered that version control in the other Xcode installs broke because it couldn't find cvs.

The main take away from this is that if you go down this route the order you install / uninstall can be important. I recommend:
  1. uninstall your current installations first (especially the one at /Developer)
  2. install each version one at a time proceeding from the oldest to the newest
P.S. The way to uninstall an XCode install is:
sudo [xcode-install-dir]/Library/uninstall-devtools --mode=all

UPDATE:
If you use macports you will need to update the "developer_dir" setting in macports.conf (usually /opt/local/etc/macports/macports.conf) to point to the version it should use. I set it to /DeveloperCurrent and created a symlink there to point to the most recent release version.

Thursday, July 8, 2010

Remove Interface Builder from the iPhone Project Templates

I find it frustrating that the XCode iPhone project templates are set up to use Interface Builder. Here are the steps to remove Interface Builder from the project templates:

  • Create a project using a template
  • Delete the .xib files from the project
  • In the .plist file, delete the "Main nib file base name*" properties
  • In main.m, pass the name of your Application Delegate class to the UIApplicationMain() function as the forth argument
  • Remove the IBOutlet keywords on the properties
  • Update application:didFinishLaunchingWithOptions: to create / initialize the application window

Wednesday, July 7, 2010

Bluetooth Not Available on Macbook Pro

This week Bluetooth stopped working on my MacBook Pro. Clicking on the Bluetooth icon revealed the message "Bluetooth Not Available". Resetting the System Management Controller (SMC) did the trick.

How you do this depends on your model. The instructions for mine, a MacBook Pro (Mid 2009), are as follows:

  1. Shut down the computer.
  2. Plug in the MagSafe power adapter to a power source, connecting it to the Mac if its not already connected.
  3. On the built-in keyboard, press the (left side) Shift-Control-Option keys and the power button at the same time.
  4. Release all the keys and the power button at the same time.
  5. Press the power button to turn on the computer. Note: The LED on the MagSafe power adapter does not change states or temporarily turn-off when you reset the SMC.

Tuesday, June 29, 2010

Sending Messages to nil is Not Always Safe

I've been under the impression that in Objective-C sending messages to nil was always safe but learned recently that it is not always the case and wanted to share.

The conventional Objective-C wisdom says that sending messages to nil is safe (it acts as a noop) and returns nil for object return values and 0 or zero filled structs for scalar or struct return values.

As it turns out some scalars / structs will not be zeroed out which means they will contain random data.

The language Apple uses in their docs say that scalars are guaranteed to be zero only if the size of the return type is "less than or equal to sizeof(void*)" or the returned struct is "to be returned in registers" as "defined by the Mac OS X ABI Function Call Guide".

CGRect is an example of one that does not meet this criteria. As an example the following code:

UIViewController *viewController = nil;
UIView *view = [viewController view];
CGRect frame = [view frame];
NSLog(@"frame=%@", NSStringFromCGRect(frame));
will print out something like this:
frame={{1.6584e-37, -1.99876}, {6.19141e-39, 6.05479e-37}}
Long story short, take care when calling methods that return scalars / structs if the object you are messaging could be nil.

A good blog post on the topic is here:
http://vgable.com/blog/2008/05/31/messages-to-nowhere

In it he points out that the behavior can vary by platform / processor so what happens on the iPhone simulator may not be what happens on the actual device.

Saturday, June 19, 2010

Don't Draw At Fractional Pixel Locations

In the Objective-C Cocoa and Cocoa Touch APIs positions and sizes of UI elements are specified in terms of CGFloats but as I recently discovered problems can occur if you use non-integral values.

One symptom you may find is that with anti-aliasing on the text of a UILabel will appear blurry if the position is set with a fractional value.

The function CGRectIntegral() can help with this.

Saturday, May 29, 2010

Objective-C Multi-Threaded Gotcha

Last week I ran into a curious crashing bug in Objective-C. The main class I was working with, call it Foo, simply needed to perform a long running operation in a background thread. Should be pretty simple right? The basic outline of the code looked like this:


@implementation Foo

- (id) init {
self = [super init];
if (self) {
// allocate members
}
return self;
}

- (void) dealloc {
// release members
[super dealloc];
}

- (void) createAndStartBackgroundThreadTodoStuff {
[self performSelectorInBackground:@selector(doStuff)
withObject:nil];
}

- (void) doStuff {
// do stuff
}

@end

The intention here is that all of the above methods should run on the main thread except the one responsible for performing the background task [Foo doStuff]. In this way I should only need to worry about thread safety issues related to [Foo doStuff].

As it turns out two of the above methods can get called in a background thread: [Foo doStuff] and [Foo dealloc].

[Foo dealloc] can be called because the performSelector* family of methods retain the receiver (self) and release it when the method invocation completes. If the autorelease pool on the background thread ends up with the last reference to the object then dealloc gets called there.

So why the crash? Well one of my member variables was not thread safe (UIWebView) and crashed when release was called from a background thread.

Memory management and multi-threading are probably the hardest aspects of programming to get right. It is even harder to get right when the issues overlap.

Sunday, April 18, 2010

Copy & Paste in Mac OS X Without Formatting

A while back I posted a link to a nice Windows tool called PureText that lets you copy and paste without all the formatting. Very useful but I have since moved to a Mac and it is not available on that platform. Today I found a solution and figured I would share.

Step 1 - Install Spark or some other application that lets you assign a global keyboard shortcut to run an AppleScript.

Step 2 - Create a new shortcut key that is assigned to the following AppleScript:


do shell script "sleep .5"
tell application "System Events"
set the clipboard to (the clipboard as text)
keystroke "v" using command down
end tell


It is a bit of a kludge and doesn't work everywhere by mostly gets the job done. Let me know if you have a better solution.

Friday, March 19, 2010

Help Somerville Get on Google's High Speed Network

Just got the following email from City of Somerville. If you live in Somerville, MA read the below and help get us on Google's high speed network:

HELP SOMERVILLE WIN THE OPPORTUNITY TO PILOT GOOGLE’S HIGH-SPEED NETWORK! The City of Somerville is seeking the opportunity to be included as a trial area for Google’s ultra-high speed network and we need your help! The network, said by Google to "deliver Internet speeds more than 100 times faster than what most Americans have access to today," will be offered at a competitive price to a small number of trial locations across the country. Along with the City submitting a Request For Information (RFI), Google is asking local residents to express their interest in a trial in their community. Your support will strengthen Somerville’s case to be included in the pilot. Please help make a case for Somerville by submitting a nomination online here: http://www.google.com/appserve/fiberrfi/public/options


fb

Saturday, March 13, 2010

On Google Buzz

Google Buzz has been out for several weeks now but only recently did I have the time to check it out.

My initial opinion is that right now (for me) it is a mostly redundant system that doesn't provide much value. Most of what I see on Buzz are just Twitter and Reader updates. The problem is that you can only see a small subset of what you see on Twitter and Reader (updates from Buzz users). That means you still need to use a full Twitter client and Reader which makes most of the content on Buzz just duplicates.

A big improvement would be to make Buzz a full Twitter and RSS clients so that I can view everything from just it. Until that can be supported I'd like to see an option in Buzz that lets me disable certain types of data (Twitter updates for example) so I don't have to see it twice.

One very nice benefit though is that non-twitter and non-reader users on GMail are now "joining the conversation" and seeing your updates which is very cool.

Friday, March 5, 2010

Going to Work at Kayak.com


I have really been enjoying my time off the past several weeks. I've been reading some good books, watching some good TV, spending quality time with my girlfriend, and trying to improve my overall health (running and eating much better). But I'm ready to return to real life now and ready to begin earning a paycheck again! I'm happy to let everyone know that I have officially accepted an offer to join Kayak.com, the best travel search site out there, and I start this Monday. Initially I will be with their mobile team working on their iPhone products. Very excited.

If you are like me then you have probably never heard of Kayak.com before. I'm told that brand awareness is their number one challenge right now and improving it is their top priority for the year. If you haven't heard of them yet you should soon. The good news is that they are already doing extremely well and the people who know them love them. Before booking your next flight or hotel room, check them out.

When I began my job search I had one specific kind of company in mind and kayak.com definitely doesn't fit the model I was looking for. After meeting with a number of companies and talking to a few mentors I decided to broaden the type of company I was willing to consider. I'm really glad I did that. If you are currently looking I urge you to do the same thing. There are lots of different companies out there. They will all offer different benefits and a unique experience. Why limit your opportunities? Talk to everyone. You might get surprised and find something you were not looking for.

Thank you to everyone who helped me out over the past several weeks. I really appreciate the emails, advice, job forwards, and references. Thank you so much.

Time to go write some software and pay some taxes.

Tuesday, February 2, 2010

Lesson #2 - Consider Hosted Software Development Tools

This is my second post (the first is here) in my series on Lessons Learned from Zeemote.

In 2006 I was the first software engineer hired at Zeemote (a now defunct company) and at the time we still didn't even know what our product was going to be. We had a few hundred lines of demo code (written mostly by an outside contractor) and we had no bug database or version control in place. The closest thing to version control was zip files stored in email attachments.

Like many small companies we used an outside IT firm to manage our network and computers. Unfortunately as time progressed some in our company lost confidence with the firm and they were replaced. This became a recurring problem and during my time at Zeemote I witnessed 4 or 5 IT firms get hired and fired (a discussion I'll save for a future post).

One consequence of the above was that our developer tools (subversion and bugzilla) were being maintained by our software engineers rather than the IT "company of the month". Maintained is too generous a word though. As we grew and became increasingly busy and stressed out we had little time to really care for these tools. I don't think we ever made a single version upgrade and only occasionally checked that backups were functioning properly. I began to lose sleep over the situation.

Soon another problem presented itself. As we rushed to develop and test our second software product we contracted with two outside resources. One was a development house in London and the other was a testing house in Pennsylvania. We were suddenly becoming a global distributed software development company! But to use these guys we needed to provide remote access to our internal version control and bug database. This would require the IT "company of the month" to set up VPN and making sure that they only had access to what they needed. Given our experiences with IT this was going to take too long and the results were going to be error prone.

After a few intermediate steps we ended up with, what I regarded as, a great solution: hosted software development tools.

Over the past decade nearly all software products have been moving to the cloud. As it turns out, software development tools are following this trend too and several companies now offer hosted version control and bug tracking. These companies host and manage the software on their servers. They provide encrypted remote access to the tools and also a web based interface for simple administration tasks.

They handle the hardware and software maintenance issues (backups, upgrades, uptime) and you focus on your core work.

After some deep thought I came upon with the following minimum requirements that any service provider should meet in order to be considered:

  1. Must allow automated downloads of nightly backups to our servers. This protects us in case the provider goes out of business or has a catastrophic failure.
  2. Must use an open / standard data format. This prevents vendor lock in and allows us to easily switch providers if we become unhappy with them or they go out of business.
  3. Must provide a basic NDA or terms of use policy that clearly states the data is ours and reasonable steps will be taken to protect it. This is to minimally satisfy the IP folks and investors in the company.
  4. Must be within our (modest) software budget. Affordability is always a requirement.
  5. Must speak with us on the telephone and instill confidence. Anyone can set up a website these days. Talk to a real person before choosing a provider. A serious company will be happy to give you a demo and answer any questions or address any concerns you may have. After speaking with one company we ran for the hills as it became clear the "company" was just two college kids with precious little experience.
As we moved forward I faced very strong opposition against my plan to outsource these tools. I was surprised to find that my strongest opposition came from within my own software group! In retrospect I shouldn't have been surprised since they would be the ones using the tools so it would impact them the most. Some developers worried about the potential of poor performance or downtime while others simply struggled with the notion of giving another company "control" over our tools and data.

The concern about poor performance or downtime could be mitigated (at least partially) in two ways. The first was that if performance or downtime did become a problem we could always switch providers because of requirements #1 and #2. Also one of the tools we hoped to use, subversion, is explicitly designed to work "offline" anyway. In most circumstances when a subversion server is inaccessible, one can simply continue working and sync back later.

The second concern about losing "control" of our tools and data was, I think in our situation, more of a mental road bump. It was a bump that I initially struggled with this too but eventually got over.

Requirements #1, #2, and #3 show that we would be the ones who maintained ownership and real ultimate control. Sure we would be allowing another company (a partner) to have access to our code but that is a fact of life for most software companies. If you don't want anyone outside your company to have seen your code then:
  1. don't form any tight development partnerships
  2. don't hire any contractors
  3. don't fire anyone
  4. don't let anyone quit or retire
Another mental road block that software developers seem to have is in thinking that code is the company's "crown jewels". We need to get over ourselves! Of course code is really important but it is just one part of your business. Had our source code been accidentally (or purposely) leaked it is exceedingly unlikely that another "joystick for cell phones" company would have emerged or that any real damage would have occurred to our business. In fact releasing the source code probably would have had a net positive impact on our business rather than a negative one.

So sure it wasn't perfect (few solutions are) but we had to move very quickly and what we were doing wasn't sustainable. Having software engineers worry about maintaining servers and backups isn't productive or efficient. In balance outsourcing these tools was a no brainer.

While I faced internal opposition a new CEO joined the company and (luckily for me) he was open minded, willing to hear me out and gave me great support.

After searching we went with Codesion.com (formerly CVSDude.com). For an extremely cheap price they provided terrific service for us. While we did have a few outages and a few performance problems they were all quickly corrected. Overall it worked out great and I highly recommend them.

The lesson learned here is that hosted development tools can provide a great option for many software companies and should be strongly considered when building your development team's infrastructure.

I'm very proud to say that at Zeemote, Inc. we never lost of single line of code or piece of change history since the first week I joined the company.

Thursday, January 28, 2010

Managing Status on Facebook, Twitter, and LinkedIn

I was asked today how I manage and post status updates to the various social networking sites I use. I figured I'd put my answer here in case anyone else might find it useful.

The three major social tools I use are:

  • Twitter - used to share links & short thoughts "publicly". I mostly use Twitter for professional purposes which for me means mostly technical & business related stuff. I keep this network public.
  • Facebook - used to keep in touch with friends and family. I try not to post much tech/business stuff here since most of my Facebook friends aren't interested! Instead, on Facebook, I post more personal stuff or more "pop culture" type stuff. I keep this network private.
  • LinkedIn - used for professional and networking purposes only.
Occasionally I want to post one status update to multiple (or all) of these networks. For example at the moment I am looking for a new job and figure I should talk to anyone who will listen! To easily post to multiple networks you can do the following:
  1. On Facebook install and configure the Selective Tweets Facebook application. It will monitor your Twitter feed and update your Facebook status with your tweet IF it includes #fb.
  2. On LinkedIn install and configure the Tweets LinkedIn application. It will monitor your Twitter feed and update your LinkedIn status with your tweet IF it includes #in.
  3. Post an update to Twitter and include #fb and/or #in accordingly.

Friday, January 22, 2010

Personality Ethic vs Character Ethic

Prior to writing The Seven Habits of Highly Effective People the author Stephen Covey reviewed much of the "success literature" (i.e. self help books) written in the the United States since 1776. He found that after World War I the focus of these writings generally changed in what they taught to be the foundation for achieving success.

In the most recent 50 years success, we have been taught, is primarily a function of what he calls "Personality Ethics". Some quotes:

Success became more a more a function of personality, of public image, of attitudes and behaviors, skills and techniques, that lubricate the process of human interaction.

This Personality Ethic took two paths: one was human and public relations techniques, and the other was positive mental attitude (PMA) ... expressed in inspiring and sometimes valid maxims such as "Your attitude determines your altitude,"

Other parts of the personality approach were clearly manipulative, even deceptive, encouraging people to use techniques to get other people to like them, or to fake interest in the hobbies of others to get out of them what they wanted, or to use the "power look," or to intimidate their way through life.
This differs from what the first 150 years of literature focused on which is something he refers to as "Character Ethic."
things like integrity, humility, fidelity, temperance, courage, justice, patience, industry, simplicity, modesty, and the Golden Rule.
Covey admits that while parts of Personality Ethic are important and in many circumstances critical--things like communication and presentations skills--these skills are at best secondary. To truly sustain long tern success one must focus first and foremost on Character Ethic. It is primary.

A great example he gives is with respect to trust. Everyone can agree that trust is a critical element for success in business, family, and friendships. While Personality Ethic suggests communication techniques / tricks to gain trust, Character Ethic says to just be trustworthy.
If I try to use human influence strategies and tactics of how to get other people to do what I want, to work better, to be more motivated, to like me and each other--while my character is fundamentally flawed, marked by duplicity and insincerity--then, in the long run, I cannot be successful. My duplicity will breed distrust, and everything I do--even using so-called good human relations techniques--will be perceived as manipulative.
and conversely
There are people we trust absolutely because we know their character. Whether they're eloquent or not, whether they have the human relations techniques or not, we trust them, and we work successfully with them.
This resonates with me because at heart I'm in idealist and always like to think that "the good guy" always wins in the end. It is nice therefore to read something that makes sense and reinforces that belief. It also helps because I think I lack some of those Personality Ethic skills!

Funny, as I read about the approaches two specific people stick out in my mind. One who excels in Personality Ethic and one who excels in Character Ethic. How about you?

Seven Habits of Highly Effective People


Sometime last year I was looking for new business books to read. I talked to mentors and colleagues and searched the web to discover that the The Seven Habits of Highly Effective People was in almost everyone's recommendation list. First published in 1989 it is already widely regarded as a classic. I went ahead and ordered it without reviewing what it was all about and without even carefully reading the cover. Last week on a plane trip between Tampa and Boston I finally opened it and began.

I've only read two chapters so far but it is clear to me that this is not a "business book" in the traditional sense or at least what I think of as a traditional business book. It would be much better described as a "self help" or "personal change" book and to be honest, had I known that in advance, I probably wouldn't have bought it.

Thus far the book resonates very deeply with me. It reinforces some of my core believes but introduces some new and powerful ideas and concepts. It also helps that the core of the book's message appears to address what I know to be among of my largest and quite serious flaws which is that of balance. Most of my current, or in some cases former, colleagues, friends, family, and girlfriend(s) can attest to this weakness.

The author Stephen R. Covey suggests the following:

I would suggest that you shift your paradigm of your own involvement in this material from the role of learner to that of teacher. Take an inside-out approach, and read with the purpose in mind of sharing or discussing what you learn with someone else within 48 hours after you learn it.
I think this is a great suggestion for this or any non-fiction book. Taking notes and discussing what you read will multiply by several times what you soak in. Coincidentally this also happens to be a great marketing technique to spread work of the book but I will avoid being cynical! I have decided to take up Stephen's suggestion and discuss some of the ideas & concepts that I learn and find interesting here on my blog. I may also post noteworthy quotes to twitter . If you have read the book or have something to add I would love to hear from you. This may take some time since another weakness of mine is slow reading.

Thursday, January 7, 2010

A Theory: Why the iPhone doesn't allow background applications

The lack of support for background applications on the iPhone drives me crazy since it prevents a number of very useful apps from being deployed on it. The one I miss most from my BlackBerry is Google Talk for instant messaging. Today I was thinking about why Apple would disallow a basic feature that every other modern OS supports. I can think of two complementary reasons.

The first has to do with user interface. Most users don't understand the very concept of "background applications". I'm not sure I've ever seen a really great UI for managing running processes on a desktop OS let alone a mobile one. Since most applications don't need the feature anyway my guess is that Apple just punted on it.

The second reason is more technical. Currently the iPhone only supports application development using Objective-C. More notable is that it is Objective-C without garbage collection. This means that each developer is responsible for his or her own memory management. All but the most egotistical of developers would admit that managing memory is a difficult problem and most of us do a bad job at it. If allowed on the iPhone many of our poorly written applications would run in the background eating away at the memory and slowing the phone down until the frustrated user reboots it. Foreground-only applications means that won't happen since the application will be destroyed after just a few seconds or minutes. As a result I suspect that most iPhone developers do little to no memory management what so ever.

iPhone OS will have to support background applications eventually and my prediction is that it will arrive on the same day that garbage collection does.