Op amp, unexpected output

Thread Starter

Smoooth

Joined Jan 2, 2017
34
Hi,

I've got a weird output when feeding an oscillating signal into an op amp (TI's OPA-356), hoped somebody could clear it up for me.

Please see the schematic attached to this post, as well as the OPA-356 data sheet.

I've got a 1KHz signal (Vmin = -0.31V, Vmax = 4.08V). I'm using a voltage divider to lower the altitude of the signal (to Vmin = -0.20V, Vmax = 2.43V), and then I'm feeding this signal into the op amp, OPA-356. I've set the gain to 1.22 (using 2.2k and 10k resistors), so theoretically the output should be between about 0V and about 3V. However, I'm getting the oscillations between 0V and 7V. I attached the oscilloscope readings to the post.

Can somebody please explain me why this is happening? I assume that the problem is with the fact that I'm feeding an oscillating signal into the op amp, cause the op amp is amplifying straight 0V or 2.4V signals perfectly. The purpose of all this is to get the output between about 0 and 3V. How can achieve that? And what am I doing wrong?

Many thanks in advance.
Schematic.png
input.png divided input.jpg output.jpg
 

Attachments

Ylli

Joined Nov 13, 2015
1,088
First thing is that you are driving the input to below ground. (below V-). This is almost never a good idea. The Op amp you are using does allow an input to 100 mV below ground, but you are exceeding that.

And no, you do not have the gain set to 2.21. The 10K resistor is simply connected as a load - output to ground and the 3.3k resistor feeds the (-) input directly. The gain of a non-inverting op amp is Av = 1 + Rf/Rin. If you want a gain of 2.21, then you would need a resistor of 3.3/1.21 = 2.73k between the (-) input and ground. You can get rid of that 10k load. [Av = 1 + Rf/Rin = 1 + 3.3/2.73 = 1 + 1.21 = 2.21]

But you still need to limit that input swing to no more than 100 mV below ground. Replace R4 with a 1.2k (will limit input low to -0.083 volts), and the select an Rf and Rin to get the total gain you want.
 
Last edited:

DickCappels

Joined Aug 21, 2008
10,187
In the first photo It looks like your scope probe is not properly compensated. In the second photo it looks like your scope's vertical amplifier is being over-driven or that you have over-compensated the probe.

For the purpose of "remote diagnosis" it would be helpful if your scope preamp is set to DC coupling.

You might want to try this procedure and then look at the output of your circuit again.
https://www.picotech.com/library/application-note/how-to-tune-x10-oscilloscope-probes
 

Thread Starter

Smoooth

Joined Jan 2, 2017
34
First thing is that you are driving the input to below ground. (below V-). This is almost never a good idea. The Op amp you are using does allow an input to 100 mV below ground, but you are exceeding that.
Right now I'm sort of making sure that I'm doing all the op amp stuff correctly. The actual oscillations will be between 0.4V and 2.4V, so I will not have that issue. The oscillator didn't arrive yet.

And no, you do not have the gain set to 2.21. The 10K resistor is simply connected as a load - output to ground and the 3.3k resistor feeds the (-) input directly. The gain of a non-inverting op amp is Av = 1 + Rf/Rin. If you want a gain of 2.21, then you would need a resistor of 3.3/1.21 = 2.73k between the (-) input and ground. You can get rid of that 10k load. [Av = 1 + Rf/Rin = 1 + 3.3/2.73 = 1 + 1.21 = 2.21]
Ooops, I'm sorry, I messed up while drawing the circuit. The actual thing looks like this:actual schematic.png

This way I should be having the gain of 1 + R1/R2 = 1.22. I mean, this what I've read from Horowitz's Art of Electronics. And this is exactly what you explained. Thing is, I'm still not getting the desired output. I changed R4 to 1k, making Vmin = -0.08, but the problem is still there: op amp's output is still 0 to 7V.
 

Thread Starter

Smoooth

Joined Jan 2, 2017
34
In the first photo It looks like your scope probe is not properly compensated. In the second photo it looks like your scope's vertical amplifier is being over-driven or that you have over-compensated the probe.

For the purpose of "remote diagnosis" it would be helpful if your scope preamp is set to DC coupling.

You might want to try this procedure and then look at the output of your circuit again.
https://www.picotech.com/library/application-note/how-to-tune-x10-oscilloscope-probes
I'm using a cheap "dso nano" oscilloscope, so I don't have much freedom with the probes:) School's over, good equipment is left in the lab. Thank you for the link - I had some issues tuning the rigol oscilloscopes in our lab, that should solve it.
 

