Simple Photodiode On/Off circuit


Closed Thread
Results 1 to 15 of 15

Hybrid View

  1. #1
    Join Date
    Jun 2011
    Posts
    26


    Did you find this post helpful? Yes | No

    Default Re: Simple Photodiode On/Off circuit

    If I use a standard LDR, I can use a 1k resistor and detect the difference between light ( < 1k Ohm) and dark, which is in the 10 M Ohm range. I understand that this works because when 5v comes in through a 1k resistor, it will go to the PIC because the 10 M Ohm of the LDR is much higher.

    However, the photodiode that I am using has a range of 2 M Ohm for dark/no laser, and about 4-5 M Ohm when the laser strikes it. If I use 3 M Ohm, the voltage that does get through to the PIC is way too low to trigger an input. Any ideas here?
    Last edited by bodgetts; - 6th August 2011 at 00:51.

  2. #2
    Join Date
    Aug 2010
    Location
    Maryland, USA
    Posts
    869


    Did you find this post helpful? Yes | No

    Default Re: Simple Photodiode On/Off circuit

    maybe set it up as a voltage divider, but use the comparater or A/D to decide if it's on or off?
    -Bert

    The glass is not half full or half empty, Its twice as big as needed for the job!

    http://foamcasualty.com/ - Warbird R/C scratch building with foam!

  3. #3
    Join Date
    May 2008
    Location
    Italy
    Posts
    825


    Did you find this post helpful? Yes | No

    Default Re: Simple Photodiode On/Off circuit

    You can use the pic comparator as an amplifier and solve the high impedence problem. See Microchips comparator tips & tricks @ page 31.

    Cheers

    Al.

    http://www.google.it/url?sa=t&source...TP7z0_z8fDfPxA
    All progress began with an idea

  4. #4
    Join Date
    Jun 2011
    Posts
    26


    Did you find this post helpful? Yes | No

    Default Re: Simple Photodiode On/Off circuit

    Thanks for the suggestions guys. The problem is that I am going to have 8 targets. If these were all just LDRs, then it wouldn't be an issue and I could hook them up with 1k pull ups and it would be fine.

    Because I need so many, I can't really use the comparators, etc of the PIC. Is there a simpler way where I can use these photodiodes on the general I/O pins?

    I am also hunting around for some diodes that maybe have a narrow frequency range, so as to only respond to the laser. Then when there is no laser it would be a lot closer to 0 instead of 2 MOhms, etc.

  5. #5
    Join Date
    Jun 2011
    Posts
    26


    Did you find this post helpful? Yes | No

    Default Re: Simple Photodiode On/Off circuit

    Maybe there is another way?

    If I measure the voltage coming through the photodiode, it is 4.6v normally, and drops to 4.4v when the laser is directly on it. How could I detect such a small voltage change?

  6. #6
    Join Date
    Mar 2006
    Location
    China
    Posts
    266


    Did you find this post helpful? Yes | No

    Default Re: Simple Photodiode On/Off circuit

    If you have 8 A/D channels avaliable on your pic you can easily detect a 0.2V change. It should give a difference for aprox 30-40 steps in the reading if you power your pic from 5V.

    Disadvantage? YES several - slow and needs you to scan the A/D frequently to detect if the laser is on or not.

    External comparators - Cheap, easy to use and fast. Use a potentiometer to set the reference level on one input. Use the other input for the LDR (4.6 to 4.4V signal) and have one comparator for each LDR.
    Connect each comparator to a digital pin and then you can read the port to get all 8 values at the same time. You could also try to connect the 8 outputs from the comparators to pins that have interupt function and then you can wait for an interupt to fire and then you know you have a hit on a target.

    It all depends what you are trying to make, ambient light can be a problem and there could be better ways to solve your design.

    8 LDR targets ... and a laser.. my guess is Laser Tag system or maybe some kind of Laser fence

    Any one else up for some guessing?

  7. #7
    Join Date
    Jun 2011
    Posts
    26


    Did you find this post helpful? Yes | No

    Default Re: Simple Photodiode On/Off circuit

    Thanks for the help. I will try your idea with the comparators, as it sounds like the easiest to implement. Can you recommend the best chip for this particular job?

    I am making a shooting target game, so when they pull the trigger I will turn on the laser and see if it has hit any of the targets. I will pulse the laser at a slightly different rate each time to stop people cheating.

Members who have read this thread : 0

You do not have permission to view the list of names.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts