logo

刚学openmv,用扩展板控制舵机,为什么舵机没反应?(灯是有反应的)

2020-04-07 21:04
Z
大鹏

from pyb import Servo

import time,pyb

s1 = Servo(1) # servo on position 1 (P7)

led = pyb.LED(1)

while(1):

led.on()

s1.angle(45) # move to 45 degrees

time.sleep(600)

led.off()

s1.angle(0) # move to -60 degrees in 1500ms

time.sleep(600)

2020-04-07 22:44
I
网红小智智 星瞳科技

https://singtown.com/learn/50057/

https://singtown.com/learn/50541/

看一下视频。