Infra Red Sensors
InfraRed sensor circuits have many varieties. The simplest uses an IR LED to deliver the light and an IR sensitive phototransistor to see it. The phototransistor turns on when IR light hits it, whether from the LED or ambient sources or reflected. The circuit shown should deliver an output if any IR light shines on it. Typical values for the resistor going to the phototransistor collector would be around 10K ohms or so. LEDs are usually driven through 200 to 1K ohm resistors. When no IR light is can be seen by the detector, you should see a good high (5 volt) from the output connected to the collector. When IR light is present, the phototransistor should conduct and you should see a good low, probably around 0.7 volts. One simple use might involve line detection, with sensors on either side and on a line to be followed by the robot. More sophisticated IR usage involves pulsing IR light at a known frequency, and using a detector that is attuned to that frequency. The circuitry within the Sharp GP1U58Y series tunes the detector to a specific frequency. Each is sensitive to IR that has been pulsed at that given frequency in short bursts. This encoding of the IR helps to mask out external sources that might have been in the way of information we really want, specifically how close something is or the recieving of coded data. What is needed for proximity detection is an IR source that outputs light at the specified frequency and on time for that freqency to match the detectors reception charecteristics. Various circuits work, from 555 timers that drive the IR LEDs to simply hooking them to lines from your controller and programming in the appropriate driving sequence. My use has been with Dennis Clarks IR proximity detector, based on the DPRG IR proximity detector by Jeff Koenig. This circuit uses a PIC to generate the appropriate frequency and pulsing for left and right IRs, counts the number of detections for each side and finally outputs a good dectection for either the left or right side. Doing this all on a seperate processor frees up the controller for other tasks in driving a robot. It can use the Sharp detector, a Radio Shack LiteOn detector, or a Panasonic PNA4601M series. I've used both the Sharp and the Panasonic PNA4602M. The board provides excellent right and left detections, and is only confused in rooms with high flourescent lighting. In these I plan to try the little trick of using a small strip of exposed film or perhaps some of the red plastic for remotes in front of the detector to hopefully shield some of the flourescent "noise" that overloads it.
More advanced infrared sensors come in "all in one" packages, such as the Sharps GP2Dxx series. These sensors can provide range information, in either analog or digital form, or simply be a trigger point when something is within an adjustable range. The GP2D02 gives an 8 bit digital reading when triggered. GP2D05s give an high or low signal when a specific preset range is reached. GP2D12s output an analog voltage corresponding to range continuously. GP2D15s output a high or low when crossing a 9.5" distance. All typically have detection capabilities from 4" to 31" and cost anywhere from $13 to $25, depending on capabilities.
IRLED phototransistor pairs can be used for encoders. Either a reflective pair which can count strips on a wheel or a slotted type to count slits in a wheel are possible. Several different types exist, usually in the form of quadrature encoders. Quadrature encoders use 2 pairs of sensors which are placed out of sequence with each other to allow knowing the direction a motor is turning, as well as how far or fast it is going. Some people have even hacked these from inside computer mice. One further advanced use of IR is in it's basic use in remote control. Again appropriate sequencing is needed, but information can be transmitted and received, just as you turn on and off your TV. Dennis Clark has again put this to use in an encoder/decoder pair of PICs for transmitting and receiving information. Other web pages discuss the coding sequences on regular TV remotes and provide some information as to the sequences involved. I haven't used this yet, but can see it as a great way to start your robot remotely or drive it or possibly have a data link between the robot and a computer.
|