I'm trying to build a break-beam sensor that will be installed on my door, so I can detect someone walking in or out by having the person break a beam of visible light or IR light hitting a sensor. The light source will be on the door (on the side that swings open near the knob) and the detector will be on the frame, such that when the door is closed, the light source and the detector will be almost touching each other (is it possible that this will overload the detector? I can always install the detector and the light source at different heights so that even if the door is closed, the light source will be far enough away to prevent an overload).
Is visible light or IR better for this application? Is there a module out there that is designed for this? I've been looking at the GP1UX311QS on AdaFruit as the sensor because this is the one used in a tutorial at ladyada.net (Sensor tutorials - IR remote receiver/decoder tutorial) but I would like to know if it would be suitable for this application and what kind of issues I can expect. I already have a bunch of CdS photoresistors but I think they will easily be flooded by the ceiling lights in my room and not be able to detect a tiny LED 2-3 feet away (the maximum distance from the door frame to the side of the door that swings open) if the ceiling lights are on.
I'd appreciate any help . Thanks everyone.