In [3]:
print('CircuitPython Blink test')
import board
import digitalio
import time

led = digitalio.DigitalInOut(board.D13)
led.direction = digitalio.Direction.OUTPUT

#while True:
for n in range(10):
    led.value = True
    time.sleep(0.1)
    led.value = False
    time.sleep(0.1)
    print('n: {}'.format(n))
CircuitPython Blink test
n: 0
n: 1
n: 2
n: 3
n: 4
n: 5
n: 6
n: 7
n: 8
n: 9
In [ ]: