Code is available on GitHub here.

Microcontroller

Our robot, like all other robots in the ENPH253 course, was run using a TINAH board. This board is a custom shield for a Wiring I/O board, designed specifically for ENPH253. It acts as a protective buffer for the board's inputs and outputs, as well as providing control outputs for 4 motors and 3 servos and an LCD screen. This board is programmed using the same interface as an Arduino board, using the C++ language.

Information about the TINAH board can be found at the ENPH253 website.

Programming and Algorithms

The robot was controlled by a state machine. It was written in such a way that changes in strategy would be fairly easy, by abstracting out the main robot functions.

PID control was heavily used in the robot: it controlled tape following, IR following, and arm movements. We also quickly found how important noise reduction was: aside from the usual circuit changes to accommodate this, we also did some noise reduction (primarily debouncing) in code. There were also algorithms to actually perform a pet pickup, perform hardcoded driving motions using wheel encoders, and search for tape after losing it.