Add initial scripts for LED control and network scanning
This commit is contained in:
14
flashing_led.py
Normal file
14
flashing_led.py
Normal file
@@ -0,0 +1,14 @@
|
||||
from machine import Pin, PWM
|
||||
from time import sleep
|
||||
|
||||
pwm = PWM(Pin(12))
|
||||
|
||||
pwm.freq(5000)
|
||||
|
||||
while True:
|
||||
for duty in range(65025):
|
||||
pwm.duty_u16(duty)
|
||||
sleep(0.0005)
|
||||
for duty in range(65025, 0, -1):
|
||||
pwm.duty_u16(duty)
|
||||
sleep(0.0005)
|
||||
Reference in New Issue
Block a user