Op-amps, rail to rail, single supply, etc...

Started by azrael, November 09, 2011, 01:52:52 PM

Previous topic - Next topic

azrael

So I'm doing a project for school, and we need to use inductors to build a sensor to read magnetic tracks...and blah blah blah. Anyway, we'll be doing some circuitry to read and filter that signal.

it needs to cut down on noise, so I was original thinking something like OPA2134s...
So a friend from a different group says that we need a rail to rail opamp, which the 2134 is not. So in the datasheet, it says that 2134s have an output voltage swing of 1v. So he says that you're losing some signal, even if you define a virtual ground to offset it?

Can someone explain to me the purpose and advantage of a rail to rail supply? Is what he's saying right?

teemuk

#1
Quote from: azrael on November 09, 2011, 01:52:52 PMSo a friend from a different group says that we need a rail to rail opamp, which the 2134 is not.
And the reason you need it is...?

QuoteSo in the datasheet, it says that 2134s have an output voltage swing of 1v.

Now where exactly does it say such a thing?

The datasheet says the OPA2134 can take from +- 2.5VDC to +-18VDC supply rail voltage and, depending on loading, swing the output to about 0.5V or 2.V near this limit defined by the rail voltage. (Note: higher loading results to higher voltage swing capability).

QuoteSo he says that you're losing some signal, even if you define a virtual ground to offset it?

I'm not quite sure what your friend means with that..  ???

QuoteCan someone explain to me the purpose and advantage of a rail to rail supply?

A generic opamp can never swing its output to the potential of the supply rails. A reasonable estimate is that the signal will start clipping at amplitudes about 1 - 2 V below the rail voltage (the actual values are indicated by the datasheet of the specific device). This can be an issue if you use a very low supply rail voltage e.g. +-1.5VDC.

For example, running the OPA2134 on +-18VDC rails to 10k load would give about 18V-1V=17V (peak) of output voltage swing, plenty for most applications. On the other hand, when running the chip with only +-2.5VDC supply, and with 2-kilo-ohm loading you'd get only 2.5V-1.5V=1V (peak) of voltage swing.

A rail-to-rail opamp, as name indicates, can swing the output from rail to rail without limits. God's blessing for circuits using a very low voltage power supply.

Naturally, you don't really give much details about the circuit you're planning to use so answering whether rail-to-rail opamps are beneficial in your case is kinda difficult.

R.G.

The power supplies are sometimes called "power rails" from the times when they were sometimes literally solid metal bars.

All opamps have a maximum output swing they can produce. This is always less than the power supply voltage limits. How much less depends heavily on the internal circuits of the opamp.

If the power supply is single ended (that is, not bipolar, +/-V) then the total possible output any opamp can do is 0V to Vsupply. That's all it has to work with.

It's common for opamps to only be able to swing within 2V or so of the power supply, especially when heavily loaded. The much-loved TL072 series, for instance, can only get to within about 1.5V of either supply. So if you power one of these from 0V and 9V, the output swing can only go from 1.5V minimum to 7.5V maximum under normal conditions.

"Rail-to-rail" opamps were invented to get around this limit. As power supplies get smaller, the little bit of the power supply the opamp output can't swing gets intolerable. So running a TL072 from 9V gets you a maximum swing of 7.5-1.5 = 6V peak to peak. If you try to run the TL072 from 5V and ground, you get the same minimum, 1.5V, but the maximum is still 1.5V lower than the power supply, which is now 5V. So the maximum is 3.5V, and the peak to peak signal is only 2V. At 0V to 3V power supply, the TL072 is useless, because it has little or no output swing left.

A rail to rail opamp would swing from nearly the most-negative supply to nearly the most-positive supply. So a RTR opamp running from 5V might swing between 0.05V to 4.95V.

Rail-to-rail opamps per se were invented to have a bigger part of the power supply available on their output. The "rail-to-rail-ness" says nothing about its noise performance, necessarily. It's a way to make do with a smaller/lower power supply and get the same size output swing.

It is possible that your classmate/competitor mentioned this for other reasons. Are you limited as to the biggest power supply voltage you can use? If not, using rail to rail may not be an advantage. Or there may be other criteria.

RTR is intended to allow you to use more of the available power supply.
R.G.

In response to the questions in the forum - PCB Layout for Musical Effects is available from The Book Patch. Search "PCB Layout" and it ought to appear.

WGTP

#3
So what are the ramifications of RTR for our typical Distortion + or Tube Screamer?  It appears that many of the RTR op amps are MOSFET, some both input and output.  I have found the TLV2372 to work well.  ;)
Stomping Out Sparks & Flames

R.G.

Quote from: WGTP on November 09, 2011, 03:07:39 PM
So what are the ramifications of RTR for our typical Distortion + or Tube Screamer?
As far as the rail-to-rail-ness, there is very little ramification. The side effects of the circuit changes to make it go rail-to-rail on input and/or output (those are different!) may make a change in the entry/exit from saturation. Maybe. But they're likely to be different per manufacturer/circuit.

