Archive for March, 2006

ADC Core Data Video Tutorial

See here for details on a new tutorial on Core Data.

In the vein of Ruby on Rails style video presentations, you can download the narrated video (38Mb) and learn very quickly how to put together a Core Data application.

Note: for the bandwidth challenged, it is broken down into smaller pieces on the ADC site.

As someone who is largely self taught on the Cocoa side of things, it was instructive to watch another developer at work with Apple’s tools. Aside from learning about Core Data, I learnt some productivity improvements for using Interface Builder and XCode.

If you are writing Cocoa apps, this is well worth a watch!

Elementary Bluetooth using PyObjC

Bluetooth connectivity to devices is supported on Mac OS X using Cocoa APIs, so is possible to access from Python. Bluetooth itself opens up a large body of knowledge that I am only starting to investigate.

This article outlines some basics for using Bluetooth in Python.

Bluetooth access is achieved through two frameworks, IOBluetooth and IOBluetoothUI. Neither of these are included in PyObjC by default, so a basic wrapper class makes life easier. (see the PyObjC docs)

Add the following to IOBluetooth.py:


import objc as _objc

_objc.loadBundle('IOBluetooth', globals(),
  bundle_path=u'/System/Library/Frameworks/IOBluetooth.framework')

The loadBundle pattern is very useful, and allows the classes from any Objective C framework to be loaded into the PyObjC bridge. By putting it into a separate Python module, usage becomes less painful.

For example, the most recent device is:


>>> from IOBluetooth import *
>>> devs = IOBluetoothDevice.recentDevices_(1)
>>> devs[0].getNameOrAddress()
u'gmwils 6600'
>>> devs[0].isConnected()
1
>>>

In this case, my Nokia 6600 is still connected in AddressBook.

To create a new connection to a device, Apple provides access to their user interface for Bluetooth management. It is strongly recommended that these controls are used to provide consistency for the user and detailed error handling.

For example, selecting a service from a device with a dialog:


>>> from IOBluetoothUI import *
>>> browser = IOBluetoothServiceBrowserController.serviceBrowserController_(0)
>>> browser.runModal()
-1000
>>> results = browser.getResults()
>>> results[0].getServiceName()
u'Bluetooth Serial Port'
>>>

Note: you will need a IOBluetoothUI wrapper, similar to the IOBluetooth wrapper from earlier.

Useful documentation links:

Disruptive Changes

I recently joined a rather innovative gym. They don’t have many weight machines or bikes or walking contraptions, instead they have four large, relatively empty rooms. For the use of this empty space, I happily pay around $30 a week.

Conveniently located at the end of my street, the Pure Health club lured me in with a simple sign saying Yoga. They offer an all you can eat range of classes, including Pilates, Yoga, Tai Chi and others. Given that they haven’t spent the money on machines I have no intention of using, the weekly fee is more than reasonable.

The concept I noticed was how they simplified the stereotypical gym, accessing a slightly different audience.

This is a process I’ve been paying attention to recently. Ponder Google’s successes: a simpler search, a simpler mail client. The pattern is also being repeated in a number of Web 2.0 companies. Everything from simpler project management to simpler word processors.

By simplifying the offering a different set of values is emphasized, potentially entering a new or larger market. This ends up being close to the central thesis of The Innovator’s Dilemma, a book I’m currently reading. The author makes the case for disruptive changes causing existing companies to fail - new companies access new markets and evolve to take over the original core market. Examples range from disk drives to earth movers.

I’m not sure the gym scenario counts as disruptive, but between the simplification of complex offerings and disruptive changes there exist a realm of possibilities for new companies.

Have you noticed anywhere else undergoing or needing disruptive change?

9cays - group email made easy

Friends have launched the beta of their email based web app, 9cays. The basic premise is that you CC a special email address and then get a plethora of added features for a conversation, such as online archive, RSS feeds, and the ability to add new participants. (see example)

It is somewhat similar to a (almost) zero configuration Yahoo Group.

I’m in agreement that email is in dire need of innovation, and the people behind 9cays are some of the smartest I know. Their service definitely makes group email, and group organisation, easier.

However, I’m not convinced that email itself is the way to progress. I find that I’m using email less and less. My main form of receiving information is via RSS, be that news, information, or the fact that one of my friends needs help to build a house.

In terms of sending information out, I tend to use instant messaging where possible, and SMS if not. Email is something I use for people who haven’t moved on.

At work, one of my teams moved from email, to email lists, to a wiki, to internal blogs. Everyone is now subscribed to each other’s internal blog and we are using it as a collective information store. There is definitely a problem with information management, and as yet no solution. (thingamy notwithstanding)

My thinking is that RSS management needs to become easier. Notification of things that are important to me among hundreds of feeds needs work. I’m not sure what is missing yet, but there is something, and it has to do with priority and context.

9cays are making a start, and in their usual manner have built a large platform behind the scenes. What is visible is merely the tip of the iceberg. I’m watching with interest to see what emerges next.

Help creating Apple Help

Useful article (via Usable Help) about creating online help for your Mac OS X application, including how to integrate context sensitive help buttons.

Also includes links to some templates (MIT license) to get you started.