# bob12315/cuadc2026 architecture

> Architecture diagram of the GitHub repository bob12315/cuadc2026, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-10-01). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/bob12315/cuadc2026
- Repository: https://github.com/bob12315/cuadc2026

## Overview

CUADC 2026 is an autonomous multirotor reconnaissance and rescue system: the onboard RK3588 runs perception, mission logic, and the operator UI, while ArduPilot handles low-level flight control. The principal workflow is configuring the field, running a mission of flight and target actions, using visual detections to locate and select targets, releasing payload, then returning and landing. The graph also shows field setup, telemetry, safety, and observability as supporting capabilities. Some runtime wiring is unsampled; those relationships are omitted unless documented in the README or visible in the source index.

Main entry points: [`telemetry_link/link_manager.py`](https://github.com/bob12315/cuadc2026/blob/main/telemetry_link/link_manager.py) (MAVLink link), [`web_ui/api_routers.py`](https://github.com/bob12315/cuadc2026/blob/main/web_ui/api_routers.py) (Web control UI), [`missions/engine.py`](https://github.com/bob12315/cuadc2026/blob/main/missions/engine.py) (Mission engine), [`application/mission_service.py`](https://github.com/bob12315/cuadc2026/blob/main/application/mission_service.py) (Mission service)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_operator["Operator UI"]
  node_webui["Web control UI<br/>[api_routers.py]"]
  node_webservices["Web services<br/>[web_services.py]"]
  node_appconfig["Runtime configuration<br/>[config.py]"]
end

subgraph group_mission["Mission Runtime"]
  node_missionservice["Mission service<br/>[mission_service.py]"]
  node_missionengine["Mission engine<br/>[engine.py]"]
  node_orchestrator["Mission orchestrator"]
  node_actions["Mission actions"]
  node_safety["Action safety<br/>[safety_pipeline.py]"]
  node_contracts["Runtime contracts<br/>[common.py]"]
end

subgraph group_perception["Perception &amp; Guidance"]
  node_yolo["YOLO perception<br/>[main.py]"]
  node_targetmanager["Target tracking<br/>[target_manager.py]"]
  node_guidance["Target localization<br/>[target_fusion.py]"]
  node_fusion["State fusion<br/>[fusion_manager.py]"]
end

subgraph group_flight["Flight &amp; Telemetry"]
  node_telemetry["MAVLink link<br/>[link_manager.py]"]
  node_commandsender["Command sender<br/>[command_sender.py]"]
  node_autopilot["ArduPilot"]
end

subgraph group_field["Field &amp; Observability"]
  node_fieldservice["Field reference<br/>[service.py]"]
  node_fieldprofiles[("Field profiles<br/>[profile_service.py]")]
  node_blackbox["Flight blackbox<br/>[blackbox.py]"]
  node_clock["Core time<br/>[time.py]"]
end

node_operator(("Browser operator"))

node_operator -->|"operates"| node_webui
node_webui -->|"routes requests"| node_webservices
node_webui -->|"uses settings"| node_appconfig
node_webservices -.->|"provides mission services"| node_missionservice
node_missionservice -->|"uses mission engine"| node_missionengine
node_missionengine -.->|"runs mission steps"| node_orchestrator
node_missionengine -.->|"starts actions"| node_actions
node_missionservice -->|"checks authorization"| node_safety
node_safety -->|"uses execution contracts"| node_contracts
node_yolo -->|"updates targets"| node_targetmanager
node_yolo -.->|"supplies visual targets"| node_guidance
node_guidance -.->|"combines target state"| node_fusion
node_missionengine -.->|"issues flight actions"| node_telemetry
node_telemetry -->|"dispatches commands"| node_commandsender
node_commandsender -->|"sends MAVLink"| node_autopilot
node_autopilot -->|"returns telemetry"| node_telemetry
node_webui -.->|"configures field"| node_fieldservice
node_fieldservice -->|"loads profiles"| node_fieldprofiles
node_fieldservice -->|"uses field contracts"| node_contracts
node_telemetry -.->|"provides flight state"| node_fusion
node_telemetry -.->|"records flight state"| node_blackbox
node_blackbox -->|"uses timestamps"| node_clock

click node_webui "https://github.com/bob12315/cuadc2026/blob/main/web_ui/api_routers.py"
click node_webservices "https://github.com/bob12315/cuadc2026/blob/main/application/web_services.py"
click node_appconfig "https://github.com/bob12315/cuadc2026/blob/main/app/config.py"
click node_missionservice "https://github.com/bob12315/cuadc2026/blob/main/application/mission_service.py"
click node_missionengine "https://github.com/bob12315/cuadc2026/blob/main/missions/engine.py"
click node_orchestrator "https://github.com/bob12315/cuadc2026/blob/main/missions/core/mission_orchestrator.py"
click node_actions "https://github.com/bob12315/cuadc2026/tree/main/missions/common/actions"
click node_safety "https://github.com/bob12315/cuadc2026/blob/main/execution/safety_pipeline.py"
click node_contracts "https://github.com/bob12315/cuadc2026/blob/main/contracts/platform/common.py"
click node_yolo "https://github.com/bob12315/cuadc2026/blob/main/yolo_app/main.py"
click node_targetmanager "https://github.com/bob12315/cuadc2026/blob/main/yolo_app/target_manager.py"
click node_guidance "https://github.com/bob12315/cuadc2026/blob/main/guidance/target_fusion.py"
click node_fusion "https://github.com/bob12315/cuadc2026/blob/main/fusion/fusion_manager.py"
click node_telemetry "https://github.com/bob12315/cuadc2026/blob/main/telemetry_link/link_manager.py"
click node_commandsender "https://github.com/bob12315/cuadc2026/blob/main/telemetry_link/command_sender.py"
click node_fieldservice "https://github.com/bob12315/cuadc2026/blob/main/field/service.py"
click node_fieldprofiles "https://github.com/bob12315/cuadc2026/blob/main/field/profile_service.py"
click node_blackbox "https://github.com/bob12315/cuadc2026/blob/main/observability/blackbox.py"
click node_clock "https://github.com/bob12315/cuadc2026/blob/main/contracts/core/time.py"

classDef toneNeutral fill:#f8fafc,stroke:#334155,stroke-width:1.5px,color:#0f172a
classDef toneBlue fill:#dbeafe,stroke:#2563eb,stroke-width:1.5px,color:#172554
classDef toneAmber fill:#fef3c7,stroke:#d97706,stroke-width:1.5px,color:#78350f
classDef toneMint fill:#dcfce7,stroke:#16a34a,stroke-width:1.5px,color:#14532d
classDef toneRose fill:#ffe4e6,stroke:#e11d48,stroke-width:1.5px,color:#881337
classDef toneIndigo fill:#e0e7ff,stroke:#4f46e5,stroke-width:1.5px,color:#312e81
classDef toneTeal fill:#ccfbf1,stroke:#0f766e,stroke-width:1.5px,color:#134e4a
class node_webui,node_webservices,node_appconfig,node_operator toneBlue
class node_missionservice,node_missionengine,node_orchestrator,node_actions,node_safety,node_contracts toneAmber
class node_yolo,node_targetmanager,node_guidance,node_fusion toneMint
class node_telemetry,node_commandsender,node_autopilot toneRose
class node_fieldservice,node_fieldprofiles,node_blackbox,node_clock toneIndigo
```

## Components

### Operator UI

- [Web control UI](https://github.com/bob12315/cuadc2026/blob/main/web_ui/api_routers.py): `web_ui/api_routers.py`
- [Web services](https://github.com/bob12315/cuadc2026/blob/main/application/web_services.py): `application/web_services.py`
- [Runtime configuration](https://github.com/bob12315/cuadc2026/blob/main/app/config.py): `app/config.py`

### Mission Runtime

- [Mission service](https://github.com/bob12315/cuadc2026/blob/main/application/mission_service.py): `application/mission_service.py`
- [Mission engine](https://github.com/bob12315/cuadc2026/blob/main/missions/engine.py): `missions/engine.py`
- [Mission orchestrator](https://github.com/bob12315/cuadc2026/blob/main/missions/core/mission_orchestrator.py): `missions/core/mission_orchestrator.py`
- [Mission actions](https://github.com/bob12315/cuadc2026/tree/main/missions/common/actions): `missions/common/actions`
- [Action safety](https://github.com/bob12315/cuadc2026/blob/main/execution/safety_pipeline.py): `execution/safety_pipeline.py`
- [Runtime contracts](https://github.com/bob12315/cuadc2026/blob/main/contracts/platform/common.py): `contracts/platform/common.py`

### Perception & Guidance

- [YOLO perception](https://github.com/bob12315/cuadc2026/blob/main/yolo_app/main.py): `yolo_app/main.py`
- [Target tracking](https://github.com/bob12315/cuadc2026/blob/main/yolo_app/target_manager.py): `yolo_app/target_manager.py`
- [Target localization](https://github.com/bob12315/cuadc2026/blob/main/guidance/target_fusion.py): `guidance/target_fusion.py`
- [State fusion](https://github.com/bob12315/cuadc2026/blob/main/fusion/fusion_manager.py): `fusion/fusion_manager.py`

### Flight & Telemetry

- [MAVLink link](https://github.com/bob12315/cuadc2026/blob/main/telemetry_link/link_manager.py): `telemetry_link/link_manager.py`
- [Command sender](https://github.com/bob12315/cuadc2026/blob/main/telemetry_link/command_sender.py): `telemetry_link/command_sender.py`
- **ArduPilot**

### Field & Observability

- [Field reference](https://github.com/bob12315/cuadc2026/blob/main/field/service.py): `field/service.py`
- [Field profiles](https://github.com/bob12315/cuadc2026/blob/main/field/profile_service.py): `field/profile_service.py`
- [Flight blackbox](https://github.com/bob12315/cuadc2026/blob/main/observability/blackbox.py): `observability/blackbox.py`
- [Core time](https://github.com/bob12315/cuadc2026/blob/main/contracts/core/time.py): `contracts/core/time.py`

### Other components

- **Browser operator**

## Connections

- Browser operator → Web control UI: operates (evidence: `README.md`)
- Web control UI → Web services: routes requests (evidence: `web_ui/api_routers.py`)
- Web control UI → Runtime configuration: uses settings (evidence: `web_ui/api_routers.py`)
- Web services → Mission service: provides mission services
- Mission service → Mission engine: uses mission engine (evidence: `application/mission_service.py`)
- Mission engine → Mission orchestrator: runs mission steps
- Mission engine → Mission actions: starts actions
- Mission service → Action safety: checks authorization (evidence: `application/mission_service.py`)
- Action safety → Runtime contracts: uses execution contracts (evidence: `execution/safety_pipeline.py`)
- YOLO perception → Target tracking: updates targets (evidence: `yolo_app/main.py`)
- YOLO perception → Target localization: supplies visual targets
- Target localization → State fusion: combines target state
- Mission engine → MAVLink link: issues flight actions
- MAVLink link → Command sender: dispatches commands (evidence: `telemetry_link/link_manager.py`)
- Command sender → ArduPilot: sends MAVLink (evidence: `README.md`)
- ArduPilot → MAVLink link: returns telemetry (evidence: `README.md`)
- Web control UI → Field reference: configures field
- Field reference → Field profiles: loads profiles (evidence: `field/service.py`)
- Field reference → Runtime contracts: uses field contracts (evidence: `field/service.py`)
- MAVLink link → State fusion: provides flight state
- MAVLink link → Flight blackbox: records flight state
- Flight blackbox → Core time: uses timestamps (evidence: `observability/blackbox.py`)
