Code to control motor shield