Click here to Skip to main content
Click here to Skip to main content
Go to top

Photodiode Amplifier via Parallel Port

, 8 Aug 2006
Rate this:
Please Sign up or sign in to vote.
Using a photodiode to trigger the signal pin on the parallel port

Introduction

In a previous article, I wrote about reading to a parallel port using the signal port. What I needed to read in was the signal from a photodiode. The following is a decent method to amplify the photodiode signal using common IC chips.

Schematic

This is a schematic of a photodiode amplifier that I used for an earlier project. It produces enough current to trigger a relay that connects the 'signal pin' to a 'ground pin.'

Sample screenshot

The components are as follows:

  1. LED or any light source, mine was a laser
  2. Photodiode
  3. 3 Pots (Potentiometer) or Resistors; R1 = 3.3K, R2 = 104.6K, R3 = 312.2
  4. Opamp, mine was a UA741
  5. NPN Transistor, mine was 2N3904
  6. IC Relay, mine was a Hamlin HE721C0500
  7. Source: You'll need a source with at least 9 Volts. Note that you'll need a source that also includes a negative voltage and ground. You can substitute +9V or my +5V and -9V for my -5V. However if you also want to substitute my +12V for a +9V, then you may have to tweak R3.

*Important note: I take no responsibility for any mishaps.

IC Diagram/Schematic

*This Diagram/Schematic can be found at www.datasheetcatalog.com.

Opamp

Sample screenshot

NPN Transistor

Sample screenshot

Reed Relay

Sample screenshot

Explanation

My photodiode can only provide at most .9V (I think). The relay I'm using requires more current than my photodiode could provide. I needed the relay to trigger the switch inside of it and allow the 'signal pin' to be grounded; this would then result in a low on my signal pin. And as indicated from my previous article; I need the signal pin to be grounded so I could read it as data.

Some may say; why didn't you just use the transistor. Wouldn't it be easier? My answer is nah! Due to the fact that the base of the transistor needs a decent current to allow Vbe to go to saturation, I used a opamp to boost the signal and then tie the output to the base of the transistor. I used 12V at the collector since I didn't have 9V.

If you have any questions, email me at phebejtsov@yahoo.com.

History

  • 8th August, 2006: Initial post

License

This article, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

Share

About the Author

phebejtsov

United States United States
No Biography provided

Comments and Discussions

 
Questioncant use my relay Pinmember¤ Muammar ¤9-Nov-06 9:40 
AnswerRe: cant use my relay Pinmemberphebejtsov8-Jan-07 5:53 
GeneralRe: cant use my relay PinmemberMuammar©8-Jan-07 19:36 
Generalhello frnds,i need run exe as background process with webapplication i need run exe as background process with webapplication is it possible then ho PinmemberSharmaAshutosh8-Nov-06 0:34 
QuestionHow to read multiple signals Pinmemberceplin16-Aug-06 6:23 
AnswerRe: How to read multiple signals Pinmemberphebejtsov16-Aug-06 19:57 
GeneralNice article Pinmemberrschaer16-Aug-06 3:46 
GeneralIdeas for improvement. PinmembernormanS14-Aug-06 20:06 
Nice article.
 
I don't do real electronics often, so these ideas may not be useful, but:
 
1. Instead of the photodiode, you could use a phototransistor with collector at 5V and resistor in the emitter line to ground - that should give better voltage swing than the photodiode, so make it less sensitive to your R1 and R2 values.
 
2. Try to use standard resistor values, with 5% or 10% tolerance, instead of pots. This should be possible if you implement idea 1. The value of R3 is not critical, so it could be standardised anyway.
 
3. In place of the 741 op-amp, there are single-supply op-amps, which would let you eliminate the -5V supply. Alternatively, I am sure there was some cheap voltage comparator in the CD4000 / CD4500 CMOS range which would do the job.
 
4. Change to a relay which will work from 5V, to eliminate the +9 / +12V supply.
 
5. Try to supply the circuit from pins on the parallel port, so an external power supply is not needed. I don't know if any power is available - maybe you could reduce the current needed by your circuit, and use power from port output lines?

GeneralRe: Ideas for improvement. Pinmemberphebejtsov15-Aug-06 5:10 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.

| Advertise | Privacy | Mobile
Web02 | 2.8.140916.1 | Last Updated 8 Aug 2006
Article Copyright 2006 by phebejtsov
Everything else Copyright © CodeProject, 1999-2014
Terms of Service
Layout: fixed | fluid