# jankd90/databases architecture

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

- Interactive diagram: https://gitdiagram.com/jankd90/databases
- Repository: https://github.com/jankd90/databases

## Overview

This is an ESP32 climate-station project paired with a host-side SQLite receiver and a guided database course. The runtime workflow is sensor measurement, WiFi transmission, host parsing, and SQLite persistence; the tutorials extend the same project through schema design, SQL analysis, and a Python application. Runtime edges are supported by the README and excerpts. Tutorial internals are represented by their exact directories because their source was not sampled.

Main entry points: [`LeesESP32_SQlite.py`](https://github.com/jankd90/databases/blob/main/LeesESP32_SQlite.py) (Climate SQLite DB), [`tutorials/01_db_design`](https://github.com/jankd90/databases/tree/main/tutorials/01_db_design) (Schema Design), [`tutorials/03_climate_analysis`](https://github.com/jankd90/databases/tree/main/tutorials/03_climate_analysis) (Climate Analysis), [`esp32-code/boot.py`](https://github.com/jankd90/databases/blob/main/esp32-code/boot.py) (WiFi Setup)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_device["ESP32 Device"]
  node_boot["WiFi Setup<br/>[boot.py]"]
  node_credentials["WiFi Credentials<br/>[secure.txt]"]
  node_driver["BME280 Driver<br/>[bme280.py]"]
  node_device_app["ESP32 Sender<br/>[main.py]"]
end

subgraph group_host["Host Ingestion"]
  node_receiver["Host Receiver"]
  node_db[("Climate SQLite DB")]
end

subgraph group_learning["Database Tutorials"]
  node_design["Schema Design"]
  node_sql["SQL Work"]
  node_analysis["Climate Analysis"]
  node_application["SQLite Application"]
  node_setup["Windows Setup"]
end

subgraph group_course["Course Materials"]
  node_manual["Course Reader"]
  node_docs["Climate Chapters"]
end

node_sensor{{"BME280 Sensor"}}
node_wifi(("WiFi Network"))
node_chartdb["ChartDB"]

node_boot -->|"reads credentials"| node_credentials
node_boot -->|"connects to"| node_wifi
node_sensor -.->|"provides readings"| node_driver
node_device_app -->|"reads measurements"| node_driver
node_device_app -->|"sends readings"| node_receiver
node_receiver -->|"parses and stores"| node_db
node_chartdb -->|"supports design"| node_design
node_design -->|"continues project"| node_sql
node_sql -->|"continues project"| node_analysis
node_analysis -->|"continues project"| node_application
node_db -->|"provides readings"| node_analysis
node_db -->|"supports app"| node_application
node_setup -->|"prepares learners"| node_design
node_manual -.->|"course materials"| node_docs

click node_boot "https://github.com/jankd90/databases/blob/main/esp32-code/boot.py"
click node_credentials "https://github.com/jankd90/databases/blob/main/esp32-code/secure.txt"
click node_driver "https://github.com/jankd90/databases/blob/main/esp32-code/bme280.py"
click node_device_app "https://github.com/jankd90/databases/blob/main/esp32-code/main.py"
click node_receiver "https://github.com/jankd90/databases/blob/main/LeesESP32_SQlite.py"
click node_db "https://github.com/jankd90/databases/blob/main/LeesESP32_SQlite.py"
click node_design "https://github.com/jankd90/databases/tree/main/tutorials/01_db_design"
click node_sql "https://github.com/jankd90/databases/tree/main/tutorials/02_sql_real_work"
click node_analysis "https://github.com/jankd90/databases/tree/main/tutorials/03_climate_analysis"
click node_application "https://github.com/jankd90/databases/tree/main/tutorials/04_sqlite_application"
click node_setup "https://github.com/jankd90/databases/tree/main/tutorials/00_windows_setup"
click node_manual "https://github.com/jankd90/databases/blob/main/Course-reader-lab-manual.md"
click node_docs "https://github.com/jankd90/databases/tree/main/docs"

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_boot,node_credentials,node_driver,node_device_app toneBlue
class node_receiver,node_db toneAmber
class node_design,node_sql,node_analysis,node_application,node_setup toneMint
class node_manual,node_docs toneRose
class node_sensor,node_wifi,node_chartdb toneIndigo
```

## Components

### ESP32 Device

- [WiFi Setup](https://github.com/jankd90/databases/blob/main/esp32-code/boot.py): `esp32-code/boot.py`
- [WiFi Credentials](https://github.com/jankd90/databases/blob/main/esp32-code/secure.txt): `esp32-code/secure.txt`
- [BME280 Driver](https://github.com/jankd90/databases/blob/main/esp32-code/bme280.py): `esp32-code/bme280.py`
- [ESP32 Sender](https://github.com/jankd90/databases/blob/main/esp32-code/main.py): `esp32-code/main.py`

### Host Ingestion

- [Host Receiver](https://github.com/jankd90/databases/blob/main/LeesESP32_SQlite.py): `LeesESP32_SQlite.py`
- [Climate SQLite DB](https://github.com/jankd90/databases/blob/main/LeesESP32_SQlite.py): `LeesESP32_SQlite.py`

### Database Tutorials

- [Schema Design](https://github.com/jankd90/databases/tree/main/tutorials/01_db_design): `tutorials/01_db_design`
- [SQL Work](https://github.com/jankd90/databases/tree/main/tutorials/02_sql_real_work): `tutorials/02_sql_real_work`
- [Climate Analysis](https://github.com/jankd90/databases/tree/main/tutorials/03_climate_analysis): `tutorials/03_climate_analysis`
- [SQLite Application](https://github.com/jankd90/databases/tree/main/tutorials/04_sqlite_application): `tutorials/04_sqlite_application`
- [Windows Setup](https://github.com/jankd90/databases/tree/main/tutorials/00_windows_setup): `tutorials/00_windows_setup`

### Course Materials

- [Course Reader](https://github.com/jankd90/databases/blob/main/Course-reader-lab-manual.md): `Course-reader-lab-manual.md`
- [Climate Chapters](https://github.com/jankd90/databases/tree/main/docs): `docs`

### Other components

- **BME280 Sensor**
- **WiFi Network**
- **ChartDB**

## Connections

- WiFi Setup → WiFi Credentials: reads credentials (evidence: `README.md`)
- WiFi Setup → WiFi Network: connects to (evidence: `README.md`)
- BME280 Sensor → BME280 Driver: provides readings
- ESP32 Sender → BME280 Driver: reads measurements (evidence: `esp32-code/main.py`)
- ESP32 Sender → Host Receiver: sends readings (evidence: `README.md`)
- Host Receiver → Climate SQLite DB: parses and stores (evidence: `LeesESP32_SQlite.py`)
- ChartDB → Schema Design: supports design (evidence: `README.md`)
- Schema Design → SQL Work: continues project (evidence: `README.md`)
- SQL Work → Climate Analysis: continues project (evidence: `README.md`)
- Climate Analysis → SQLite Application: continues project (evidence: `README.md`)
- Climate SQLite DB → Climate Analysis: provides readings (evidence: `README.md`)
- Climate SQLite DB → SQLite Application: supports app (evidence: `README.md`)
- Windows Setup → Schema Design: prepares learners (evidence: `README.md`)
- Course Reader → Climate Chapters: course materials
