Subject:
|
Re: Sample bump sensor routine
|
Newsgroups:
|
lugnet.robotics.handyboard
|
Date:
|
Tue, 4 Feb 1997 13:02:33 GMT
|
Original-From:
|
Mike Ross <mross@outland.jsc.nasa.*SayNoToSpam*gov>
|
Viewed:
|
1313 times
|
| |
| |
On Mon, 3 Feb 1997, Bill Rose wrote:
> I am having trouble writing a routine for my bump sensors. Evertime I write
> a program I can't get the analog ports to initialize. I guess this is where
> you would connect bump switches isn't it. I can get my bot to go forward,
> turn, and go backward but I am having a problem with the multitasking of the
> motion and bump routines. I have the mobile robotics book but just haven't
> found the right combination. I would appreciate any of you software people
> for any help.
Why would you use the analog ports for a bump sensor? Isn't that just a
contact switch? Tie to a digital port pulled high with a 47K ohm
resistor, and have the normally open contact tie the pin to ground when
the contact switch is closed. The analog ports, being able to determine
many levels of voltage, also have more overhead and timing concerns. Use
the digital pins if you can. Good luck.
-mike
* Michael L. Ross/C33 | Lockheed Martin Eng & Sci Svcs Co. ****
* Robotics Department | 2400 Nasa Rd. 1, Houston, TX 77058*****
* (281)333-7094; (281)333-6071 fax* #include <disclaimer.h>*
* Finger me for my public key. mross@outland.jsc.nasa.gov ****
|
|
Message has 1 Reply: | | Re: Sample bump sensor routine
|
| whether you use analog or digital ins, you don't need the 47k pullup because the hb already has one. just wire the signal line to ground through the normally open switch. bill, i suggest you write your program without using the multitasking (...) (28 years ago, 4-Feb-97, to lugnet.robotics.handyboard)
|
Message is in Reply To:
| | Sample bump sensor routine
|
| I am having trouble writing a routine for my bump sensors. Evertime I write a program I can't get the analog ports to initialize. I guess this is where you would connect bump switches isn't it. I can get my bot to go forward, turn, and go backward (...) (28 years ago, 4-Feb-97, to lugnet.robotics.handyboard)
|
3 Messages in This Thread:
- Entire Thread on One Page:
- Nested:
All | Brief | Compact | Dots
Linear:
All | Brief | Compact
This Message and its Replies on One Page:
- Nested:
All | Brief | Compact | Dots
Linear:
All | Brief | Compact
|
|
|
|