Skip to content
Permalink
Branch: master
Find file Copy path
Find file Copy path
Fetching contributors…
Cannot retrieve contributors at this time
10 lines (9 sloc) 274 Bytes
from time import sleep
from makeblock import MegaPiPro
board = MegaPiPro.create()
stepper = board.StepperMotor(MegaPiPro.PORT1)
position = 0
def on_finished(value):
position = 5000 - position
stepper.move_to(position,100,on_finished)
on_finished(position)
You can’t perform that action at this time.