Pick of the Week - Nov 10 [Show all picks]
Path Finder 5 - A feature-laden Finder replacement
Submit Hint Search The Forums LinksStatsPollsFAQHeadlinesRSS
12,000 hints and counting!

Choose an audio input device based on sound levels System
I frequently record Keynote presentations I give using my Mac (using ProfCast). Typically I use a wireless lapel mic and have my sound preferences pane set to record from Line In. However, on occasion I forget to turn on my mic, or the battery is dead, and so I get nothing but silence. In these instances, I'd like to be able to use my PowerBook's internal mic as a backup, so I set about finding a method using AppleScript to accomplish this.

I eventually got something working with the help of a freeware program called AudioLeak that monitors the RMS sound level of the selected input source. Together with a little GUI scripting, I can have my Mac try to connect to Line In, but switch to the internal mic if the line is dead. Here's the final script.

I have this script embedded in a droplet, so that I drag a Keynote file onto the droplet and it runs this script along with some other stuff I want to do just before starting a presentation (i.e. check monitor resolution, hide all other apps, etc), and then launch the file in Keynote. Alternatively, you could have this script run periodically using iCal or cron or an idle handler.

In addition to AudioLeak, you'll need to have GUI scripting enabled (in System Preferences » Universal Access).

[robg adds: I haven't tested this one.]
    •    
  • Currently 0.00 / 5
  • 1
  • 2
  • 3
  • 4
  • 5
  (0 votes cast)
 
[5,477 views]  

Choose an audio input device based on sound levels | 1 comments | Create New Account
Click here to return to the 'Choose an audio input device based on sound levels' hint
The following comments are owned by whomever posted them. This site is not responsible for what they say.
Choose an audio input device based on sound levels
Authored by: Yoron on Sun, Jul 1 2007 at 9:50AM PDT
What about using a similar script to warn/remind you that the lapel mic isn't on?

[ Reply to This | # ]