Restore these lines of code to prevent lockup of the motor on the first run after system boot
Line 91 DRV8825_SelectMotor(MOTOR1); Line 92 DRV8825_Stop();