Motor Reset Function: Resetting and Rotating X & Y Motors
This code defines a function called 'motor_reset' which resets the position values of two motors (X and Y) and also rotates them for 40000 steps in a specific direction (0) and at a speed of 100. It starts by launching the Y-axis motor (motorY_lunch(1)) and the X-axis motor (motorX_lunch(1)). Then, it calls the 'motorX' and 'motorY' functions to rotate the motors, passing the number of steps, speed, and direction as parameters. Finally, it sets the previous position values of both motors to 0.
原文地址: https://www.cveoy.top/t/topic/mVM5 著作权归作者所有。请勿转载和采集!