This commit is contained in:
xyj 2023-12-26 17:06:31 +08:00
parent 5b4ad733c1
commit 1befe16519
1 changed files with 3 additions and 2 deletions

View File

@ -2,6 +2,7 @@
实验名称点亮第1个LED 实验名称点亮第1个LED
实验平台核桃派 实验平台核桃派
''' '''
import time
#导入相关模块 #导入相关模块
import board import board
@ -12,5 +13,5 @@ led = DigitalInOut(board.LED) #定义引脚编号
led.direction = Direction.OUTPUT #IO为输出 led.direction = Direction.OUTPUT #IO为输出
led.value = 1 #输出高电平点亮板载LED蓝灯 led.value = 1 #输出高电平点亮板载LED蓝灯
time.sleep(10)
#led.value = 0 #输出低电平熄灭板载LED蓝灯 led.value = 0 #输出低电平熄灭板载LED蓝灯