Original code written for ECE 150 course at uWaterloo.