-
Notifications
You must be signed in to change notification settings - Fork 0
Debugging and Troubleshooting
The bottom dock separates four concerns:
- Debug — validation and runtime problems
- App logs — application console output
- Serial monitor — opt-in USB serial output
- Firmware — PlatformIO build and flash output
Transport statistics show receive bandwidth, bit rate, and observed FPS. They are diagnostics, not app settings; target FPS belongs in the app JSDoc config.
Studio preview replays the same bytes sent to the connected ESP32. If both the preview and panel pause, the ACK-controlled frame loop paused upstream. If the preview is correct but the physical panel is corrupted, investigate firmware, SPI frequency, wiring, display driver/profile, and power.
The preview-only IDE view is available at:
http://localhost:8766/preview
DISPLAY_SERVER_PERF_LOG=1 npm startPeriodic output includes server FPS, frame bytes, build time, ACK latency, heap use, and event-loop delay. Increasing ACK latency points toward network, firmware, or SPI display time. Increasing build/event-loop time points toward application or server rendering work.
Another Studio instance owns the port. Stop it, or select another port with
DISPLAY_SERVER_PORT / DISPLAY_SERVER_DEBUG_PORT.
- Confirm the server LAN address in firmware.
- Confirm the ESP32 and host can reach each other.
- Check Wi-Fi credentials and serial boot logs.
- Verify TCP port
8765is not blocked.
- Reconnect the controller and verify its current serial device name.
- Stop Serial Monitor before upload.
- Ensure no other PlatformIO/Arduino process owns the port.
Studio stops its own Serial Monitor automatically before flashing.
Studio shows the source location and stack trace. The renderer restores the last valid framebuffer. Correct the code and save again.
@fps is a maximum target. Actual FPS is limited by render time, changed frame
size, TCP throughput, ACK latency, SPI speed, and display write time. Reduce
full-screen updates or lower target FPS to a sustainable value.
- Confirm the server and firmware use the same protocol revision.
- Verify display dimensions, rotation, color order, and driver.
- Prefer hardware SPI and test a lower SPI frequency if wiring is marginal.
- Check power integrity and wire length.
- Reflash after changing Hardware Setup.
Canvas animation uses raster dirty rectangles after the initial frame so intermediate vector layers are not exposed one command at a time.
- Avoid creating gradients or large reusable Canvas resources every frame.
- Keep arrays, logs, and application globals bounded.
- Enable performance logs and compare heap, RSS, build time, and ACK latency.
- Test Blank Canvas to separate renderer/transport cost from app behavior.
Video mode requires ffmpeg. Set DISPLAY_VIDEO_SOURCE to a file, camera, or
network input that ffmpeg understands. JPEG payloads are limited by the
protocol and must fit within the firmware receive buffer.