your help os needed for this IR detection problem
kicknitinkc
Posts: 28
I'm trying to set up a simple IR detection circuit. How can I set up this phototransistor: http://www.parallax.com/StoreSearchResults/tabid/768/txtSearch/phototransistor/List/0/SortField/4/ProductID/604/Default.aspx to detect infrarea light? The product description says it can detect some infrared light but I'm not getting it to work. If that phototransistor is not ideal, then can I just simply replace it with the IR transistor with the black tint? Thanks.
Comments
You can learn a lot about how to use that phototransistor in What's a Microcontroller? v3.0, Chapter 7. The book is a free download from www.parallax.com/go/WAM.
This phototransistor detects visible light as well as infrared light in the environment. The dark-shaded infrared phototransistor filters out the visible daylight, so if you are looking for ambient infrared light in the environment, this would work better.
If you are trying to make an infrared detection circuit like the kind used in infrared remote controls, you are better off using an Infrared LED as your light source, and an infrared receiver, like this one:
http://www.parallax.com/tabid/768/List/1/ProductID/177/Default.aspx
This receiver is designed to look for infrared light that is flashing at a rate of 38 kHz per second. You can pulse and infrared LED to do this with the BASIC Stamp FREQOUT command.·Examples·for this type of IR detection circuit in Robotics with the Boe-Bot chapter 7 and 8. It's a free download from
http://www.parallax.com/tabid/134/List/1/ProductID/138/Default.aspx
-Steph
Sam
If you are using RCTIME with the phototransistor, that is going to give you a slower response in darker conditions, and the size of the capacitor used has an influence as well. With an IR receiver you will have a fast response and simple detected/not detected output. Your programming stragegy will matter here too - you could try putting the IR LED FREQOUT and bit-variable state check in a tight loop, maybe with a DO WHILE or DO UNTIL condition so the loop continues until the change in state you are looking for is detected.
Sam