CodePudding user response:
Start the motor rotates at the same time start the timer, repeatedly reading a timer to time after the stop the motor,CodePudding user response:
This is easy to implement, open the systick timer, set the timer interrupt, if 1 ms interruptLet each time, set a variable into the interrupt this variable + 1, can control time, time to
Close the motor