MrChips

Joined Oct 2, 2009
30,824
Tell us more about your oscilloscope and probe that you are using.
What is the brand and model of the scope?
What is the probe you are using? Does it have a x1 and x10 attenuation switch?
What setting is this attenuation switch?
What is the scope input attenuation option setting?
 

Thread Starter

Smoooth

Joined Jan 2, 2017
34
Tell us more about your oscilloscope and probe that you are using.
What is the brand and model of the scope?
What is the probe you are using? Does it have a x1 and x10 attenuation switch?
What setting is this attenuation switch?
What is the scope input attenuation option setting?
Yep, please see the message above. I'm using DSONV-11. My options are very limited as far as the probes go. I'm pretty sure they have no input impedance. Just wires.
 

MrChips

Joined Oct 2, 2009
30,824
Show us a photo of your probes and a photo of the input channel attenuation settings on the scope.

Do you know the meaning of x10 attenuation?
 

Thread Starter

Smoooth

Joined Jan 2, 2017
34
Show us a photo of your probes and a photo of the input channel attenuation settings on the scope.

Do you know the meaning of x10 attenuation?
yes, you add an attenuator, more impedance, to achieve better accuracy. x10 reduces the signal by the factor of 10.

Here's what I'm using:IMG_1236.JPG

No switches, no mentioning of attenuation. It's cheap, but it should be doing the job, although with low accuracy. I mean, it shouldn't confuse 7V with 3V.
 

MrChips

Joined Oct 2, 2009
30,824
Then can you explain how you can get a reading of 7V from a 3.3V supply?

I suggest you read the User Manual and access the probe selection setting of your scope.
It would appear that you have it set for x10 probe.
 

Thread Starter

Smoooth

Joined Jan 2, 2017
34
Then can you explain how you can get a reading of 7V from a 3.3V supply?

I suggest you read the User Manual and access the probe selection setting of your scope.
It would appear that you have it set for x10 probe.
yes, I that makes sense. Problem is with the oscilloscope then. But from the theoretical point of view, having the circuit this circuit, the op amp should work as I intend it to, right? (input's between 0.4V and 2.4V)
actual schematic.png
 

MrChips

Joined Oct 2, 2009
30,824
Why not put some faith into your oscilloscope? There is nothing wrong with the scope.

The scope is seeing 0 to 0.7V
You told it that you are using a x10 probe. Hence it multiplies all readings by 10.

Change the setting on the scope and repeat all your measurements.
 

Thread Starter

Smoooth

Joined Jan 2, 2017
34
Why not put some faith into your oscilloscope? There is nothing wrong with the scope.

The scope is seeing 0 to 0.7V
You told it that you are using a x10 probe. Hence it multiplies all readings by 10.

Change the setting on the scope and repeat all your measurements.
No, I'm using a x1 probe.
Interesting thing: it doesn't matter if I supply the op amp with -0.15 to 2.4V or with -0.08 to 1.33V - the output of the op amp is the same: -0.14 to 7V. Do you have any suggestions about how on Earth it is getting 7V?
 

MrChips

Joined Oct 2, 2009
30,824
No, I'm using a x1 probe.
Interesting thing: it doesn't matter if I supply the op amp with -0.15 to 2.4V or with -0.08 to 1.33V - the output of the op amp is the same: -0.14 to 7V. Do you have any suggestions about how on Earth it is getting 7V?
We can see that you are using a x1 probe.
So tell the scope you are using a x1 probe. It doesn't know that until you tell it.
 

dl324

Joined Mar 30, 2015
16,943
This way I should be having the gain of 1 + R1/R2 = 1.22. I mean, this what I've read from Horowitz's Art of Electronics.
upload_2017-6-15_9-44-47.png
Did you also learn how to draw schematics from that book?

This is a more conventional way to draw a schematic. "Flow" should be predominantly from left to right and top to bottom.
upload_2017-6-15_9-40-56.png
I didn't bother labeling the opamp terminal numbers or give it a component designator because my schematic editor didn't have a part like that and I just drew lines...
 

Thread Starter

Smoooth

Joined Jan 2, 2017
34
We can see that you are using a x1 probe.
So tell the scope you are using a x1 probe. It doesn't know that until you tell it.
Yeah, I did it.
Aye, I think it's the negative voltage
Whenever I supply the op amp with anything less than -0.05V, it mysteriously goes crazy, somehow outputting 7V.
I supplied it with -0.04 to 0.64, and it worked correctly.
 
Top