Lecture 15 Line Tracer Hong, Youpyo @ DGU
Line Tracer
Line Tracer Configuration Sensors : Detect the Road Situation CPU : Determines the Direction to Move and Generate Corresponding Signals Motors and Wheels
Direction to Move if left=white, center=black, right=black then turn right if left=white, center=black, right=white then go straight
So Go straight Turn Left Turn Right
Infrared Sensor Detector the lights with 0.75mm ~ 1mm waves Consists of Transmitter and Receiver Most remote controllers for consumer electronics have transmitter and the sets have receiver Auto doors, auto lights and motion detectors include both ; transmitter sends out the infrared signal and the receiver detects the response
Infrared Sensor for Line Tracer White floor reflects the infrared signal Black floor absorbs the infrared signal Warning) If you keep turning on the infrared transmitter too long, the lifetime of the device will be reduced or the device can be damaged.
DC Motor Driver IC Motor requires huge current for the operation. Not only CMOS but also TTL is not strong enough to provide such big current. Sometimes DC motors generate reverse current toward the driving chip. Therefore special DC motor driver IC is need (Ex. Sanyo LB1630.)
Pseudo Code Pseudo-code is a way of expressing an algorithm in similar style of C code. Do not worry about detail grammar. We will not compile anyway. You can even create a your own function name. direction ( ) { if (sensor input is 001) …. else if
Homework Write a pseudo code to illustrate the operation of the line tracer. You need to define proper variables and come up with an algorithm.