How muhammedkusay/micro-air-vehicle-telemetry works
This is a real-time ArduPilot telemetry monitor: MAVLink data is decoded and shared with a live React dashboard, while a slower Laravel API path records flights and telemetry for vehicle and flight history views. README documents the WebSocket and persistence rates, database, maps, and visualization capabilities. The sampled source confirms the service entry point, API request helper, and Laravel controllers; links inside unsampled hooks, routes, and service modules are limited to documented behavior.
Main entry points: main.py Telemetry runner · api.php API routes · FlightController.php Flight controller · App.jsx React routes
Components 23
Telemetry service
- Telemetry runner
telemetry_service/main.py - MAVLink I/O
telemetry_service/app/mavlink.py - Telemetry state
telemetry_service/app/telemetry.py - WebSocket server
telemetry_service/app/websocket.py - History API client
telemetry_service/app/api.py
History API
- Laravel API
backend/public/index.php - API routes
backend/routes/api.php - Vehicle controller
backend/app/Http/Controllers/VehicleController.php - Flight controller
backend/app/Http/Controllers/FlightController.php - Telemetry controller
backend/app/Http/Controllers/TelemetryController.php - Vehicle model
backend/app/Models/Vehicle.php - Flight model
backend/app/Models/Flight.php - Telemetry model
backend/app/Models/Telemetry.php
Dashboard
- React routes
frontend/src/App.jsx - Live dashboard
frontend/src/pages/Dashboard.jsx - Vehicle and flight pages
frontend/src/pages - REST request hook
frontend/src/hooks/useApi.js - Live telemetry hook
frontend/src/hooks/useTelemetry.js - Charts and maps
frontend/src/components
External systems
- ArduPilot SITL
- MySQL database
- OpenStreetMap tiles
Other components
- Operator
Connections 25
- Operator → React routes: navigates
- ArduPilot SITL → MAVLink I/O: sends MAVLink
- Telemetry runner → MAVLink I/O: connects and receives
- Telemetry runner → Telemetry state: updates state
- Telemetry runner → WebSocket server: starts server
- Telemetry runner → History API client: creates flight; sends records
- History API client → Laravel API: posts history
- React routes → Live dashboard: routes
- React routes → Vehicle and flight pages: routes
- REST request hook → Laravel API: requests REST data
- Live telemetry hook → WebSocket server: receives live stream
- Live dashboard → Charts and maps: renders telemetry
- Vehicle and flight pages → Charts and maps: renders flight data
- Charts and maps → OpenStreetMap tiles: loads map tiles
- Laravel API → API routes: dispatches
- API routes → Vehicle controller: dispatches vehicle requests
- API routes → Flight controller: dispatches flight requests
- API routes → Telemetry controller: dispatches telemetry requests
- Vehicle controller → Vehicle model: queries
- Flight controller → Vehicle model: queries
- Flight controller → Flight model: queries and creates
- Telemetry controller → Telemetry model: queries and stores
- Vehicle model → MySQL database: reads and writes
- Flight model → MySQL database: reads and writes
- Telemetry model → MySQL database: reads and writes