mirror of
https://github.com/IS1DI/x0gp.git
synced 2026-07-17 04:57:55 +00:00
- Implement UDPVideoService to stream MJPEG video frames from ESP32s via UDP and send control commands. - Normalize race database schema: - Remove redundant driver_ids array from races table (migration 011). - Move per-driver outcomes (total_time_ms, best_lap_ms, position) to race_drivers table (migration 012). - Add device_id column to lobby_drivers to link active physical devices (migration 013). - Update WebSocket handler to pass lobbySvc, driversSvc, and videoSvc for driver identity tracking, syncing in-memory driver metadata, and forwarding WS controls to physical cars. - Add CORS middleware to HTTP routes. - Regenerate Swagger documentation.
7 lines
315 B
SQL
7 lines
315 B
SQL
-- 013_driver_device.sql — add device_id to lobby_drivers.
|
|
--
|
|
-- Represents the currently selected physical ESP32 DEVICE_ID (0..127) for a driver.
|
|
-- This device is pinned to the driver during races and released when the race ends or they leave.
|
|
|
|
ALTER TABLE lobby_drivers ADD COLUMN IF NOT EXISTS device_id INT;
|