树莓派开发之——跑马灯
raspberry实现跑马灯用例使用跑马灯是学习树莓派的开始,下面的例子即为树莓派开发跑马灯的python代码用例。import RPi.GPIO as GPIOimport timeWHITE = 5YELLOW = 6BLUE = 13GREEN = 19RED = 26leds = [WHITE, YELLOW, BLUE, GREEN, RED]ON = GPIO.HIGHOFF = GPIO.LOWdef sleep(sec): time.sleep
原创
2020-10-25 19:47:10 ·
1236 阅读 ·
0 评论