TestDrive is a starter project to run Adafruit motor shields and Arduino Microcontroller Board. Since Adafruit and Arduino are different manufacturers, the motor shields are not compatitable with Arduino thus a library must be installed. TestDrive is a good starter to complete a semi-autonomous, obstacle-avoiding robot prototype using Arduino ultrasonic sensors and a robot smart car chassis.
All items can be bought on Amazon.
- Adafruit motor shields
- Arduino Microcontroller Board
- Wires
- Scotch tape
- Smart Car Robot Chassis Kit
Software Installation: Arduino IDE (https://www.arduino.cc/en/Guide/ArduinoUno) AFMotor.h file (https://learn.adafruit.com/adafruit-motor-shield/library-install)
The links above has step-by-step instructions on how to install the Arduino IDE and Adafruit library has installation steps. Copy and paste TestDrive.ino code to the IDE.
Plug in the Arduino microcontroller to the board. Use wires to attach to the microcontroller and motors to run the wheels of the kit. Scotch tape is fine for this tester, as long as the wires are securely touching.
Turn off wifi of the robot if any, or else, uploading the code will not run it.
Optional to change the speed and direction of the wheels based on the comments.
TestDrive.ino uses comments as directions on how to edit the speed and direction of the wheels, and explanation on reasons behind each line. Otherwise, TestDrive.ino is fairly easy to read.
Detach the wire from arduino, and put in batteries then let it run!
This is how a semi-autonmous, obstacle-avoiding robot would look with TestDrive.ino:
*Arduino *Adafruit
- Shelley Wu - Initial work - shelleywu
- Hat tip to anyone who tries to use this code in any way. Please credit me in any usage.