franklinwh-system-view
A friendly picture of a FranklinWH site, shared by the FranklinWH bridges: grid, aGate, batteries, solar, home, smart circuits and generator, with live flows. It opens as a full-page overlay over a bridge's own dashboard, and can be the page a browser starts on.
- Simple by default. Pictures and plain words: battery charge, mode, what the inverter is doing, grid up or down, solar, home use, circuits. Hover for a sentence, click for details.
- Fits any screen. Desktop and tablet get a landscape layout, phones a portrait one. Zoom with − / Fit / +, pinch, or Ctrl+wheel; drag to pan when zoomed. It always opens fitted. A site's diagram on a phone opens as wide as the screen and scrolls down; Fit (or − from there) shows all of it, and + goes back to full width. Placed between a host's bars, it leaves the notch and home-bar insets to those bars. Zoom, Customise diagram, the extras and Start on sit in the Options drop-down, which opens over the diagram and closes on a click outside it or Esc.
- Extras, when wanted. Under Options each has its own switch, off until switched on and remembered in the browser: Voltage & frequency under the grid, Today's energy (kWh) under each picture, Power on wires (the kW on each wire, with an arrow the way it goes), Alarms (a count on the device; its details list them) and Solar forecast & actual (today's forecast, the actual so far and what is still to come, in a box on the diagram's left; above it on a phone). Smart circuits is the other way round: shown until switched off, and the diagram is laid out again without them.
- Colours mean state. Green normal, grey offline or disabled, amber warning, red critical.
- Only what's there is drawn. A site with no solar shows no solar.
How a bridge uses it
from fastapi.staticfiles import StaticFiles
import franklinwh_system_view as sv
app.mount("/system-view", StaticFiles(directory=sv.static_dir()), name="system-view")
@app.get("/api/system")
def api_system():
return sv.build(my_payload()) # validates, then adds both layouts per gateway
<link rel="stylesheet" href="system-view/system-view.css">
<script src="system-view/system-view.js"></script>
<script>FWHSystemView.mount({endpoint: "api/system"});</script>
<button onclick="FWHSystemView.open()">System view</button>
A host with its own gateway picker keeps it and the overlay on the same gateway:
FWHSystemView.mount({endpoint: "api/system",
gateway: () => picker.id, // shown when the overlay opens
onGateway: (id) => picker.select(id)}); // the user picked a gateway in the overlay
picker.onChange((id) => FWHSystemView.showGateway(id));
With gatewayChips: false the overlay leaves out its own gateway chips and shows only the
gateway the host's picker has.
Customise diagram. Where no reading tells the bridge how a site is built, the user tells it. The bridge stores the answers (one JSON object) and lets the package do the rest:
raw = my_payload()
p = sv.customise.apply(raw, saved) # names, legs, models, solar, appliances
p["customise"] = {"endpoint": "api/system/customise", "fields": sv.customise.fields(raw, saved)}
return sv.build(p)
@app.put("/api/system/customise")
def save(values: dict):
store(sv.customise.clean(values, my_payload())) # ValueError → 400
With several gateways the dialog shows one at a time, from a Gateway picker that starts on the gateway the diagram shows.
A site with several gateways. Give each gateway its site (id, name, and the
service meter it is fed through when you know it: id, name, ac single/split/three,
rated_amps). Gateways that name the same site are drawn in one diagram: the grid and the
service meter on the left, then one row per aGate with its batteries, solar, smart circuits
and home. The shown gateway is highlighted, and tapping another aGate shows that gateway
(and calls onGateway). build() puts these diagrams in site_groups; a gateway alone on
its site is drawn as before.
Weather. Put the current Open-Meteo reading in site.weather (code, condition,
temp_c); the page draws it next to the site's name.
The payload is described in schema.py; fixtures/ holds examples. Signs: grid
power_w > 0 imports, battery power_w > 0 discharges. Leave out what you can't read.
Several aPowers. battery.units draws one card per aPower (up to four, then "+N more"). Set battery.rollup to true to draw one battery instead: the gateway's soc_pct and power_w as the aGate reports them, labelled Batteries ×N (count, else the number of units). Its hover has a line per aPower and its details a row per aPower, from each unit's name, soc_pct, soh_pct, current_a and status (text, such as the BMS state); what a unit leaves out is not shown. A unit's state warn, crit or off colours the one battery.
Optional per gateway: energy_today (grid_import_kwh, grid_export_kwh, solar_kwh,
home_kwh, battery_charge_kwh, battery_discharge_kwh, each kWh or null) and alarms, a
list of {target, unit?, code?, text, level} where target is one of the objects (grid,
agate, home, solar, battery, circuits, generator), unit the 1-based battery or
circuit it is about, and level warn or crit. Also solar_forecast
(forecast_kwh, today's forecast; actual_kwh, made so far; remaining_kwh, still to come;
each kWh or null), from the bridge's own forecast. A value that is missing is not drawn.
Try it
python -m franklinwh_system_view.demo us_tou_two_apowers_solar
Design: franklinwh-direct-connect-bridge #428.
Metadata
Release files for franklinwh-system-view 0.5.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| franklinwh_system_view-0.5.0.tar.gz | 55.4 kB | With provenance | Details for franklinwh_system_view-0.5.0.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| franklinwh_system_view-0.5.0-py3-none-any.whl | Python 3 | none | any | Details for franklinwh_system_view-0.5.0-py3-none-any.whl |
Total release size: 99.7 kB
Release files / franklinwh_system_view-0.5.0.tar.gz
| Download URL | franklinwh_system_view-0.5.0.tar.gz |
|---|---|
| Size | 55.4 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
2953757939babbf57b63ba23b21ba7aad9792a15b445cc75c197523b3ae5b16b
|
|
BLAKE2b-256 checksum How to use checksums |
34dc18a19ddd3af573cdedb7329e1bc9be64b84c14eca4105af656e5be7bcb30
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.16
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Nov 18, 2026.
Transparency logRelease files / franklinwh_system_view-0.5.0-py3-none-any.whl
| Download URL | franklinwh_system_view-0.5.0-py3-none-any.whl |
|---|---|
| Size | 44.3 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
03fc383efff0d03213fdf2e3d4fe6746364b9a35200036d509d02ed8aadde413
|
|
BLAKE2b-256 checksum How to use checksums |
fc2b538bd2ab6d4ad8c9bd6df0d1a665477b14005e87a8fd5d2b654d3c75f392
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.16
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Nov 18, 2026.
Transparency logSecurity for franklinwh-system-view 0.5.0
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
Full provenance
Both files in this release have been uploaded with provenance metadata.
Attestation for franklinwh_system_view-0.5.0.tar.gz
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Nov 18, 2026.
Transparency logA note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.