Author Topic: 50$ robot with Arduino?  (Read 2207 times)

0 Members and 1 Guest are viewing this topic.

Offline XyverTopic starter

  • Robot Overlord
  • ****
  • Posts: 125
  • Helpful? 0
50$ robot with Arduino?
« on: January 27, 2010, 12:40:55 AM »
How hard would it be to convert the 50$ robot with rangefinder to be controlled by Arduino?  I want it to avoid things in range instead of chasing them.

Offline Hawaii00000

  • Contest Winner
  • Supreme Robot
  • ****
  • Posts: 347
  • Helpful? 2
Re: 50$ robot with Arduino?
« Reply #1 on: January 27, 2010, 08:52:00 PM »
Depends if you know how to program an Arduino... You should be able to use the servo library to control the servos, but I don't think there's a rangefinder library. Do you know how to wire the servos/rangefinder?
"God chose to make the world according to very beautiful mathematics."
-Paul Dirac
Its Hawaii Five-O. Get it?

Offline madsci1016

  • Contest Winner
  • Supreme Robot
  • ****
  • Posts: 1,450
  • Helpful? 43
    • Personal Website
Re: 50$ robot with Arduino?
« Reply #2 on: January 27, 2010, 09:32:20 PM »
It would not be too hard (to program), even if there is no library. Just keep track of where the servo is, and do a analogRead on the pin the IR is on, and convert that to a distance (or don't convert, thats optional, if you are just interested in avoiding things). If the servo is to the left, and the voltage(ie the return of analogRead() ) goes beyond a threshold, then have your robot go right.


Get Your Ad Here