element14 Community
element14 Community
    Register Log In
  • Site
  • Search
  • Log In Register
  • Members
    Members
    • Benefits of Membership
    • Achievement Levels
    • Members Area
    • Personal Blogs
    • Feedback and Support
    • What's New on element14
  • Learn
    Learn
    • Learning Center
    • eBooks
    • STEM Academy
    • Webinars, Training and Events
    • More
  • Technologies
    Technologies
    • 3D Printing
    • FPGA
    • Industrial Automation
    • Internet of Things
    • Power & Energy
    • Sensors
    • More
  • Challenges & Projects
    Challenges & Projects
    • Design Challenges
    • element14 presents
    • Project14
    • Arduino Projects
    • Raspberry Pi Projects
    • More
  • Products
    Products
    • Arduino
    • Dev Tools
    • Manufacturers
    • Raspberry Pi
    • RoadTests & Reviews
    • Avnet Boards Community
    • More
  • Store
    Store
    • Visit Your Store
    • Choose Another Store
      • Europe
      •  Austria (German)
      •  Belgium (Dutch, French)
      •  Bulgaria (Bulgarian)
      •  Czech Republic (Czech)
      •  Denmark (Danish)
      •  Estonia (Estonian)
      •  Finland (Finnish)
      •  France (French)
      •  Germany (German)
      •  Hungary (Hungarian)
      •  Ireland
      •  Israel
      •  Italy (Italian)
      •  Latvia (Latvian)
      •  
      •  Lithuania (Lithuanian)
      •  Netherlands (Dutch)
      •  Norway (Norwegian)
      •  Poland (Polish)
      •  Portugal (Portuguese)
      •  Romania (Romanian)
      •  Russia (Russian)
      •  Slovakia (Slovak)
      •  Slovenia (Slovenian)
      •  Spain (Spanish)
      •  Sweden (Swedish)
      •  Switzerland(German, French)
      •  Turkey (Turkish)
      •  United Kingdom
      • Asia Pacific
      •  Australia
      •  China
      •  Hong Kong
      •  India
      •  Korea (Korean)
      •  Malaysia
      •  New Zealand
      •  Philippines
      •  Singapore
      •  Taiwan
      •  Thailand (Thai)
      • Americas
      •  Brazil (Portuguese)
      •  Canada
      •  Mexico (Spanish)
      •  United States
      Can't find the country/region you're looking for? Visit our export site or find a local distributor.
  • Translate
  • Profile
BeagleBoard
  • Products
  • Dev Tools
  • Single-Board Computers
  • BeagleBoard
  • More
  • Cancel
BeagleBoard
Blog BBB - Building a DAC - part 2
  • Blog
  • Forum
  • Documents
  • Members
  • Mentions
  • Sub-Groups
  • Tags
  • More
  • Cancel
  • New
BeagleBoard requires membership for participation - click to join
Blog Post Actions
  • Subscribe by email
  • More
  • Cancel
  • Share
  • Subscribe by email
  • More
  • Cancel
Group Actions
  • Group RSS
  • More
  • Cancel
Engagement
  • Author Author: shabaz
  • Date Created: 9 Feb 2014 10:51 PM Date Created
  • Views 685 views
  • Likes 7 likes
  • Comments 16 comments
  • texas-instruments
  • audio
  • beaglebone_black
  • burr
  • burr_brown
  • beagleboneblack
  • hifi
  • bbb
  • BeagleBone
  • texas_instruments
  • hifi_mixed_signal_dac
  • ti
Related
Recommended

BBB - Building a DAC - part 2

shabaz
shabaz
9 Feb 2014

(BBB - Building a DAC part 1 can be found here).

Part 3 implements a complete design in an enclosure for a Sonos-like solution.

Introduction

The BeagleBone Black (BBB) has a digital audio interface and this was explored slightly in an earlier post.

The findings from that prototype were used to construct up a DAC board and it is described here. The aim was to have a relatively simple, easy-to-assemble board designed for portable use (headphone or small speakers) but with at least iPod-level performance. The circuit is described here and the complete schematic is attached to the post. The entire circuit connects to the BBB using 6 pins and needs no separate power supply. This is a recording using just the microphone from the camera - actual audio quality is much better.

You don't have permission to edit metadata of this video.
Edit media
x
Upload Preview

 

For a better quality, the audio from the prototype can be heard in this zipped mp3 file. This was directly recorded from the headphone output so that it is more representative of what the user will hear (the original track that was played through the DAC was downloaded from Amazon, for comparison purposes).

 

Detailed Description

This is the functionality on the board:

The DAC integrated circuit and headphone amplifier portion were left unchanged from the part 1 prototype although the DAC was replaced with TI’s PCM5102 which is pin-compatible with the earlier PCM5101A. The PCM5102 device is used in commercial DACs such as Meridian’s Explorer.

The remainder design is kept simple too. Three regulators are used to supply power to the DAC (can be reduced to one to save costs, or replace with the lower cost pin-compatible TC1015-3.3):

An optional speaker output was desired, and the selected device was LM4861 which can run from a single low voltage supply and offers over 1W of power. This is enough to provide loud volume for home use (in the video above, the single mono speaker was a couple of meters away and the audio was played at a volume setting of 15 on mplayer). The circuit uses two of these for stereo, although only one needs fitting for mono summed speaker output (the photo above shows only one populated). The LM4861 input is driven from the headphone output, not the line output, to keep line output and headphone outputs as distortion free as possible.

The speakers are muted using the LM4861 shutdown pin driven from the headphone socket built-in switch.

The board was tested with headphones, a small 4 ohm speaker and a larger home speaker. Sound was as expected, and there are no known issues although more testing needs to be done. The board runs cold unless driving a speaker, in which case the LM4861 which is intended to be run without heatsinking in normal temperatures, would perhaps benefit from a tiny heatsink such as this one. The BBB image that I used outputs 16-bit audio at 48ksample/sec (i.e. the sound is as good as a regular CD player), but the DAC will work at higher resolution and sample rates for those with recordings that would benefit from it. The board was tested on an older Angstrom image and a Debian image. There are discussions in the comments section in the earlier post describing current ongoing exercises to get drivers working for different settings.

 

Summary

The described circuit is low cost and provides hopefully nice performance. The complete schematic and parts list is attached.

Attachments:
dac-documentation-v1.zip
dac-cam.zip
Anonymous

Top Comments

  • Former Member
    Former Member over 7 years ago +1

    I taught myself to make PC boards, using the free gEDA tools (gschem and pcb). My first project was a small 1.5x2 inch Beaglebone outboard 2 channel DAC.  I'm also using the pcm5102a, due to the ease of…

  • Former Member
    Former Member over 7 years ago +1

    There is a nice discussion of how to add a PCM5102A-based audio device driver to linux: Sitara Linux SDK Audio DAC Example - Texas Instruments Wiki

    You can use it "as is" with shabaz's design. This lets…

  • clem57
    clem57 over 2 years ago +1

    shabaz do you think this would work on the BB-AI? If you can, please try it out.

    Thanks Clem

  • clem57
    clem57 over 2 years ago

    shabaz do you think this would work on the BB-AI? If you can, please try it out.

    Thanks Clem

    • Cancel
    • Up +1 Down
    • Reply
    • More
    • Cancel
  • jithu_element14
    jithu_element14 over 4 years ago in reply to Former Member

    Hey hi John Rhoades,

    I am also trying to play mp3 audio on beaglebone black using PCM5101A-based DAC. i wanted to know that is this not possible without building its driver into the kernel? I am not and expert in linux.so any other possible way of doing it?

     

    Thanks,

    Jithu

    • Cancel
    • Up 0 Down
    • Reply
    • More
    • Cancel
  • Former Member
    Former Member over 7 years ago

    There is a nice discussion of how to add a PCM5102A-based audio device driver to linux: Sitara Linux SDK Audio DAC Example - Texas Instruments Wiki

    You can use it "as is" with shabaz's design. This lets you get rid of the pesky BCLK inversion problem, as well as use sample rates other than 48kHz. Of course, to use a BCLK rate that is not a multiple of 48kHz, you need an external MCLK source. If you want the ultimate fidelity, an external low-jitter MCLK source is necessary, but fidelity with the internal MCLK is really pretty awesome. I can barely detect any difference between external and internal clocking on my $10K hifi system. What I hear is that positions of instruments are slightly more clear and precise, and transients like piano notes are more distinct, with the external clock. Don't hold me to a blind testing!

     

    If you wish to supply the MCLK externall just change

     

    ret = snd_soc_dai_set_sysclk(cpu_dai, 0, sysclk, SND_SOC_CLOCK_OUT);

    to

    ret = snd_soc_dai_set_sysclk(cpu_dai, 0, sysclk, SND_SOC_CLOCK_IN);

    and activate the appropriate pinmux for AHCLKX.

     

    Although this example is based on kernel 3.12.10, I found it quite easy to adapt for kernel 3.15.4. I wish this had been available last Jan., it would have saved me a lot of work.

    • Cancel
    • Up +1 Down
    • Reply
    • More
    • Cancel
  • shabaz
    shabaz over 7 years ago

    Hi John,

     

    Good stuff! Nice compact board.

    • Cancel
    • Up 0 Down
    • Reply
    • More
    • Cancel
  • Former Member
    Former Member over 7 years ago

    I taught myself to make PC boards, using the free gEDA tools (gschem and pcb). My first project was a small 1.5x2 inch Beaglebone outboard 2 channel DAC.  I'm also using the pcm5102a, due to the ease of interfacing and the small number of external parts needed. The central chip is the DAC and the other large rectangular chip is a crystal oscillator that generates the master clock. I used 3 x 3.3 v regulators with plenty of bypass capacitance, and I cannot detect any trace of digital grunge. I thought that working with very tiny SMD parts would be problem, but actually it is easier than the old way. Fewer holes to drill, and solder bridges are easily fixed using solder wick.

     

    • Cancel
    • Up +1 Down
    • Reply
    • More
    • Cancel
>
Element14

element14 is the first online community specifically for engineers. Connect with your peers and get expert answers to your questions.

  • Members
  • Learn
  • Technologies
  • Challenges & Projects
  • Products
  • Store
  • About Us
  • Feedback & Support
  • FAQs
  • Terms of Use
  • Privacy Policy
  • Legal and Copyright Notices
  • Sitemap
  • Cookies

An Avnet Company © 2022 Premier Farnell Limited. All Rights Reserved.

Premier Farnell Ltd, registered in England and Wales (no 00876412), registered office: Farnell House, Forge Lane, Leeds LS12 2NE.

ICP 备案号 10220084.

Follow element14

  • Facebook
  • Twitter
  • linkedin
  • YouTube