Shop OBEX P1 Docs P2 Docs Learn Events
How to use IR sensors to map rooms? — Parallax Forums

How to use IR sensors to map rooms?

nofearsotnofearsot Posts: 25
edited 2005-05-22 19:33 in BASIC Stamp
How to use IR sensors to map rooms? sad.gif

▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
www.geocities.com/cdrombot

Comments

  • LoopyBytelooseLoopyByteloose Posts: 12,537
    edited 2005-05-21 08:09
    IR sensors don't seem to see black. Ultrasound sensors get a bit confused by reflections. Radar is a bit of overkill. Video requires a lot of processing.

    I would love to map rooms, but it seems that you really have a more complicated set of tasks.

    First I would use IR to establish that the robot is not going to walk off a table or a curb.

    Second I would use IR, ultrasound, and bumpers to avoid immediate collisions.

    Now the robot can wander and gather data.

    Herein lies the challenge. You have to determine what sensors and how much data are useful. Your map may be entirely different from anyone elses.

    In fact, you may be the next Thomas Edison or Bill Gates if you get the whole thing right. Good luck.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    G. Herzog in Taiwan
  • nofearsotnofearsot Posts: 25
    edited 2005-05-21 10:49
    IR DET: PNA4602 - 38 Khz IR Detector
    IR led: QED233

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    www.geocities.com/cdrombot
  • LoopyBytelooseLoopyByteloose Posts: 12,537
    edited 2005-05-22 07:42
    I guess you want to get the above components operable.
    [noparse][[/noparse]Try not to be so cryptic, please.]

    Try reading the specification sheets for the product to get your wiring right. Then, take a look at the appropriate Nuts and Volts reprints in the Parallax documents. That should give you an idea about the programing and interface to a BasicStamp.

    Nevertheless, after you get all this working you will find that some colors are seen and others are not.

    Also, as long as the color remains constant, there are some options to identfy distance by varing frequency {the Toddler robot manual has a chapter on it}.

    You can easily build a good line follower, but as discussed above mapping is a more complex task.
    Eventually, you have to consider multiple perimeters to serve different purposes and multiple levels with different types of sensors.

    Parallax used to sell a color sensor, that may be useful too. I am not sure if it is still available.

    The new Ping sensor is a narrow beam ultrasound that may be more appropriate for mapping. The older wider beam are more suitable for sensing room security.

    Still each has short comings that requires it to interact with other sensors to confirm barriers. Without confirmation, you see bounces from ultrasound as objects and you don't see dark objects in front of IR.

    Obvously, bumpers remain the most successful confirmation of an object and having the robot go and touch it is useful for maping. This is similar to you hearing, but not seeing or vise-versa. Animals and People really integrate quite a bit of sensory information inorder to function safely and have several tests for validity. Once safety is overcome, then there is time to map for the sake of other needs or convience.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    G. Herzog in Taiwan
  • nofearsotnofearsot Posts: 25
    edited 2005-05-22 13:18
    Hello. I have a problem with my ir leds. They are continuously burned. Ι use this IR leds: QED233. Do anyone know how how to build a scanning head?

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    www.geocities.com/cdrombot
  • JonathanJonathan Posts: 1,023
    edited 2005-05-22 13:50
    Hi,

    Do you have resistors in series with your LEDs, say about 220 ohms? Especially if you are running them directly from a Stamp pin. If you are switching them on with a transistor, you can get away with a much lower resistor, say 10 ohms, as long as you keep the duty cycle low. This is what TV remote controls do.

    As to a sensor head, I guess you mean a pan/tilt type array. You can see one I made at:

    http://madlabs.info/h2fcrp/h2fcrp_sensors.shtml

    HTH,

    Jonathan

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    www.madlabs.info - Home of the Hydrogen Fuel Cell Robot
  • nofearsotnofearsot Posts: 25
    edited 2005-05-22 13:58
    thank you jonathan. Where I must connect the resistors and if i program the robot freqout 1,1,38500 is the same with this freqout 1,1,48500

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    www.geocities.com/cdrombot
  • JonathanJonathan Posts: 1,023
    edited 2005-05-22 14:30
    The resistors need to be in series with either lead of the LED. Are you running directly from a Stamp pin? If so, I would use a transistor so you can drive the LED harder. In any case, do not drive it directly from a Stamp pin without the resistor, you can damage the Stamp pin.

    The Stamp can't really produce a clean 38kHz. They way it works is that you can generate enough harmonics at 38kHz to make a sensor work. There will be a differnece between the two freqout commands, but if you are looking for 48.5kHz, it may or may not produce enough harmonics. I know the 38kHz works, as that is what the Parallax Sumobot uses.

    Jonathan

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    www.madlabs.info - Home of the Hydrogen Fuel Cell Robot
  • nofearsotnofearsot Posts: 25
    edited 2005-05-22 16:08
    Can I build a scanning head with dc motors?

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    www.geocities.com/cdrombot
  • JonathanJonathan Posts: 1,023
    edited 2005-05-22 19:33
    Yes, you can use DC motors but...

    The nice thing about servos or stepper motors is that it is easy to set them to a certain location. You can easily and accurately place the sensor in the same spot and know where the sensor is pointed. With DC motors, you are going to have to come up with ways to know where the sensor is pointed. One way to do so would be with a rotary encoder. However, I would suggest you start with servos, they are cheap and easy to use. With DC motors you will also need an H-bridge to run them, wheras you can run a servo with no additional hardware.

    Jonathan

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    www.madlabs.info - Home of the Hydrogen Fuel Cell Robot
Sign In or Register to comment.