Outputting Multichannel Audio

usefuldesign.au's picture

My question is what is the most cost effective way of getting the audio out of a Mac and split to 16 channel (or less prob 5 stereo ch enough)? Would be either from a Mac Mini or if I can get this all ported to a ATV (before it becomes another iOS device!) by someone with the know how, then even better in terms of cost. I'm assuming digital out jack to a break out box is only way to do this. What kind of hardware do people have experience with that's reliable and modest in cost (sound quality isn't really the issue here)?

I'm making a little QC comp to playback multiple audio tracks of spoken word at the same time using Kineme Audio Tools. One track would be instructions in English (goes to a PA) and the other tracks would be same content but in other languages and needs to be routed to headphones. I guess there could be a need of up to 6 languages in any given instance (though in likelihood rarely more than 3). Languages to be played back on a particular day from those available as alternative tracks will be set by admin in some way that the QC comp only has to playback the correct tracks and route them to the correct phone jacks (in some cases multi sends of same language to more than 1 phone jack).

So the 16ch's I see provided in SoundFlowerBed can do it and I have the comp routing to separate channels for each track for any given directory, either in mono or stereo. I'll add external controls probably via a custom box (eg. arduino mc) that can display track info to an LCD as well as playhead control and position etc like an iTunes HUD. The comp/app will also be used to playback video but only in the (single) language on Video file.

Comment viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.

jrs's picture
Re: Outputting Multichannel Audio

I've used used a motu 828mk3 (an 8 channel firewire soundcard) to do something similar before with a mac pro. The motu causes the mac pro to kernel panic around once a month so I'd suggest using something like a firepod instead. Both are about AUD$1100 if you hunt around so its not cheap but there aren't many other options.

Multi channel amps were not only hard to find but very expensive so we just used 4 separate amps - they were $200 each but were big so should be much less for headphone amps.

franz's picture
Re: Outputting Multichannel Audio

using a motu ultralight mkIII on 10.6 (with the newest drivers), no kernel panics....

dust's picture
Re: Outputting Multichannel Audio

the cheapest way to get multi-channel output from intel based mac. is go digital spdif out. im pretty sure k audio supports core audio files (.caf) which means you can multiple tracks inside one file. much like how a dvd works with various language dubs.

so for $1+ you can get a 3.5mm digital light pipe cable that can then be plugged into a spdif coax or light pipe enabled receiver and out putted to specific speakers. it seems the core audio file specification has specific identifiers chunks for foreign languages etc..

you can actually make a user defined data chunk by extending the .caf specification with you own 16bit unique identifier UUID. sound familiar ? this is how you select audio devices with kAudio. seeing that .caf was made to get around the 4gb limitations of .aiff and the specification is extendable i'm pretty sure you can stack way more than 16 channels in .caf file.

just look at this enumeration of the built channel tags to get an idea. your not limited to just audio but midi and sampler instrument data play back. more than likely you will find a consumer product that handle 6 channels surround sound.

but with pro digital gear you link multiple units up via fiber optic to extend your tracking capabilities. actually analog as well or some ADAT machines use this feature kind of like an 8 track or well a ADAT is an 8 track. to get 16 you hook two up via fiber. good ones will have fiber optic connection in them all ready. they have i/o ports in the back for monitoring on a mixer. this sometime hardwired into your ADC matrix patch bay for easy routing.

i bet you could find a used ADAT for 30 bucks or something on ebay maybe a whole rack of them for cheap. but this is just an example of how you can stack units with fiber optic cables. you need a D/A converter. and they are thousands of dollars. although

like you mentioned you would need an ADAT A/D - D/A converter. a cheap good one would be a

"Behringer ADA8000 Ultragain Pro 8-Channel A/D D/A Converter"

now your talking arduino. yes arduino has a built DAC or D/A converter and you can play back sounds via PWM digital outputs at 4bit. ok sometimes its cool to crunch a baseline to 4bit but that sucks. plus the EEPROM on an arduino is like 10k or something so your limited to a few seconds. i mean its possible to get a wave shield for your arduino and output uncompressed audio via sd card as 2 a channel from an arduino. so that would take 4 arduinos at $50 each and 4 wave shields at $20-30.

if your going that route your better off building your own. a 12bit DAC only cost like a dollar.

http://ww1.microchip.com/downloads/en/DeviceDoc/21897B.pdf

in the end it would better to buy an ADA8000 or just buy a cheap m-audio card like a fast track ultra. it provides DAC input output with a DSP mixer so you can i/o 8x16 and have separate headphone monitoring with zero latency. the onboard DSP gives some basic effects. but that is really if you want to record and hear your self with live input without having to through the computer to headphones or "cans". still you can output spdif and 8 tracks from your computer. m-audio has good stuff.

this solution would be the easiest if your running a qc patch or a solution similar maybe more outputs like 16+. as you could just select the UUID of the card then send what ever tracks out to different outputs.

you could also do cheap mono trick where you could get a bunch of really cheap usb to 8th inch things like an iMic or something. these where made particularly for early mini macs which had no audio output jack. you would go to audio/midi set up and make an aggregate device and add each card to your aggregate. 4 of them would give 8 mono out or 4 stereo l/r pairs. you would want to make your file a stereo file but have your left track be english and right track be latin or what ever language. then in kAudio you would select your aggregate as a UUID and output using 8th inch to rca or what ever cable you need to go to the sound system.

to get an idea of how many tracks not including user defined chunks of core audio formatted audio checj this enum out. this means you can theoretically can out all you tracks via one kaudio patch, supposing you have logic pro or some DAW that can make multi-tracked .caf files.

you could try as a quicktime i know quicktime 7 supports multi-track audio as well.

enum
{
    kCAFChannelLabel_Unknown    = 0xFFFFFFFF,   // unknown role or unspecified                                                    // other use for channel
    kCAFChannelLabel_Unused     = 0,            // channel is present, but
                                            // has no intended role or destination
    kCAFChannelLabel_UseCoordinates         = 100,  // channel is described
                                            // solely by the mCoordinates fields
 
    kCAFChannelLabel_Left                   = 1,
    kCAFChannelLabel_Right                  = 2,
    kCAFChannelLabel_Center                 = 3,
    kCAFChannelLabel_LFEScreen              = 4,
    kCAFChannelLabel_LeftSurround           = 5,    // WAVE (.wav files): "Back Left"
    kCAFChannelLabel_RightSurround          = 6,    // WAVE: "Back Right"
    kCAFChannelLabel_LeftCenter             = 7,
    kCAFChannelLabel_RightCenter            = 8,
    kCAFChannelLabel_CenterSurround         = 9,    // WAVE: "Back Center or
                                                    // plain "Rear Surround"
    kCAFChannelLabel_LeftSurroundDirect     = 10,   // WAVE: "Side Left"
    kCAFChannelLabel_RightSurroundDirect    = 11,   // WAVE: "Side Right"
    kCAFChannelLabel_TopCenterSurround      = 12,
    kCAFChannelLabel_VerticalHeightLeft     = 13,   // WAVE: "Top Front Left"
    kCAFChannelLabel_VerticalHeightCenter   = 14,   // WAVE: "Top Front Center"
    kCAFChannelLabel_VerticalHeightRight    = 15,   // WAVE: "Top Front Right"
    kCAFChannelLabel_TopBackLeft            = 16,
    kCAFChannelLabel_TopBackCenter          = 17,
    kCAFChannelLabel_TopBackRight           = 18,
 
    kCAFChannelLabel_RearSurroundLeft       = 33,
    kCAFChannelLabel_RearSurroundRight      = 34,
    kCAFChannelLabel_LeftWide               = 35,
    kCAFChannelLabel_RightWide              = 36,
    kCAFChannelLabel_LFE2                   = 37,
    kCAFChannelLabel_LeftTotal              = 38,   // matrix encoded 4 channels
    kCAFChannelLabel_RightTotal             = 39,   // matrix encoded 4 channels
    kCAFChannelLabel_HearingImpaired        = 40,
    kCAFChannelLabel_Narration              = 41,
    kCAFChannelLabel_Mono                   = 42,
    kCAFChannelLabel_DialogCentricMix       = 43,
 
    kCAFChannelLabel_CenterSurroundDirect   = 44,   // back center, non diffuse
    // first order ambisonic channels
    kCAFChannelLabel_Ambisonic_W            = 200,
    kCAFChannelLabel_Ambisonic_X            = 201,
    kCAFChannelLabel_Ambisonic_Y            = 202,
    kCAFChannelLabel_Ambisonic_Z            = 203,
 
    // Mid/Side Recording
    kCAFChannelLabel_MS_Mid                 = 204,
    kCAFChannelLabel_MS_Side                = 205,
 
    // X-Y Recording
    kCAFChannelLabel_XY_X                   = 206,
    kCAFChannelLabel_XY_Y                   = 207,
 
    // other
    kCAFChannelLabel_HeadphonesLeft         = 301,
    kCAFChannelLabel_HeadphonesRight        = 302,
    kCAFChannelLabel_ClickTrack             = 304,
    kCAFChannelLabel_ForeignLanguage        = 305
};

hope this helps.

usefuldesign.au's picture
Re: Outputting Multichannel Audio

Thanks jrs and franz. This is just voice and I'm trying to get the whole package cost down to potentially do multiple installs, so I'm looking maybe at other DAC paths than studio quality audio gear…

usefuldesign.au's picture
Re: Outputting Multichannel Audio

Hi Dust

Thanks for the comprehensive answer. As it happens I have been looking closely at the ADA8000 online while your post was just sitting here unread! I'm unclear about the TOSLink/ADAT/spdif/lightpipe thing. The Berringer website says this is TOSLink enabled but the PDF manual says it's using ADAT.

According to wikipedia TOSLink and ADAT only share connectors and are otherwise completely different specs. ADAT streams up to 8ch 24bit at 48kHz so I'm thinking, is this thing really going to talk to (well I guess it just listens really) a Mac Mini or ATV optical out, which has the Mini-TOSLink connector but is probably running SPDIF I'm guessing?

The stack of cheap USB to 8th inch option sounds interesting too.

One problem I have is that although I might only want 3 additional languages out at any one time, they need to be selected from maybe 12 or so. Therefore I'm reluctant to pre-encode the audio into one track with multiple languages. A) it might get to fat and B) I would then need to decode only the right tracks outside the Mac meaning more expensive gear, if it's even possible. That's why I'm thinking use the QC comp to specific languages at to specific channels at run time (according to Admin settings that can be changed from day to day).

I also read about a cheapish HDMI decoder which has 4 steroeo jacks out for each channel of 7.1 (which is 7 or 8 mono channels) but again the signal has to be encoded before it hits the HDMI output of the MacTV/Mini which could be to much of an issue to deal with for me.

I'll read you answer more carefully now. Thanks again.

dust's picture
Re: Outputting Multichannel Audio

yeah someone told me lately that dvi and hdmi are now supporting audio. this is probably a good thing because if your computer breaks you will only have to replace the video card which i think is attached to the pcie bus. my mbp audio card was broken when i got my computer. the new macs have the audio card built into the logic board which means if headphone jack goes down then you need a whole new logic board.

as per the the behringer i can't not really confirm anything, as a tsolink/spdif is commonly referred to as adat although they are two different formats they are fairly easily inter-changeable. check out this discussion...

http://www.gearslutz.com/board/high-end/8666-spdif-adat-optical.html

trying to keep everything in the digital relm until the audio hits my speakers has been a goal of mine and more than likely will give you the best quality but if your not an audio gear head then even something like the behringer is over board.

now i would test your system with a tsolink cable connected to surround system first to make sure the spdif actually works and works out of qc. the best way to do this would be with a movie file and vcl or something.

make sure your using ac-3 5.1 dolby surround codec. you can get info in quicktime to make sure your movies audio is formatted properly. to make sure you have all your codecs properly in place install the perian preference pain.

http://www.perian.org/

plug you spdif into a reciever and go to audio/midi utility and make sure it says digital out 2 channel 16bit or 24bit. doesn't really matter, and don't worry about the digital out saying two channel. dolby is technically only 2 channels even though it encapsulates many tracks.

now before SL you would need to enable ac3 pass though so other media will pass the ac3 digitally out.

to do this open terminal and type.

defaults write com.cod3r.a52codec attemptPassthrough 1

again maybe you do not need to do this with snow leopard. you amp or what ever should let you know if things are working. previously in leopard without enabling pass through only the dvd player was giving me surround via built in light pipe.

so you will want to experiment or find someone to test a file for you on their system. kaudio does work with .caf files. if you use the m4a:acc format im pretty sure this will encode your audio file for surround. i forget logic and sound track pro does automatically for you. i know students are always having trouble with soundtrack pro as it defaults to a surround and if you are not connected digitally with the above mentioned method you will hear nothing.

im thinking probably your best and most practical solution is a usb/firewire based multi-track output box like an m-audio card. i know this is a bit pricy but second hand from audio-lines or ebay or something might not be that bad. i mean you can't beat a $1 dollar tsolink cable and the price of the built in card but for sure ease of use and from a organizational view point its probably best to go this route as you do not need to make surround file all you have to do set an output channel for each k audio patch.

usefuldesign.au's picture
Re: Outputting Multichannel Audio

Thanks Dust. Just heard back from Behringer:

Toslink is the physical connection type and ADAT is the format. Mac does not support output of ADAT and so this connection will not work.
 
The output on the MAC is most likely SPDIF which can use either Toslink or Coax connection types.
 
Best regards,
BEHRINGER Support

Will report back when I know more. Yes, Perian. I used to rely on that a lot then something else came along — can't remember what and didn't use it again (not knowingly anyhow). Been reading that ATV does translation of audio from one codec to another for use in HDMI port so new audio codec used in iTunes movie downloads will work with older multichannel receivers that use an older codex. Not sure if that's realtime, I guess it must be otherwise why download then newer codec (size?). So if I was a coder maybe there would be a pathway from kAudio as 16ch to HDMI and a cheap breakout box. Still got to check out some of the options you mentioned.

usefuldesign.au's picture
Re: Outputting Multichannel Audio

Somebody I was showing this project to suggested multiple bluetooth devices. Seeing as the audio ends up in headphones, it could be a good solution.

If i buy a bunch of bluetooth dongels, does anybody know if they will the appear in the ++Kineme Audio Device Info++ patch as separate devices?

If so I think it's problem solved, I found a dongle with a range of 100 meters for A$15. If 100M is correct that will be sufficient (I need ≃35m with no walls to penetrate). Will USB port get hammered to much if I put 5 or more dongles on it?

dust's picture
Re: Outputting Multichannel Audio

bluetooth sucks usb audio dongles are 99 cents. i know i mentioned this before lets say for ten bucks you get ten dongles. that should output 20 channels of audio or 60 virtual tracks. its possible output track X to Left channel and use another patch to output track Y to channel right of the same dongle as k audio lets you choose channels. so you wouldn't necessarily need to interleave different audio tracks on L/R. i know i mentioned that before but didn't entirely make it clear that you didn't need to combine or interleave your language tracks to one file.

read on for some wireless solutions and why bluetooth sucks. plus i put some links to an alternative FM solution.

but yes bluetooth will show in k audio UID as input and output. personally i think bluetooth audio blows. every bluetooth device i have bought and keep buying as bluetooth upgrades its protocol. after every time i tell my self i will never buy another bluetooth device again.

so 2 days ago i went and did it again (buy bluetooth) this time using a buy it now ebay OEM Motorola product thinking each time it might be different. it will work with my ipad or iphone, i will be able to go more than ten feet from my computer, there will be no static etc...

well again i'm wrong bluetooth audio still sucks. i keep giving it chance and keep getting burned. it doesn't matter if you spend over 100 dollars or 10 dollars it just sucks. now transmitting some data it isn't that bad.

i mean its totally possible to buy a bunch OEM bluetooth headsets for 5$ and transmit independently out of quartz and think its a good idea. not sure if it will work for your project. i mean your not going to get any where close to 35 meters out of a bluetooth headset. bluetooth is getting better ranges but if the device says 60 feet cut it in half and divide by 2 and then you will be in the audible range.

if you go with a transmitter usb device you will then need receivers as well. you can hook as many as you want up usb if you get a powered hub. you can even get multiple of the same devices and not worry about name collisions as they all have unique identifiers appended to the name.

maybe my problems have been with my laptop and mobiles bluetooth cards and maybe a usb transmitter will be better. oh wait i have a top of the line universal bluetooth stereo device that can plug into any 1/8th inch jack but thats only as good as long as the battery lasts and only works with receivers of the same brand so i highly doubt a usb solution will be any better.

bluetooth works relatively well with wii mote type devices but i think in the end you will be much happier with usb audio break out box but even that doesn't help if you need a wireless headset solution.

i have some wireless gear and suggest UHF for wireless audio input and output as the range and quality is so much better but can get pricy if you are wanting in ear monitors or something.

what might be cheaper wireless alternative is short range FM modulation. i had a mate that went on ebay and bought a bunch of those headphones that have little radios in them.

he got a whole lot for cheap as people use mp3 players now and then used one of those little short range radio transmitters to broadcast audio at his party and everybody walked around with these funky 80's headphones tuned into the local frequency.

you know those transmitters that hook your ipod up to a car by tuning into a radio station. so theoretically you could get a some transmitters, and headphones but that would still require a multi-channel card but if you can get ten dongles for 99 cents each this might be cheaper.

so these guys are 99 cents 10 should give you 20 tracks of audio or 60 virtual what ever thats all about.

http://cgi.ebay.com/USB-2-0-Mic-Speaker-5-1-Audio-Sound-Card-ADAPTER-NR-...

these guys are 99 cents if you buy ten of these then you have ten transmitters and ten headphones in the 30m. its not clear if you can set the transmission signal it says will receive 88 ~ 108Mhz but also says multiple headsets receive same signal so you might want to go with some car transmitters (see below) and throw away transmitters that come these and use the headphones.

http://cgi.ebay.com/Wireless-Headset-Headphone-Earphone-TV-FM-Radio-New-...

or use these headphones as they scan fm and maybe arguably more fashionable. same price of 99 cents.

http://cgi.ebay.com/M-Ms-Mini-Plush-FM-Scan-Radio-w-Headphones-Blue-NEW-...

these transmitters you tune to particular frequency so lets say you can send one language track to a headset on 89.9 fm and use another to send 103.1 fm or something. by now you should have got the idea. not sure on range but normally 30 feet plus. feet not meters.

http://cgi.ebay.com/FM-Transmitter-Car-kit-MP3-Foldable-SD-MMC-USB-CD-/2...

you will need be able to power the car transmitters so you will need some of these babies again 99 cents. not sure about power voltage in AU though.

http://cgi.ebay.com/110V-AC-12V-DC-Car-Cigarette-Lighter-Socket-Adapter-...

either way you go you can transmit multi-track audio via FM for cheaper and in better quality than any bluetooth device.

cybero's picture
Re: Outputting Multichannel Audio

I think you're spot on with the USB via Wireless Network advice, dust.

I found Airport Base Station transmission and Extreme Airport Station to be far superior to any bluetooth transmission.

Strength of signal and speed of transmission / latency factors are going to be far higher without a well 'gridded' bluetooth framework supporting .

Airport is so much easier to secure, retain connectivity with and enjoy the widespread benefits of an appropriately boosted network of.

You also speak of Wireless UHF, which definitely seems to be the preferred form factor for Audio Instrument peripherals, especially a lot of game controllers :-) .

