# Amplifying a Photodiode using an OpAmp

Tags:
1. Jul 7, 2016

### mazzo532

Dear electrical engineers,

Here a question from a serious electronics n00b =D.

I tried to build a system as shown in the image. I have a photodiode which gives me a clock signal in the range of 200 to 500mV. Frequency will be in the range of 100 to 1000 Hz.
I would like to amplify this signal in order to have a voltage between C and D in the range of 2 to 5V, hence my goal gain should be around 10.

I have an LT1006 amplifier, which should be fine for this purpose (Documentation HERE). I'm trying to use it as a Non-Inverting OpAmp.

Useless to say that my system does not work. Somehow I get a constant output of about 2V regardless of the diode status.
There must be some gross mistake somewhere, but I have no idea. Could someone tell me what did I do wrong?

Mazzo

2. Jul 7, 2016

### BiGyElLoWhAt

Normally, with a constant voltage output, that means you're railing. Is your input voltage +/- 2V by any chance?
Try removing the gain and see what happens. Check for shorts, make sure your feedback loop is connected properly.

Op amps can never output a higher voltage than their source. If your gain function $g$ times the output voltage $V_{out}$ is higher than your source voltage (+/- 5V in the diagram), you will get your source voltage as your output.

3. Jul 7, 2016

### BiGyElLoWhAt

Also, how are you reading it? I'm assuming an o-scope? Perhaps it's just ticking too fast? All diodes are not made equal, meaning that if you're trying to get it to break down, you need very close to what's called the "breakdown voltage", but you want it to breakdown only when photons hit it. So you want it to be below.

Another possibility, is you photodiode lighting up? You might have it in backwards, which just allows current to flow through it, as opposed to it being reverse biased.

4. Jul 8, 2016

### sophiecentaur

I see you have no bias resistor from the diode to Ground. I would imagine that could define the Volts on the Diode better than relying on the OP Amp input resistor. Try a few tens of kOhm. Have you looked at the diode volts with a DVM? Could be interesting.
Also, why choose such low resistor values in your feedback loop? I'd be inclined to use at least 10 times those values.

5. Jul 8, 2016

### mazzo532

Hello guys,
thanks both of you for your answers! Let's reply with order:

