nrf5/modules: Adding a python test file with function to dim a specific led (17).
This commit is contained in:
parent
0999226103
commit
2db3f0deb7
10
nrf5/modules/test.py
Normal file
10
nrf5/modules/test.py
Normal file
@ -0,0 +1,10 @@
|
||||
import time
|
||||
from machine import PWM
|
||||
|
||||
def pulse():
|
||||
for i in range(0, 101):
|
||||
p = PWM(0, pin=17, freq=50, duty=i, period=16000)
|
||||
time.sleep_ms(10)
|
||||
for i in range(0, 101):
|
||||
p = PWM(0, pin=17, freq=50, duty=100-i, period=16000)
|
||||
time.sleep_ms(10)
|
Loading…
x
Reference in New Issue
Block a user