-
Notifications
You must be signed in to change notification settings - Fork 1
HowTo Setup PlatformIO
This guide walks you through setting up PlatformIO to build and upload Glitchy firmware.
Note: PlatformIO is the current recommended build system, replacing the older Arduino IDE setup.
- A computer running Windows, macOS, or Linux
- USB cable for ESP32-S3 connection
- Basic familiarity with command line or VS Code
Download and install VS Code from code.visualstudio.com.
- Open VS Code
- Click the Extensions icon in the sidebar (or press
Ctrl+Shift+X) - Search for "PlatformIO IDE"
- Click Install on the PlatformIO IDE extension
- Wait for installation to complete (this may take several minutes)
- Restart VS Code when prompted
- In VS Code, go to File → Open Folder
- Navigate to
glitchy/Code/Glitchy/ - Select the folder and click Open
- PlatformIO will automatically detect the project and download required dependencies
The first time you open the project, PlatformIO will:
- Download the ESP32 platform tools
- Install required libraries (AsyncTCP, ESPAsyncWebServer, ArduinoJson)
- Configure the build environment
This may take 5-10 minutes depending on your internet connection. Watch the terminal output for progress.
- Click the checkmark icon (✓) in the PlatformIO toolbar at the bottom
- Or use keyboard shortcut:
Ctrl+Alt+B - Or open Command Palette (
Ctrl+Shift+P) and type "PlatformIO: Build"
- Or use keyboard shortcut:
- Wait for the build to complete
- A successful build shows
[SUCCESS]in the terminal
- Connect your ESP32-S3 to your computer via USB
- Click the arrow icon (→) in the PlatformIO toolbar
- Or use keyboard shortcut:
Ctrl+Alt+U - Or open Command Palette and type "PlatformIO: Upload"
- Or use keyboard shortcut:
- Wait for upload to complete
Tip: If upload fails, you may need to hold the BOOT button on the ESP32-S3 while connecting, or press BOOT then RST.
Follow the official installation guide for your OS:
Quick install (Python required):
pip install platformiocd path/to/glitchy/Code/Glitchypio runpio run --target uploadpio device monitorThe Glitchy project uses the following configuration (platformio.ini):
[platformio]
default_envs = esp32-s3-devkitc-1
[env:esp32-s3-devkitc-1]
platform = espressif32
board = esp32-s3-devkitc-1
framework = arduino
lib_deps =
https://github.com/me-no-dev/AsyncTCP.git
https://github.com/yubox-node-org/ESPAsyncWebServer
bblanchon/ArduinoJson@^7.3.1
monitor_speed = 115200| Setting | Value | Description |
|---|---|---|
platform |
espressif32 | ESP32 platform package |
board |
esp32-s3-devkitc-1 | Target board |
framework |
arduino | Arduino framework |
monitor_speed |
115200 | Serial monitor baud rate |
| Library | Purpose |
|---|---|
| AsyncTCP | Asynchronous TCP for ESP32 |
| ESPAsyncWebServer | Async HTTP/WebSocket server |
| ArduinoJson | JSON parsing and serialization |
After successful upload:
- Open Serial Monitor (click plug icon or
pio device monitor) - Press the RST button on the ESP32-S3
- You should see startup messages including WiFi AP information
- Connect to the Glitchy WiFi network (default:
Glitchy) - Open
http://192.168.4.1in your browser
"Library not found"
- Run
pio pkg installto refresh dependencies - Check internet connection
"Board not found"
- Run
pio pkg update -p espressif32
"No serial port found"
- Check USB cable connection
- Install CP210x USB drivers from Silicon Labs
- On Linux, add user to
dialoutgroup:sudo usermod -aG dialout $USER
"Upload failed, timeout"
- Hold BOOT button while connecting USB
- Press BOOT, then RST, then release BOOT
- Try a different USB port
"Permission denied" (Linux/macOS)
sudo chmod 666 /dev/ttyUSB0 # or /dev/ttyACM0"Port is busy"
- Close other applications using the serial port
- Disconnect and reconnect USB
If you previously used Arduino IDE:
- Your code will work without changes (same Arduino framework)
- Library locations are different (PlatformIO manages its own)
- Build outputs are in
.pio/build/instead of temp folders - No need to manually install board packages or libraries
References: