Desk · 6 June 2013 · Ian Malpass

A dockable, switchable headset setup for the Apple Thunderbolt Display

I’m lucky enough to have an Apple Thunderbolt Display as my main screen, and I like it a great deal. I have the display wired to the local area network, and have assorted USB devices attached which would be a pain to connect and disconnect whenever I wanted to dock and undock the Air. With the Thunderbolt connector, I can dock the laptop with just one cable. (Well, two if you include the power cable.)

What the display lacks, though, is audio sockets. It has a built-in microphone and speakers, and they work very well, but since I work at home (complete with kids and dogs and other distractions) I sometimes want the isolation of my Bose QC15 headphones, which also have an optional in-line mic which is handy for video conferencing.

A reasonable person would just plug the QC15s into the audio socket on the Air. It has a TRRS socket which lets it work as a combined headphone output and mic input. Job done. But then I’d have to plug and unplug it every time I wanted to switch between speakers and headphones. I also don’t really want the headphone cable dangling around on the desk surface.

So, what can an unreasonable person do?

The first step is to add audio sockets to the display. The solution here isn’t anything terribly fancy: simply a USB sound card. The sound cards that are generally available tend to stick with separate output and input sockets. You can convert these to a single TRRS socket with a splitter adapter. While I was on, I got an extension cable so that I could make the headphone socket conveniently accessible under the front of my desk so I wouldn’t have the cable lying across the desk surface. This gives a nice, neat, hidden-cable solution to connecting your headset to the display (and really isn’t terribly unreasonable).

However, I want to be able to switch between the display audio and headphones easily. As it is, you have to option-click the speaker icon in MacOS to get access to your audio output and input devices, and then separately select the USB sound card (or display audio) for output and input. Worse, I have to reach for the mouse (which I try to avoid).

As one who uses the keyboard as much as possible, I’m an avid user of Alfred. One of Alfred’s features is the ability to trigger shell scripts and Applescripts by keyword. My first attempt involved switchaudio-osx, which provides command line access to the audio device settings, which I drove using a small shell script invoked from Alfred. Given the keyword “audio”, I could Cmd+space, type “audio” (actually, pretty quickly Alfred learned what I wanted and I only had to get as far as “a”), hit enter, and flip between my audio devices. Bliss.

But that solution was very much a product of my UNIXish tendencies, where the command line and shell scripts rule. With MacOS, you can script the audio device selection using Applescript. I love the power of Applescript, but I don’t think I’ll ever love the language. Still, with enough Googling and trial-and-error (and profanity) I can work out enough to be dangerous, and finally I have a solution which works without having to install external dependencies.

I have achieved audio nirvana. At least for now.