# Sampling DC offset of a composite signal

Discussion in 'Electronic Design' started by Stephen Boulet, Dec 20, 2004.

1. ### Stephen BouletGuest

I have a DC voltage with an AC signal superimposed on it. Is there a
simple circuit to get the DC offset? If a digital volt meter can do it ...

I'm trying to use the DC voltage to null out a DC offset in a
differential signal. Our application uses only positive voltages.

Stephen

2. ### Kevin AylwardGuest

Yes. A resister and a capacitor LP filter!!!

Kevin Aylward

http://www.anasoft.co.uk
SuperSpice, a very affordable Mixed-Mode
Windows Simulator with Schematic Capture,
Waveform Display, FFT's and Filter Design.

3. ### John WoodgateGuest

I read in sci.electronics.design that Stephen Boulet
How about a low-pass filter?

4. ### Nicholas O. LindanGuest

1) Chopper stabilize the signal by chopping the AC source.

2) Filter the *&(@# out of it with an LP filter.

3) If the AC signal is fixed frequency then integrate the signal
for one (or more) AC cycles or sample the signal at 1/2 the
AC frequency and average the two measurements.

4) Use an integrating measurement of sufficient length that the
AC signal is insignificant.

5) Get a better signal source.

If you sample fast enough all the filtering/integrating can
be done in software.

However, I am not quite sure what you mean by 'only positive
voltages'. After you subtract the DC offset from the signal
the remaining AC will be negative half the time. If the system
is strictly analog you will need to have a virtual ground somewhere.

5. ### Stephen BouletGuest

The signals are differential, each centered at 1.75 V. The AC signal
superimposed on them can go as high as 0.8 Vpp, so the overall voltage
is always positive. The bandwidth of the signal is from about 3 kHz to
75 kHz.

I'm not so used to working down at audio frequencies. Taking your idea 4
(since it seems an active filter is needed), I can make a 1st order
filter with an op amp in the inverting configuration (say 1 Mohm in
parallel with 0.1 uF in the feedback path and a 1 Mohm resistor going
into the inverting terminal). That would give me about 0.8 mV of ripple,
not even taking into account part tolerances. I am feeding a dc offset
into the non-inverting terminal, so the fact that it's an inverting amp
is ok.

I'll probably need a second order filter -- my max suggested error in
common mode voltage is 1 mV.

Thanks for the ideas.

Stephen

6. ### Nicholas O. LindanGuest

Ah, that's different. I thought you had a DC offset voltage to be
gotten rid of.

If you want the AC w/o the DC why not just use a differential
amplifier? A _real_ diff. amp works better that the usual 1-trick
pony. You will need to reference to a virtual ground, though ...

If you want the DC without the AC why not just add the two signals.

A small 1:1 audio transformer will remove any common mode DC, and
is possibly the most sensible solution.

To eliminate common mode errors due to the DC I would suggest using
capacitive coupling.

7. ### MacGuest

View the following ascii-art schematic with courier or a similar
fixed-width font.

diff in + ----------+
|
\
/ R Low offset
\ voltage op-amp.
/ |\
| | \
+---------+------------|+ \_______ Vout
| | +--|- / |
\ --- C | | / |
/ R --- | |/ |
\ | +----------+
/ |
| --- GND
diff in - ----------+

Vout will be your DC offset, if I understand you right.

This is a simple low-pass filter with a time constant of RC/2. So you
should choose R and C such that the frequency is well below the lowest
frequency of interest. Also, you have to be careful that R is not too
big because op-amps do have input bias current, and you want the
maximum input bias current (see the datasheet) to be much less than the
DC current flowing through R. So you want an op-amp with a low offset
voltage and a low bias current.

What the heck. We might as well choose R and C.

We probably don't want to use a capacitor any bigger than 10 uF. So we'll
set C to 10 uF and choose R based on that. We'll set f to 300 Hz, since
that is one tenth of your cutoff frequency. This will assure minimal
attenuation at frequencies of interest.

f = 2 * pi * R/2 * C
R = f / (pi * C)
R = 300 / (pi * 10uF)
R = 30 / (pi * 1uF)

This is around 10 * 1,000,000 which is 10 Megohms. You will need to find
an op-amp with a very low input bias current, or choose an even larger
capacitor.

So, tentatively, we have:
R = 10 Megohm
C = 10 uF

You could also use less uF or megohms, and accept more attenuation
near the low end of your band. Or you could cascade multiple op-amp
low-pass stages to get good performance with more reasonable values for R
and C. For example, you could put your cutoff frequency at 1000 Hz, and go
through three stages. You might want to put together a spreadsheet to try
different scenarios.

And you should double-check all my calculations. I've been known to make
mistakes!

HTH

--Mac

<AOL>
Me, Too!
</AOL>

;-)
Rich

9. ### BanGuest

Use a DC-servo made from a precision opamp and a first order LP(to maintain
stability) feeding back into the reference input of the existing amp. You
will need 2circuits for both sides of the bridge. You do not need a second
order filter. If there is some ripple because of the finite attenuation, you
will not change the DC-level, but attenuate the lower frequencies, just like
a high-pass. actually if you choose the input capacitor a little bigger, you
can compensate for this.

10. ### BanGuest

That is very true.
the time constant is R*C
fg= 1/(2pi*R*C)
with C= 0.1uF and 100Hz I get here 15k915, just take 15k.

11. ### John WoodgateGuest

I read in sci.electronics.design that Stephen Boulet
With one op-amp you can make a third-order filter. But be careful which
op-amp you choose. And audio op-amp won't make a good filter at 75 kHz.
You need a faster one.

12. ### Fred BloggsGuest

You have two inputs V1= VDC + Vac/2 and V2= VDC-Vac/2 and Vac is the
"signal"? -the only possible interpretation of "signals are
differential." So what the hell do you want to pick off, VDC or Vac? If
it's VDC then you've been given your answer, a summer. Or is it Vac, in
which case you use an ac-coupled differential amplifier. What is your
problem? Is this a single supply application you can't figure out?- or
homework? Take it to sci.electronics.basics.

13. ### Don LancasterGuest

And the problem with a low pass filter is...?

--
Many thanks,

Don Lancaster
Synergetics 3860 West First Street Box 809 Thatcher, AZ 85552
voice: (928)428-4073 email:

Please visit my GURU's LAIR web site at http://www.tinaja.com

14. ### AlGuest

Uhh, you analog guys is hard to please ;-)

Al

15. ### MacGuest

Boy, I really screwed that one up. Thanks for correcting me. The only
thing I got right was using R/2 instead of the usual R, because, if you
look at my schematic, the resistors are in parallel with respect to the
common mode input.

So you should use:
fq= 1/(pi*R*C)

15k and 0.1uF will still work fine if the lowest frequency of interest is
3000 Hz.

--Mac