@BiGyElLoWhAt
- I'm using an adjustable power supply unit, set to 5V.
- I'm testing the photodiode just by intermittently illuminating it with a flashlight. By hand. The diode alone, plugged straight into an o-scope (or a multimeter) works fine. Ambient light gives about 200mV and direct flashlight gives 500mV. I would say it works.
- About the diode being backward. This is interesting . Diode receives light and gives me a voltage drop across its plugs: I plugged the hi-voltage side to the + side of my OpAmp. Negative side goes to D (that's my negative PSU plug). Is that wrong?
- Question: what do you mean by +-5V? Why would you say there's a negative voltage? Can't I just consider that my negative PSU connector is zero volts and the positive one is at +5V?

@sophiecentaur
- Grounding is in fact the muddiest point of the story for me. Gonna show you my infinite ignorance: why would I need to ground anything?
- I checked my diode health status with a multimeter. It works. Ambient light gives about 200mV and direct flashlight gives 500mV.
- About resistors, I have actually just set their ratio (that's 10) and I've randomly chosen their resistance magnitudes. How does that affects the system? By the way I'll test higher resistances as soon as I'm back in the lab.

Mazzo

6. Jul 8, 2016

### jim hardy

here's why you cant get more than about 2 volts
from datasheet you posted

try 100X larger resistors.

old jim

EDIT i see Sophie caught it too
that should work

7. Jul 8, 2016

### mazzo532

@jim hardy
Thanks for your help Jim! This is great, but still I have some doubt: my system was giving a 2V constant voltage. It was completely independent on the amount of light the diode was receiving. There must be some other mistake.

8. Jul 8, 2016

Suggest you use a simpler circuit where you connect the "+" terminal of the op-amp to ground. The one end of the photodiode is grounded and the other end connects to the "-" terminal of the op-amp. The photodiode polarity doesn't matter, you'll get the opposite output by reversing the polarity. The feedback resistor (R=100 kohm) connects from the "-" op-amp terminal to the op-amp output. A small capacitor, (10 pF) can be put in parallel with the feedback resistor to reduce noise. The output voltage is measured between the output terminal of the op-amp and ground. Oftentimes the op-amp requires +12 V and -12 V bias voltages. (This circuit amplifies the photocurrent with zero voltage across the diode. It is essentially a current amplifier.)

9. Jul 8, 2016

### jim hardy

keep us posted whether higher resistors helps ?

As Sophie pointed out
your circuit allows no current through the photodiode
so the first photon to strike it drives it to full voltage
and its capacitance holds it there
That's an exagggeration of course but only a mild one
a resistor across diode gives the charges someplace to go
try a megohm ?
The opamp has a few nanoamps of input current
see parameter "Input Bias Currrent", 9 to 15 na,
and your circuit must provide a path for that trickle . You want it not to flow through your photodiode.

Last edited: Jul 8, 2016
10. Jul 8, 2016

### mazzo532

Interesting. You mean I should have a path to the Ground placing a MOhm resistor? Should i put between points A and D?

11. Jul 8, 2016

Please read my suggestion in post #8. I have used this op-amp circuit with photodiodes countless times and it is both simple and reliable.

12. Jul 8, 2016

### jim hardy

I think so. Sophie called it a "bias" resistor.

megohm was a USWAG, acronym for Unscientific_wild-a**guess
it'll depend on what is the current produced by your photodiode

can you measure that ?

@mazzo532
see polarity issue in post # 14 and 16

Last edited: Jul 8, 2016
13. Jul 8, 2016

### f95toli

What type of photodiode is it? Is it a packaged device that actually gives a voltage out? Or is is just a "plain" diode?
In the latter case you certainly need a path to ground (the light generates a current and that current needs to go somewhere).
I would have thought a few kOhms would be a good starting point (Mohm sounds way too high), but the best thing to do is to check the datasheet of the photodiode, there you will probably find some example circuits and you can just use whatever value they are using.

14. Jul 8, 2016

### jim hardy

CharlesLink's suggestion is a good one

AHA because it looks like you are driving your single supply opamp's input negative in non-inverting mode, asking it to do the impossible - produce a negative output...

Charles suggests instead inverting mode like this
from LM324 datasheeet at http://www.ti.com/lit/ds/symlink/lm124-n.pdf

that might work with a single supply opamp in the polarity shown

easy enough to try.

15. Jul 8, 2016

Thank you Jim! I would have included a circuit diagram with my description but I haven't yet learned how to upload files onto PF. That's precisely the circuit I was referring to. The circuit gives an output voltage equal to $V_{out}=I_p R_f$ where $I_p$ is the photocurrent at zero voltage across the photodiode.

16. Jul 8, 2016

### jim hardy

i use the "snip" , click " copy" , and paste into Paint, add notes & arrows then save to disk (made a folder FOR_PF for such things)
then use UPLOAD button lower right
i save as jpg not png because the files are smaller that way
...........................................................................................................................

.regarding the circuit ----

i missed his reverse polarity/single-supply conflict until i read your post carefully.
do you think he'd get away his non-inverting configuration if he just flipped his diode over?

Ahhh it's the small things of the earth that confound the mighty, eh ?

17. Jul 8, 2016

### BiGyElLoWhAt

When will NASA stop with all the acronyms?

18. Jul 8, 2016

Flipping the photodiode over might make it work, but I am not a EE and the original circuit is overly complex. The op-amp circuit with the circuit diagram @jim hardy provided is a standard one that is used in photoradiometric measurements throughout the industry. The "-" terminal of the op-amp as a virtual ground along with the near infinite input impedance of the op-amp makes it a very simple circuit to analyze. .. There is one puzzle that did surface (the technicians at the workplace asked me this question) with the analysis of this circuit, particularly when a load resistor is placed at the output. How come the (current) goes into is not equal to the comes out of? And the answer is evidently the current in the two bias lines is not necessarily equal but will be such that the current into the device is the current out of the device.

Last edited: Jul 8, 2016
19. Jul 8, 2016

### jim hardy

current into and out of where ?

The two signal input lines , + and - , ideally would both have zero current , infinite impedance , sensing voltage perfectly ..

In reality they have a few nanoamps (or pico or femto amps in better opamps) which we generally dismiss
but we do know it exists and it is stated in the datasheet as ""Input Bias Current". It can be either polarity.
The difference in those bias currents is spec'd also. it's "Input Offset Current"

Current coming out of the amplifier via the output pin got into the device through the power supply pins
so Kirchoff is neither disproven nor disobeyed , just we have to keep our thinkin' sraight.
Suggest your tech draw his circle around it enclosing ALL the pins.

any help ?

old jim

20. Jul 8, 2016