← All projects

Latest test build

Build 620 Oct 2026

Newest test build, not an official version.

VLight Diagnostics & Troubleshooting Runbook

1. Diagnostics Commands

Server Health Check

Run diagnostic checks on the VLight server environment:

./vlight-server doctor

Expected output:

Running VLight Server Diagnostics...
  [OK] V Language Runtime:    v0.5.2
  [OK] SQLite WAL Persistence: vlight.db
  [OK] Pairing State Engine:  Active (window open: false)
  [OK] Device Node Registry:  x nodes recorded
All server subsystems operational.

Embedded Toolchain Check

Verify that V, GCC, PlatformIO, and esptool are detected:

./vlight doctor

2. Common Issues & Solutions

A. Node Not Discovering Server

  • Cause: UDP broadcast (port 9123) is blocked by host firewall or client isolation is enabled on the Wi-Fi router.
  • Resolution:
    1. Allow UDP port 9123 in ufw:
      sudo ufw allow 9123/udp
    2. Verify that the server daemon is running:
      ./vlight-server status
    3. Ensure that your ESP32 node and server share the same subnet.

B. Transpilation or C Build Errors

  • Cause: Missing V module linking or freestanding embedded headers.
  • Resolution:
    1. Run vlight doctor to ensure that ~/.vmodules/vlight is linked.
    2. Ensure freestanding build flags are present:
      v -gc none -no-bounds-checking -d no_main -d no_backtrace -o app.c main.v

C. ESP32 Boot Loops or Strapping Warnings

  • Cause: WS2812B data pin is attached to a strapping pin or an input-only pin.
  • Resolution:
    • Run ./vlight targets to check pin restrictions.
    • Avoid GPIO 0, 2, 5, 12, 15 on ESP32 during boot.
    • Avoid GPIO 34-39 on ESP32 (input only).
    • Use clean output pins such as GPIO 18, 19, 21, 22, 23.

D. Server Crash / Database Locked

  • Cause: SQLite concurrent access without WAL mode.
  • Resolution: The VLight server automatically enables SQLite WAL mode (PRAGMA journal_mode=WAL). If a crash occurred, remove stale lock files:
    rm -f vlight.db-shm vlight.db-wal
    ./vlight-server doctor