What are the audio device names on mac? (for use with afplay)

The command 'afplay' has an option -d or --device that supposedly allows you to give an AUDIO DEVICENAME. How can I find valid AUDIO DEVICENAMEs? I tried system preferences and system profiler, but I get these errors:
afplay -d "LINE OUT" x.wav -v
warning: device 'LINE OUT' not found
afplay -d "Line Out" x.wav -v
warning: device 'Line Out' not found
afplay -d Headphone x.wav -v
warning: device 'Headphone' not found

and I've tried every permutation of the names I could come up with.

Mac Pro 2009, Mac OS X (10.5.6)

Posted on May 8, 2009 9:56 AM

Reply
4 replies

May 8, 2009 1:56 PM in response to Chris CA

I'm not writing any code, just trying to use the command line tool 'afplay'.

Yes, I have headphones and external speakers connected. I also have internal speakers.

Maybe a better way to phrase the question: what does afplay want as input? Is AUDIO DEVICENAME defined universally somewhere? I couldn't find setDeviceName() calls anywhere, but I also didn't know where to look.

This thread has been closed by the system or the community team. You may vote for any posts you find helpful, or search the Community for additional answers.

What are the audio device names on mac? (for use with afplay)

Welcome to Apple Support Community
A forum where Apple customers help each other with their products. Get started with your Apple Account.