# shiva4646/cansat.ver.06 architecture

> Architecture diagram of the GitHub repository shiva4646/cansat.ver.06, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-12-03). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/shiva4646/cansat.ver.06
- Repository: https://github.com/shiva4646/cansat.ver.06

## Overview

This is a CanSat ground-station GUI for monitoring live flight telemetry, viewing sensor/GPS/orientation data, sending commands, and downloading flight logs. The primary workflow is telemetry arriving through the frontend’s socket connection, being normalized into shared state, and presented in dashboard and specialist views; users can also send uplink commands and request a log download. Backend and legacy modules appear in the tree, but their internal wiring is not established by the available excerpts, so those links are omitted.

Main entry points: [`GUI-master/frontend/src/App.jsx`](https://github.com/shiva4646/cansat.ver.06/blob/main/GUI-master/frontend/src/App.jsx) (App and routing), [`GUI-master/frontend/src/context/TelemetryContext.jsx`](https://github.com/shiva4646/cansat.ver.06/blob/main/GUI-master/frontend/src/context/TelemetryContext.jsx) (Telemetry state), [`GUI-master/frontend/src/pages/Dashboard.jsx`](https://github.com/shiva4646/cansat.ver.06/blob/main/GUI-master/frontend/src/pages/Dashboard.jsx) (Flight dashboard), [`GUI-master/frontend/src/components/GPSMap.jsx`](https://github.com/shiva4646/cansat.ver.06/blob/main/GUI-master/frontend/src/components/GPSMap.jsx) (GPS map and trace)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_app["Ground-station UI"]
  node_app["App and routing<br/>[App.jsx]"]
  node_sidebar["Navigation sidebar<br/>[Sidebar.jsx]"]
  node_timer["Mission timer<br/>[MissionTimer.jsx]"]
end

subgraph group_telemetry["Telemetry and views"]
  node_context["Telemetry state"]
  node_dashboard["Flight dashboard<br/>[Dashboard.jsx]"]
  node_sensors["Sensor views<br/>[Sensors.jsx]"]
  node_gyro["Orientation views<br/>[Gyro.jsx]"]
  node_gps["GPS view<br/>[GPS.jsx]"]
  node_communication["Communication view<br/>[Communication.jsx]"]
  node_charts["Telemetry charts<br/>[RealtimeChart.jsx]"]
  node_map["GPS map and trace<br/>[GPSMap.jsx]"]
  node_model["3D satellite view<br/>[Satellite3D.jsx]"]
  node_uplink["Uplink controls<br/>[UplinkControl.jsx]"]
  node_controls["Telemetry controls"]
  node_modelasset["CanSat model asset<br/>[cansat.glb]"]
end

subgraph group_backend["Backend modules"]
  node_backend_server["Backend server<br/>[server.js]"]
  node_ground_logger["Ground logger<br/>[ground_logger.py]"]
  node_favorites["Favorites module<br/>[fav.js]"]
end

node_operator(("Ground-station operator"))
node_socket_service{{"Socket service"}}
node_map_tiles{{"Map tile service"}}
node_download_service{{"Log download endpoint"}}

node_operator -->|"uses"| node_app
node_app -->|"provides state"| node_context
node_app -->|"renders"| node_sidebar
node_app -->|"renders"| node_timer
node_app -->|"routes to"| node_dashboard
node_app -->|"routes to"| node_sensors
node_app -->|"routes to"| node_gps
node_app -->|"routes to"| node_gyro
node_app -->|"routes to"| node_communication
node_context -->|"connects via socket"| node_socket_service
node_dashboard -->|"reads telemetry"| node_context
node_dashboard -->|"renders"| node_charts
node_dashboard -->|"renders"| node_map
node_dashboard -->|"renders"| node_model
node_sensors -->|"reads telemetry"| node_context
node_sensors -->|"renders"| node_charts
node_gyro -->|"reads telemetry"| node_context
node_gyro -->|"renders"| node_model
node_gps -->|"reads telemetry"| node_context
node_gps -->|"renders"| node_map
node_communication -->|"reads link state"| node_context
node_map -->|"reads position history"| node_context
node_map -->|"loads map tiles"| node_map_tiles
node_model -->|"reads orientation"| node_context
node_model -->|"loads model"| node_modelasset
node_uplink -->|"sends commands"| node_context
node_controls -->|"uses telemetry state"| node_context
node_app -->|"requests log"| node_download_service
node_timer -->|"triggers download"| node_app

click node_app "https://github.com/shiva4646/cansat.ver.06/blob/main/GUI-master/frontend/src/App.jsx"
click node_sidebar "https://github.com/shiva4646/cansat.ver.06/blob/main/GUI-master/frontend/src/components/Sidebar.jsx"
click node_timer "https://github.com/shiva4646/cansat.ver.06/blob/main/GUI-master/frontend/src/components/MissionTimer.jsx"
click node_context "https://github.com/shiva4646/cansat.ver.06/blob/main/GUI-master/frontend/src/context/TelemetryContext.jsx"
click node_dashboard "https://github.com/shiva4646/cansat.ver.06/blob/main/GUI-master/frontend/src/pages/Dashboard.jsx"
click node_sensors "https://github.com/shiva4646/cansat.ver.06/blob/main/GUI-master/frontend/src/pages/Sensors.jsx"
click node_gyro "https://github.com/shiva4646/cansat.ver.06/blob/main/GUI-master/frontend/src/pages/Gyro.jsx"
click node_gps "https://github.com/shiva4646/cansat.ver.06/blob/main/GUI-master/frontend/src/pages/GPS.jsx"
click node_communication "https://github.com/shiva4646/cansat.ver.06/blob/main/GUI-master/frontend/src/pages/Communication.jsx"
click node_charts "https://github.com/shiva4646/cansat.ver.06/blob/main/GUI-master/frontend/src/components/RealtimeChart.jsx"
click node_map "https://github.com/shiva4646/cansat.ver.06/blob/main/GUI-master/frontend/src/components/GPSMap.jsx"
click node_model "https://github.com/shiva4646/cansat.ver.06/blob/main/GUI-master/frontend/src/components/Satellite3D.jsx"
click node_uplink "https://github.com/shiva4646/cansat.ver.06/blob/main/GUI-master/frontend/src/components/UplinkControl.jsx"
click node_controls "https://github.com/shiva4646/cansat.ver.06/blob/main/GUI-master/frontend/src/components/TelemetryControls.jsx"
click node_modelasset "https://github.com/shiva4646/cansat.ver.06/blob/main/GUI-master/frontend/public/cansat.glb"
click node_backend_server "https://github.com/shiva4646/cansat.ver.06/blob/main/GUI-master/backend/server.js"
click node_ground_logger "https://github.com/shiva4646/cansat.ver.06/blob/main/GUI-master/backend/ground_logger.py"
click node_favorites "https://github.com/shiva4646/cansat.ver.06/blob/main/GUI-master/backend/fav.js"

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_app,node_sidebar,node_timer toneBlue
class node_context,node_dashboard,node_sensors,node_gyro,node_gps,node_communication,node_charts,node_map,node_model,node_uplink,node_controls,node_modelasset toneAmber
class node_backend_server,node_ground_logger,node_favorites toneMint
class node_operator,node_socket_service,node_map_tiles,node_download_service toneIndigo
```

## Components

### Ground-station UI

- [App and routing](https://github.com/shiva4646/cansat.ver.06/blob/main/GUI-master/frontend/src/App.jsx): `GUI-master/frontend/src/App.jsx`
- [Navigation sidebar](https://github.com/shiva4646/cansat.ver.06/blob/main/GUI-master/frontend/src/components/Sidebar.jsx): `GUI-master/frontend/src/components/Sidebar.jsx`
- [Mission timer](https://github.com/shiva4646/cansat.ver.06/blob/main/GUI-master/frontend/src/components/MissionTimer.jsx): `GUI-master/frontend/src/components/MissionTimer.jsx`

### Telemetry and views

- [Telemetry state](https://github.com/shiva4646/cansat.ver.06/blob/main/GUI-master/frontend/src/context/TelemetryContext.jsx): `GUI-master/frontend/src/context/TelemetryContext.jsx`
- [Flight dashboard](https://github.com/shiva4646/cansat.ver.06/blob/main/GUI-master/frontend/src/pages/Dashboard.jsx): `GUI-master/frontend/src/pages/Dashboard.jsx`
- [Sensor views](https://github.com/shiva4646/cansat.ver.06/blob/main/GUI-master/frontend/src/pages/Sensors.jsx): `GUI-master/frontend/src/pages/Sensors.jsx`
- [Orientation views](https://github.com/shiva4646/cansat.ver.06/blob/main/GUI-master/frontend/src/pages/Gyro.jsx): `GUI-master/frontend/src/pages/Gyro.jsx`
- [GPS view](https://github.com/shiva4646/cansat.ver.06/blob/main/GUI-master/frontend/src/pages/GPS.jsx): `GUI-master/frontend/src/pages/GPS.jsx`
- [Communication view](https://github.com/shiva4646/cansat.ver.06/blob/main/GUI-master/frontend/src/pages/Communication.jsx): `GUI-master/frontend/src/pages/Communication.jsx`
- [Telemetry charts](https://github.com/shiva4646/cansat.ver.06/blob/main/GUI-master/frontend/src/components/RealtimeChart.jsx): `GUI-master/frontend/src/components/RealtimeChart.jsx`
- [GPS map and trace](https://github.com/shiva4646/cansat.ver.06/blob/main/GUI-master/frontend/src/components/GPSMap.jsx): `GUI-master/frontend/src/components/GPSMap.jsx`
- [3D satellite view](https://github.com/shiva4646/cansat.ver.06/blob/main/GUI-master/frontend/src/components/Satellite3D.jsx): `GUI-master/frontend/src/components/Satellite3D.jsx`
- [Uplink controls](https://github.com/shiva4646/cansat.ver.06/blob/main/GUI-master/frontend/src/components/UplinkControl.jsx): `GUI-master/frontend/src/components/UplinkControl.jsx`
- [Telemetry controls](https://github.com/shiva4646/cansat.ver.06/blob/main/GUI-master/frontend/src/components/TelemetryControls.jsx): `GUI-master/frontend/src/components/TelemetryControls.jsx`
- [CanSat model asset](https://github.com/shiva4646/cansat.ver.06/blob/main/GUI-master/frontend/public/cansat.glb): `GUI-master/frontend/public/cansat.glb`

### Backend modules

- [Backend server](https://github.com/shiva4646/cansat.ver.06/blob/main/GUI-master/backend/server.js): `GUI-master/backend/server.js`
- [Ground logger](https://github.com/shiva4646/cansat.ver.06/blob/main/GUI-master/backend/ground_logger.py): `GUI-master/backend/ground_logger.py`
- [Favorites module](https://github.com/shiva4646/cansat.ver.06/blob/main/GUI-master/backend/fav.js): `GUI-master/backend/fav.js`

### Other components

- **Ground-station operator**
- **Socket service**
- **Map tile service**
- **Log download endpoint**

## Connections

- Ground-station operator → App and routing: uses (evidence: `GUI-master/frontend/src/App.jsx`)
- App and routing → Telemetry state: provides state (evidence: `GUI-master/frontend/src/App.jsx`)
- App and routing → Navigation sidebar: renders (evidence: `GUI-master/frontend/src/App.jsx`)
- App and routing → Mission timer: renders (evidence: `GUI-master/frontend/src/App.jsx`)
- App and routing → Flight dashboard: routes to (evidence: `GUI-master/frontend/src/App.jsx`)
- App and routing → Sensor views: routes to (evidence: `GUI-master/frontend/src/App.jsx`)
- App and routing → GPS view: routes to (evidence: `GUI-master/frontend/src/App.jsx`)
- App and routing → Orientation views: routes to (evidence: `GUI-master/frontend/src/App.jsx`)
- App and routing → Communication view: routes to (evidence: `GUI-master/frontend/src/App.jsx`)
- Telemetry state → Socket service: connects via socket (evidence: `GUI-master/frontend/src/context/TelemetryContext.jsx`)
- Flight dashboard → Telemetry state: reads telemetry (evidence: `GUI-master/frontend/src/pages/Dashboard.jsx`)
- Flight dashboard → Telemetry charts: renders (evidence: `GUI-master/frontend/src/pages/Dashboard.jsx`)
- Flight dashboard → GPS map and trace: renders (evidence: `GUI-master/frontend/src/pages/Dashboard.jsx`)
- Flight dashboard → 3D satellite view: renders (evidence: `GUI-master/frontend/src/pages/Dashboard.jsx`)
- Sensor views → Telemetry state: reads telemetry (evidence: `GUI-master/frontend/src/pages/Sensors.jsx`)
- Sensor views → Telemetry charts: renders (evidence: `GUI-master/frontend/src/pages/Sensors.jsx`)
- Orientation views → Telemetry state: reads telemetry (evidence: `GUI-master/frontend/src/pages/Gyro.jsx`)
- Orientation views → 3D satellite view: renders (evidence: `GUI-master/frontend/src/pages/Gyro.jsx`)
- GPS view → Telemetry state: reads telemetry (evidence: `GUI-master/frontend/src/pages/GPS.jsx`)
- GPS view → GPS map and trace: renders (evidence: `GUI-master/frontend/src/pages/GPS.jsx`)
- Communication view → Telemetry state: reads link state (evidence: `GUI-master/frontend/src/pages/Communication.jsx`)
- GPS map and trace → Telemetry state: reads position history (evidence: `GUI-master/frontend/src/components/GPSMap.jsx`)
- GPS map and trace → Map tile service: loads map tiles (evidence: `GUI-master/frontend/src/components/GPSMap.jsx`)
- 3D satellite view → Telemetry state: reads orientation (evidence: `GUI-master/frontend/src/components/Satellite3D.jsx`)
- 3D satellite view → CanSat model asset: loads model (evidence: `GUI-master/frontend/src/components/Satellite3D.jsx`)
- Uplink controls → Telemetry state: sends commands (evidence: `GUI-master/frontend/src/components/UplinkControl.jsx`)
- Telemetry controls → Telemetry state: uses telemetry state (evidence: `GUI-master/frontend/src/components/TelemetryControls.jsx`)
- App and routing → Log download endpoint: requests log (evidence: `GUI-master/frontend/src/App.jsx`)
- Mission timer → App and routing: triggers download (evidence: `GUI-master/frontend/src/components/MissionTimer.jsx`)
