# small ac to dc voltage follower

#### alfak20

Joined Sep 30, 2010
10
My input signal is from 0 to about 30mV. I have to use op amp (due to high impendance -LM324 maybe) to convert that voltage to DC voltage 0-5 VDC ?

#### MrSalts

Joined Apr 2, 2020
106
Well, if your signal max is 30mV, then you'll need 166x gain and you'll want the 0 to correspond to zero. You can try the LM358 or LM324 but you'll need supply voltage about 1.5v more than your max output voltage. So 6.5 to 9v. Even 12VDC or more will give the same output waveform.

#### Audioguru again

Joined Oct 21, 2019
2,374
You did not say if the 30mV is RMS, peak or peak-to peak. You also did not say the maximum frequency.
The lousy old LM324 with a peak-to-peak gain of 166.7 times has trouble above 2kHz and full of noise (hissss) since the gain is so high. Then you must rectify it without a rectifier voltage loss and filter it into the DC you want.

#### MrSalts

Joined Apr 2, 2020
106
Note, I assumed the 0 to 30mV was positive range so 15mV peak (30mV peak-to-peak) with a 15mV positive offset.

#### Audioguru again

Joined Oct 21, 2019
2,374
You said you want the output to go from 0V to +5V but I think you want it to be AC with a +2.5V DC offset, not DC. With the low performance LM324 the unknown frequency is very important.

#### alfak20

Joined Sep 30, 2010
10
To be precise: AC input signal is 30mV p-p, frequency is 50 Hz, DC output should follow input voltage - that means when AC is going from 0-30 peak-peak then DC is going from 0-5VDC. At the input I must put one buffer because of high impendance request, but the rest of the circuit must be somehow better than just diode+capacitor that is the thread - anyhow thanks to all of you for the fast reaction -but the problem is not so easy to resolve - may somewhere exists chip to get this job done.

#### AnalogKid

Joined Aug 1, 2013
8,805
Still NOT clear. Is the input signal

a sine wave
a square wave
a triangle wave
a sawtooth wave

or some other wave shape?

It sounds like you want a DC output voltage that is proportional to the peak-to-peak amplitude of the input waveform. Is this correct?

ak

#### Audioguru again

Joined Oct 21, 2019
2,374
Since your output is AC with a DC offset then a rectifier and filter capacitor is not needed unless you want only DC at the output.
What "high impedance" input do you want? The input impedance of the LM324 quad or LM358 dual is not shown on its datasheet but it is at least 300k ohms. A BiMOS single opamp like a TLC071 has an input impedance of 1000G ohms.

#### alfak20

Joined Sep 30, 2010
10
Still NOT clear. Is the input signal

a sine wave
a square wave
a triangle wave
a sawtooth wave

or some other wave shape?

It sounds like you want a DC output voltage that is proportional to the peak-to-peak amplitude of the input waveform. Is this correct?

ak
Input signal is sine wave - so, over time that signal changes amplitude - i just want DC voltage that follows that changes as I said some kind of DC follower.
The reason for high impendance : I dont want to sink input signal, it is like digital voltmeter ...after that I am going to "transfer" that DC voltage using 4-20mA using AD694 but that has been already solved, the problem is just that input circuit that has to be precise (as we can to make it precisely)

#### AnalogKid

Joined Aug 1, 2013
8,805
We might be having a language problem ...

A DC voltage that "follows the instantaneous shape of a sine wave IS a sine wave. Are you talking about shifting the wave, such as translating it so that the negative half-cycles are above GND? A sinewave with all parts of it being positive voltages, such as the negative peaks at GND and the positive peaks at 5 V?

ak

#### crutschow

Joined Mar 14, 2008
25,992
It would seem that you could use an op amp precision rectifier with gain and filter out to get DC from your AC input..

What is the output impedance of your source?

Last edited:

#### MrSalts

Joined Apr 2, 2020
106
Input signal is sine wave - so, over time that signal changes amplitude - i just want DC voltage that follows that changes as I said some kind of DC follower.
The reason for high impendance : I dont want to sink input signal, it is like digital voltmeter ...after that I am going to "transfer" that DC voltage using 4-20mA using AD694 but that has been already solved, the problem is just that input circuit that has to be precise (as we can to make it precisely)
Please draw the incoming waveform (label 0V and peak) and outgoing waveform at 0V, 5mV and 30mV

#### Audioguru again

Joined Oct 21, 2019
2,374
Forget about the word "follower" and do not look at the schematic that has a wrong input of +15mV and -15mV peak-to-peak.
The input sinewave is 0V to +30mV peak-to-peak and the amplifier output should be 0V to 5V peak-to-peak.
The required "high input impedance" of the opamp is unknown and the max frequency is also unknown.

#### Ian0

Joined Aug 7, 2020
1,121
Is the output to be linear or in decibels?

#### Audioguru again

Joined Oct 21, 2019
2,374
Is the output to be linear or in decibels?
He said that when the input is 0V to +30mV peak-to-peak then the output must be amplified to 0V to +5V peak-to-peak.
Decibels are important since the max flat frequency response of an opamp is shown in its datasheet on a frequency/gain graph.

#### Ian0

Joined Aug 7, 2020
1,121
He said that when the input is 0V to +30mV peak-to-peak then the output must be amplified to 0V to +5V peak-to-peak.
Decibels are important since the max flat frequency response of an opamp is shown in its datasheet on a frequency/gain graph.
I was just wondering if he wanted the output on a logarithmic scale, so 5V out = 30mV in, 4V out = 3mV in, 3V out = 300uV in.
He didn't say where the signal came from, it could be some transducer such as a measurement microphone.

#### Audioguru again

Joined Oct 21, 2019
2,374
I think a (dynamic) microphone would produce a +15mV and -15mV peak-to-peak signal, not just positive-going.

#### RPLaJeunesse

Joined Jul 29, 2018
139
If the OP would specify what is really needed that would be helpful. OK, it is 30mv p-p at 50 Hz. Is there a DC bias on that? If one adds AC coupling to eliminate bias then the signal is +/-15mV with respect to common. But precision AC coupling a 50Hz signal would mean a capacitor with a long time constant and this may not be acceptable at startup. Is direct coupling with a somewhat sophisticated DC bias cancellation scheme needed? Does the OP want a level shifter with gain, a precision half-wave rectifier, or a precision full-wave rectifier? With or without peak sampler? With or without lowpass filter? What corner frequency and how much ripple rejection in the filter? What supply voltage is available? Supply power available? And what is "precision" (in % or bits accurate)? Precision over what temperature range? So many questions need answering! Perhaps an overview of the whole system and what it is used for would be a starting point.

#### Audioguru again

Joined Oct 21, 2019
2,374
I wonder what produces a 50Hz sinewave that does not have an average voltage of 0VDC but instead has all its negative peaks at 0VDC?