Examples

Short programs you can paste into a REPL or save as main.py. Basics assume any firmware. Hardware examples name the API; the pin numbers follow Pico unless a note says otherwise. Network examples need a radio (Pico W, ESP32, ESP8266).

Basics

Hello, types, loops, modules, files, errors and asyncio — no hardware required.

Hardware

Pin, PWM, ADC, IRQ, Timer, I2C, SPI, UART, RTC, watchdog and sleep.

Network

Wi-Fi, sockets, HTTP, MQTT, WebREPL and Bluetooth Low Energy.

Projects

Weather station, web server, logger, robot and an OLED clock.

Try without a board

Language-only snippets also run on the Pico MicroPython emulator. Anything that toggles GPIO 25 will light the emulated LED.