help interfacing DAC with amplifier

Thread Starter

abc77

Joined May 10, 2017
59
I want to interface 24bit DAC(PCM1789) with line/audio amplifier(TPA6138A2). But how do i make the output voltage level of DAC compatible with the input of audio amplifier?

As i understand DAC datasheet, the DAC output voltage of 1.6*VCC1, and if VCC1 is 5V then this would mean 8V(peak to peak). However as I understand, the accepted input voltage for the amplifier is 0V to 3.3V. Did I read the datasheet correctly?
 

crutschow

Joined Mar 14, 2008
34,283
You need to completely read the data sheet.
The DAC output is 1.6*VCC1 differential.
This must be converted to single-ended signal and filtered by a differential circuit such as shown in Fig. 37 or Fig. 38 on page 30 of this data sheet.
Those give a single-ended output of 2Vrms, which should be acceptable to your amp.
The explanation for this is in paragraph 8.1.3 on page 29.

Of course you will need a volume control pot between this output and your TPA6138A2 amp.
 

crutschow

Joined Mar 14, 2008
34,283
From a cursory look, it appears okay, except for the value of R21 and R22 that's 47Ω in the data sheet but 47kΩ in your schematic.
That resistor is likely to prevent oscillations from a capacitive load and should not be needed if you put a volume pot at that point.

What is generating the digital inputs?
 

Thread Starter

abc77

Joined May 10, 2017
59
thank you for the review and your time. yeah it is 47KOhm, i mistakenly put 47Ohm.

this is my first try using DAC/amp circuit meant for stereo headsets. question i had is, the output from DAC is 2Vrms but what is it like? will it be 0V to 2Vrms? will there be clipping of signal(goes below zero) or is the mid voltage 1V?

is POT necessary? i rather don't want to put a POT really, any better solution to keep the signal level output in consistent with amplifier input such that I be able can control volume from headset.

The digital input is coming from Microcontroller. anything i might be missing here?

thank you
 

crutschow

Joined Mar 14, 2008
34,283
this is my first try using DAC/amp circuit meant for stereo headsets. question i had is, the output from DAC is 2Vrms but what is it like? will it be 0V to 2Vrms? will there be clipping of signal(goes below zero) or is the mid voltage 1V?
It's 2Vrms for maximum music level from the source.
It will go below zero but that's usual for an AC audio signal. They normally are plus and minus around zero.
is POT necessary? i rather don't want to put a POT really, any better solution to keep the signal level output in consistent with amplifier input such that I be able can control volume from headset.
It's not necessary, but then your amp will be putting out the maximum output at all times.
Is that okay?
The digital input is coming from Microcontroller. anything i might be missing here?
The micro is configured to put out the proper digital signal that the D/A requires as an input?
Where is the micro getting the audio signal?
 

Thread Starter

abc77

Joined May 10, 2017
59
hi,

if there is clipping, will not the signal be lost?

i forgot to put the TRRS connector with microphone input. below is the updated picture of the audio socket. herein, do i need to put an amplifier between the microphone signal coming from the socket and microcontroller ADC? if so how do i choose the amplifier? i mean i don't know the amplitude level coming from standard headset at the socket.

about the POT, i wanted the output audio level at some mid range acceptable range so to say such that the user can tune the volume using the volume control that are build in typical headset. Or, I can also put a POT but not bulky analog one or a preset POT which are small in size.

i haven't done the micro to DAC yet but the digital samples are transferred using SPI

the micro is getting audio from PC using USB connection

thank you
 

Attachments

crutschow

Joined Mar 14, 2008
34,283
if there is clipping, will not the signal be lost?
Yes, it will be severely distorted..
You just need to attenuate the signal by proper selection of R9 and R11 so clipping in the amplifier doesn't happen (if you don't add a pot, which could be a small trimpot).
 

Thread Starter

abc77

Joined May 10, 2017
59
by clipping i meant that if signal goes below zero. so do i have to lift up the mid voltage from zero to 1V?

do you think i need to add amplifier between audio socket to the microcontroller ADC pin?
 

crutschow

Joined Mar 14, 2008
34,283
by clipping i meant that if signal goes below zero. so do i have to lift up the mid voltage from zero to 1V?
U2 will handle a plus and minus voltage if it has a plus and minus power supply.
Your schematic doesn't show any power to U2.
do you think i need to add amplifier between audio socket to the microcontroller ADC pin?
What micro?
So you are converting an analog signal to digital with a micro and then back to analog by U1?
Why?? :confused:
 

Thread Starter

abc77

Joined May 10, 2017
59
so i have made the +1.65ve and -1.65ve for the op-amps from the +3.3V supply, attached is pic. is it good?

I am thinking of using PIC24 or more higher end or AVR. it should be capable of handling audio though.

the mic is for processing speech signal. this 3.5 audio circuit is part of a larger system.

the micro ADC has either 5V or 3.3V(depending on microcontroller) so knowing the audio signal amplitude level from the microphone would allow to know whether amplifier is required or not.

but i don't know and can't find concrete microphone signal amplitude level.

thank you
 

Attachments

Thread Starter

abc77

Joined May 10, 2017
59
of-course i did check the datasheet initially, attached is the initial one(was connected to 5V) but later somehow changed it to 3.3V, my bad. but i am also not so proficient to catch up the mistake... is the supply now ok, because also my first time using -ve an +ve rail like this, came to know from web.

can you tell how i could do the microphone input to the MCU( such as PIC24 or PIC32 ) ADC?
 

Attachments

bertus

Joined Apr 5, 2008
22,270
Hello,

Your split supply will not work, as the centre and -a are connected together by the ground symbol.

abc77_6.jpg

Bertus
 

Thread Starter

abc77

Joined May 10, 2017
59
@ crutschow,

the microphone is for typical handfree headset(those with microphone, volume control, call accept/end buttons). Do i need specific name of the headset and its specification? because my view was and thereof my intention is to make the circuit work with most of the headsets. If i needed specification, what parameters should will i be looking for and how to fit them to my design? any steps for design?

thank you
 

crutschow

Joined Mar 14, 2008
34,283
You need to know what mic's output AC voltage is for a typical voice input and whether it needs any bias voltage to operate.
Then we can think about what the interface design would be.
 
Top