Serial audio transmission over cable

Discussion in 'General Electronics Chat' started by seanstevens, May 29, 2015.

  1. seanstevens

    Thread Starter Member

    Sep 22, 2009
    25
    1
    Hi All,

    I was wondering if anyone here has experience in transmitting audio in digital format over twisted pair or cable (any sort). I am aware of some of the digital audio protocols like I2S, SDPIF and PCM out there but I am trying to bounce the idea around to see what is best for the given environment and required quality.

    Rough requirements are:
    • simple serial protocol
    • 16KHz sampling max, i.e. audio can be up to 8KHz for example
    • transmission medium is cable
    • robust enough to withstand some environmental/electrical noise in the operating area
    • to be able to feed the serial audio up to 500 meters
    I am not sure if I can use a PCM chip and just feed the data to the cable, I cannot imagine it to be that simple. I am thinking of following blocks, audio pre amp, filter, A/D, transmission in to the media, possible booster in line, receiver section, filter, D/A filter and amp.
    Having looked at some available ICs out there, they are fairly fixed in either their speed, sampling frequency etc. not to sure about I2S where it may be possible to slow down the clock signal to the required speed.

    Just an idea I am playing around and thought to ask, its really similar to a normal analogue PA system but I want a digital version.

    Thanks,
    Sean
     
  2. MrChips

    Moderator

    Oct 2, 2009
    12,429
    3,360
    If you do not require hi-fi audio quality I would investigate using delta modulation.
    The system is easy to implement using standard building blocks, analog comparator, D/A, digital counter. You can run it at 500ksps or higher.
    The demodulator is simply an analog integrator.

    An addition to the delta modulation concept is to use analog compression before encoding and an expander after the demodulator. This will improve the dynamic range.
     
    Last edited: May 29, 2015
  3. nsaspook

    AAC Fanatic!

    Aug 27, 2009
    2,907
    2,165
  4. crutschow

    Expert

    Mar 14, 2008
    12,993
    3,229
    You might try a Toslink converter such as one of these. Toslink typically uses an optical connection for short runs but it also can use an RCA type 75Ω video (not audio) coax cable for longer runs.
    Not sure what the maximum distance is though. 500 meters is a very long run.
    You may need booster amps along the way.
     
  5. Papabravo

    Expert

    Feb 24, 2006
    10,137
    1,786
    In our audio products we used RS-485 drivers and receivers for all kinds of digital audio. They were always point to point connections so no multipoint connections.
     
  6. ian field

    Distinguished Member

    Oct 27, 2012
    4,413
    782
    You might be thinking of SPDIF. Another popular way of moving digital audio about.
     
  7. ian field

    Distinguished Member

    Oct 27, 2012
    4,413
    782
    One UK ISP is offering internet up to 3Mb speed on the old twisted pair originally installed by/for the GPO all those years before it was privatised and became BT.

    Digital audio should be easier on twisted pair.
     
  8. crutschow

    Expert

    Mar 14, 2008
    12,993
    3,229
    The simplest likely would be to use PWM modulation since it requires no synchronization and is relatively simple to decode at the receiving end (just requires a low-pass filter).
    For 8kHz audio you could use a PWM frequency of about 50-100kHz.
    For that distance and common-mode noise concerns, you probably want to send it over twisted pair, such as CAT-5 wire, with differential line drivers and receivers such as the RS-422 or the RS-485 types that Papabravo suggested.
    Those drivers should be good up to 4000' at 10MHz for properly terminated lines, so you should have no problem sending a lower frequency for the 1600' you want.
    If it's a problem you may need to add a receiver/transmitter buffer in the middle of the line.
     
    Last edited: May 30, 2015
    seanstevens likes this.
  9. ian field

    Distinguished Member

    Oct 27, 2012
    4,413
    782
    Another possible option is FM, the modulator and demodulator could be borrowed from a light beam communicator that are in various places online, a toroidal ferrite balun on each end of the twisted pair should be the biggest part of modifying the schematic.
     
  10. crutschow

    Expert

    Mar 14, 2008
    12,993
    3,229
    Below is the LTspice simulation of a very simple PWM circuit using only one CMOS Schmitt trigger inverter as the active device.
    U1A is connected as a relaxation oscillation whose effective trigger point is modulated by the input audio signal, modifying its duty-cycle and generating a PWM output.
    Because it's such a simple circuit the PWM frequency varies from about 100kHz to 200kHz over one input cycle which causes a small variation in the demodulated output ripple, but that should not be a problem in practice.
    The demodulated output is shown using a simple 2-pole RC passive filter at the output of a buffer inverter.
    There is a little ripple shown in the Demod output which should not be audible but can be reduced by further filtering if desired.
    The simulated harmonic distortion is about 1% for a 1Vrms input, which should be adequate for public address type use.
    If you want better than that you will need a more complex circuit.

    Simple PWM.gif
     
    Last edited: May 31, 2015
    seanstevens and AnalogKid like this.
  11. AnalogKid

    Distinguished Member

    Aug 1, 2013
    4,520
    1,247
    Crutschow - I was leaning toward delta or FM because I think the narrow PWM pulses at the signal peaks might not get down the line with the same fidelity as the wider pulses, causing amplitude-bsed distortion. Been too long since I found out, but I think delta and FM have more narrow power spectra than PWM for the same modulation percentage.

    But that is a very nice circuit.

    ak
     
  12. crutschow

    Expert

    Mar 14, 2008
    12,993
    3,229
    If you use RS-485 chips with a 10MHz limit for the transmission then I would not expect a fidelity problem with a 200kHz maximum frequency PWM waveform.
    Certainly PWM is probably not the optimum modulation, but I don't think the signal power spectra is a significant concern in this application.
    I was going for simplicity over optimum in the design (KISS to the max.) and I like the ease of decoding a PWM signal. :)
     
    Last edited: Jun 1, 2015
  13. AnalogKid

    Distinguished Member

    Aug 1, 2013
    4,520
    1,247
    Agree with all of that. I was commenting on the ability of the cable to deliver useable pulses after 500 m. FM pulses have 50% duty cycle at all frequencies, and you can decode them with a monostable and a lowpass filter.

    ak
     
    Last edited: Jun 2, 2015
  14. seanstevens

    Thread Starter Member

    Sep 22, 2009
    25
    1
    Thank you all for all your very useful and detailed inputs, it is really appreciated. This is forum at its best!

    MrChip - Will look at delta as long as the demodulator is simple, thanks.

    Insaspook - you asked why digital, I guess in an electrically noisy place where this could deploy, it would be easier to combat the noise? I maybe wrong of course, but then your link takes me to Microchip digital audio, maybe I misunderstood.

    Crutschow - thanks for the link to Toslink, I like to build something myself, so I like your PWM and excellent simulation and circuit and originally I was hoping to use CAT-5 cable as the medium which is perfect also the same for the RS485 which I had though to use, havent done anything with RS-422 before. One thing though, 50-100KHz region seem to be a pretty noisy section of the spectrum when it comes to electrically noisy environment (machinery noise) , I dont know how much lower or higher I could take that frequency.

    Ian Field & AnalogKid - FM is an option I guess, fidelity is not a major concern, PA quality isnt exactly HIFI as you know, obviously the more quality the better if it can be pumped down a CAT-5 and not be sensitive to the off missing bits hence why PWM or FM or I guess PCM would be good, but obviously demodulating the first two modes is much easier than the later. 500 meter is just a guess and max, simple boosters can sit in between if needed.

    Papabravo - thanks for that, this needs to be one master out to many slaves listening, like a PA system.

    Thank you all very much.
     
  15. nsaspook

    AAC Fanatic!

    Aug 27, 2009
    2,907
    2,165
    If IMHO it's only PA quality and not multi channel sound then analog balanced cable and line drivers/simple transformers will work just a well without the complications of A/D D/A conversions. The MCHP link was just for design ideas in case you did go digital.
     
    seanstevens likes this.
  16. crutschow

    Expert

    Mar 14, 2008
    12,993
    3,229
    I don't see 50-100kHz noise as a particular problem if you are using twisted pair CAT-5 and RS485 transmitters/receivers. Radiated induced noise into the line would be common-mode to both wires and the RS485 receiver is good at ignoring common-mode noise.
     
    Last edited: Jun 2, 2015
  17. seanstevens

    Thread Starter Member

    Sep 22, 2009
    25
    1
    nsaspook, thanks for that, I will look in to that, that would almost be the simplest method if analogue can handle up to 8K component.

    curtschow, yes theoretically I agree, but in practice I am not sure, guess depends on the environment.

    Thanks again to everyone, I will be looking further in to PWM and analogue methods.
     
Loading...