Newsgroups: comp.robotics
Path: brunix!cat.cis.Brown.EDU!noc.near.net!MathWorks.Com!europa.eng.gtefsd.com!howland.reston.ans.net!usc!elroy.jpl.nasa.gov!lll-winken.llnl.gov!enews.sgi.com!wdl1!mail!cps201!dombrows
From: dombrows@lds.loral.com (Brian Dombrowski, 5424)
Subject: Re: Fun with sensors - Light Tracking
Message-ID: <1994Aug16.181038.2441@lds.loral.com>
Sender: news@lds.loral.com
Reply-To: dombrows@lds.loral.com
Organization: Loral Data Systems
References: <32p30f$3vv@handler.Eng.Sun.COM>
Date: Tue, 16 Aug 1994 18:10:38 GMT
Lines: 33


A couple of years ago, I made light tracker from a gear head motor from
a cordless screw driver and two IR photo-transistors.  The transistors,
Q1 & Q2, were mounted on a 0.5 x 2" piece of perf-board and the perf-board
was mounted perpendicular to the motor shaft to form a T shaped assembly:

		TOP VIEW

		
                        |#D  <- Q1
	motor shaft -> o|
	facing at you	|#D  <- Q2


The key was to use the differential signal from the transistors to know
which way to turn the motor shaft inorder to track the light source
( IQ1 - IQ2.)  I used LM324 OP AMPS to generate the differential signal
and to also implement a PID controller.  The gain of each of the P,I, and
D terms could be controlled with pots.  The output signal drove the
motor via an 'H' bridge motor drive made with TIP120's and TIP125's.

The thing worked very well.  The cool thing was being able to change
the gain of the PID parameters to adjust sensitivity and overshoot.
It was able to follow a flash light and cigarette lighter around the
room.  The simplest part was the sensor.  The big pain in the ass was
the building the analog PID controller.  If I knew about the HC11 then,
I could have just used the analog inputs and done it all in code!
This would be very easy to try and you'd be surprised at how well
the above sensor works.

Bd


