Page 1 of 1

simple guide/link to play sounds via Airfoil Pro

PostPosted: Mon Jan 09, 2023 1:59 pm
by lazlohollyfeld
Hello all -

Use case: I want to use indigo triggers to play an arbitrary sound (.mp3, .wav, etc) on one or more HomePods or Airport Express speakers.

Is this possible? Everything i've read seems to focus on streaming to speakers - NOT playing a specific sound file or text-to-speech audio..

I've read thru all the documentation i could fine - but cannot seem to find anything wrt this use case.. If this is a supported use case, can someone please share any resources that could help?

thanks!!!

Re: simple guide/link to play sounds via Airfoil Pro

PostPosted: Mon Jan 09, 2023 3:30 pm
by jay (support)
I'm unclear exactly what you understand and what you don't based on your post. It reads like you only don't know how to play a file or text to speech, so that's what I'll address.

For text to speech, you can use an action in Indigo using the "Speak" box at the bottom of the action pane in the action options section - that will speak the value you enter. In Airfoil, you select the Other Sources->Text to Speech option on the source popup (you can also select that option in the Change Source action in the Airfoil plugin's action list). So with Airfoil set up like this, any text to speech will be played through Airfoil to the connected speakers.

For a random sound file, you can use the QuickTime Player app to play the sound file. Just select that as the source in Airfoil. Alternately, you can set the source to System Audio (which will play all sounds your Mac makes through the connected Airfoil Speakers) and use the afplay command-line tool from the Run Shell Script action and point it to your sound file. The Full path to file on server text field would have something like this in it:

Code: Select all
/usr/bin/afplay /full/path/to/your/sound/file.wav

Re: simple guide/link to play sounds via Airfoil Pro

PostPosted: Mon Jan 09, 2023 7:28 pm
by lazlohollyfeld
Ahh - ok - I think I get it. I think I assumed it worked a different way - and didn’t realize I would just play it locally and then send it to the devices. I thought it was more of an action.

That makes sense - all I needed!

Thank you!

Re: simple guide/link to play sounds via Airfoil Pro

PostPosted: Mon Jan 09, 2023 8:12 pm
by jay (support)
Right. At its simplest, Airfoil just connects audio from various macOS sources to audio output devices. The Airfoil plugin just allows Indigo to change the Airfoil configuration.

simple guide/link to play sounds via Airfoil Pro

PostPosted: Tue Jan 10, 2023 6:24 am
by GlennNZ
Hi

The new appleTV Plugin (I add a link) allows connection to HomePods, with updating playing info.

viewforum.php?f=382



But also has a text to speech trigger. (uses default, selected Mac System Voice)

This trigger can use variable and device substitution as well.
So single trigger can get Homepod to say really whatever you want.

Glenn


Sent from my iPad using Tapatalk