Center a voltage for use with ADC

Discussion in 'The Projects Forum' started by Lilrayray, Mar 9, 2009.

  1. Lilrayray

    Thread Starter Active Member

    Feb 21, 2009
    31
    0
    Hi all,

    I am trying to amplify a signal and prep it for use with an ADC. Unfortunately, I am having difficulty centering the voltage in the 0 to +5V range. From what I have read, all it takes is a simple summer op-amp circuit that uses a voltage divider to cut the input voltage in half and add it to the input signal.

    Below I have attached a diagram of what I have come up with thus far: A simple non-inverting rig that should amplify the signal by ~32x and center it between 0 to +5V. Unfortunately, when I run simulations, the output voltage is still partially negative and saturates in the negative.

    Also, another quick question: does anyone know of a cheap usb-capable ADC converter capable of handling audio with decent resolution? I have considered the arduino, however it seems limited to recording a clap or similar.

    Thanks for the help!
     
  2. bertus

    Administrator

    Apr 5, 2008
    15,638
    2,344
    Hello,

    Do you want to amplify the signal in DC or may it be AC ?

    Greetings,
    Bertus
     
  3. mik3

    Senior Member

    Feb 4, 2008
    4,846
    63
    First disconnect R4 from ground and apply the signal between node 1 and R4. Second, put a capacitor in series with R4 as not to amplify the DC offset and saturate the amplifier. Finally, set the DC offset to 2V because the op amp cannot swing all the way to the supply rail voltage.
     
  4. Lilrayray

    Thread Starter Active Member

    Feb 21, 2009
    31
    0
    Im not sure I quite understand your instructions: Are you referring to the op-amp output as node-1? Also, I left out the capacitor because it seemed to be messing with the simulation.

    Is the diagram overly compressed? If you have difficulty viewing it, please tell me and I will re compress it as a .png.

    The signal is AC.
     
  5. mik3

    Senior Member

    Feb 4, 2008
    4,846
    63
    By node 1 I mean the bottom side of R1. There number 1 is written in red.
     
  6. Lilrayray

    Thread Starter Active Member

    Feb 21, 2009
    31
    0
    Wouldnt connecting the signal between node 1 and R4 completely mess up the feedback loop? I feel as if I am missing something very simple.

    Anyway, thanks for the help!
     
  7. mik3

    Senior Member

    Feb 4, 2008
    4,846
    63
    No, the feedback loop is determined by R3.
     
  8. Lilrayray

    Thread Starter Active Member

    Feb 21, 2009
    31
    0
    Ok, so I played around and I think I have fixed it!

    Attached below is my ~finished circuit (first two opamps strictly amplify and the third centers the voltage). Are there any glaring any issues with this circuit (and before you mention it, yes I will be placing a capacitor between the signal source and first opamp).

    Also, initially I attempted to use a voltage divider to cut the 5V source voltage in half and feed it into the final op-amp, however when I did so, the sinusoid was not shifted correctly and it was stretched vertically. Any idea why this might happen?

    Finally, about the op-amps themselves: I had read that the OP213s were decent for audio, however they are nearly $5.00 a piece, and as I will be making 3 or 4 of the circuits the price will go up (to be honest $30 isnt that much to worry about). I have read a lot about using NE5532/4s. Can I safely replace these OP213s in my circuit with NE5332s without obtaining any adverse affects?
     
  9. mik3

    Senior Member

    Feb 4, 2008
    4,846
    63
    Well, I don't think you need 3 op amps for what you want to achieve.

    What is the amplitude of the input signal?
    Is it a DC varying signal or an AC signal?

    What gain do you need?
     
  10. Lilrayray

    Thread Starter Active Member

    Feb 21, 2009
    31
    0
    Between 5 and 10 mV

    It's an AC signal (electret mic for example).

    A gain of 100 or 200 should suffice.
     
  11. mik3

    Senior Member

    Feb 4, 2008
    4,846
    63
    You can do it by just using one op amp.
     
  12. Lilrayray

    Thread Starter Active Member

    Feb 21, 2009
    31
    0
    I suppose, but I have been told that cascading two op-amps to achieve higher gains is generally better?
     
  13. mik3

    Senior Member

    Feb 4, 2008
    4,846
    63
    Yes it is better, but if you use an op amp with a gain-bandwidth product over 4MHz it will be quite fine because you won't amplify frequencies above 16KHz.
     
  14. Lilrayray

    Thread Starter Active Member

    Feb 21, 2009
    31
    0
    Hmm, ok, Ill give a single op-amp circuit a try..

    Also, do different op-amps require a considerable change in the circuit configurations, or will most similarly-specced opamps behave the same?
     
  15. thatoneguy

    AAC Fanatic!

    Feb 19, 2009
    6,357
    718
    Unsure on purpose of 2nd op amp. Wouldn't 68k feedback in first stage leave you with the 100 gain it looks like you are attempting?

    --ETA: You are running dual supply, +/- 5V, 10V total, yet want no negative peaks. Run the op amp single ended, 5V and ground, then use input through capacitor to a 2.5V biased input, just like a capacitive coupled transistor amplifier bias. This would leave you with the signal amplified, and centered on 2.5V as zero.
     
    Last edited: Mar 10, 2009
  16. Lilrayray

    Thread Starter Active Member

    Feb 21, 2009
    31
    0
    Ah, ok, I think I have it working! However, I do have two more questions:

    Foremost, the input signal will be a very low frequency <1kHz. Will coupling the input with a capacitor act as a high-pass filter and block out these lower frequencies?

    Also, this might be a rather stupid question, but what is the general output voltage of an electret mic? I cant seem to find any indication in the microphone's data sheet or elsewhere online!

    Thanks for all of the help!!
     
  17. thatoneguy

    AAC Fanatic!

    Feb 19, 2009
    6,357
    718
    I haven't seen the schematic you created, but the value of the coupling capacitor is the same as calculating a transistor amplifier cap.

    The RIN or input impedance at 1kHz so that it is capable of moving the voltage divider bias up and down to be amplified. This ties in closely with your second question.

    I'd suggest a trimmer pot on feedback to adjust gain to where you need it, It is doubtful that all fixed resistors will provide the full span of your ADC capability.
     
  18. Lilrayray

    Thread Starter Active Member

    Feb 21, 2009
    31
    0
    Ok, on the data sheet for the mics I am using recommends the use of a 10uF capacitor. I added this to my circuit, and now the signal is shifting up nearly 3 volts and saturating. I am assuming this has to do with the fact that it is now in series with R3. R3 is necessary for biasing the input, so removing it would have adverse affects on the circuit, would it not? I looked over a transitive amplifier circuit however I am unsure how to apply it to this setup.

    Also, using a potentiometer is a good idea and should make this far more manageable, thanks!
     
  19. thatoneguy

    AAC Fanatic!

    Feb 19, 2009
    6,357
    718
    Turn the signal generator down to mic level, then adjust gain to just below clipping.
     
  20. Lilrayray

    Thread Starter Active Member

    Feb 21, 2009
    31
    0
    the function generator is currently set to a 10mV amplitude (I didnt change it)
     
Loading...