How suprithh7/aerotwin works
AeroTwin is a browser-based, seeded UAV-engine mission rehearsal simulator. Users edit and assess a mission in BRIEF, run a fault-injected FLY rehearsal, then inspect detection and Data Guard outcomes in DEBRIEF; the E-key engineering console exposes the same simulation and diagnosis models. The graph preserves the documented planning, simulation, navigation, diagnosis, rehearsal, and encrypted-payload capabilities. Some stage internals were not sampled, so their documented relationships use README evidence; unsampled implementation details are not inferred.
Main entry points: missionStore.ts Mission store · EngineerOverlay.tsx Engineering overlay · FlyStage.tsx Flight display · session.ts Payload session
Components 29
Mission planning
- Mission editor
src/components/rehearsal/BriefStage.tsx - Mission store
src/mission/missionStore.ts - GeoJSON exchange
src/mission/geoJson.ts - Weather and terrain
src/mission/weather.ts - Preflight checks
src/mission/preflight.ts - Monte Carlo risk
src/mission/monteCarlo.ts - Route geometry
src/mission/route.ts - Alternate reachability
src/nav/alternates.ts
Engine twin
- Simulation state
src/state/store.ts - Simulation worker
src/sim/worker.ts - Engine model
src/sim/engineModel.ts - Fault diagnosis
src/diagnosis/diagnose.ts - Life projection
src/diagnosis/rul.ts
Rehearsal experience
- Stage shell
src/App.tsx - Flight display
src/components/rehearsal/FlyStage.tsx - Failure director
src/rehearsal/director.ts - Rehearsal state
src/rehearsal/store.ts - Debrief report
src/components/rehearsal/DebriefStage.tsx - Rehearsal map
src/components/rehearsal/RehearsalMap.tsx
Data Guard
- Payload session
src/payload/session.ts - Payload cryptography
src/payload/crypto.ts - Priority offload
src/payload/offload.ts - Data Guard policy
src/payload/guard.ts
Engineering console
- Engineering overlay
src/components/rehearsal/EngineerOverlay.tsx - Diagnosis panel
src/components/DiagnosisPanel.tsx - Fault controls
src/components/FaultPanel.tsx - Strip charts
src/components/StripCharts.tsx - Engine schematic
src/components/EngineSchematic.tsx
Other components
- Mission operator
Connections 34
- Mission operator → Mission editor: edits mission
README.md - Mission editor → Mission store: updates
README.md - Mission store → GeoJSON exchange: round-trips
src/mission/missionStore.ts - Mission store → Weather and terrain: fetches forecasts
src/mission/missionStore.ts - Mission store → Preflight checks: assesses
README.md - Mission store → Monte Carlo risk: requests risk run
src/mission/missionStore.ts - Mission store → Route geometry: resolves route
src/mission/missionStore.ts - Mission operator → Flight display: runs rehearsal
README.md - Stage shell → Mission editor: renders stage
src/App.tsx - Stage shell → Flight display: renders stage
src/App.tsx - Stage shell → Debrief report: renders stage
src/App.tsx - Flight display → Simulation state: reads telemetry
README.md - Simulation state → Simulation worker: sends commands
src/state/store.ts - Simulation worker → Engine model: steps simulation
src/sim/worker.ts - Simulation worker → Fault diagnosis: classifies snapshots
src/sim/worker.ts - Fault diagnosis → Life projection: estimates life
src/diagnosis/diagnose.ts - Flight display → Failure director: injects events
README.md - Failure director → Simulation state: dispatches faults
- Flight display → Alternate reachability: shows reachability
README.md - Alternate reachability → Route geometry: uses leg geometry
src/nav/alternates.ts - Flight display → Payload session: runs Data Guard
README.md - Payload session → Payload cryptography: encrypts items
src/payload/session.ts - Payload session → Priority offload: sends priority queue
src/payload/session.ts - Payload session → Data Guard policy: evaluates policy
src/payload/session.ts - Payload session → Alternate reachability: checks landing options
src/payload/session.ts - Mission operator → Debrief report: reviews outcome
README.md - Debrief report → Rehearsal state: reads run record
- Stage shell → Engineering overlay: opens on E key
src/App.tsx - Engineering overlay → Rehearsal map: renders validation map
src/components/rehearsal/EngineerOverlay.tsx - Engineering overlay → Fault controls: renders controls
src/components/rehearsal/EngineerOverlay.tsx - Engineering overlay → Diagnosis panel: renders diagnosis
src/components/rehearsal/EngineerOverlay.tsx - Engineering overlay → Strip charts: renders charts
src/components/rehearsal/EngineerOverlay.tsx - Engineering overlay → Engine schematic: renders schematic
src/components/rehearsal/EngineerOverlay.tsx - Engine schematic → Simulation state: reads snapshot
src/components/EngineSchematic.tsx