Become a fan of Slashdot on Facebook

 



Forgot your password?
typodupeerror
×
Music Media Technology

Is All SPDIF Audio Output the Same? 97

CyberSpaZtiK asks: "I am going to build a Linux audio appliance to hold my music collection in various formats and for output to my stereo system. Because of a probable lack of Linux availability or support for audio cards with high quality D/A converters and low-noise electronics (or am I mistaken?), I want to keep the output path completelely digital by using a card with SPDIF output. However, it occurs to me that I actually know very little about SPDIF - are all SPDIF outputs made equal? Can I expect every SPDIF interface to emit the exact PCM data of the source audio, or are there over/under-sampling/aliasing, etc. issues that you sometimes get with digital signal processing? What do I need to understand about SPDIF and/or other digital output interfaces to make an informed decision?"
This discussion has been archived. No new comments can be posted.

Is All SPDIF Audio Output the Same?

Comments Filter:
  • Use TOSLINK instead (Score:5, Informative)

    by RzUpAnmsCwrds ( 262647 ) on Tuesday May 24, 2005 @03:36PM (#12626537)
    SPDIF outputs are usually pretty consistent at passing the PCM data or the DD/DTS sountrack if you have them configured right.

    Some cards, however, such as Creative's Audigy series, are notorious for resampling inputs/outputs, so you might want to check.

    Even a cheap card, like the $15 cards on Newegg, should provide a clean output. Don't buy the garbage about "jitter" that I'm sure someone will bring up - so long as your card and cabling are operating within the specification, you won't have any problems.

    Do consider TOSLINK instead, however. TOSLINK uses fiber-optics, so your audio equipment and PC are electrically isolated. This reduces the chance of creating a ground loop or introducing RF noise into your reciever/amp. Moreover, it protects your equipment in the event of an electrical mishap.
    • by sffubs ( 561863 )
      Well, my Audigy is probably doing all kinds of crap to SPDIF audio signal, but to tell you the truth I can't find fault with it by listening. (My hearing isn't below average, before you ask :) ).

      I would just like to confirm what you say about TOSLINK. My PC is currently too far from my receiver for my optical cables to stretch, so I have to use the SPDIF connection. Every time there is an electrical event in my house (heating, fridge, freezer, kettle switching) the audio cuts out for a second or so.
      • I would just like to confirm what you say about TOSLINK. My PC is currently too far from my receiver for my optical cables to stretch, so I have to use the SPDIF connection. Every time there is an electrical event in my house (heating, fridge, freezer, kettle switching) the audio cuts out for a second or so.

        This is most likely due to faulty wiring and/or a ground loop [epanorama.net]. The linked page provides a very good description of the problem.. Unfortunately, it's usually quite hard to locate a ground loop, and they
    • by FlexAgain ( 26958 ) on Tuesday May 24, 2005 @03:57PM (#12626753)
      RzUpAnmsCwrds (262647) wrote
      Do consider TOSLINK instead, however. TOSLINK uses fiber-optics, so your audio equipment and PC are electrically isolated. This reduces the chance of creating a ground loop or introducing RF noise into your reciever/amp. Moreover, it protects your equipment in the event of an electrical mishap.

      One slight clarification, TOSLINK normally does carry SPDIF. TOSLINK is primarily just detailing the physical medium, the data is still encoded as SPDIF (which can also be carried on wire). The original author didn't specify how he was intending to use SPDIF, it may have been over either medium.
      • """
        One slight clarification, TOSLINK normally does carry SPDIF. TOSLINK is primarily just detailing the physical medium, the data is still encoded as SPDIF (which can also be carried on wire). The original author didn't specify how he was intending to use SPDIF, it may have been over either medium.
        """

        Um, I'm pretty sure S/PDIF is also the name for the physical connector, namely the RCA plug type of digital audio connector. The data is encoded as Dolby Digital, PCM, or whatever.

        Of course, I'm no stereo nu

        • Um, I'm pretty sure S/PDIF is also the name for the physical connector, namely the RCA plug type of digital audio connector. The data is encoded as Dolby Digital, PCM, or whatever.

          Of course, I'm no stereo nut so I could be wrong.

          Yes, you are wrong. S/PDIF is effectively the data format. It can run over TOSLINK or 75 ohm (read: normal coaxial video) cabling.

          And of course the ubiquitous wikipedia link [wikipedia.org].
          • no talk page on that wikipedia article which tells me its not to be too highly trusted

            i'm sure that what i heared was that S/PDIF was the original coaxial based system and that TOSLINK was a fibre cabling system based on it that worked using the same protocol.
          • Correct: the S/PDIF connection can be optical or coaxial. You connect the equipment with either TOSLINK (fiber) or "coaxial digital" cables. Really any 75 ohm cable will work. (and in reality most any cable will work if your equipment is flexible enough).

            The one thing to know, though, is that the PCM data can be sent at any number of frequencies. While most amps can read at 44.1kHz and 48 (and usually lower frequencies as well), not all can. Additionally, some sound cards (particularly the more generic or
          • Since we're being pedantic, most "coaxial" A/V cables ("RCA" baseband) aren't coaxial. The connectors are, but the cables aren't.

            Take a look. The wires are side-by-side.

            -Peter
            • What the fuck are you talking about?
            • Then stop buying your cables at Dollarama. Seriously. If that's what your cables look like, they are shit. Period. The only "side-by-side" you should be seeing is two or more coaxial cables running side by side, under the same sleeve.

              Look, I went the Dollarama way once, when I wanted to hook up my Commodore 64 to a LCD monitor via a scan doubler. The picture had horrible dot crawl. The cheap-ass telephone cables with s-video connectors wee the culprit. A 7$ cable with real coax fixed that problem. I'd ahte

            • I wasn't even drinking when I posted this.

              Weird.

              Anyway, they're coaxial. I'm dumb.

              -Peter
        • Um, I'm pretty sure S/PDIF is also the name for the physical connector...

          Admittedly, I don't know squat about this, but I'm pretty sure S/PDIF stands for something along the lines of Sony/Philips Digital Interface (my old roomies were audio engineers). It specifies how the signal is transimitted over the wire. The form the connector takes may vary.
    • ++ TOSLINK. I use both S/PDIF and ADAT Optical. I have had far less problems with optical connections then S/PDIF over coax/RCA cables. I do have to worry about jitter, but if you are operating a home theater/computer with only 4 or 5 digital input sources, all within the same room, you have nothing to worry about. Just use decent cables. Some problems can arise from varying sample rates and bit depth, but that is pretty easy to deal with.
      • If you are using electrical connection, I read somewhere that you need to use 75 ohm cable for these digital connections - at least this is what I use and it seems to be fine.

        I use video leads which are 75 ohm and cheaper than the specialist 'digital ' links they sell to hi-fi suckers, and I reckon it doesn't re-arrange too many of those pesky '0's and '1's.

        I think that jitter probably is crap. It is a digital signal. Having a good quality stable clock is probably important, buy if my computer can keep al
        • SPDIF is designed for 75 ohm video cables, so your cable should work perfectly. Jitter isn't "crap", it's there. If you don't care whether your THD is 0.01% or 0.1%, you don't need to worry about it -- and most people don't need to worry about such differences. If you want to get the best possible audio quality, you do need to consider jitter. It's not just some mythical audiophile invention, almost any datasheet for a DAC chip will have a jitter/THD graph.

          In any case, I would be more worried about the
          • Jitter may well be there, but with a digital transmission, either the data doesn't get through (in which case the sound doesn't come out), or it does. There's no inbetween state, so unless there are errors, jitter is not worth caring about.

            In any case, most (if not all) equipment with SPDIF inputs reclocks the signal before doing anything (even loopthrough is reclocked). Again, so long as no link is reporting errors, you're A-OK, no matter what the level of jitter is.

            • Equipment cannot completely reclock the signal. It can run it through a PLL, but that still lets through quite a bit of jitter (especially low-frequency jitter). You aren't going to get errors in the data regardless of jitter level because it uses Manchester coding. However, the quality of the clock you extract from the signal is quite important if you are running it to a DAC. That's where jitter starts to be important.
              • by farnz ( 625056 )
                Bullshit. Complete and utter bullshit. In decent equipment, when you reclock, you use a PLL to lock to the existing signal, and create a binary bitstream in a buffer; you then use your own clock to pump bits out of the buffer. So long as the jitter isn't too bad, there will be bits going in often enough that the buffer never drains. All that then matters is the quality of your clock.

                Jitter is an issue for equipment designers; it is not an issue for equipment users. With the aid of a decent lab, you can ver

      • I've had the opposite experience: no problems with S/PDIF over coax, but trouble with S/PDIF over Toslink. Optical cables are also more expensive than coax, so I'd recommend trying coax first.
    • by Anonymous Coward
      ...of course if you are trying to avoid wires (almost) entirely, you can try beaming your SPDIF outputs over a home 2.4 Ghz video sender pair (e.g. as sold by Radio Shack). Plug the coax SPDIF into the video input of the sender and, on the other side, pull the SPDIF off the video receiver into your stereo's amplifier. It sound's crazy, but the video sender is the only non-network wireless device with the bandwidth to pull off this trick. This is good to the limit of the video sender (less than 100 ft) and
    • by Anonymous Coward
      Ugh, Audigy. For games, feel free to use the Audigy, but that thing WILL resample everything, which is probably not noticeable if you're going straight to speakers after, but you start getting lovely second-and-third-generation artifacts if you pass it to something ELSE that resamples.

      Most games use DirectSound3D or OpenAL these days, so you shouldn't even notice if you don't have the Audigy, since they do it in software mode that's quite indistinguishable from the hardware -- audio's simply less demandin
    • A proper S/PDIF over coax implementation should use isolation transformers to electrically isolate the signal, preventing groundloops. RF is still a posibility, but using proper coax cable instead of any old RCA cable will help greatly prevent problems there as well.

      A card like the M-Audio Audiophile 2496 would be a respectable choice for under $100. I don't have my card handy to look at, but I think it uses a proper transformer for isolation. I don't think the creative labs cards do though. There may
  • I can't answer your question, but I will tell you one thing for sure. The lack of anything that effectively manages a music collection in Linux has long been a beef of mine. I hate to say it, but music "jukeboxes" are one area where Widows has a definate advantage.
    • Really? I've had exactly the opposite experience. I like using a web frontend to mserv because I like the random "jukebox" features, but I've seen tons and tons of other jukeboxes out there for Linux. There's jukeboxes out there whether you want a commandline, gui or web frontend, whether you want your collection indexed on the fly or stored in a database, whether you want to play the music locally or stream it, whether you want to play wav, mp3, ogg, whatever.

      What are the Linux jukeboxes missing that

      • The ones I have found have not seemed very good to me. Which one have you used? Because I am very open to recomendations.
        • Re:Way to go (Score:2, Interesting)

          by sneakers563 ( 759525 )
          Well, I should say that I wanted to build a living room "jukebox" and DVR for parties, so my requirements might be a bit different from yours. I've used Mserv [mserv.org] because I wanted a kiosk-type jukebox that would act like a real jukebox. That is, if no songs were selected, it would start picking songs based on ratings and how long it had been since they had last been played. I don't know of any other jukeboxes, Windows or Mac (perhaps someone can enlighten me) that will weight it's random selections like that
          • That is still really cool because that is another thing I have been lloking into for a while now. Thanks for all the valuable tips.
          • iTunes' party shuffle feature will do this. You can set it to play higher rated songs more frequently, or just use a dynamic playlist that has the features you want.
      • hmmm. how about: * replaygain * proper gapless * script language based system for * tag setting & renaming * osd / title bar * main screen * support for cue files embedded in audio files [ 1 file / album, but appears as a normal set of tracks in the player ] all in the same player? (for those who don't know, i'm specifically referring to foobar2000 under windows, the one non-game program that makes me want to keep windows on my system. Amarok is getting close (I even heard rumours of someone workin
        • I can't even understand what you've written, so I'll bow to your expertise!
          • Dude, I think that's a perl script or something. I think you run it on the command line to get the actual output. Something like:
            perl -e "[that post here]"

            At least, I think that's how to turn it into English.

          • damn that lack of autoformatting! too much time using phpBB forums I geuss :S. Heres it properly:
            Features I would like in an audio player that (afaik) are not currently availiable under linux (or at least, are not availiable together to any degree:
            1. replaygain [replaygain.org]
            2. proper gapless playback support
            3. A scripted language based system to for determining how the player outputs/reads:
              1. tags
              2. filenames
              3. on-screen displays / title bars / etc
              4. the actual main player window
            4. support for embedding cue files in id tags (rip
    • I am a huge fan of rhythmbox. I prefer it to iTunes any day. I use rhythmbox at home however at work I have to use iTunes (I take my ipod back and forth and plug it in at work). iTunes is alot slower, and has useless eye candy (so many animations ... so useless)

    • Unless you've tried both JuK and amaroK and found them both lacking, you can not claim that there are no music "jukeboxes" on Linux.

      Paul.
  • by Kickasso ( 210195 ) on Tuesday May 24, 2005 @03:41PM (#12626588)
    It will occupy you for years to come.
  • by Hidyman ( 225308 ) on Tuesday May 24, 2005 @03:51PM (#12626674) Homepage
    We are talking digital signals here.
    Any self respecting DAC circuit will not be affected by jitter.
    I use toslink all the time and there is no problem with "jitter".

    Jitter is marketing hype.
    • by stienman ( 51024 ) <adavis@@@ubasics...com> on Tuesday May 24, 2005 @04:45PM (#12627310) Homepage Journal
      Jitter is a problem for electrical engineers and programmers. By the time we're done with the system, you won't be able to tell whether there is any jitter or not, nevermind how much. Regardless, there WILL be jitter.

      Unless, of course, all your units have synchronized clocks, or each have their own atomic clock.

      Unlikely, to say the least.

      Jitter is not a problem the average prosumer really needs to worry about, nevermind the average consumer.

      The audiophiles who care about it care the same way about their tubes, oxygen-free cables, and green highlighters. Whatever gives you a warm fuzzy feeling, man.

      But, technically, it does exist, and it is a problem that results in either doubling up on samples, skipping samples, or some sort of macabre clock synchronization scheme that only ends in tears.

      Only, technically, that's not jitter either.

      -Adam
    • Actually, Jitter is a real, audible and nasty issue in certain specific applications... but not this one.

      It's not a problem you are ever likely to come across outside a big recording studio where several devices are talking to each other digitally with DAC clocks drifiting compared to each other (oh, and it's easliy solved, the solution is to slave everything to a master clock).

      The problem of sending a 44.1kHz signal from one end of your house to another is trivial compared to feeding a broadband signal
    • I spend a lot of time dealing with jitter in my job. For example, if you want to capture a TV signal, then jitter is quite important (even more if it is HDTV). But for generating audio signals over a serial link, then jitter should not be a problem, provided the digital data is properly latched, and the clocking method is not absolute crap (jitter of 1ns on the clock would not be an issue, and that is a crappy level of jitter - it gives a SNR of ~93dB at 20KHz - jitter requirements for WLAN is more like 50p
  • $25 TOSLINK card (Score:5, Informative)

    by hab136 ( 30884 ) on Tuesday May 24, 2005 @03:58PM (#12626783) Journal
    I've been using a Chaintech AV-710 [newegg.com] with my linux home theater PC for a long time now (a year?), outputs to my surround sound receiver. Fully supported under ALSA. mplayer, xine, and ogle all pass through the AC3 5.1 sound for my receiver to decode. I went for fiber optic, mainly because I didn't want to worry about grounding effects.

    Chaintech's product page [chaintechusa.com]

    • Does it work with DTS?

      I'm trying to find an inexpensive solution for S/PDIF over TOSLINK for Linux that supports AC3 and DTS, but my messages don't make it to the ALSA list for some reason.

      Maybe it's because too many words are all caps!

      -Peter
      • Does it work with DTS?

        In my setup (playing DVDs), the AC3 audio is sent straight to the receiver. The receiver does the Dobly/DTS/THX/whatever decoding. So yes, it works with DTS, since Linux is just shoveling data off the disk and then onto the wire, no matter the encoding.

        Here's my /etc/asound.conf where everything goes out the optical out:

        pcm.!default {
        type plug
        slave.pcm "cards.pcm.iec958"
        }

        pcm.!spdif {
        type plug
        slave.pcm "cards.pcm.iec958"
        }

        pcm.!iec958 {
        type plug
        slave {

  • by Marillion ( 33728 ) <ericbardes&gmail,com> on Tuesday May 24, 2005 @04:01PM (#12626826)
    The S/PDIF protocol has a consumer mode and a professional mode. I do some professional audio work and my DiO-2496 will emit both. My MD player will only accept the consumer mode which includes Serial Copy Management System (SCMS) flags which indicates if the source is first generation (allowed) or second generation (not allowed). The other nice thing about this card, it is completely ignores inbound SCMS and can re-code a second generation stream as a first generation consumer stream or a professional stream. Haven't needed it, but cool. I've connected it to professional DAT units, consumer MD units and DVD players.
    • You mean AES/EBU? Yes, the 2 bit copyprotect flag isn't in that spec, although as you say you can get a device to change a normal SPDIF stream.

      IIRC there are 4 settings for copy-protect: prohibit, don't prohibit, and one generation (the other setting is unused). It repeats every frame.

      However that's only a minor part of the difference. The big difference between professional and consumer kit is pro kit is ballanced, additionally AES/EBU can support 3 frquencies (44.1, 48 and 96), I believe SPDIFF is limit
  • MAudio Delta 44 (Score:1, Informative)

    by medgooroo ( 884060 )
    Your mistaken. the MAudio cards all work beautifully... and sound it too... *currently listening to music in superb definition on said card* together with jack and assorted other toys, audio on linux is not something that is lagging.
    • This man speaks the truth.

      Most M-Audio cards [m-audio.com] work with Linux ALSA and JACK. If you just want some decent audio output you can buy the Audiophile 24/96 for less than $100 at the store. It has SPDIF out as well.

      The Mia card by Echo works as well.

      RME has soundcards [rme-audio.com] that work well with Linux too. They will get you some higher quality at a price.
      • My (old but still good) Echo Gina works with Linux, but needs some work to get drivers functioning, and doesnt work with the standard ALSA mixer API (has separate mixer app).

        It does 20bit 2-in/8-out recording/playback with a very low noise floor, and also offers stereo digital in/out with SP/DIF consumer/pro modes on Linux.

        My friend gave me his since Echo no longer do Windows drivers for their old cards.

    • I have a MAudio Dio 2496 that I have a problem with: the digital outs (both coax and optical) cut off the first half-second or so of any sounds, including songs. The analog outputs, however, work beautifully. I've had this card in 2 or 3 different Linux installations and everytime it's the same thing. I don't think it's my receiver because my dvd/cd player is also hooked up to a digital input on the receiver and it doesn't show the same behavior.
  • If digital inputs are at a premium, consider a Griffin iMic - works perfectly with the ALSA USB Audio driver.

    In my testing, it's the cleanest sound I've heard from a computer with the exception of optical toslink.
    • I have one of these, and I love it. Currently, I use it mostly for recording my vinyl LP collection, but also just audio playback. The stereo stack sees the laptop as just another tape deck (Play/Record).
  • by amliebsch ( 724858 ) on Tuesday May 24, 2005 @04:42PM (#12627278) Journal
    I didn't realize this before going to SPDIF: as far as I know, there are no sound cards and only one chipset that will output more than 2 channels through the digital link. Even if the card supports 5.1 surround by analog jacks, e.g., the SB Audigy, it will not encode your digital signal in anything other than 2-channel PCM; except when you are directly passing it raw AC3 or DTS digital data (say, from a DVD or an AC3 encoded file.) You will not be able to get, for example, surround sound over SPDIF from games that support multi-channel surround sound.

    If anybody know of sound cards available for purchase that actually support this, (the feature is called DICE), let me know.

    • You could try Xitel's Pro Hi-Fi Link [xitel.com]. It's a bit pricey, but it connects via the standard USB Audio protocol to your computer. It also includes all the audio cables you need. I believe it supports passing through stuff like AC3.
    • Even if the card supports 5.1 surround by analog jacks, e.g., the SB Audigy, it will not encode your digital signal in anything other than 2-channel PCM; except when you are directly passing it raw AC3 or DTS digital data (say, from a DVD or an AC3 encoded file.)

      Annoying ain't it? I know more than one person who would love to be able to buy a multichannel soundcard that did realtime AC3 encoding. I believe the now defunct nVidia motherboard was the only way you could do get this type output in a PC and

    • I disagree. My Audigy will output a 5.1 signal via SPDIF to my surround sound amp for decoding. Works fine. Alternatively, the card will just send a Dolby Digital stream to the amp which it also handles fine.
      • are you talking about any sound other than during DVD playback? How did you get this to work?
        • Erm - in the Creative settings, I just turned on digital output and told it I had a 5.1 setup. The amp (a Creative something-or-other) is set to default mode and I know it works, because I get surround sound in games.

          I wish I could give you more detail but the computer in question is 400 miles away.
          • If this works, it must be by some proprietary Creative flimflammery. I believe some of their speaker sets use a multi-conductor DIN which actually transmits multiple two-channel PCM signals simultaneously. Obviously, this is not "real" multichannel SPDIF and will not work with your average digital receiver.

            I have tried everything I can think of to get 5.1 AC3 or DTS over regualr RCA coaxial SPDIF, to no avail. Everything I've found leads me to believe it is impossible.

          • Unfortunately this is incorrect. It may sound like surround sound, it may even be Pro Logic (which is an analog hack to get surround sound out of a 2 channel source), but nVidia holds the only license Dolby ever sold for realtime Dolby Digital 5.1 encoding hardware. If you don't have an nForce-based motherboard, you aren't doing real Dolby Digital 5.1 through SPDIF.
      • Sorry, but the grand-parent is correct. The Audigy will not mix DD5.1 on the fly - only nVidia's nForce did this (and it was fantastic).

        The Creative cards will, however, use CMSS (another Creative invention) to upmix a 2 channel source to 5.1 when used with certain Creative amps. Alternately, there's always Dolby Pro Logic.
    • It's not hardware, but: real-time AC3 encoding for JACK [essej.net] might do the trick!

      Of course, not so useful for playing games under Windows.

  • I'm looking for a low-cost DAC/ADC chip for SP/DIF, something that takes audio and produces SP/DIF, and vice versa. If it can use fixed modes and doesn't require a uC that would be great.

    The Phillips UDA1355H [philips.com] looks like what I want, but Phillips doesn't even list availability information, and DigiKey and Mouser say either nothing or non-stock, which leads me to think that the chip doesn't exist.

    Does anybody have anything like this?

    I already know about PCM2902 USB DAC [hepso.dna.fi] project, and while that's useful (si
  • Can I expect every SPDIF interface to emit the exact PCM data of the source audio, or are there over/under-sampling/aliasing, etc. issues that you sometimes get with digital signal processing?

    At least according to this site, no. See " 44 KHz Digital Data To Digital Output" sections such as Turtle Beach Santa Cruz [pcavtech.com]. A full list of tested cards is here Here [pcavtech.com]

  • If this makes you tick, build it, but there are easier options, such as the squeezebox from slimp3

    Mark
  • Of course there are differences between good and bad SPDIF outputs (good and bad systems with SPDIF outputs to be precise). The impedance, the connectors, the regularity of the data output, the jitter... suposing the system won't resample the datas.
    Concerning your computer, I don't think it would have any problem in forwarding data at the right rate.
    Avoid too much cpu-intensive tasks when listening your music.

    People talk about jitter and it's interesting because it mainly affects only the end segment
    • I'd pick up a Benchmark DAC-1 instead. The output is much tighter than the MiniDAC from Apoggee. That is unless you are running with a Big Ben, but even then, the clocking on the DAC-1 is SUPER tight.
  • way back when I was on the 'dat-heads' mailing list (back when DAT taping at live shows was still new and not at all common), there was quite a bit of talk about jitter and its real world effects.

    without getting deep in math and tech, the short answer that everyone seemed to agree upon was:

    - when sending the signal from a source device to PLAYBACK device, if the target device is a DAC, then jitter does matter.

    - when COPYING the data from a device to a storage device (DAT, computer, etc), then jitter does
  • one thing to watch out for, in spdif output cards, is that MANY internally resample ALL data at 48k. this will alter the bitstream of a true 44.1 file if you try to diff it of what you see on the wire vs what is on disk.

    sound blasters and their ilk are famous for this.

    the envy24 chip is known to be bit-accurate. what you send is what you get. m-audio has these cards.

    another good 'musician quality' (bit accurate) card is one that uses the 8738 chip. its cheap and very common.

    I think it was M$ (I may

I have hardly ever known a mathematician who was capable of reasoning. -- Plato

Working...