Infrared Add-On Module for Line Following Robot

Similar documents
ME 3210: Mechatronics Signal Conditioning Circuit for IR Sensors March 27, 2003

Pacific Antenna Two Tone Generator

KDS Channel DMX Controlled Servo Kit

Installation/assembly manual for DCC/Power shield

EL Wire sequencer / power supply PART NO

Universal Keying Adapter 3+

VG-305A AC Traffic Light Controller Kit

KDR00101 DMX Controlled Relay Kit

KDR00301 DMX Controlled Relay Kit

N8VEM S-100 BACKPLANE VERSION 04 MAY 3, 2015 J.B.

Schematic Diagram: R2,R3,R4,R7 are ¼ Watt; R5,R6 are 220 Ohm ½ Watt (or two 470 Ohm ¼ Watt in parallel)

[Note: Power adapter is not included in the kits. Users need to prepare a 9 12 V ( >300mA capacity ) DC power supply]

The PUMPKIN LIGHT LED

DIY Line Tracking Smart Car with AT89C2051

PIC Dev 14 Through hole PCB Assembly and Test Lab 1

Bill of Materials: Picaxe-based IR Control Module Pair PART NO

LED Knight Rider. Yanbu College of Applied Technology. Project Description

GLiPIC Ver C Assembly manual Ver 1.0

PIC Dev 14 Surface Mount PCB Assembly and Test Lab 1

Assembly Instructions for the KA Electronics RIAA EQ Monitor Switcher

