Toggle pin 0 twice per second. This could be used for example to blink LED on pin 0 once per second with this test circuit:
BOARD__1gp0____3gnd
| |
R_2k |
| |
+-aLEDc-+
Tested on:
micropython/blink_gpio.py
from machine import Pin
from time import sleep
pin = Pin(0, Pin.OUT)
i = 0
while (True):
pin.toggle()
print(i)
sleep(0.5)
i += 1