GET /api/stats?range=7d|30d computes compressor, CWU, CO and heater hours,
compressor starts and temperatures per Europe/Warsaw day from the raw
heat_pump polls. Hours hold each poll for at most 600 s so gaps add nothing;
starts are 0 -> >0 transitions and are a lower bound at 300 s polling.
Historia gets a Wykresy | Statystyki switch (shared SubView helper, also
used by Energia) with totals tiles, a daily chart and a cycling hint.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
POST /api/presets/{id} accepts optional values per setpoint of the preset,
checked against the gateway's limits before anything is sent, so Wyjazd
can use temperatures other than the defaults.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
GET /commands showed the last poll for up to 5 minutes after a write.
It now shows the value read back after our own write or restore when
that is newer than the poll. POST /commands/restore runs a pending
restore at once through the normal path (conflict check, read-back,
audit with the requester, rate limit).
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
A command may carry "until" (ISO-8601 with offset). The change is stored
as a restore with leaseUntil = due = until, so it survives a restart and
runs at its end. Held changes must lower the value below both the current
value and the original, end in the future and within 30 days; otherwise
they are rejected without a write. Renewals now only extend a lease.
ADR-012 amends ADR-011 for held changes.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
A "Urządzenia" card lists the Deye, Fronius and house meter as rows with
a "Szczegóły ›" chevron, 56 px high. Tapping one opens a bottom sheet on
a phone (a dialog on wide screens) with the grouped values; it closes by
button, backdrop or Escape and returns focus to the row.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
One extra FC4 request per poll; PRAD2 is unchanged and still written when
the extra request fails.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The user chose to defer the login: Traefik admits only Krosno and clears
a client's Remote-User. A later ADR picks the login before access from
outside.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The plain-JS UI was too weak to grow into the reference dashboard. The new
UI (React, TypeScript, Vite, Tailwind, Recharts) follows research/ui/: a
side bar on large screens, tabs on a phone, and an SVG picture of the
installation whose pipes flow, compressor turns and tanks glow while the
matching pump runs. Energy flows are animated the same way.
Maven builds and tests the UI (frontend-maven-plugin, Node per project),
so check.sh and CI need only Java. The fixes of the web review (stale and
missing readings, silent inverters, outages, Warsaw time, timeouts,
out-of-order answers, restore values) carry over; tests read the API
contract examples. The CSP now allows the self-hosted font.
Supersedes fix/web-review. ADR-008 records the new UI stack.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The phone API and the web UI are built in parallel, so they need one
contract first: view records, the history allowlist, the gateway and
history ports, and example JSON. ADR-008 records the stack (proposed).
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The deploy script ran on the Pi: healthy restart, a Modbus read and an
Influx write within 20 s, the next poll on time. The first write split
into two points 1 ms apart, which the baseline already does.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The backend does not exist yet, so CI has no image to build; it comes
with the backend in M3. The deploy item stays open until the script has
run once on the Pi.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
- ADR-006: gateway writes readings to InfluxDB with a buffer; backend reads them
- S6: commands only from the backend (token and firewall)
- M1 gateway reads heat pump, Deye, Fronius and the house meter (moved from
rpi-measurements); D7 subnet fix first
- M3 read-only backend and web UI with pump and energy; Grafana step dropped
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01U8EHjVrf5ffw1Vjn5bPGJu
- ADR-006 supersedes ADR-002: the Pi gateway owns device links, checks commands
and runs timed restores; the backend runs in Docker in Kraków
- restore value is read from the controller before the first write
- roadmap: energy view moves to M4 (my father wants it), setpoints to M5
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01U8EHjVrf5ffw1Vjn5bPGJu
- spec: goal covers heat pump first, energy second; explicit in/out scope
- docs/frisko/rx910-se21.md: controller facts moved out of the roadmap
- roadmap: M6 energy, M7 native decision, C6 energy feasibility done
- ADR-005: InfluxDB plus one local file, no other database
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01U8EHjVrf5ffw1Vjn5bPGJu
Restart from the version running on the Pi (e345063) with written goals and rules:
- docs/spec.md: goal, principles, architecture, requirements
- docs/roadmap.md: bottom-up milestones M0-M6, baseline defects, controller facts
- docs/decisions/: ADR-001..004 (evolve baseline, backend on Pi, single Modbus
owner, web UI first)
- CONTRIBUTING.md and CLAUDE.md: workflow, safety and context-size rules
- research/frisko/: RX910-SE21 register map, phone-app XML maps and APK,
MR208-PC+ reference docs
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>