LCD Prototype Circuit on Solderless Breadboard. 840 Pin Solderless Breadboard ( # ND)

TEMPERATURE SENSOR/FAN CONTROL BOARD USER'S MANUAL

High Power (15W + 15W) Stereo Amplifier

Drexel University Electrical and Computer Engineering Department ECE 200 Intelligent Systems Spring Lab 1. Pencilbox Logic Designer

Using solderless breadboards

Onwards and Upwards, Your near space guide. Figure 1. CheapBot Line Follower

Assembly Instructions for the KA Electronics IGFO Input Gain Filter Output Board

Freeze the Dizz Jameco Part No

Building the FlipChip Tester

DELUXE STEREO AMPLIFIER KIT

CHAPTER 5. Voltage Regulator

Number Name Description Notes Image 0101 Resistor, 100 ohm. brown-black-browngold. ¼ watt, 5% tolerance, red-red-brown-gold. brown-black-red-gold.

ELECTRONIC INSTRUMENTATION AND SYSTEMS LABORATORY

MP3 audio amplifier. Build Instructions. Issue 2.0

IR TRANSMITTER BLOK PCB ASSEMBLY INSTRUCTIONS. Copyright EduTek Ltd Rev. 2

Physics 120/220 Lab Equipment, Hints & Tips

Model INSTRUCTION MANUAL DIGITAL MULTIMETER

PicoTurbine Mark 8.3 Generator Field Controller Kit

Laboratory of Sensors Engineering Sciences 9 CFU

Lab 4: Digital Electronics BMEn 2151 Introductory Medical Device Prototyping Prof. Steven S. Saliterman

K191 3 Channel RGB LED Controller

SRD- Switching Regulator Step-down regulator. Switch-mode Step-down Regulator

UF-3701 Power Board Construction Guide

EVAL-INAMP-62RZ/82RZ/82RMZ

Connecting LEDs to the ADB I/O

Thursday, September 15, electronic components

Pacific Antenna Easy TR Switch Kit

Chill Interface PCB Assembly Instructions

UNIT II SPECIAL SEMICONDUCTOR DEVICES

Advanced Lantern 1.0 Kit. Introduction to the Advanced Lantern 1.0 Kit

Building the RGBW LED Controller

E85: Digital Design and Computer Engineering Lab 1: Electrical Characteristics of Logic Gates

This Presentation Will

CS4141 IDL Notes. I. Quick Overview of IDL Prototyping Unit

ROBOT LINE TRACKING MOUSE KIT C-9801

DPScope SE Assembly Guide

Button Code Kit. Assembly Instructions and User Guide. Single Button Code Entry System

Lab 2.2 Ohm s Law and Introduction to Arduinos

AUDIO AMPLIFIER PROJECT

MAX16128/MAX16129 Evaluation Kits. Evaluate: MAX16128/MAX General Description. Features. Component List

K8099 NIXIE CLOCK. * optional enclosure TKOK19 (black) - TKOK17 (white) ** optional plexiglass enlcosure B8099 ILLUSTRATED ASSEMBLY MANUAL

Insert the male, 90 angled, 2x10 connectors into the corresponding 2x10 sockets and put them in place, flat under the PCB. Solder.

PLD Series +5V Laser Diode Drivers

Sierra Radio Systems. HamStack. Project Board Reference Manual V1.0

Assembly Instructions for the KA Electronics Elliptic Equalizer

MP6500 Stepper Motor Driver, Digital Current Control

KAA Watt x 2 Class-D Audio Amplifier Kit

MICRO BURN IN PRODUCTS LISTED IN MODEL NUMBER ORDER FOLLOWED BY A BRIEF DESCRIPTION

Uzebox Kit Assembly Guide

CP5176 Assembly guide. Soldering. CP5176 Assembly guide Main PCB PCB split. Document revision 2.1 Last modification : 12/11/17

INSTRUCTION MANUAL HIGH CURRENT DRIVER BOARD STAND ALONE

Week 9: Design a Night Light. The experimental procedure Is not in the lab manual

Maxim Integrated Products 1

A4988 Stepper Motor Driver Carrier

ECE 270 Lab Verification / Evaluation Form. Experiment 1

Professional Radio GM Series. Controlhead Service Information

1/Build a Mintronics: MintDuino

Part 2: Building the Controller Board

BG1B Universal Gate Drive Prototype Board

Embedded Systems and Software

LDD M SERIES INSTRUCTION MANUAL LDD M SERIES

Digital Circuits. Page 1 of 5. I. Before coming to lab. II. Learning Objectives. III. Materials

Electronic Coin Toss

OPERATOR S INSTRUCTION MANUAL DIGITAL MULTIMETER

Touch Control Switch + - R6 R4 R8 R7 CAT# Grading. Assembly Instructions by Earl D. Gates SUNY Oswego Fall Conference 2007.

The Basic Counter. Hobby Electronics Soldering Kit. Instruction Guide

Development Kit Manual DK-114N-1 and DK-114N-3

STAGE INTERCOM KIT 1.1 SPECIFICATION. General: The lower section is a small power amplifier designed to drive headphones or a small 8ohm speaker.

Variable Power Supply Digital Control Circuit Diagram Using Lm317

ECE 2010 Laboratory # 2 J.P.O Rourke

Triori Game PART NO

Stamp Stack II-SX. BASIC Programmable Microcontroller Kit Quick and easy project prototyping for the Basic Stamp

+Denotes lead-free and RoHS compliant. C38 C43, C62, C64, C65, C66, C68, C70, C72, C73, C74, C76 C44 C49, C67, C75 C63, C69, C71, C77

LLIA90 LED ARRAY 90 LED Array Illuminator. LLIA90 LED Illuminator Array

Massachusetts Institute of Technology Department of Electrical Engineering and Computer Science Introductory Digital Systems Laboratory

Copyright 2014, R. Eckweiler & OCARC, Inc. Page 1 of 6

DMX CONTROLLED RELAY K8072

Transcendent Frequency Counter

Electronics Construction Manual

Morse Code Practice Oscillator

Transcription:

1 Infrared Add-On Module for Line Following Robot January 3, 2015 Jeffrey La Favre The infrared add-on module allows multiple line following robots to operate on the same track by preventing collisions at intersections. When two robots meet at an intersection, the IR emitter output of the robot on the left is detected by the robot on the right, causing the robot on the right to stop until the robot on the left clears the intersection. The module schematic above is divided into five circuits. The voltage regulator (VR) of the Power Supply Circuit provides five volt regulated power to IC1, IC2 and IC3. Direct supply of power from the nine volt battery to IC1 and IC2 is not possible because their maximum voltages allowed are 6.0 and 5.5 volts respectively. Integrated circuit IC1 is a Hex Schmitt-Trigger Inverter (manufactured by Texas Instruments, part number SN74AC14). The word Hex indicates that the chip contains six independent inverters, as can be seen in the schematic. An inverter converts a low voltage input to a high voltage output and a high voltage input to a low voltage output. The input pins are 1, 3, 5, 9, 11, and 13 and the output pins paired with the inputs are pins 2, 4, 6, 8, 10 and 12 respectively. Positive power is applied at pin 14 and negative power at pin 7. The IR module utilizes only four of the six inverters. If an inverter is not utilized, its input should be grounded (connected to negative power bus). Notice that input pins 5 and 9

2 are grounded and therefore, those are the two inverters that are not used. The output pins of unused inverters are not grounded. That is why there are no connections to pins 6 and 8. The two inverters connected to pins 1 through 4 are utilized in the IR Emitter Circuit. IR emitter D5 (a type of LED that emits infrared light) must emit infrared light at a pulse rate of 38,000 Hz. That means the IR emitter must turn on and off 38,000 times each second. The current pulses that turn the IR emitter on and off are produced by the inverter connected to pins 1 and 2. At the instant power is applied to IC1, pin 2 outputs 5 volts, which causes current to flow through resistors R9 and R8. The resistance of R8 is adjustable so that the rate of current flow can be adjusted. As the current flows through the resistors, it charges capacitor C6 (as a capacitor charges, it stores electrons). As the capacitor is charged, the voltage applied to pin 1 (input pin) rises. At a certain rising voltage on pin 1, the inverter is triggered which causes pin 2 to output 0 volts. When this happens, C6 begins to discharge (electrons drain out of the capacitor). As the voltage supplied to pin 1 by C6 drops, at a certain low voltage, the inverter is triggered once again and the output voltage at pin 2 changes back to 5 volts. This cycle repeats over and over continuously as long as power is applied to IC1. The time period of the cycle is determined by the values of resistors R8 and R9 and the value of capacitor C6. The higher the value of C6, the longer time it takes for the capacitor to charge and discharge. The higher the value of resistors R8 and R9, the lower the current flow, which results in a longer time to charge and discharge capacitor C6. The values of C6, R8 and R9 were selected so that the capacitor will charge and discharge about 38,000 times each second. As you have already learned, the marked value on resistors is usually not the exact true value. The true value must be determined by a meter. The same applies for capacitors. Therefore, it is necessary to have some way to adjust those values so that the charge/discharge rate equals 38,000 Hz. That is why R8 is an adjustable resistor. You will adjust R8 so that the charge/discharge rate equals 38 khz. Output pin 2 of IC1 is also connected to input pin 3 of IC1. Therefore, when the output of pin 2 is high (5 volts) the output of pin 4 is low (0 volts). And when the output of pin 2 is low, the output of pin 4 is high. The output of pin 4 is the mirror image of the output at pin 2. Also, the output pulse at pin 4 will be 38 khz if that is the rate at output pin 2. Pin 4 of IC1 is connected to a series circuit containing resistors R10 and R11 and IR LED (IR emitter) D5. Therefore, if the inverter output of pin 4 cycles at 38 khz, then the IR LED D5 will flash on and off 38,000 times each second. That is exactly what we want to happen because the IR detector (IC2) is designed to detect IR light at a pulse rate of 38 khz. Resistors R10 and R11 limit the amount of current supplied to D5. R11 is an adjustable resistor, which is used to adjust the brightness of the IR LED D5. You may be wondering why it is necessary to use two inverters to supply a 38 khz pulse current to the IR emitter. Why not just connect the output pin 2 to the circuit containing D5? If we did that, the pulse rate would not be stable. The circuit containing D5 would share the current supplied by pin 2 with the circuit containing R8, R9 and C6. During operation, D5 heats, causing a variation in the current draw of the D5 circuit. That variation would also cause a variation in the pulse rate output at pin 2. To prevent

3 this instability in pulse rate, the output of pin 2 is connected to the input at pin 3. By this method, the current supplied to R8, R9 and C6 is constant and the pulse rate produced is stable. The IR module must produce and detect infrared light pulsing at 38 khz. Now let s learn how the IR pulse is detected. Integrated chip IC2 is an IR Receiver Module (manufactured by Vishay, part number TSSP4038). This IC is designed to detect infrared light pulsing at a rate of 38 khz. That is why the IR emitter D5 is adjusted to pulse at 38 khz. IC2 is most sensitive to infrared light at a wavelength of 950 nanometers (nm). Its sensitivity to light at 850 and 1100 nm is only 10% of that at 950 nm. IC2 is not sensitive at all to visible light. Therefore, we want to use an IR emitting diode that emits light close to a wavelength of 950 nm. The IR LED D5 selected for this project is a Vishay part number CQY36N, which emits IR at a peak of 950 nm, a good match to our IR detector. IC2 has three pins. The middle pin (pin 2) connects to the negative power supply. Pin three connects to the positive power supply, which must not be more than 5.5 volts. Ceramic capacitor C3 is connected between pins 2 and 3 to function as a noise filter for IC2. Pin 1 is the output pin of IC2. If no IR pulse at 38 khz is detected, then the output at pin 1 is 5 volts. If an IR pulse is detected, the output of pin 1 is 0 volts. Notice that pin 1 of IC2 is connected to pin 13 of IC1. Therefore, pin 13 of IC1 receives the output of IC2. When an IR pulse of 38 khz is detected, we want our IR module to disconnect power from the robot motors. Let s follow the path of action that makes that happen. When IC2 detects the IR pulse, it supplies 0 volts to input pin 13 of IC1. The 0 volt input at pin 13 causes the output of the inverter at pin 12 to be 5 volts. Pin 12 is connected to input pin 11 of a second inverter. Therefore, the output pin 10 of the second inverter outputs 0 volts when 5 volts is applied to input pin 11. To summarize, an input of 0 volts at pin 13 results in an output of 0 volts at pin 10. The output of pin 10 is connected to pins 2 and 6 of IC3. IC3 is an LM393 voltage comparator, the same type used on the main PCB of the robot. Therefore, the output of pin 10 of IC1 is connected to the negative input pins of the LM393. Recall that if the input voltage of the negative input pin is greater than the input voltage at the positive input pin, the internal switch of the voltage comparator is turned on. If IC2 detects the IR pulse, 0 volts is applied to pins 2 and 6 of LM393 (IC3). The voltage divider created by resistors R2 and R3 supplies 2.5 volts to pins 3 and 5 of IC3, which are the positive input pins for the two voltage comparators. Therefore, if an IR pulse is detected, the switches of IC3 are turned off, which in turn turns off power transistors Q1 and Q2. When transistors Q1 and Q2 are turned off, power is disconnected. That is exactly what we want. When an IR pulse at 38 khz is detected, we want the IR module to disconnect power to the motors so that the robot will stop. The function of IC3 in this module is essentially the same as the LM393 chip used on the main robot PCB. It is wired to control power to the motors. Outputs at pins 1 and 7 are connected by resistors R5 and R4 to the bases of transistors Q2 and Q1, which in turn provide power to the robot motors. In the wiring for this breadboard, green LEDs D3 and D4 are connected to the power transistors to visually indicate

4 when the transistors are on and supplying power. When you wire the module on a circuit board, the green LEDs and current limiting resistors R7 and R8 will not be included. Instead, you will wire the power transistors to the robot motors. There is one circuit remaining on the breadboard that we have not discussed yet. Red LED D6 is connected to output pin 12 of IC1. When an IR pulse is detected, pin 12 outputs 5 volts which causes D6 to glow indicating detection. The red color of the LED reminds us that the robot is in the stop condition. Resistor 12 functions as the current limiter for D6. Assembly of Power Supply Circuit on Breadboard All jumper wires for the breadboard are 22 gauge solid wire. 1. Insert switch SW1 with its middle pin in row #3 as seen in the photo. This will be the power switch. 2. Bend the wires of Schottky diode D1 so that they will fit the board as seen in the photo. Insert D1 with the silver band down, connecting to the positive power bus at the bottom of breadboard. Connect the other wire of D1 to the same row that contains the middle pin of SW1 (row 3 in photo). The Schottky diode prevents damage to components if you accidentally try to connect the battery with the wrong polarity. 3. The red wire just to the right of D1 is not needed, please disregard. Insert film capacitor C1 (1.0 µf, 63 volts) with one pin in row 7 of the board and the other pin in row 9. 4. Prepare a black jumper wire and insert one end in row 7 and the other end to the negative power bus at bottom of the breadboard. 5. Prepare a red jumper wire and insert one end in row 9 of the breadboard and the other end to the positive power bus at the bottom of the board. C1 is now connected across the positive and negative power supply busses at the bottom of the board. These power busses will connect to the nine volt battery and C1 serves as a noise filter (suppresses voltage spikes) for the 9 volt supply.

5 6. Insert the voltage regulator (VR), with its flat face pointing toward the top of the board as seen in the photo. The left pin of VR should be inserted into row 9 of the board, middle pin in row 10 and right pin in row 11. Do not confuse this component with the two transistors you will use later. The number FKE26 LM78L 05ACZ is printed on the flat face of the voltage regulator. You may need to use a magnifying glass to read it. 7. Prepare three black jumper wires and connect one end of each to the bottom negative power bus. The other ends should be connected to rows 10, 12 and 15 as seen in photo. 8. Insert electrolytic capacitor C2 (22 µf, 25 volts) with its negative wire in row 12 and its positive wire in row 11. C2 functions as a noise filter for the 5 volt regulated supply from the voltage regulator. Notice that the positive wire of C2 is connected to the 5 volt output of the voltage regulator (the right wire of VR) and the negative wire of C2 is connected to the negative power bus. 9. Prepare a red jumper wire and connect one end to row 11, the same row that contains the positive wire of C2. Connect the other end of the wire to the positive power bus at the top of the board. This wire connects the 5 volt output of VR to the positive power bus at top of board. 10. Prepare a red jumper wire and connect one end to the positive power bus at the top of the board. Insert the other end into row 14 as seen in photo. This will supply 5 volts to red LED D2. 11. Insert the long wire (anode) of red LED D2 into the same row (row 14) that contains the red jumper of step 10. Connect the short wire (cathode) to row 15. D2 functions as a power indicator. When it glows, you know that power is being received from the battery through the voltage regulator (VR). 12. Bend the wires of resistor R1 (1,000 Ω) so that it will fit the board as seen in the photo and insert one end in the same row that contains the cathode of D2 (row 15 at top of board). Connect the other end to row 15 at bottom of the board. R1 functions as a current limiter for the red LED D2. 13. Prepare a black jumper wire and connect it to the negative power bus at the bottom of the board. Connect the upper end to the negative power bus at the top of the board. 14. Connect the red wire from the battery to row 2, the same row that contains the left pin of switch SW1. Connect the black wire from the battery to the bottom negative power bus as seen in the photo. 15. Ask an adult to check your wiring. This completes the wiring of the power supply circuit. The voltage regulator (VR) converts the 9 volt supply from the battery to 5 volts. With the flat surface of VR pointing upward, the left wire should be connected to the positive side of the 9 volt battery. The middle wire should be connected to the negative side of the 9 volt battery. Then the right wire of VR supplies a positive 5.0 volts regulated. You should notice that your wiring sets up two power buses on the breadboard. The bus at the top supplies 5.0 volts regulated, while the lower bus supplies the unregulated voltage from the battery (about 9 volts). The term regulated means the voltage will always be close to 5.0 volts (± 5% or 4.75 to 5.25 volts) provided the battery voltage is above 5 volts. The voltage directly from the battery is not regulated (unregulated). As the battery charge is depleted the battery will drop in voltage because it is not regulated.

6 The inverter chip (IC1) that you will wire next requires a regulated 5.0 volt supply to operate properly. It will not function at all if supplied 9 volts. That is why it is necessary to include the voltage regulator for this module. In contrast, the integrated circuit you used previously for the line following robot does not require a regulated voltage. It will work fine at 9 volts. Different classes of integrated circuits can have different power supply (voltage) requirements. When designing a circuit containing an integrated circuit, you should consult the data sheet for the IC to determine the power requirements. Measuring voltages of the power supply Before you continue with the next circuit, you should measure voltages on your board to confirm operation of the voltage regulator. 1. Slide the switch SW1 to the right (the off position) 2. Connect the 9 volt battery 3. Slide the switch to the on position. 4. Is the red LED D2 glowing? Yes No If the answer is no, then you need to troubleshoot your wiring. Ask an adult for help if you need it. 5. Slide the switch to the off position 6. Insert a short piece of bare 22 gauge wire into the positive power bus at the top of the board. Also insert pieces into the positive and negative power busses at the bottom of the board. Make sure these wire do not touch each other as this would cause a short circuit. These will serve as test points to measure voltages. 7. Set your meter to read DC volts (a setting of 10 volts maximum or next higher setting). 8. Slide the switch to the on position. The red LED should be glowing. 9. Touch the black meter probe to the test point connected to the negative power bus at bottom of board and the red meter probe to the test point connected to positive power bus at bottom of the board. Make sure you do not create a short circuit while measuring the voltage. 10. Read the voltage from the meter and record it here volts. It should be 9 volts or a little higher if you have a fresh battery. 11. Touch the black meter probe to the negative test point and the red meter probe to the positive test point at the top of the board. Avoid creating a short circuit while measuring the voltage. 12. Read the voltage from the meter and record it here volts. It should be close to 5 volts (between 4.75 and 5.25 volts) 13. When you have completed your measurements, slide the switch to the off position and disconnect the battery. Also turn off your meter. Remove the bare wire test points. If you obtained the proper voltages at the test points (about 9 volts unregulated and 5 volts regulated), then your power supply circuit is functioning properly and you are ready to continue. The next circuit you will build is the Infrared Emitter circuit. The directions are on the next page.

7 Assembly of IR Emitter Circuit on Breadboard The integrated circuit IC1 should already be inserted on the breadboard as seen in the photo below, rows 24 through 30 of the left half of the board. 1. Insert tantalum capacitor C5 (10 µf, 25 volts) into board with positive wire in same row as pin #14 of IC1 (the positive wire is marked on the capacitor). The remaining wire should be inserted into the next row to the left of pin #14 (row 23 in photo). 2. Insert ceramic capacitor C4 (0.1 µf, 50 volts) into board with one wire in same row as pin #14 of IC1. The remaining wire should be inserted into the next row to the left of pin #14. Capacitors C4 and C5 protect IC1 from voltage spikes that could cause it to malfunction. 3. Prepare a black jumper wire and connect one end to the top negative power bus (just below blue line at top of photo) and the other end to row #23, the same row as the negative wire of C5. The filtering effect of C4 and C5 requires that one wire of each be connected to the positive 5 volt power supply close to the IC1 chip and the other wire of each to the negative power supply. 4. Prepare a red jumper wire and connect one end to the five volt positive power bus (just above the red line at top of photo) and the other end to row #24, the same row that contains pin #14 of IC1. This jumper provides 5 volts power to IC1, required at pin #14. 5. Prepare three black jumper wires. Connect one end of each to the negative power bus at top of board. Connect the other ends to the rows containing pins #9, 11 and 13 of IC1. All input pins for IC1 (1, 3, 5, 9, 11, 13) must be connected to the negative power bus if they are not connected to any other component. Pin #9 will not be used for this project and the black jumper connecting it to the negative bus will remain. The jumpers to pins #11 and 13 are only temporary and will be removed before you complete the wiring of IC1. This will protect the IC1 chip from damage when applying power to adjust trimmer pot R8, which will be done before completing the wiring of IC1. 6. Prepare a green jumper wire. Connect one end to the same row that contains pin #1 of IC1. The other end should be inserted into the second row to the left of pin #1.

8 7. Insert trimmer pot R8 (20 turn, 10,000 Ω) with its center pin in the same row as the left end of the green wire of step 6. 8. Prepare resistor R9 (22,000 Ω) by bending its wires so that they span five rows. Insert the left wire into the same row that contains the left pin of R8 (row 21 in photo). Insert the other end in the same row that contains pin #2 of IC1 (row 25 in photo). 9. Insert one wire of film capacitor C6 (0.001 µf, 50 volts) into the same row that contains pin #1 of IC1 (row 24 in photo) and the other wire of C6 into the negative power bus at the bottom (below blue line in the photo). 10. Prepare a short piece of bare wire and bend it to span two rows. Then use this wire to connect the rows containing pins #2 and 3 of IC1. 11. Prepare resistor R10 (470 Ω) to span the distance as seen in the photo. Insert the left wire into the same row that contains pin #4 of IC1 and insert the other wire into the first row of the right half of the breadboard (see photo). This resistor, in combination with R11, controls the current to IR emitting diode D5. 12. Pins #5 and 7 of IC1 must be connected to the negative power bus as seen in the photo. Prepare two black wires as jumpers from pins #5 and 7 to the negative power bus and install them in the breadboard. Pin #5 is an unused input pin and pin #7 is the negative power connection for IC1. 13. Install trimmer pot R11 (1,000 Ω) with its left pin in the same row as the right wire of R10. 14. Prepare a green jumper wire that will span seven rows. Insert the left end into the same row as the center pin of R11. Insert the right side of the wire seven rows to the right of the left end (when counting, also count the row containing the left side of the wire). 15. Insert the longer wire of IR emitter D5 (anode) into the same row (row 8 in photo) that contains the right side of the green wire of step 14. Insert the shorter wire (cathode) into the next row to the right (row 9 in photo). 16. Prepare a black jumper wire to connect the cathode of D5 to the bottom negative power bus as seen in the photo (in the photo the jumper is connected to row 9 and the negative power bus). 17. Ask an adult to check your wiring. You have now completed the wiring of the IR emitter circuit. Before you continue with the next circuit, you should adjust resistor R8 so that the flashing rate of the IR emitter is 38,000 Hz (38,000 flashes per second). Obviously we cannot adjust the flashing rate by counting the number of flashes just using our eyes. First of all, humans cannot see infrared light. Secondly, the flashing rate is obviously much too fast to count. However, we can use an instrument to count the pulses of electric current delivered to the IR emitter from IC1. Mr. La Favre has two instruments that can be used to measure the pulse rate: 1) digital multimeter 2) digital oscilloscope. When you are ready to make your adjustment, an adult will assist you in connecting either instrument to your breadboard. While the instrument displays the pulse rate, you will adjust the screw of R8 until the instrument indicates a pulse rate of 38,000 Hz.

9 The positive probe of the instrument should be connected to the left wire of resistor R10 and the negative probe should be connected to a wire that is inserted into the negative power bus. Then turn on the power switch of the breadboard to display the pulse rate on the instrument. The image above is a copy of my oscilloscope screen after I adjusted R8 to obtain a pulse rate of 38 khz. Notice that on the right the frequency is displayed as 38.11 khz. Well, this is not exactly 38 khz, but it is close enough. The advantage of an oscilloscope is that it displays the wave pattern of the pulsating signal. This particular pattern is called a square wave. When the voltage is low, the wave trace makes a horizontal line near the bottom. Then over a very short period of time the voltage jumps up to a high voltage and then stays there for about half the cycle period. Then it quickly plunges down to the bottom, indicating a rapid loss of voltage. The complete pattern of one low horizontal line followed by a rising vertical line, then a high horizontal line and lastly a plunging vertical line constitutes one cycle. The square pattern indicates that over the majority of the cycle period, the voltage is either low or high and not at intermediate voltage values. This is the typical pattern seen in digital circuitry. In contrast, the AC power delivered to your home has a sine wave pattern. A sine wave looks more like a water wave, seen from its side. In AC power, the voltage rises and drops gradually from the bottom to top and return as seen in the image to the right. In the next section you will wire the IR detector to IC1. The IR detector is designed to detect infrared light that flashes at 38,000 Hz. That is why you need to adjust the flash rate of the IR emitter. While the detector can detect flashing rates slightly below and above 38,000 Hz, it is most sensitive in detection at 38,000 Hz.

10 Assembly of IR Detector Circuit on Breadboard 1. Remove the two black jumper wires that connect rows 25 and 27 to the negative power bus (they have already been removed in the photo below). 2. Insert the IR detector (IC2) on the breadboard. The dark lens should point to the bottom of the board. The left pin of IC2 should be in row 17, the middle pin in row 18 and the right pin in row 19 as seen in photo. 3. Prepare a black jumper wire and connect one end to the top negative power bus and the other end to row 18. This connects the middle pin of IC2 to the negative power supply as needed. 4. Prepare a red jumper wire and connect one end to the top positive power bus. Connect the other end to row 19. This connects the right pin of IC2 to the positive power supply. 5. Connect one wire of capacitor C3 to row 19 and the other wire to row 18, as seen in photo. 6. Prepare a green jumper wire to connect the left pin of IC2 (row 17) to pin 13 (row 25) of IC1. The left pin of IC2 is the output pin. Pin 13 is one of 6 input pins of IC1. Pin 12 is the output that is paired with input pin 13. IC1 is a hex inverter chip, which means it has 6 inverters. If a high voltage (such as 5 volts) is applied to the input pin of an inverter, the output pin of the inverter puts out a low voltage (0 volts). When IC2 detects an IR 38 khz pulse, the left pin outputs zero volts and if there is no detection it outputs 5 volts. Therefore, when the IR pulse is detected, zero volts are applied to pin 13 of IC1 which results in 5 volts output at pin 12 of IC1. 7. Prepare a bare wire jumper to span 2 rows and use it to connect pins 11 and 12 of IC1 (rows 26 and 27). This transfers the output of pin 12 to the input pin 11 and also a green wire connected in row 27. Now notice that there are 2 green wires, one attached to row 27 and one attached to row 28. You will attach these later. The green wire connected to row 27 sends the output of pin 12 to a red LED (not shown in the photo). When this red LED is glowing it indicates that an IR pulse has been detected. How does that happen? When the IR pulse is detected, input pin 13 receives zero volts which causes output pin 12 to output 5 volts. The 5 volts is connected to row 27 by the wire jumper between row 26 (pin 12) and row 27, which also contains the green wire that connects to the red LED. Therefore, the 5 volts of output pin 12 is applied to the red LED, causing it to glow. If there is no IR pulse detected, pin 13 receives 5 volts, which causes pin 12 to be 0 volts. In that condition zero volts is applied from pin 12 to the red LED and it does not glow, indicating that no IR pulse is detected. The green wire connected to row 28 receives the output of pin 10. Its function will be explained later.

11 8. Ask an adult to check your wiring. Assembly of Voltage Comparator and Power Transistor Circuits on Breadboard The voltage comparator IC3 should already be inserted on the board with its notch on the right side. Pins 1 and 8 are inserted into row 13 of the board and pins 4 and 5 in row 10. 1. Bend the wires of resistor R2 (2,200 Ω) so that they span 6 rows. Insert R2 into rows 6 and 11 as seen in photo. 2. Prepare a red jumper wire and connect it to the positive power bus and row 6. 3. Bend the wires of resistor R3 (2,200 Ω) so that they span 6 rows. Insert R3 into rows 11 and 16 as seen in the photo. 4. Prepare a black jumper wire and connect it to the negative power bus and row 16. 5. Prepare a green jumper wire and connect it to row 11 (IC3 pin 3) and row 10 (IC3 pin 5) as seen in photo. You have now completed the first circuit in this section. Notice that resistors R2 and R3 are in series and are connected to the 5 volt power bus. They function as a voltage divider. These resistors have the same resistance value. Therefore, if we place a test point between the two resistors in row 11 we can measure 2.5 volts at that location if our black meter probe is connected to the negative power bus. That 2.5 volt source is also applied to pins 3 and 5 of IC3. Those are the positive input pins for each voltage comparator of IC3. 6. Prepare a green jumper wire and connect it to row 12 (pin 2 of IC3). Connect the other end of the wire to row 11 (pin 6 of IC3). 7. Prepare a green jumper wire and connect it to top row 28 of IC1. Connect the other end to row 11 (pin 6 of IC3). You have now completed the second circuit which sends the signal from IC1 pin 10 (top row 28) to the negative input pins 2 and 6 of IC3. If there is no IR pulse detection then the output of pin 10 of IC1 will be 5 volts. The 5 volts will be applied to both negative input pins of IC3. As we have already learned, 2.5 volts will be applied to the positive input pins of

IC3. Therefore, when there is no detection of an IR pulse, the switches of IC3 will be turned on and likewise, the power transistors will also be turned on, allowing power to connect to the robot motors. This is what we want. If an IR pulse is detected, we want the robot to stop. If there is no detection, the robot should be moving. That will happen when pin 10 of IC1 outputs zero volts. 8. Prepare a green jumper wire and connect one end to the top 27 row of IC1 (pin 11). Connect the other end to top 29 row to the far right of the board. 9. Insert red LED D6 into board with long wire (anode) in row 29 and cathode (short wire) in row 30 as seen in photo. 10. Prepare resistor R12 (470 Ω) to fit the board and insert in rows 30, jumping the gap, as seen in photo. 11. Prepare and insert a black jumper wire to connect R12 to the bottom negative power bus. You have now completed the circuit from pin 12 of IC1 through D6 to the negative power bus. The red LED D6 glows when an IR pulse is detected. You could think of it as a red stop light. 12. Bend the wires of resistor R4 (2200 Ω) so that it spans 7 rows. Insert it in board as seen in photo, with the left end in row 12 (pin 7 of IC3) and the right end in row 18. 13. Bend the wires of resistor R5 (2200 Ω) so that it spans 7 rows. Insert it in board as seen in photo, with the left end in row 13 (pin 1 of IC3) and the right end in row 19. 14. Insert transistor Q1 with its flat face down, its left wire in row 17, middle wire in row 18 and right wire in row 19, as seen in photo. 15. Prepare a red jumper wire and insert one end into row 17, the same row that contains the left wire of Q1. Insert the other end into the bottom positive power bus (see photo). 16. Insert transistor Q2 with its flat face down, its left wire in row 18, middle wire in row 19 and right wire in row 20, as seen in photo. 17. Prepare a red jumper wire and insert one end into row 18, the same row that contains the left pin of Q2. Insert the other end into row 17, the same row that contains the left pin of Q1. 18. Insert green LED D3 with its long wire (anode) in row 20 and its short wire (cathode) in row 21 as seen in photo. 19. Insert green LED D4 with its long wire (anode) in row 19 and its short wire (cathode) in row 20 as seen in photo. 20. Bend the wires of resistor R6 (470 Ω) so that they span 6 rows and insert in board with its left end in row 21 and right end in row 26 as seen in photo. 21. Bend the wires of resistor R7 (470 Ω) so that they span 7 rows and insert in board with its left end in row 20 and right end in row 26 as seen in photo. 22. Prepare a black jumper wire and connect it to the row 26 (same row as right end of R6) and the top negative power bus, as seen in photo. 23. Prepare a black jumper wire and connect it to row 26 (same row as right end of R7) and the bottom negative power bus, as seen in photo. 24. Prepare a black jumper wire and connect it to row 10 (pin 4 of IC3) and the top negative power bus. 25. Prepare a red jumper wire and connect it to row 13 (pin 8 of IC3) and the top positive power bus. 12

13 26. I forgot to add capacitor C7 to my breadboard before I took the photos for these instructions. Therefore, I left that step out in these instructions, since the breadboard will still function without C7. Nevertheless, we will include C7 when you wire the IR module on the circuit board. 27. Ask an adult to check your wiring. Congratulations! You have completed all wiring on the breadboard. IC3 is a voltage comparator, the same type (LM393) used on the main board of the line following robot. If you compare the wiring of both IC chips, you will notice that the wiring is nearly identical. The only difference is the inputs to the chips. The LM393 on the main board gets its inputs from two sets of photoresistors while the LM393 on the IR module gets one input from pin 10 of IC1 and one input from a 2.5 volt source created by the circuit containing resistors R2 and R3. When you wire the IR module on a circuit board there will be some differences compared to the wiring on the breadboard. The circuit board will contain two Molex headers, one with 2 pins and one with 4 pins. There will be a two-wire set containing Molex connectors, one connector for the 2 pin header on the IR module and the other connector which will connect to the two pin header on the main PCB labeled Tube LEDs. This wire set transfers power from the 9 volt power bus on the main PCB and delivers it to the IR module. Since there is already a power switch connected to the main PCB, there is no need to add another one to the IR module. The wiring for your robot already contains a wiring set containing four wires and a Molex connector with a shunt inserted into the connector. After you finish your IR module, you will remove the shunt from the connector and insert this four-wire connector into the four-pin Molex header on the IR module. Power for the motors coming from the main PCB is transferred by two of the wires to the inputs of transistors Q1 and Q2 of the IR module. The other two wires of the four-wire set are connected to the outputs of transistors Q1 and Q2 of the IR module. These two wires provide power to the motors. Therefore, transistors Q1 and Q2 of the IR module must be turned on as well as the power transistors on the main PCB board before power is delivered to the motors. The power for each motor must pass through two power transistors in series, one on the main PCB and the other on the IR module. Both transistors must be turned on in order for the motor to receive power. The wiring for your breadboard includes two green LEDs, which will not be included when you wire the circuits of the IR module on a circuit board. Each one of the green LEDs (D3 and D4) is connected to the output of one power transistor (Q1 and Q2). When these green LEDs are glowing it indicates that their connected power transistors are turned on. We could include these LEDs on the circuit board, but it is not necessary. There are already LEDs on the main PCB board to indicate when power is being applied to a motor. Furthermore, when the power transistors on the IR module are off, then the red LED D6 glows, which provides a check of function of the IR module. Testing your IR module 1. Connect a 9 volt battery to the breadboard. 2. Set the power switch to the on position.

14 3. Even though the IR emitter D5 is pointing away from the IR detector IC2, there will probably be enough infrared light emitted off the side of D5 to trigger the IR detector. If the detector is in the detect condition, then the red LED D6 should be glowing and the green LEDs D3 and D4 should be off. If this is not the case, then ask an adult for help in troubleshooting the problem. 4. Now place your hand or another object between the IR emitter and the IR detector to block the infrared light from reaching the detector. If you are successful in blocking enough IR light, then the red LED D6 should turn off and the green LEDs D3 and D4 should be glowing. If this is what you observe, then your circuits are operating properly. If not, then ask an adult to help you troubleshoot the problem. Parts List Capacitors C1 1.0 µf, film, 63 VDC Digi-key 3019PH-ND C2 22 µf, 25 V, aluminum Digi-key 604-1052-ND C3, C4, C7 0.1 µf, ceramic, 50 V Digi-key BC2665CT-ND C5 10 µf, tantalum, 25 V Digi-key 399-3565-ND C6 0.001 µf, film, 50 VDC Digi-key 493-3377-ND Resistors (1/4 or 1/2 watt) R1 1,000 Ω Digi-key S1KHCT-ND R2, R3, R4, R5 2,200 Ω Digi-key 2.2KH-ND R6, R7, R10, R12 470 Ω Digi-key CF14JT470RCT-ND R8 10,000 Ω 25 turn trimmer pot Digi-key 3296W-1-103RLFCT-ND R9 22,000 Ω Digi-key S22KQCT-ND R11 1,000 Ω 1 turn trimmer pot Digi-key 3386W-1-102RLFCT-ND Diodes D1 Schottky diode 20 volt, 1 amp Digi-key 1N5817-TPCT-ND D2, D6 red LED Digi-key 160-1087-ND D3, D4 green LED Digi-key 160-1131-ND D5 IR Emitter 950 nm (Vishay part number CQY36N) Digi-key 751-1026-ND Transistors Q1, Q2 PNP bipolar, TO-92 package, 500 ma (Fairchild Semiconductor PN2907A) Digi-key PN2907ABUFS-ND Integrated Circuits IC1 Hex Schmitt-Trigger Inverter, 14 pin DIP (Texas Instruments, part number SN74AC14) Digi-key 296-4301-5-ND

IC2 IR Receiver Module, 38 khz (Vishay, part number TSSP4038) Digi-key TSSP4038-ND IC3 LM393 dual voltage comparator, 8 pin DIP Digi-key LM393NGOS-ND VR 5 volt linear voltage regulator 0.1 amp, TO92 package Digi-key LM78L05ACZFS-ND 15