Hi all, I have a need to detect an object passing by a phototransistor, 2=94 to 6= =94 away. Indoors is easy: I have an IR LED reflecting off the object. (I= can not have the object break a light beam from the LED. Everything must = be contained in a single, small box.) When the object passes by, I get an = increase in voltage. Outdoors, I expect the object to block ambient light = and give me a lower voltage when it passes. This works most of the time. = Sometimes I get a higher voltage (which is OK) but sometimes I get no or ve= ry little change. I have a narrow tube over the phototransistor about 2=94= long to make it more directional. It has to work with the sun in any posi= tion. You would think it would work best when pointed in the direction of = the sun (with the object blocking the sunlight), but this is actually one o= f the worst conditions, especially in the afternoon. Maybe extra IR is get= ting in from hot surroundings? Any idea why I don't always get a voltage change, and how I could possibly = make this work? Thanks much for any suggestions, Dan -- = http://www.piclist.com PIC/SX FAQ & list archive View/change your membership options at http://mailman.mit.edu/mailman/listinfo/piclist