Hello, this is my first post, but I have been on here before and found these forums very helpful. Here is my question:
I am building a robotic dog for a class and everything has gone smoothly until now. What I need to do is have my Infrared photodiode(http://info.hobbyengineering.com/specs/sfh205.pdf) connected to the non-inverting input of an LM339 comparator. The supply voltage for the comparator is at 5V. I also have a 2.5V reference voltage going into the inverting input of the comparator.
I have tested the comparator (which has a 220ohm pull up resistor on the output) using the reference voltage and a secondary varying voltage for the non-inverting input and it worked perfect. When I connect the IR photodiode, it does not work properly.
What happens is I turn the power on my breadboard on and the output voltage is at around .6-.7volts, which is fine. But after about 5 seconds, the output jumps up to 5volts and stays there.
Now, testing the photodiode separatly, I connect one side to 5V, then the other side to a .1uF capacitor, and the cap then goes to ground. I take the measurement in between the photodiode and the cap. I then use my IR emitter and the circuit works perfect, the closer I get, the higher the voltage (5V being the max).
Basically what I need to do is have the comparator output 5V when the photodiode is outputting over 2.5V and have the comparator output 0V when the photodiode outputs <2.5V. This has been a very frustrating part of the project because I know that it will work, I just can not get it exactally right. Thanks in advance for any help you can give.
-Scott
I am building a robotic dog for a class and everything has gone smoothly until now. What I need to do is have my Infrared photodiode(http://info.hobbyengineering.com/specs/sfh205.pdf) connected to the non-inverting input of an LM339 comparator. The supply voltage for the comparator is at 5V. I also have a 2.5V reference voltage going into the inverting input of the comparator.
I have tested the comparator (which has a 220ohm pull up resistor on the output) using the reference voltage and a secondary varying voltage for the non-inverting input and it worked perfect. When I connect the IR photodiode, it does not work properly.
What happens is I turn the power on my breadboard on and the output voltage is at around .6-.7volts, which is fine. But after about 5 seconds, the output jumps up to 5volts and stays there.
Now, testing the photodiode separatly, I connect one side to 5V, then the other side to a .1uF capacitor, and the cap then goes to ground. I take the measurement in between the photodiode and the cap. I then use my IR emitter and the circuit works perfect, the closer I get, the higher the voltage (5V being the max).
Basically what I need to do is have the comparator output 5V when the photodiode is outputting over 2.5V and have the comparator output 0V when the photodiode outputs <2.5V. This has been a very frustrating part of the project because I know that it will work, I just can not get it exactally right. Thanks in advance for any help you can give.
-Scott