Author Topic: op amps, analog electronics  (Read 1283 times)

zahc

  • friend
  • Senior Member
  • ***
  • Posts: 5,799
op amps, analog electronics
« on: January 25, 2011, 07:56:21 PM »
I need sense the output of a solar cell that puts out a few microamps. I need to amplify that to a 0-5V range of my ADC. I'm using a TI 2371 rail-to-rail CMOS op amp set up as a transimpedence amplifier or current-to-voltage amp like so:



Its not really working. My first fear was that the op amp just doesn't have enough gain, but to amplify 1uA to 1V of output should take about a 1Mohm feedback resistor, which would be a gain of about 10^6. I know some opamps have an open loop gain of only 10,000 or so but the 2371 datasheet says the gain bandwidth product is 3MHz. Doesn't this mean it should have a max gain at 1Hz of 3*10^6?
Maybe a rare occurence, but then you only have to get murdered once to ruin your whole day.
--Tallpine

zahc

  • friend
  • Senior Member
  • ***
  • Posts: 5,799
Re: op amps, analog electronics
« Reply #1 on: January 25, 2011, 08:25:45 PM »
I tried a feedback resistor of 100k and now it works, but in the ~100mV output range. Before it was always pegged on .6V output. I guess I will need another opamp to amp it up to 5V, which is annoying.
Maybe a rare occurence, but then you only have to get murdered once to ruin your whole day.
--Tallpine

Headless Thompson Gunner

  • friend
  • Senior Member
  • ***
  • Posts: 8,517
Re: op amps, analog electronics
« Reply #2 on: January 25, 2011, 08:37:33 PM »
Cascade two amplifier stages, each with lower gain.  Or use a shunt resistor to convert the cell's current to a voltage, and then amplify that voltage.

Yes, in theory a single op-amp of appropriate specs should be able to do what you want.  In practice, high gain op amp circuits tend to be squirrely.  They tend to work best with a gain somewhere between 10 and 1000, with feed back resistances well under the megaohm range.

What's probably happening is that there's some high frequency oscillation.  Transimpedance opamp circuits are known for their instability.  You're correct that at 1Hz the gain should be sufficient, but I betcha there's also a bunch of high frequency trash getting amplified in there as well, loading the opamp down.  I don't suppose you have an oscilloscope of a frequency analyzer...?  
« Last Edit: January 25, 2011, 08:52:23 PM by Headless Thompson Gunner »

zahc

  • friend
  • Senior Member
  • ***
  • Posts: 5,799
Re: op amps, analog electronics
« Reply #3 on: January 25, 2011, 11:01:26 PM »
No, I really wish I did. I went down to 68kOhms and put a cap across the feedback resistor, and now that stage is working wonderfully for the light levels I'm interested in, giving outputs from 10 to 200ma. I added a 2nd jfet opamp stage as an non-inverting amp which I'm currently trying to get working, but once I do I should be good.
Maybe a rare occurence, but then you only have to get murdered once to ruin your whole day.
--Tallpine

zxcvbob

  • friend
  • Senior Member
  • ***
  • Posts: 12,247
Re: op amps, analog electronics
« Reply #4 on: January 25, 2011, 11:48:36 PM »
(it's been 30 years since I've looked at this stuff and I'm going from memory)  You need a resistor on the input, otherwise your input impedence is approximately zero.  Then the gain is the ratio of Rfeedback / Rinput.

I probably should have looked it up before posting :P
"It's good, though..."

230RN

  • saw it coming.
  • friend
  • Senior Member
  • ***
  • Posts: 18,904
  • ...shall not be allowed.
Re: op amps, analog electronics
« Reply #5 on: January 26, 2011, 12:39:05 AM »
I too think you need a high resistance to ground on the input.  Essentially, you're trying to make an electrometer, as I see it.

But I too, haven't messed with that stuff in more than two decades.

In this schematic of an electrometer used in those old CD* radiation detectors, although it's a tube device, you can see the application of the high input resistances from grid to circuit ground:

http://www.vaughns-1-pagers.com/science/victoreen/cdv-715-a1-schematic.jpg

The ionization chamber generates a few ions which are collected by that plate in it, and which drain to circuit ground through the very high resistances R12 to R15.  This creates the tiny voltage on the grid, pin 7, which is amplified by the tube.  Note R12 to R15 are glass-encapsulated precision resistors of very high values, 10^8 to 10^11 ohms. You should not need this kind of precision, or even that high a resistance, but the principle is illustrated in this diagram.  You're talking microamps, and electrometers are usually measuring things in the femtoamp and attoamp range.

You might consider using this electrometer principle by using a MOSFET with "drain" resistors on the gate for an electrometer-type input (or, if you prefer, you can call it a "preamplifier".)

Terry, 230RN

* = "Civil Defense"
« Last Edit: January 26, 2011, 01:15:46 AM by 230RN »
WHATEVER YOUR DEFINITION OF "INFRINGE " IS, YOU SHOULDN'T BE DOING IT.

drewtam

  • friend
  • Senior Member
  • ***
  • Posts: 1,985
Re: op amps, analog electronics
« Reply #6 on: January 26, 2011, 07:28:59 AM »
Have you tried Oregano?
I've had success with it before modelling opamps.

http://elettrolinux.com/CAD/CAM-EDA/oregano-an-electronic-tool.html
http://linuxappfinder.com/package/oregano
I’m not saying I invented the turtleneck. But I was the first person to realize its potential as a tactical garment. The tactical turtleneck! The… tactleneck!

Headless Thompson Gunner

  • friend
  • Senior Member
  • ***
  • Posts: 8,517
Re: op amps, analog electronics
« Reply #7 on: January 26, 2011, 11:55:16 AM »
If I'm reading him right, then he's using a textbook transimpedance opamp circuit, which has no resistance on either opamp input, and one feedback resistor from output to inverting input. 

The input impedance for the amplifier is the feedback resistor, and the input is held at ground potential.  Gain is equal to the input current times the feedback resistance.

http://ecircuitcenter.com/Circuits/opitov/opitov.htm

This might be an issue for the solar cell.  To get a high gain from the transimpedance circuit, you need a large feedback resistance, which means you have a large input impedance.  If you're using the solar cell's current output as your signal, you may find that the cell can't drive the high input impedance.

zahc

  • friend
  • Senior Member
  • ***
  • Posts: 5,799
Re: op amps, analog electronics
« Reply #8 on: January 27, 2011, 07:36:34 PM »
It's working now. Here's the final circuit.
Maybe a rare occurence, but then you only have to get murdered once to ruin your whole day.
--Tallpine