Arduino Tutorials

Arduino 04 – Obstacle Avoidance Challenge

  • Posted on: 12 October 2017
  • By: Cailen Robertson

Basic Arduino Code

Now that we have the building of the cars and driving controls sorted out from the previous workshops we can now look at getting the robot to drive itself.

Below is the code for the workshop, we use 3 ultrasonic sensors mounted on the front of the car. Make sure that you change the pin numbers to match your wiring! You can always check that your sensors are working properly by reading the serial output on your computer when the bot is plugged in.