Advertisement

Implementing Infrared Object Detection

Not rated 20,266

#infrared #object detection #IR sensor #remote control #consumer electronics #schematic #software #TV remote #detection system
Implementing Infrared Object Detection
Implementing Infrared Object Detection

Description: This document provides an overview of the components, schematic, software, and practical tips for utilizing infrared (IR) technology for object detection. The components employed are commonly found in consumer electronic remote controls and are readily available. An old television or other IR remote device can be repurposed to create an effective IR detection system. The two fundamental components for working with IR are the emitter and the detector. The emitter is typically an LED that emits near-infrared light, with a common wavelength of 880 nm, which is just outside the visible spectrum for humans. Many suppliers, both new and surplus, offer LED emitters. A standard IR detection system will usually incorporate two emitters. By controlling the activation of these emitters, the system can ascertain basic directional information: Left, Right, or Front. Various types of detectors are available for IR light, including photodiodes and phototransistors. It is advisable to purchase IR emitter/detector pairs that are matched for optimal performance, particularly when sourcing surplus components, as they are often verified for compatibility. Another key component for IR applications is a detector module, such as the Sharp GP1U5 (also known as the G1U52X). This module includes an IR detector and a small circuit that can detect a 40 kHz modulation, meaning the IR light flashes on and off at approximately 40 kHz. The advantage of using modulated light is the ability to filter out unwanted ambient light sources. The environment contains various light sources, and being able to identify a specific modulation, such as 40 kHz, allows for effective noise rejection. The components are illustrated in a robotic application, with the Sharp IR detector module positioned at the top and the emitters housed in aluminum tubes near the bottom. To utilize the Sharp IR detection module, a circuit capable of modulating the light at 40 kHz is required. This modulation is achieved through an oscillator circuit, which is described in detail below. The circuit employs a single 74HC04 inverter in multiple unconventional configurations. The circuit consists of three primary sections. The center section (U1:A and U1:B, along with discrete components) forms a feedback oscillator. The output of gate A feeds into the input of gate B, which in turn feeds back to the input of gate A. A gate propagation delay causes the circuit to oscillate continuously. The critical output is from gate U1:B, which is connected to the driver gates. The resistors and capacitors in the circuit regulate the frequency of the feedback loop. Resistor R2 adjusts the frequency, and while the Sharp detector is tolerant of slight variations, it is advisable to maintain the modulation frequency as close to 40 kHz as possible. The circuit is specifically designed for the 74HC04 and is not compatible with the 7404, 74LS04, or other TTL versions. It is recommended to use the correct component to ensure functionality. The output from the oscillator is routed through two buffers, which isolate the oscillator from the IR emitter section. The buffers also serve as current sources for the IR emitters, ensuring that the timing is unaffected by the characteristics of the LEDs used. The final gates, U1:C and U1:D, serve as control lines connected to the output ports of the CPU, buffering the CPU from the current demands of the LEDs. The interface with the CPU is facilitated through pins 5 and 9 in the circuit (gates C and D), controlling the activation of the emitters.

For the implementation of an IR detection system, the circuit design can be further optimized by exploring various configurations of the oscillator and selecting appropriate components to enhance performance. The use of matched emitter/detector pairs is crucial for achieving reliable detection capabilities. Additionally, careful consideration of the layout and power supply design can minimize noise and improve the overall responsiveness of the system. The integration of microcontrollers with built-in PWM (Pulse Width Modulation) features could simplify the modulation process and allow for more sophisticated control over the emitters. Furthermore, the application of filtering techniques in the software can enhance the detection accuracy by processing the signals received from the IR detectors. Overall, a well-designed IR detection system can provide valuable functionality in robotics, automation, and other electronic applications.This page is going to describe the parts, schematic, softw1are, and some tips on using Infrared for object detection. The parts used are typically the same parts found in most consumer electronic remote controls, and are widely available.

If you have an old TV or other IR remote device, you have the makings of a nice IR detection system. The tw1o basic parts for working with IR are the emitter and the detector. The emitter is typically an LED that emits near-infrared light. A typical wavelength is 880nm, which is just beyond the human eyes ability to see. Many suppliers, new and surplus, can provide you with sources of LED emitters. A typical IR detection system will use tw1o emitters. By controlling when the emitters are active, the detection system can determine simple directional information: Left, Right, or Front. There are several types of detectors for IR light. There are photo-diodes, photo-transistors, and a couple others. Usually, you buy IR emitter/detector pairs, which are tuned for each other. This is recommended when buying surplus, since chances are someone has verified they work together. The other important detector for working with IR is a detector module, such as the Sharp GP1U5 (also the G1U52X) module.

This module contains the IR detector and a small circuit that detects a 40khz modulation (i. e. the IR light is flashing on and off at about 40khz). The nice part about using a modulated light is the ability to reject noisy light signals. The world is full of light sources. Being able to detect a certain quality of a light, such as flashing at 40khz, means you can filter out much of the light you don`t want. The above photo shows these parts installed on the front of a robot. The Sharp IR detector module is the square box at the top of the frame, and the emitters are enclosed in aluminum tubes near the bottom.

To use the Sharp IR detection module, you need to have a circuit that can flash the light at 40khz, which is 40, 000 a second (pretty fast!). This is called modulation. The circuit that does modulation is called an oscillator, and I have shown one below. The above circuit is an interesting one to look at. It uses a single 74HC04 (inverter) in several ways that you don`t normally see, especially all at once.

Lets take a quick tour. There are three major parts to the circuit. The center (U1:A and U1:B plus discrete components) forms a feedback oscillator. If you follow the flow of the logic gates, you see that the output of A is fed into the input of B, which is fed to the input of A. Now, there is a gate propagation delay factor that causes this circuit to continuously flip states. The important state is the output of gate U1:B, which is fed to the driver gates. The resistors and capacitor in the circuit are there to regulate the frequency at which this circuit feeds back into itself.

Resistor R2 can be used to adjust the frequency of this circuit. The Sharp detector is fairly forgiving about the exact modulation frequency, but getting it as close as possible to 40khz is recommended. Note that the above circuit is tuned to work with the 74HC04, and is known NOT TO WORK with the 7404, 74LS04, and other TTL versions.

Do yourself a favor and get the real thing. The output from the oscillator is sent through tw1o buffers. Here the gates act to isolate the oscillator section from the IR emitter section. The buffers also act as current sources for the IR emitters. It is important to isolate the oscillator from the LED`s, since the timing would be affected by the particular types of LED you use. The final gates are the U1:C and U1:D gates. These are the control lines that you would connect to the output ports of the CPU. They act to buffer the CPU from the current requirements of the LED`s. The interface to the CPU is done through pins 5 and 9 in the above circuit (gates C and D). These control when the emitters turn on. The only other variable is

Related Circuits