Forum Rule: Always post complete source code & details to reproduce any issue!
Results 1 to 10 of 10

Thread: DIY USB Audio Cable

  1. #1
    Senior Member
    Join Date
    Jan 2015
    Location
    France
    Posts
    181

    DIY USB Audio Cable

    Hello,

    Nothing really related to teensy, but maybe someone have experience in a problem I face.

    For my hifi system, today I've build an USB cable to link the streamer to the DAC (USB 2.0). For this purpose I used AWG26 bulk silver wires that I covered with silk tubing (several layers). For the build, since my DAC don't need +5V, I omit this wire, so the cable use only 3 wires : GND, D+ and D-. They are each covered with silk tubing and then all covered with another silk tubing to make a "single" cable/

    The solder are good and there is nothing really bad with the build. This is my first USB cable, but I use to build other cables with success.

    Now the problem : there are crunches in the sound when I use this cable on my hifi. The higher sound rate I use (44K => 196K => DSD), the more crunches I ear.

    I'd like to know if someone have good advices to try to solve this problem. The system use USB 2.0, and the cable is type A-type B. I haven't any shield on it and I didn't twist D+ and D-.

    Thank you,
    Manu

  2. #2
    Senior Member PaulS's Avatar
    Join Date
    Apr 2015
    Location
    Netherlands
    Posts
    816
    I would not be surprised that not using a twisting data pair causes issues. After all, we are talking about high frequencies at 480Mbps.
    This spec clearly states that the data pair must be twisted.

    regards,
    Paul

  3. #3
    Senior Member
    Join Date
    Jan 2015
    Location
    France
    Posts
    181
    Thank you.
    This was my first guess. I’ll try to twist them tomorrow and report.

  4. #4
    Senior Member PaulStoffregen's Avatar
    Join Date
    Nov 2012
    Posts
    26,561
    Adding extra insulation between the wires could also be problematic. The amount and type of insulation is important. A certain distributed capacitance is expected. Even with the correct capacitance, if the wrong type of insulation is used, it could cause high frequencies to be attenuated.

  5. #5
    Senior Member
    Join Date
    Jul 2020
    Posts
    1,753
    Silk is likely one of the poorest choices for high speed data cable dielectric as it absorbs a lot of moisture (upto 30%), and moisture is very
    lossy at high frequency - this is why ethernet and other high speed cables are either polythene (PE) or teflon (PTFE) insulation which are
    both strongly hydrophobic and have moisture absorbancies below 0.1% according to the data I can find. Its certainly the case that most
    coax cable uses only polythene or foamed polythene as insulation, as this is the cheapest dielectric with adequate RF performance. USB 2
    at 480Mbps is well into the UHF/microwave bands and choice of dielectric is crucial.

    With cabling running at RF speeds you need to ensure it functions as a stable transmission line with constant characteristic impedance
    matched to the specification of the system involved, and with as low loss as possible.

    Varying levels of moisture cause big problems as water has a very high dielectric constant, as well as being lossy in itself, so if
    insulation can absorb moisture and dry out again as the weather changes its capacitance will change significantly, changing the
    characteristic impedance of the cable and leading to reflections and inter-symbol interference - general degradation of signal integrity.

    You certainly dont need silver wires either - silver plated copper will have all the advantages of silver at high frequencies, but its only a
    mere few percent better than copper any way so in most circumstances not worth it.

    In a USB cable the D+ and D- wires must be run as a symmetric transmission line (ie as a twisted pair) with a nominal impedance
    of 90 ohms.

    I think you've been confused by audiophools with only a vague understanding of electromagnetism and signal propagation?

  6. #6
    Senior Member
    Join Date
    Jan 2015
    Location
    France
    Posts
    181
    Hello,

    I finally solve this problem per twisting the D+ and D- wires and add a little bit of poor insulation.
    Thank you for all your valuable replies, all !

    @MarkT : I have knowledge (a least a little) in electromagnetism, crosstalk, etc. ;-) But I'm also curious. And yes, there are audiophools that often talk about strange things. Often on the same forums there are also trolls that state they don't know, at least. In my case, I just want to try, not to convince anyone that it's the graal or something to do... And currently due to chip shortage I have time to loose (too many) :-( I may end in a fast-food thing since it's look an easier way to earn a living today than to build electronic things...

    Another thing I think about since a long time, but never figured out if it's something I can do : Is teensy can be a good "interface" between a streamer and a DAC chip like Sabre 9038 chips (or others). If it's possible I'd like to build one DAC ;-)

    Cheer,
    Manu

  7. #7
    Senior Member PaulS's Avatar
    Join Date
    Apr 2015
    Location
    Netherlands
    Posts
    816
    Quote Originally Posted by Manu View Post
    Another thing I think about since a long time, but never figured out if it's something I can do : Is teensy can be a good "interface" between a streamer and a DAC chip like Sabre 9038 chips (or others). If it's possible I'd like to build one DAC ;-)
    If you are talking about USB-based streamer, yes, Teensy can do. Teensy can output I2S signals to suitable DAC's.
    Mind you though, the PJRC audio library that makes this all possible is limited to 16bit/44.1kHz.
    So a board like this is perhaps overkill.
    You may want to look into this board. The PCM5102 DAC is using 8x upsampling and sounds surprisingly well for it's price. And it is proven to work with a Teensy.

    Paul

  8. #8
    Senior Member
    Join Date
    Jan 2015
    Location
    France
    Posts
    181
    Thank you Paul. I was aware about the 44.4KHz limitation of the audio library and this was my main stop. Now that I have time to do some code, and before digging into it, can someone confirm that Teensy can do more than 16bit/44.1kHz if the right code is created ?

  9. #9
    Senior Member
    Join Date
    Jul 2020
    Posts
    1,753
    Yes - there are some variants of the Audio library out there supporting higher bit depths, and the 44.1kSPS is configurable by editing AudioStream.h in the core libraries,
    look for the AUDIO_SAMPLE_RATE_EXACT #define.

  10. #10
    Senior Member
    Join Date
    Jan 2015
    Location
    France
    Posts
    181
    Thank you. I'll give a look at it

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •