How drngominhtu/esp32_webserver_rbcteam_v2 works
This repository implements an ESP32-hosted MQTT dashboard for live robot monitoring and control. A browser loads the dashboard from the ESP32, connects over WebSocket, and receives broker messages for topic discovery, tables, charts, and the robot map; browser commands travel back through the ESP32 to the MQTT broker. The map and R1 scripts are separate browser views in the tree. Source excerpts show the firmware bridge and portions of the browser behavior; links for unsampled page assets reflect explicit firmware routes or documented capabilities.
Main entry points: main.cpp HTTP and WS Server · script.js Dashboard Logic · scriptmap.js Robot Position Map · scriptR1.js R1 Dashboard View
Components 15
ESP32 Gateway
- HTTP and WS Server
src/main.cpp - MQTT Bridge
src/main.cpp
Dashboard UI
- Dashboard Page
data/index.html - Dashboard Assets
data - Dashboard Logic
data/script.js - Parameter Tables
data/script.js - Charts and Export
data/script.js - Topic Controls
data/script.js
Robot Visualization
- Map Page
data/map.html - Robot Position Map
not_main/scriptmap.js - R1 Dashboard View
not_main/scriptR1.js - Map Styles
not_main/stylemap.css
External Systems
- MQTT Broker
- Robot Devices
Other components
- Browser User
Connections 22
- Browser User → HTTP and WS Server: requests pages
src/main.cpp - HTTP and WS Server → Dashboard Page: serves page
src/main.cpp - HTTP and WS Server → Dashboard Assets: serves assets
src/main.cpp - HTTP and WS Server → Map Page: serves map
src/main.cpp - HTTP and WS Server → Map Styles: routes stylesheet
src/main.cpp - Browser User → Dashboard Logic: runs dashboard
data/script.js - Dashboard Logic → Parameter Tables: updates values
data/script.js - Dashboard Logic → Charts and Export: plots values
data/script.js - Dashboard Logic → Topic Controls: sends subscriptions
data/script.js - Browser User → HTTP and WS Server: opens WebSocket
src/main.cpp - HTTP and WS Server → MQTT Bridge: handles WS events
src/main.cpp - MQTT Bridge → MQTT Broker: subscribes and publishes
src/main.cpp - MQTT Broker → MQTT Bridge: delivers messages
src/main.cpp - MQTT Bridge → Browser User: forwards updates
src/main.cpp - MQTT Broker → Robot Devices: delivers commands
README.md - Browser User → Robot Position Map: runs map view
not_main/scriptmap.js - Robot Position Map → HTTP and WS Server: opens WebSocket
not_main/scriptmap.js - HTTP and WS Server → Robot Position Map: forwards position data
- Browser User → R1 Dashboard View: runs R1 view
not_main/scriptR1.js - R1 Dashboard View → HTTP and WS Server: requests R1 topic
not_main/scriptR1.js - HTTP and WS Server → R1 Dashboard View: forwards topic data
- MQTT Broker → MQTT Bridge: discovers topics
src/main.cpp