# otmaniamine/smart-weather-station-iot-ai architecture

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

- Interactive diagram: https://gitdiagram.com/otmaniamine/smart-weather-station-iot-ai
- Repository: https://github.com/otmaniamine/smart-weather-station-iot-ai

## Overview

WeatherENSTA combines an ESP32 weather station, cloud logging, temperature forecasting, and a React dashboard. The documented workflow samples environmental sensors, sends readings to Google Apps Script for Google Sheets storage, and presents weather data in an interactive map and dashboard; the README also describes LSTM-based forecasting. The tree includes station firmware, an IoT upload sketch, a temperature notebook, and frontend components. The cloud and AI links below rely on README documentation; their implementation details were not excerpted.

Main entry points: [`Interface/src/App.tsx`](https://github.com/otmaniamine/smart-weather-station-iot-ai/blob/main/Interface/src/App.tsx) (Dashboard App), [`Interface/src/components/MapSection.tsx`](https://github.com/otmaniamine/smart-weather-station-iot-ai/blob/main/Interface/src/components/MapSection.tsx) (Map Section), [`IOT/DHT11toGoogleSheet.ino`](https://github.com/otmaniamine/smart-weather-station-iot-ai/blob/main/IOT/DHT11toGoogleSheet.ino) (DHT11 Uploader), [`Station/Sensors`](https://github.com/otmaniamine/smart-weather-station-iot-ai/tree/main/Station/Sensors) (Weather Sensors)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_hardware["Station Hardware"]
  node_sensors["Weather Sensors"]
  node_station_ds_ldr["Station DS/LDR"]
  node_station_ds_wind["Station DS/Wind<br/>[stationDSwind.ino]"]
end

subgraph group_cloud["Cloud Logging"]
  node_dht_upload["DHT11 Uploader"]
  node_apps_script["Apps Script<br/>[scriptDataBase.txt]"]
  node_sheets[("Google Sheets")]
end

subgraph group_analytics["Forecasting"]
  node_forecast["LSTM Forecasting"]
end

subgraph group_interface["Web Dashboard"]
  node_app["Dashboard App<br/>[App.tsx]"]
  node_map_section["Map Section<br/>[MapSection.tsx]"]
  node_map["Interactive Map<br/>[Map.tsx]"]
  node_weather_dashboard["Weather Dashboard"]
  node_live["Live Weather<br/>[Live.tsx]"]
  node_landing_sections["Product Sections"]
end

node_user(("Dashboard User"))

node_sensors -->|"readings"| node_station_ds_ldr
node_sensors -->|"readings"| node_station_ds_wind
node_station_ds_ldr -.->|"telemetry"| node_dht_upload
node_station_ds_wind -.->|"telemetry"| node_dht_upload
node_dht_upload -->|"HTTP GET"| node_apps_script
node_apps_script -->|"append rows"| node_sheets
node_sheets -->|"read data"| node_weather_dashboard
node_sheets -.->|"historical data"| node_forecast
node_forecast -->|"predictions"| node_app
node_user -->|"views"| node_app
node_app -->|"renders"| node_map_section
node_map_section -->|"renders"| node_map
node_map_section -->|"renders"| node_weather_dashboard
node_app -->|"renders"| node_live
node_app -->|"renders"| node_landing_sections

click node_sensors "https://github.com/otmaniamine/smart-weather-station-iot-ai/tree/main/Station/Sensors"
click node_station_ds_ldr "https://github.com/otmaniamine/smart-weather-station-iot-ai/blob/main/Station/StationDSandLDR.ino"
click node_station_ds_wind "https://github.com/otmaniamine/smart-weather-station-iot-ai/blob/main/Station/stationDSwind.ino"
click node_dht_upload "https://github.com/otmaniamine/smart-weather-station-iot-ai/blob/main/IOT/DHT11toGoogleSheet.ino"
click node_apps_script "https://github.com/otmaniamine/smart-weather-station-iot-ai/blob/main/IOT/scriptDataBase.txt"
click node_forecast "https://github.com/otmaniamine/smart-weather-station-iot-ai/blob/main/AI/mini_project_temperature.ipynb"
click node_app "https://github.com/otmaniamine/smart-weather-station-iot-ai/blob/main/Interface/src/App.tsx"
click node_map_section "https://github.com/otmaniamine/smart-weather-station-iot-ai/blob/main/Interface/src/components/MapSection.tsx"
click node_map "https://github.com/otmaniamine/smart-weather-station-iot-ai/blob/main/Interface/src/components/Map.tsx"
click node_weather_dashboard "https://github.com/otmaniamine/smart-weather-station-iot-ai/blob/main/Interface/src/components/WeatherDashboard.tsx"
click node_live "https://github.com/otmaniamine/smart-weather-station-iot-ai/blob/main/Interface/src/components/Live.tsx"
click node_landing_sections "https://github.com/otmaniamine/smart-weather-station-iot-ai/tree/main/Interface/src/components"

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_sensors,node_station_ds_ldr,node_station_ds_wind,node_user toneBlue
class node_dht_upload,node_apps_script,node_sheets toneAmber
class node_forecast toneMint
class node_app,node_map_section,node_map,node_weather_dashboard,node_live,node_landing_sections toneRose
```

## Components

### Station Hardware

- [Weather Sensors](https://github.com/otmaniamine/smart-weather-station-iot-ai/tree/main/Station/Sensors): `Station/Sensors`
- [Station DS/LDR](https://github.com/otmaniamine/smart-weather-station-iot-ai/blob/main/Station/StationDSandLDR.ino): `Station/StationDSandLDR.ino`
- [Station DS/Wind](https://github.com/otmaniamine/smart-weather-station-iot-ai/blob/main/Station/stationDSwind.ino): `Station/stationDSwind.ino`

### Cloud Logging

- [DHT11 Uploader](https://github.com/otmaniamine/smart-weather-station-iot-ai/blob/main/IOT/DHT11toGoogleSheet.ino): `IOT/DHT11toGoogleSheet.ino`
- [Apps Script](https://github.com/otmaniamine/smart-weather-station-iot-ai/blob/main/IOT/scriptDataBase.txt): `IOT/scriptDataBase.txt`
- **Google Sheets**

### Forecasting

- [LSTM Forecasting](https://github.com/otmaniamine/smart-weather-station-iot-ai/blob/main/AI/mini_project_temperature.ipynb): `AI/mini_project_temperature.ipynb`

### Web Dashboard

- [Dashboard App](https://github.com/otmaniamine/smart-weather-station-iot-ai/blob/main/Interface/src/App.tsx): `Interface/src/App.tsx`
- [Map Section](https://github.com/otmaniamine/smart-weather-station-iot-ai/blob/main/Interface/src/components/MapSection.tsx): `Interface/src/components/MapSection.tsx`
- [Interactive Map](https://github.com/otmaniamine/smart-weather-station-iot-ai/blob/main/Interface/src/components/Map.tsx): `Interface/src/components/Map.tsx`
- [Weather Dashboard](https://github.com/otmaniamine/smart-weather-station-iot-ai/blob/main/Interface/src/components/WeatherDashboard.tsx): `Interface/src/components/WeatherDashboard.tsx`
- [Live Weather](https://github.com/otmaniamine/smart-weather-station-iot-ai/blob/main/Interface/src/components/Live.tsx): `Interface/src/components/Live.tsx`
- [Product Sections](https://github.com/otmaniamine/smart-weather-station-iot-ai/tree/main/Interface/src/components): `Interface/src/components`

### Other components

- **Dashboard User**

## Connections

- Weather Sensors → Station DS/LDR: readings (evidence: `README.md`)
- Weather Sensors → Station DS/Wind: readings (evidence: `README.md`)
- Station DS/LDR → DHT11 Uploader: telemetry
- Station DS/Wind → DHT11 Uploader: telemetry
- DHT11 Uploader → Apps Script: HTTP GET (evidence: `README.md`)
- Apps Script → Google Sheets: append rows (evidence: `README.md`)
- Google Sheets → Weather Dashboard: read data (evidence: `README.md`)
- Google Sheets → LSTM Forecasting: historical data
- LSTM Forecasting → Dashboard App: predictions (evidence: `README.md`)
- Dashboard User → Dashboard App: views
- Dashboard App → Map Section: renders (evidence: `Interface/src/App.tsx`)
- Map Section → Interactive Map: renders (evidence: `Interface/src/components/MapSection.tsx`)
- Map Section → Weather Dashboard: renders (evidence: `Interface/src/components/MapSection.tsx`)
- Dashboard App → Live Weather: renders (evidence: `Interface/src/App.tsx`)
- Dashboard App → Product Sections: renders (evidence: `Interface/src/App.tsx`)
