A small PlatformIO project with one shared Arduino blink sketch and build environments for ESP8266, ATtiny85 Digispark-compatible boards, ESP32, ESP32-S3, and Raspberry Pi Pico.
- PlatformIO Core or the PlatformIO extension for VS Code
- A USB data cable for boards programmed over USB
Run a build from this directory, choosing the environment for your board:
pio run -e esp01
pio run -e digispark-tiny
pio run -e esp32dev
pio run -e esp32-s3-devkitc-1
pio run -e picoThe shared example is in src/main.cpp. Board LED pins and wiring differ; check your board documentation if the built-in LED does not blink.
pio run -e <environment> -t uploadReplace <environment> with one of the names above. Typical upload methods:
| Environment | Board | Upload method |
|---|---|---|
esp01 |
ESP8266 module (esp12e definition) |
Serial bootloader |
digispark-tiny |
ATtiny85 Digispark USB | Micronucleus bootloader; connect the board when prompted |
esp32dev |
ESP32 Dev Module | Serial bootloader |
esp32-s3-devkitc-1 |
ESP32-S3 DevKitC-1 | USB or serial bootloader, depending on the board connection |
pico |
Raspberry Pi Pico (RP2040) | picotool; hold BOOTSEL while connecting if it is not detected |
The digispark-tiny USB upload requires a compatible Micronucleus bootloader already installed on the ATtiny85. If it is missing, program the chip using AVR ISP first. Raspberry Pi Pico is an RP2040 board and uses its own PlatformIO platform; it is not an ESP32 target.
All environments are defined in platformio.ini. The Pico target follows PlatformIO's pico board definition. For a different Pico variant, choose its matching board ID and configure flash, PSRAM, or upload protocol as needed.