Cleaning up unused code and committing the first portion

of the updated motor controller code