How perspektivlos/solar-lokal-app works
Solar-Lokal-App is a cloud-free local energy monitoring and control center for a DC-coupled solar-battery system. The main workflow is: an operator views live energy and device status, the backend collects device telemetry, and the UI presents flows and metrics; operators can also issue device controls and inspect diagnostics or historical energy. The graph includes documented capabilities whose implementation was not fully sampled. Source excerpts show selected calls; other links are limited to explicit README statements or are omitted where wiring is uncertain.
Main entry points: server.py API server · App.js App routes · collectors.py Device collector · api.js API client
Components 26
Operator interface
- App routes
frontend/src/App.js - Live dashboard
frontend/src/pages/Dashboard.jsx - Control UI
frontend/src/pages/Control.jsx - Diagnostics UI
frontend/src/pages/Diagnose.jsx - History UI
frontend/src/pages/History.jsx - Energy report
frontend/src/pages/Report.jsx - API client
frontend/src/lib/api.js
Live collection
- API server
backend/server.py - Device collector
backend/collectors.py - MQTT parsing
backend/mqtt_client.py - Demo data
backend/mocks.py
Energy analysis
- Energy balance
backend/energy_balance.py - Battery analysis
backend/phase2.py - SUN calculations
backend/sun.py
Control and diagnosis
- Alarm evaluation
backend/alarms.py - Device discovery
backend/discovery.py - Device controls
backend/routes.py - SmartShunt normalization
backend/smartshunt.py - SmartShunt probe
backend/smartshunt_probe.py - Battery preview API
backend/phase2_routes.py
History and storage
- Daily history API
backend/verlauf_routes.py - History calculations
backend/verlauf.py - Influx point schema
backend/influx_points.py - Grafana dashboards
deploy/proxmox/grafana/generate_dashboards.py
Other components
- Operator
- Energy devices
Connections 33
- Operator → App routes: opens
- App routes → Live dashboard: routes to
frontend/src/App.js - App routes → Control UI: routes to
frontend/src/App.js - App routes → Diagnostics UI: routes to
frontend/src/App.js - App routes → History UI: routes to
frontend/src/App.js - App routes → Energy report: routes to
frontend/src/App.js - Live dashboard → API client: requests live data
- Control UI → API client: sends controls
- History UI → API client: requests history
- Energy report → API client: requests data
- API client → API server: calls API
frontend/src/lib/api.js - API server → Device collector: collects live data
backend/server.py - Device collector → MQTT parsing: reads telemetry
backend/collectors.py - MQTT parsing → Energy devices: receives MQTT
- Device collector → Energy devices: queries devices
backend/collectors.py - Device collector → Demo data: uses demo values
backend/collectors.py - API server → Energy balance: calculates balances
backend/server.py - API server → Alarm evaluation: evaluates alarms
backend/server.py - API server → Influx point schema: writes time-series points
backend/server.py - Energy balance → Battery analysis: supports battery analysis
backend/energy_balance.py - Device collector → SmartShunt normalization: normalizes telemetry
backend/collectors.py - API server → SUN calculations: uses SUN calculations
backend/server.py - API server → Device controls: serves control routes
backend/server.py - Device controls → Energy devices: sends commands
- API server → Device discovery: runs discovery
backend/routes.py - API server → Battery preview API: registers preview API
backend/phase2_routes.py - Battery preview API → Device collector: collects live data
backend/phase2_routes.py - Battery preview API → Alarm evaluation: evaluates battery alarms
backend/phase2_routes.py - API server → Daily history API: registers history API
backend/verlauf_routes.py - Daily history API → Energy balance: summarizes day balance
backend/verlauf_routes.py - Daily history API → History calculations: loads history helpers
backend/verlauf_routes.py - API server → Grafana dashboards: supports Grafana analysis
- Operator → Grafana dashboards: views long-term trends