# rudreshgawade1-cloud/esp32-smart-parking architecture

> Architecture diagram of the GitHub repository rudreshgawade1-cloud/esp32-smart-parking, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-09-27). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/rudreshgawade1-cloud/esp32-smart-parking
- Repository: https://github.com/rudreshgawade1-cloud/esp32-smart-parking

## Overview

This repository is a browser-based virtual prototype of an ESP32 smart parking system, with a separate Arduino sketch representing the real-hardware counterpart. The main user workflow is to trigger or manipulate cars, simulate sensor detection and slot assignment, and see barriers, slot indicators, and displays update; users can also manage parking from the phone widget. The README documents the module roles and features, but the web and firmware source were not included in the sampled files, so internal call wiring is shown only where documented.

Main entry points: [`serve.py`](https://github.com/rudreshgawade1-cloud/esp32-smart-parking/blob/main/serve.py) (Local web server)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_web["Web simulation"]
  node_page["Simulator page"]
  node_ui["Panels and loop"]
  node_interaction["Phone and dragging"]
  node_simulation["Parking simulation"]
  node_scene["3D lot renderer"]
  node_station["Control station"]
  node_models[("3D models")]
end

subgraph group_firmware["Hardware firmware"]
  node_sketch["ESP32 sketch"]
end

subgraph group_local["Local serving"]
  node_server["Local web server<br/>[serve.py]"]
end

node_user(("User"))
node_browser(("Browser"))
node_sensors["IR sensors"]
node_actuators["Barriers and LEDs"]
node_displays["LCD and OLED"]
node_phone["Phone widget"]

node_user -->|"uses"| node_page
node_server -->|"serves page"| node_browser
node_browser -->|"requests assets"| node_server
node_ui -->|"enables controls"| node_interaction
node_interaction -->|"controls cars"| node_simulation
node_simulation -->|"simulates detection"| node_sensors
node_simulation -->|"updates state"| node_actuators
node_simulation -->|"updates lot"| node_scene
node_simulation -->|"updates displays"| node_station
node_ui -->|"runs view"| node_scene
node_scene -->|"loads models"| node_models
node_user -->|"uses"| node_phone
node_phone -->|"provides controls"| node_interaction
node_user -->|"taps to zoom"| node_station
node_user -->|"opens code"| node_sketch

click node_server "https://github.com/rudreshgawade1-cloud/esp32-smart-parking/blob/main/serve.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_page,node_ui,node_interaction,node_simulation,node_scene,node_station,node_models,node_user,node_browser toneBlue
class node_sketch toneAmber
class node_server toneMint
class node_sensors,node_actuators,node_displays,node_phone toneIndigo
```

## Components

### Web simulation

- **Simulator page**
- **Panels and loop**
- **Phone and dragging**
- **Parking simulation**
- **3D lot renderer**
- **Control station**
- **3D models**

### Hardware firmware

- **ESP32 sketch**

### Local serving

- [Local web server](https://github.com/rudreshgawade1-cloud/esp32-smart-parking/blob/main/serve.py): `serve.py`

### Other components

- **User**
- **Browser**
- **IR sensors**
- **Barriers and LEDs**
- **LCD and OLED**
- **Phone widget**

## Connections

- User → Simulator page: uses
- Local web server → Browser: serves page
- Browser → Local web server: requests assets
- Panels and loop → Phone and dragging: enables controls
- Phone and dragging → Parking simulation: controls cars
- Parking simulation → IR sensors: simulates detection
- Parking simulation → Barriers and LEDs: updates state
- Parking simulation → 3D lot renderer: updates lot
- Parking simulation → Control station: updates displays
- Panels and loop → 3D lot renderer: runs view
- 3D lot renderer → 3D models: loads models
- User → Phone widget: uses
- Phone widget → Phone and dragging: provides controls
- User → Control station: taps to zoom
- User → ESP32 sketch: opens code
