From Discovering Computer Science

Obstacle: Obstacle

Obstacle Avoidance Robot



Session 1-Assembling Your Robot
VideosText FilesSource File
Platform Assembly  

In session 1, you will assemble your robot. Use the Platform Assembly video to aid you in your assembly process.



Session 2-Wiring
VideosText FilesSource File
Wiring the Assembled PlatformMotor Shield Diagram 
 Wiring the Ultrasonic Sensor to the Motor Shield 

In session 2, you will complete the wiring of your robot. The video will show you how to wire your motors to the motor shield, and the Text File will explain how to wire the ultrasonic sensor to the motor shield.



Session 3-Getting Your Robot Moving
VideosText FilesSource File
Simple Move Tutorial Simple Move

In session 3, now that your robot is completely assembled and wired up, its time to get it moving. You will start with getting to just move forward in a straight line without incorporating the ultrasonic sensor, then experiment around with changing the pin values to make it execute different maneuvers.

Maneuvers
E1E2M1M2Descriptions
HighHighLowLowThis will make the Robot move forward
HighHighHighHighThis will make the Robot move backwards
HighHighHighLowThis will make the Robot spin Clockwise
HighHighLowHighThis will make the Robot spin counter-clockwise
HighLowLowHigh or LowThis will make the Robot turn Left
HighLowHighHigh or LowThis will make the Robot back up to the Left
LowHighHigh or LowLowThis will make the Robot turn Right
LowHighHigh or LowHighThis will make the Robot back up to the Right
LowLowHigh or LowHigh or LowThis will make the motors stop

Note: find more information about PWM speed control here
Find more information about AnalogWrite here



Session 4-Getting Your Sensor Working
VideosText FilesSource File
Simple Sensor Tutorial Simple Sensor

In session 4, you will use your ultrasonic sensor to detect an object. It will convert it's time signal into a distance and display that distance on the serial monitor.



Session 5-Incorporating the Sensor and Motors
VideosText FilesSource File
Forward Stop Tutorial Forward Stop

In session 5, you will be incorporating both the ultrasonic sensors and the motors into a program that moves forward until it senses something at a certain range which then causes the robot to stop.



Session 6-Avoiding Obstacles
VideosText FilesSource File
Final Obstacle AvoidanceAchieving Full Obstacle Avoidance 

In session 6, you will complete the implementation to create complete obstacle avoidance. After you get a working code with one sensor, try to implement more sensors in order to better avoid obstacles.

Retrieved from http://pages.cs.wisc.edu/~karu/DiscoveringCS/wiki/index.php?n=Obstacle.Obstacle
Page last modified on January 25, 2014, at 03:22 PM