To LUGNET HomepageTo LUGNET News HomepageTo LUGNET Guide Homepage
 Help on Searching
 
Post new message to lugnet.robotics.handyboardOpen lugnet.robotics.handyboard in your NNTP NewsreaderTo LUGNET News Traffic PageSign In (Members)
 Robotics / Handy Board / 6891
6890  |  6892
Subject: 
interfacing the GP2D12
Newsgroups: 
lugnet.robotics.handyboard
Date: 
Thu, 14 Oct 1999 00:01:00 GMT
Original-From: 
Gary Livick <glivick@[Spamcake]pacbell.net>
Viewed: 
772 times
  
Somebody asked the other day about a problem interfacing the Sharp
GP2D12.  I didn't see an answer, and I just did it myself and solved the
problem, so here is how to do it.

For those who don't know, Sharp just came out with an IR ranging sensor
good out to about 30 inches that provides an analog signal related to
range.  The signal is not linear, but that can be dealt with in
software.  The area examined by the sensor is very narrow, so by
mounting it on a small servo and sweeping it while gathering range data,
a lot if information can be obtained about the immediate surroundings.

The GP2D12 has a few advantages over sonar; 1. it is good down to about
5",  2. it is less than $15.00, 3. it refreshes about every 32 ms, and
4. it does not require a driver, you just plug it in and start reading
data.

Hooking it up has one small gotcha with the HandyBoard and probably most
of the other MIT-spawned boards as well.  The output of the sensor wants
to see a floating pin, but the analog inputs on the HandyBoard are
pulled high by RP3, a 47k resistor pack.  To connect the sensor to the
HandyBoard, you have to cut a trace so the input can float on that pin.
That is easy enough to do, as the traces on the main board are easy to
identify, and easy to repair if you change your mind later and want to
restore the pin to normal.  However, some care must be taken to choose a
pin for an input.  If you just cut a trace for a pin at random, due to
the way the circuit is layed out you may just isolate the input pin from
the HC11 instead of removing the pull-up voltage.  Unless you want to
figure out what I'm talking about, use analog 5 to connect your GP2D12.
Trimming the trace between RP3 and that pin has the anticipated result.

The sensors are available at http://www.acroname.com  Check out some of
my robots in the gallery while you are there.

Gary Livick



Message is in Reply To:
  PWM on tic3
 
Hi, I want to get the width of a PWM on TIC3 Channel, I wrote an .asm but it doesn't work, I don't know what's wrong? I need your help. Thanks in advance. Said. Here is the .asm program: #include "c:\pcode\include\6811regs.asm" * program equates * (...) (25 years ago, 13-Oct-99, to lugnet.robotics.handyboard)

2 Messages in This Thread:

Entire Thread on One Page:
Nested:  All | Brief | Compact | Dots
Linear:  All | Brief | Compact
    

Custom Search

©2005 LUGNET. All rights reserved. - hosted by steinbruch.info GbR