That is correct. However, this application calls for a microphone amplifier in order to detect the presence of a signal using the internal ADC of a MCU powered from a single voltage supply.Another possible problem is that the output of the opamp averages +6V and needs a coupling capacitor to feed another circuit to block the +6VDC.
Thanks for spending time explaining to me ! Really appreciate it. Hope you can enlighten my doubt.The problem is the +6V offset on the bottom side of the sinewave generator. Usually, any signal generator is referenced to GND.
Consider what happens when we turn the amplitude of the sinewave output down to 0V amplitude. The DC voltage of the inverting input of the opamp is at +6V. The voltage at the non-inverting input is also at +6V because of the voltage divider. In other words, the two inputs are at the same voltage. In general, any opamp circuit with proper negative feedback resistor will always have the inverting and non-inverting inputs at the same voltage. Any voltage difference would be amplified by the opamp's open-loop gain and the output of the opamp would hit the supply voltage rail (either V+ or V-). In our example shown, the output is at +6V, regardless of the circuit gain -R2/R1.
In order to reference the signal generator back to 0V, we have to break the DC path. We do this by "AC coupling" the signal generator to the inverting input of the opamp using a capacitor.
View attachment 145850
With the capacitor in place, the signal generator can be referenced to any voltage. The voltage at the inverting input is still +6V.
Why?
That is because the role of the feedback resistor and very high open-loop gain of the opamp means that the output of the opamp has to reach a voltage to force the difference voltage at the two inputs to zero.
Now, does this circuit resemble your microphone amplifier circuit?
Thanks for spending time explaining to me ! Really appreciate it. Hope you can enlighten my doubt.
When you say that when the sine wave amplitude is bring down to 0V the inverting will be at 6V ? I thought there is a feedback resistor R2 and the voltage will be divided through R1 and R2. I also not quite sure why the output will be 6V regardless of the gain -r2/r1. Is it because the non inverting is at 6v so the inverting will follow 6v (ideal opamp). I do understand that the capacitor is to block the dc voltage. But what do you mean by reference to any voltage? Also in the video what is the reason to bring the DC offset to 2.5v . Thank you so much !
Yes. That is the correct answer. The value of R2 is not important. Let us take, as an example, R2 = 0Ω. The opamp will amplify the difference between Vin+ and Vin- by its open loop gain which can be as high as 100,000. Suppose the difference is 10μV. The output would be 10μV x 100,000 = 1V. But that is not going to happen because the output is fed back to the inverting input. This is negative feedback. In other words, the system self-stabilizes until (Vin+ - Vin-) = 0V.Is it because the non inverting is at 6v so the inverting will follow 6v (ideal opamp).
The capacitor C1, in essence, is a high pass filter. Any signal at 0Hz is rejected. Only frequencies above 0Hz are allowed through. This means it does not matter what is the value of the DC voltage (within some maximum limitation). Your microphone is biased with 12VDC. This is not seen at the Vin- input of the opamp.But what do you mean by reference to any voltage?
I have already explained this in tremendous detail and with substantial effort. This is the entire purpose of this thread which has been dragged out to 26 posts. Instead of repeating the same question, how about you expand on what it is that you do not understand.Also in the video what is the reason to bring the DC offset to 2.5v .
Well, phooey I say to you!Mr.Chips, your circuity is pfttt (an expression a Scottish guy I knew used, pronounced "sir-QUE-i-tree is fut", which isn't really true here since the smoke is still inside)
Your circuit at 18 is biasing the input signal to +6 V, which is not a happy situation for an inverting amp on a single positive supply. You could bias with -6 V, as long as you take a gain less than 2 with 12 V supply.
His circuit is fine and will work as shown. I suggest you read *all* of the symbols on the schematic. I disagree with his technique of using the same symbol for a voltage source and its return, and having a positive voltage source symbol pointing downward, but the schematic is correct.Mr.Chips, your circuity is pfttt
Your circuit at 18 is biasing the input signal to +6 V, which is not a happy situation for an inverting amp on a single positive supply. You could bias with -6 V, as long as you take a gain less than 2 with 12 V supply.
Actually, I'm also to blame. I knew the resolution of the images was not the best but I was in a rush to get the circuits posted for the TS. I should have posted clearer images. Next time I will.Mr. Chips
I'm sorry, I was looking post 17, not 18 AND I misread the the +6V on the NII as 0V. You're absolutely right, all is well in that case.
I should know better than to look at things like that on the computer I was using. I've made errors before because I can't see well enough and misread things. But it is my lounging computer whereas my other one is my sittin' like I'm workin' (which I don't do anymore) computer.
I presume that you know you can get one-day prototyping service from apcircuits.I should add: I've made some remarkably dopey errors in simple circuits on prototype PCBs. I very rarely breadboarded anything and didn't use simulation much, so I usually went from a paper design directly to a PCB. Lots of what I did was very difficult to breadboard anyway. One thing I learned was to do all of the calculations for a circuit before laying out the PCB instead of while I was waiting for delivery of bare boards. I couldn't use most of the fast turn outfits because they wouldn't do things like 4 oz copper on 3/32" laminate, so I usually had to wait a week or more for boards. Doing all the calc's before layout proved to be a good way of finding things that were wrong, and often it was a resistor to the wrong place in an amp circuit. I've probably said "D'oh" almost as many times as Homer.
Okay maybe i should elaborate more about my doubt. From what i understand , the voltage divider at the non inverting of the opamp is what creates the DC Offset. Does that mean the circuit you drew have an offset of 6v ? So the sine wave will oscillate at the 6v dc offset ?Also, as discussed elsewhere, you do not need to provide a 2.5V offset for your application. You do not need a 12V power supply. What you need is a rail-to-rail opamp which will run on a single +5V supply. For your application, it would be better to use the opamp in non-inverting mode. Since the LM358 is a dual opamp, use both opamps with moderate gain each. Then rectify and integrate the output to give you an envelope of the sound signal received.
Am i right to say that DC offset is needed for amplify the signal? And if i dont include the dc offset will it affect the signal?If you want to manipulate the signal (amplify for example), you need to change the "frame of reference" of the signal so it is between the voltages of your power supply.
Will this work ? And does the voltage at the non inverting have to be 2.5v ? And what does the offset do in this case. Can i just pull down the resistor on the non inverting side to gnd ? 0VThe problem is the +6V offset on the bottom side of the sinewave generator. Usually, any signal generator is referenced to GND.
Consider what happens when we turn the amplitude of the sinewave output down to 0V amplitude. The DC voltage of the inverting input of the opamp is at +6V. The voltage at the non-inverting input is also at +6V because of the voltage divider. In other words, the two inputs are at the same voltage. In general, any opamp circuit with proper negative feedback resistor will always have the inverting and non-inverting inputs at the same voltage. Any voltage difference would be amplified by the opamp's open-loop gain and the output of the opamp would hit the supply voltage rail (either V+ or V-). In our example shown, the output is at +6V, regardless of the circuit gain -R2/R1.
In order to reference the signal generator back to 0V, we have to break the DC path. We do this by "AC coupling" the signal generator to the inverting input of the opamp using a capacitor.
View attachment 145850
With the capacitor in place, the signal generator can be referenced to any voltage. The voltage at the inverting input is still +6V.
Why?
That is because the role of the feedback resistor and very high open-loop gain of the opamp means that the output of the opamp has to reach a voltage to force the difference voltage at the two inputs to zero.
Now, does this circuit resemble your microphone amplifier circuit?
This question may be a bit off-topic, so feel free to move it to another thread if it doesn't belong here.As an aside, from the onset, I questioned why do we need to offset the signal in the first place. If we simply amplify the AC signal with the opamp inputs referenced to GND we would be amplifying one half of the signal and clip the other half. Do we really care if all we need is the presence or envelope of the sound signal?