My project requires me to build a robot that can navigate an obstacle course without remote control.
I have used this http://forum.arduino.cc/index.php/topic,8666.0.html as a guide and so far I have hooked up the hardware and I can debug/read the IR sensor values when connected to the analog pin. The main difference between that and mine is that I am using servos not PWM and motors. I also read somewhere that using digital pins would be better than analog but am unsure how to code that.
I am wanting to be able to count how many times the sensor reads a change from black to white (or something similar to read movement) so that I can caluculate how far the robot has gone and then say after x amount of turns, turn robot left, then go straight then after x amount of turns, turn robot right etc.
I'd appreciate any help coding this or direction to where I can get more info to code this properly. and apologies for my lack of knowlede-I have been using Arduino for about 10 days.
My setup so far: https://www.dropbox.com/s/58rm8lddpshjuxy/IMG_1392.JPG