dust's picture
Re: Outputting Multichannel Audio

yeah UHF rocks. i mean i haven't tested how far i can really go with my little boxes but definitely can go way farther than any bluetooth or any wireless 2+ ghz telephone etc...

actually thought another idea as well could be to use cell phones and some conferencing viop software or google voice or something maybe. i know sykpe has an api and am still discovering google voice.

i know some things are possible with vxml and php etc.. as i had made a interactive installation that people would call to change graphics etc.. so with things like voxeo, vxml and evolution designer you can easily wip up some viop mark up code or use the evolution designer for code free stuff to do some interesting things. so instead of rigging up some cheap electronics it may be possible to just conference call people on mobile devices and route your audio to individual numbers via soundflower 16 channel or something from QC.

check out voxeo's developer page. im not sure the countries they support but are skypes or where skypes backbone and let me do interesting things before like make a call bridging/routing system like google voice, with the provided toll free number they give you.

so you can do things like make free phone calls from a pay phone by calling your number a saying the word mom and have it call your mom etc... if you get a token you can even make calls from your website supposing you have a php server. the php server is to echo the return vxml or basically xml to voxeo's servers so they in turn make a call from your web page etc...

this kind of solution make take some prep and may be a learning experience depending on your experience with telephony but certainly would be a free solution. unfortunately pay phones are being phased out so my free phone call trick might not work for much longer.