Shop OBEX P1 Docs P2 Docs Learn Events
Help with the PING))) Ultrasonic Distance Sensor — Parallax Forums

Help with the PING))) Ultrasonic Distance Sensor

bryan13bryan13 Posts: 4
edited 2014-03-25 12:07 in Accessories
I am a senior in high school and i'm trying to figure out how to use the ultrasonic to roam as a project for class. I have ran the programs I have found in the forums and on the website but none of them work. everyone of them makes the boe-bot scan with the sensor but it wont move forward or back, it only turns it circles. the simple roaming program makes my boe-bot move like 2 inches and stops, it repeats that process and the ping server is constantly moving. on all the videos I've watched, the boe-bot keeps moving until it senses an object then scans for the clearest path. if you could give me any advice on what i'm doing wrong or even post a program that would be greatly appreciated.

Comments

  • PublisonPublison Posts: 12,366
    edited 2014-03-21 09:09
    Welcome to the forums!

    This may be an indication of low battery voltage. Try a brand new set of batteries and report back.

    Running the wheel servos and the ping sensor servo puts a lot of stain on the batteries.
  • Chris SavageChris Savage Parallax Engineering Posts: 14,406
    edited 2014-03-21 09:39
    Also please note that the Advanced Romaing with PING))) program requires no only calibration of the servo positions (see the comments in the code) but it requires the IR sensors to be working on the BOE-Bot. As always, check all your connections as these programs expect certain things to be connected to certain I/O pins. Perhaps post a picture of the top of your robot showing the connections.
  • bryan13bryan13 Posts: 4
    edited 2014-03-21 11:17
    The only wires I have plugged up are the ones strictly for the Ping))). I am confused of why the IR sensors would have an effect on it. Explain?
  • bryan13bryan13 Posts: 4
    edited 2014-03-21 11:32
    Snapshot_20140321.JPG
    This is all we have. I didn't know the IR sensors have to be connected I thought the Ping was suppose to take place of the IR.
    320 x 240 - 15K
  • Chris SavageChris Savage Parallax Engineering Posts: 14,406
    edited 2014-03-21 12:39
    It depends on which code you're running. The Roaming with the PING))) (Advanced) requires the IR sensors typically installed on the BOE-Bot during normal assembly. That is because in that code the PING))) is only looking forward until and object has been detected by any of the sensors as being too close at which point it does a scan using the PING))) and chooses the most open path. Your picture is too small to see any details. Normally you would connect the PING))) sensor and the servo to the servo headers as long as the jumper for those headers is set to VDD and not VIN.
  • bryan13bryan13 Posts: 4
    edited 2014-03-25 12:07
    so I have the IR sensors setup, now the problem is that the robot cant get out of corners.
Sign In or Register to comment.