And anyway, most circuits which have other clipping mechanisms should not ever let the opamp's native clipping show through.

QuoteIt appears that many of the RTR op amps are MOSFET, some both input and output.  I have found the TLV2372 to work well.  ;)
I like the TLC2272. But exactly WHAT inside there that makes it good is not clear. It may even be the low open loop gain.  :icon_eek:
R.G.

In response to the questions in the forum - PCB Layout for Musical Effects is available from The Book Patch. Search "PCB Layout" and it ought to appear.

azrael

I dunno why we need a rail to rail, that's just what he said. I've never really heard of it, so I was hoping to learn something.

Quote from: teemuk on November 09, 2011, 02:23:02 PM
QuoteSo in the datasheet, it says that 2134s have an output voltage swing of 1v.

Now where exactly does it say such a thing?

The datasheet says the OPA2134 can take from +- 2.5VDC to +-18VDC supply rail voltage and, depending on loading, swing the output to about 0.5V or 2.V near this limit defined by the rail voltage. (Note: higher loading results to higher voltage swing capability).
Sorry, I meant that it swings within 1v of the rails, wrote it wrong.

Quote from: teemuk on November 09, 2011, 02:23:02 PM
QuoteSo he says that you're losing some signal, even if you define a virtual ground to offset it?

I'm not quite sure what your friend means with that..  ???
Well, I was thinking that if you define ground to be 2.5v with a 5v supplied circuit, you would have a good amount of headroom, allowing the signal to swing between 0-5v. But as my understanding goes, the circuit would only go from 0v to 4.5v, losing some of the signal. I guess he doesn't think that's good for our purposes.

Quote from: teemuk on November 09, 2011, 02:23:02 PM
A rail-to-rail opamp, as name indicates, can swing the output from rail to rail without limits. God's blessing for circuits using a very low voltage power supply.

Naturally, you don't really give much details about the circuit you're planning to use so answering whether rail-to-rail opamps are beneficial in your case is kinda difficult.
Sorry, I didn't want to give the impression that I wanted someone to do my project for me. :)


The sensors will be running over the track and due to induction we'll be getting a voltage which will tell us how our car is relative to the track.
We'll be reading voltage off the inductor, and sending it to a peak detector to rectify the voltage and give us the peak of the voltage swings.
Then there'll be a bandpass filter around 75kHz to cut any noise out of the circuit and to amplify the signal.

Personally, I don't think our circuit should be anywhere near the rails. From what I understand about previous years' projects, the inductor was giving readings of like....300-400mV peak to peak with a 1mH inductor. We'll be using 10mH, but still.

However, I'm listening to him because he said his team last year ran into issues with this and stuff. This is my first year doing this.

Oh, we'll either being running off the regulated 5v, or direct from the battery, which would be around 11-12v.

amptramp

As R.G. indicated, there are two separate rail-to-rail issues.  One is rail-to-rail input and the other is rail-to-rail output.  Some amplifiers like the LF356 series have a rather bad habit of output reversal if the inputs exceed the specified input rail voltages.  Indeed, this may be what your colleague was referring to, because there is usually not that much of a problem with restricted output voltages, but phase reversal caused by exceeding the input voltages would wreak havoc with a control system design like the one you mentioned.  This is usually not symmetrical and some amplifiers like the LM324 have a common mode input that goes to the negative rail but only within 2 volts of the positive rail.  Some comparators have the same issues.

azrael

I think he used 741s last year, would that perform as you described?

PRR

> it needs to cut down on noise

Why? Audio-band hiss in TL072 is 0.002mV; in a low-low-noise-voltage part maybe 0.000,2mV. You say 400mV signal. I can't see that you are anywhere near noise.

But note: a wound-wire (coil) sensor passing over a magnet gives a blip with height proportional to speed. As you coast to a stop your 400mV full-speed blip may fade to 40mV and less. THAT's why the peak-detector: whatever the height, the top of the blip is the center of the magnet.

This could be simpler with electric eye. So I assume this is a lesson in wound-pickup signal processing.

This might be even easier with a strip of copper dragging from the car and coed copper strips on the track bed. In fact three strips on the car and a strip left center right on the track would be dead-simple to process into three stopping-points. I think model train sets had such a scheme. Binary logic could decode 1-3 strip code into 8 positions. However such cleverly simple schemes may not be what employers need to see when you get out of school.

> a friend from a different group says that we need a rail to rail opamp

Again: Why? If signal is 400mV, and you amplify X10, that's 4,000mV or 4V. You can put +/-15V or 30V total rails on most opamps. You can, ideally, balance sensor, gain, and rails so the output never comes close to rails.

Yes, there are cases where R2R is handy. If you need precise sensing near ground and the project manager won't approve a dual-supply, an amp where the pins still function very-near ground may avoid ugly work-arounds.

> his team last year ran into issues with this and stuff

I may be cynical, but maybe he didn't work-through all the issues and stuff last year, and is still beating the wrong path.
  • SUPPORTER

azrael

Built the sensor last night, worked great.

