09 February 2009

Headphone Dilemma

Categories: , , , , , , , , , ,

Color me prejudiced. Apparently Quick Silver is a shining beacon -- or better yet, the shining beacon -- in the world of Mac users / geeks. Perhaps my being only a Hackintosh user / geek is reason for the lack of that certain X factor determinant of the aforementioned species. Or perhaps having another "Menulet" crowd my menubar is just purely disgusting to me. 

But for what its worth, I've to get used to Quick Silver cause it's what I'm gonna live with from now on if I want to be able to use headphones on my MacBook Wind.

You see, on the MSI Wind, the headphone jack is one of the things that don't play well with OS X. But the good news is that people obviously smarter than me (and thank God they are) have come up with this great workaround involving a script called "switch.sh".

You run the script to switch audio channel from speakers to headphones and vice versa. In a nutshell, it does the duty that plugging in or unplugging your pair of earbuds should accomplish automatically.

Normally this could be done via terminal but that would entail typing command lines which yours truly is bound to forget and which is an error prone process altogether. There's an option where you create the script as an app and then you give it a nice icon and then you run it every time you wanna switch. The problem is, the app actually sits in your dock. Not that I mind it taking space in there; I've already learned to live with the nuisance that is the Realtek WLAN Utility but that I'd had to click it as well. I prefer a keyboard shortcut -- for some reason my brain remembers those, probably from muscle memory mostly.

And guess what, Quick Silver makes it possible to do just that. Oh well, if this were an arranged marriage, I guess I'd have to play my part until the AppleHDA / VooDoo team at the msiwind.net forums releases the much awaited fix that would let us, avid MSI Wind hackintoshers, use the headphones in the usual no-script-just-plug-and-unplug way and also the internal mic.

Here's the guide (taken from msiwind.net forums) :

1) Download this package which contains the switch.sh script and CHUD, and download Quick Silver here
2) Unzip the package anywhere you want. Me, I saved it in my Downloads folder first.
3) Install CHUD and install Quick Silver.
4) Save the switch.sh script in /Users/your username/Library.
5) Launch Terminal and type this command lines:
    cd Library
    chmod 755 switch.sh

6) After exiting Terminal, launch Script Editor - it's in the AppleScript sub-folder in your Applications folder - but I just command + spacebar and start the app via Spotlight (which is easier in my opinion).
7) Type this:
    do shell script "Users/your username/Library/switch.sh" user name "your username" password "your password" with administrator privileges

It should look like something like this:


8) Hit the Compile button -- the one with the Hammer then go to the menubar: File > Save as and name your script. I followed what the original guide author did and named mine "HeadPhones". Put it in the "main" or "root" /Library/Scripts folder like so;
9) Launch Quick Silver
10) Now here is when I get too lazy to write so you follow the photo story:

You can just drag n' drop the actual script file in the box in Quick Silver



Click on the small (microscopic) gear icon to the right to access the drop menu from you select "Triggers"


Customize your trigger key by clicking on the line under "Trigger" column.


picture-4Click on Edit and the field should flash.
From thence you can type the key trigger combination you want. I made mine "alt + S" ("S" for switch :D)

Make sure that Quick Silver is launched at login. You can do this in Quick Silver: Preferences > check "Start at login" > uncheck: Warn before, Enable advanced, Show icon in dock, and Show icon in menu bar.

You can remove it in your dock by hold clicking on the app icon and then click on "Remove from Dock".

And from then on, you can happily just hit alt + S (or whatever your trigger is) to toggle from internal speakers in earphones :D

Spread The Love, Share Our Article

Related Posts