Shop OBEX P1 Docs P2 Docs Learn Events
using a ping sonar to map rooms.. — Parallax Forums

using a ping sonar to map rooms..

stamp_demonstamp_demon Posts: 69
edited 2005-05-19 02:19 in BASIC Stamp
Hello, I was wondering if nayone had any experience with using a sonar rangefinder to map rooms. I'd love to see some code examples to study... thank you all very much _Duane

Comments

  • Paul BakerPaul Baker Posts: 6,351
    edited 2005-05-17 15:29
    Are you looking for a polar plot of distances to the nearest objects from the present position of the bot or a 2D object location map?
  • stamp_demonstamp_demon Posts: 69
    edited 2005-05-18 00:20
    I was hoping to be able to obtain a polar plot from the bots location to other objects in the room.
  • Paul BakerPaul Baker Posts: 6,351
    edited 2005-05-18 16:20
    Ok that should be alot easier to do, you would keep an array of variables, you would take the distance measurment, fill in the variable corresponding to that angle, rotate, repeat until the polar plot is filled in.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
  • stamp_demonstamp_demon Posts: 69
    edited 2005-05-19 02:19
    okay I think I can figure that out... I'll play around with it and post my code... thnax Duane
Sign In or Register to comment.