Here's what we decided and what came of our work in the lab:

Right now, yes, the sensor can pick up a signal from fairly good distances, like of a couple inches. They'll never be closer than say...an inch from the track. So what if when they were at the "optimal distance" from the track or "on track", we had them at 5-ish volts? this way we could better gauge how it far off track it would be.
So I used a split rail power supply to give us a nice full sine wave. It was a pretty cool design I found on a headphone amplifier site:
http://tangentsoft.net/elec/bitmaps/vgrounds/vfb-opa.png


It's pretty good at keeping noise low, since we are using the OPA2350 in the lab, and we are keeping the opamp close to the sensing coil itself. This led me to think that we should just keep the opamp and sensor together and then run the low impedance output from the opamp to filter system and whatnot.




This is all tested with us just waving the coil over the magnetic track, though (using a circuit to generate a magnetic track, btw).



Not sure what an electric eye is, but yes, they want us to use inductors for the sensor, PRR. :) Also, we'll be using three sensors, so maybe the programmers on my team will be approaching the position determination similarly to your strip idea.
Good point about the noise, I'm actually more concerned about noise from the background sources and maybe caused by longer lead runs now. Hopefully a good bandpass filter will fix that.


Thanks for the help and info so far guys, I'm glad I was able to get some insight here, despite it being a stompbox forum. :D

DavenPaget

Quote from: azrael on November 11, 2011, 02:49:32 PM
Built the sensor last night, worked great.

Here's what we decided and what came of our work in the lab:

Right now, yes, the sensor can pick up a signal from fairly good distances, like of a couple inches. They'll never be closer than say...an inch from the track. So what if when they were at the "optimal distance" from the track or "on track", we had them at 5-ish volts? this way we could better gauge how it far off track it would be.
So I used a split rail power supply to give us a nice full sine wave. It was a pretty cool design I found on a headphone amplifier site:
http://tangentsoft.net/elec/bitmaps/vgrounds/vfb-opa.png


It's pretty good at keeping noise low, since we are using the OPA2350 in the lab, and we are keeping the opamp close to the sensing coil itself. This led me to think that we should just keep the opamp and sensor together and then run the low impedance output from the opamp to filter system and whatnot.




This is all tested with us just waving the coil over the magnetic track, though (using a circuit to generate a magnetic track, btw).



Not sure what an electric eye is, but yes, they want us to use inductors for the sensor, PRR. :) Also, we'll be using three sensors, so maybe the programmers on my team will be approaching the position determination similarly to your strip idea.
Good point about the noise, I'm actually more concerned about noise from the background sources and maybe caused by longer lead runs now. Hopefully a good bandpass filter will fix that.


Thanks for the help and info so far guys, I'm glad I was able to get some insight here, despite it being a stompbox forum. :D

I know what they meant by noise . They used a 741 , the oldest and quite low fidelity opamp i ever heard .
Why do the companies that sell "Tone Control" preamp things come with a 741 anyway  :icon_mrgreen:
Hiatus

azrael

well most people say they have a lot of problems with noise in their projects, just in general. I think that's due to low leads with high impedance signals running through them and a lack of proper power supply filtering.
i'll also be using some shielded wiring when needed.

DavenPaget

Quote from: azrael on November 12, 2011, 01:44:40 AM
well most people say they have a lot of problems with noise in their projects, just in general. I think that's due to low leads with high impedance signals running through them and a lack of proper power supply filtering.
i'll also be using some shielded wiring when needed.
I kid you not , it's the 741 that is .
Hiatus

azrael

Oh, I know how bad the 741 is. But I've seen other projects, and they don't use then 741, but they still complain about signal noise.

PRR

> They used a 741 , the oldest and quite low fidelity opamp i ever heard .

'741 is not bad. The way you USE it is more important.

Look at the "Ground Driver" circuit you quoted. The reference node is 110K impedance. That is 110K of thermal hiss (about 4 microvolts in the audio band).

The hiss of the opamp does not matter when you reference it through 110K of resistance. LM741 hisses ~~1uV, TL072 about 2uV.

Plus whatever stray crap can be picked-up on a 110K node (not much if wired tight, huge if this node extends a few inches inside a box of large signals or power crap).
  • SUPPORTER

azrael

I did a quick perfboard the other day when I was bored, I got it a bit bigger than a quarter, which wasn't bad considering the electro i had was huge haha.

ORK

Quote from: PRR on November 12, 2011, 06:07:20 PM
> They used a 741 , the oldest and quite low fidelity opamp i ever heard .

'741 is not bad. The way you USE it is more important.

Look at the "Ground Driver" circuit you quoted. The reference node is 110K impedance. That is 110K of thermal hiss (about 4 microvolts in the audio band).

The hiss of the opamp does not matter when you reference it through 110K of resistance. LM741 hisses ~~1uV, TL072 about 2uV.

Plus whatever stray crap can be picked-up on a 110K node (not much if wired tight, huge if this node extends a few inches inside a box of large signals or power crap).

How about a little cap from non-inverting input to ground?