Firmware Installation¶
SpoolBuddy requires firmware on two devices: the Raspberry Pi Pico (NFC bridge) and the CrowPanel Display (ESP32-S3).
Device Overview¶
| Device | Purpose | Firmware Type |
|---|---|---|
| Raspberry Pi Pico | NFC reader controller | Arduino (.uf2) |
| CrowPanel 7.0" | Display, scale, WiFi | Rust/ESP-IDF (.bin) |
Part 1: Pico NFC Bridge¶
The Pico runs the NFC bridge firmware that communicates with the PN5180 reader.
Option A: Pre-built UF2 (Recommended)¶
-
Download the pre-built firmware:
-
Enter BOOTSEL mode:
- Hold the BOOTSEL button on the Pico
- While holding, plug in the USB cable
- Release the button
-
The Pico appears as a USB drive named "RPI-RP2"
-
Flash the firmware:
- Drag and drop the
.uf2file onto the RPI-RP2 drive -
The Pico automatically reboots and starts running
-
Verify:
- The onboard LED should blink every 500ms
- Connect a serial monitor at 115200 baud to see:
Option B: Build from Source¶
Requires PlatformIO installed.
# Clone the repository
git clone https://github.com/maziggy/spoolbuddy.git
cd spoolbuddy/pico-nfc-bridge
# Build
pio run
# Upload (Pico in BOOTSEL mode)
pio run -t upload
# Monitor serial output
pio device monitor
Part 2: CrowPanel Display¶
The CrowPanel runs the main SpoolBuddy firmware (Rust/ESP-IDF).
Option A: Pre-built Binary (Recommended)¶
-
Download the pre-built firmware:
-
Install espflash:
Or download from espflash releases
- Connect the display:
- Use a USB-C data cable (not charge-only)
- Connect to your computer
-
The display may show a blank screen or old firmware
-
Find the port:
-
Flash the firmware:
Option B: Build from Source¶
Requires Rust and the ESP toolchain.
Prerequisites¶
-
Install Rust:
-
Install ESP toolchain via espup:
-
Install espflash:
-
(Linux only) Add USB permissions:
Build and Flash¶
# Clone the repository
git clone https://github.com/maziggy/spoolbuddy.git
cd spoolbuddy/firmware
# Source ESP environment
. $HOME/export-esp.sh
# Build and flash (with serial monitor)
cargo run --release
Or build separately:
# Build only
cargo build --release
# Flash manually
espflash flash --monitor target/xtensa-esp32s3-espidf/release/spoolbuddy-firmware
Verification¶
After flashing both devices, verify the system is working:
Pico NFC Bridge¶
- LED blinks every 500ms
- Serial output shows "Ready!"
- PN5180 version displayed (e.g., 3.5)
CrowPanel Display¶
- Display backlight turns on
- UI renders on screen
- Touch responds to input
- Serial output shows initialization
Integration Test¶
- Power on the complete system
- Place a Bambu Lab spool on the scale
- The NFC tag should be detected
- Weight should display on screen
Troubleshooting¶
Pico Issues¶
| Issue | Solution |
|---|---|
| RPI-RP2 drive doesn't appear | Try a different USB cable, ensure BOOTSEL held during plug-in |
| "PN5180 ERROR!" in serial | Check SPI wiring to PN5180 |
| I2C not working | Verify SDA/SCL connections to CrowPanel |
Display Issues¶
| Issue | Solution |
|---|---|
| "Permission denied" (Linux) | Run sudo usermod -a -G dialout $USER and re-login |
| Port not detected | Try different USB cable (must be data cable) |
| espflash timeout | Hold BOOT button while pressing RESET, then flash |
| Build fails with "rust-src not found" | Run espup install and source export-esp.sh |