Commit Graph

7 Commits

Author SHA1 Message Date
Max Gramser aa2137f3f8 Choose vacuum, vac & mop or mop on the vacuum card, and a climate card for the CYD (0.2.46)
App 0.2.46 / firmware 0.2.39:
- The vacuum's state message carries extras from its own device: the cleaning mode and water
  selects (found by translation key, then entity id ending, so localized ids work), the suction
  speeds to offer, the battery sensor (HA 2026.8 dropped battery_level), charging and the current
  room. Speeds and water levels a mode covers move into the mode row; Custom only while in use.
  The manager watches these entities and resends only the vacuum's message when one changes.
- Vacuum card redesign on both boards: robot with state, battery, charging bolt and room; Start
  (Pause, Resume) and Dock; then segmented rows for mode, suction and water, showing only the rows
  the chosen mode uses. Taps show at once and wait for Home Assistant; Locate is a round button in
  the Guition hero.
- CYD climate card without the arc: big setpoint between large -/+ keys (debounced, hold to
  repeat) and one row of mode keys in HA's order and colours, with a more key for fan and swing.
- Both profiles clear climate_edit_pending when the climate card is closed, instead of running
  ui_refresh every second while the flag stayed set.

Tested with the owner's Roborock S8 on HA 2026.9.1 (live data, OTA-flashed bench boards) and with
host renders of both boards; see docs/TEST_RESULTS_0246.md.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
2026-09-15 15:22:28 +02:00
Max Gramser 3e959b3df9 Put ESP Screens in English and keep layouts when entity IDs change (0.2.40)
Everything a user sees or reads is now English: both boards' labels,
status replies and logs, the ESP Screens editor and Alerts cheatsheet,
and the README and guides (docs/TILES.md, CALIBRATING.md, ACCEPTANCE.md
and TROUBLESHOOTING.md replace the Dutch file names). Labels follow
Home Assistant's own English names (Heat/Cool modes, Heating/Cooling
actions, Away, Returning to dock, weather conditions), dates use English
abbreviations and the top bar writes numbers the English way. Docs use
HA 2026.9's menu names (Settings -> Apps, App store, Settings -> Tools).
Unused legacy files (home-like.yaml, buttons.yaml, a.out) are removed.

Firmware 0.2.34 names its entities in English. Home Assistant registers
a renamed ESPHome entity under a new entity ID, so the inbox
text.<screen>_tegelinstellingen becomes text.<screen>_tile_settings and
the layout stored under the old ID would be lost. The manager now
recognises the screen by its device, during a run or after a restart,
and moves its layout and update history along; the Update button and
the nightly round follow the screen through the rename. Screens that
still run 0.2.33 or older keep working: both languages are matched.

Main is the only release branch from now on.

Tested on a Home Assistant Yellow (HA 2026.9.1) with both bench boards:
see docs/TEST_RESULTS_0240.md.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
2026-09-15 02:08:43 +02:00
Max Gramser ef0ca8b350 Custom icon per tile: 150 MDI icons in firmware and editor
- screen_manager/app/tile_icons.py is the single icon list (12 groups, 20 media
  and music icons); tools/generate_icons.py writes it into the three icon fonts
  of both boards and builds the editor's subset font.
- Firmware 0.2.18 shows o.icon when its fonts carry the glyph, else the domain
  icon. The app sends the chosen icon, or Home Assistant's own mdi icon on auto.
- Tile sheet gets an icon picker with search; the mockup shows the icon the
  screen actually draws.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
2026-09-13 11:16:57 +02:00
Max Gramser 94546cf727 Add stable CYD firmware, USB calibration wizard and complete setup guide 2026-09-12 10:18:49 +02:00
Max Gramser 1eb65d8f71 Tegels Ambient en Alarm erbij; Woonkamer naar rij 5
Het raster is nu vol: tien tegels op vijf rijen.

- Tegel 2 (rij 1, rechts) wordt Ambient — script.ambient_morning, met een
  muzieknoot als icoon. Als script krijgt hij automatisch het paarse
  actie-accent, dus hij is meteen te onderscheiden van de lampen eromheen.
- Woonkamer (light.woonkamer_2) verhuist van tegel 2 naar tegel 9, rij 5
  links, en neemt zijn sofa-icoon mee. Verder ongewijzigd: helderheids-
  slider op long-press, en omdat de lamp color_temp/rgb/xy meldt komt de
  kleurknop in de overlay vanzelf mee.
- Tegel 10 (rij 5, rechts) wordt Alarm — input_boolean.alarm_engaged.
  Een input_boolean reageert niet op switch.toggle, vandaar de expliciete
  TAP_SERVICE input_boolean.toggle.

Tegels 9 en 10 abonneren alleen op wat ze echt lezen, zoals 7 en 8:
tegel 9 op state + brightness + supported_color_modes, tegel 10 alleen op
state. Waar een sensor ontbreekt gaat er NAN of "" naar de overlay.

Alle tien plekken per tegel zijn nagelopen met een audit over het hele
bestand: substituties, MDI-glyph, sensor, widget, ack-script, t*_on,
set_value_auto, apply_tile en de twee HA-events. Geen verwijzingen naar
sensors die niet bestaan.

Firmware: 1.329 MB flash, 72172 bytes statisch RAM. Na flashen 144 KB
vrije heap, grootste blok 90 KB.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
2026-09-01 15:57:11 +02:00
Max Gramser cf211fb255 Accentkleur per tegel afleiden uit het Home Assistant-domein
Scripts en lights hadden allebei hetzelfde gele rondje, dus op het scherm
was script.goede_morgen niet te onderscheiden van light.woonkamer_2. Een
script vuur je af, een lamp zet je aan of uit; dat hoort niet hetzelfde
te zijn.

De kleur komt nu uit het domein van het entity_id — Home Assistant's
eigen indeling — in plaats van uit tien handmatige kleurvelden per tegel:

  script / scene / button / input_button / automation  -> ACCENT_ACTION (paars)
  light                                                -> ACCENT_LIGHT (amber)
  al het overige                                       -> ACCENT_DEVICE (cyaan)

TILE*_CIRCLE_ACTIVE_COLOR en TILE*_ICON_DISABLED_COLOR staan hiervoor op
de sentinel ${ACCENT_AUTO}, bewust buiten het 24-bits kleurbereik zodat
een echte hexwaarde altijd wint. Tegel 8 gebruikt dat nog steeds: de
brievenbus blijft rood zodra er post ligt.

Alleen de drie scripttegels (3, 4, 5) verschuiven van amber naar paars.
Light blijft amber en de overige apparaten blijven cyaan, dus verder
verandert er visueel niets.

De sliderkleur in de long-press-overlay lost dezelfde sentinel op, zodat
een tegel met slider ook automatisch de goede kleur krijgt.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
2026-09-01 11:45:52 +02:00
Max Gramser a5521ceaaa Initial commit: SmartDisplay CYD config met scrollbaar tegelraster
Eerste commit van het project. De config staat op het punt waar het
tegelraster scrollbaar is en er acht tegels in staan.

Wat er in deze ronde aan de bestaande config veranderd is:

- Home screen scrollt. Wallpaper, kamernaam en klok staan op de pagina
  zelf en blijven staan; alle tegels zitten in een transparante
  `tile_scroll` container die verticaal scrollt. Ruimte voor 2x5 = 10
  tegels, waarvan rij 1-3 zichtbaar is in rust. GRID_ROW*_Y is nu
  relatief aan die container; SCROLL_Y/SCROLL_H per orientatiepreset.
  LVGL annuleert klik en long-press zodra een sleep de scroll-limiet
  passeert, dus tikken en scrollen bijten elkaar niet.

- Achtergrond is een twee-stops gradient in plaats van een 320x240
  RGB565-wallpaper. Scheelt ~150 KB flash en een image-blit per
  hertekening, wat het scrollen bruikbaar maakt. Dezelfde gradient
  wordt hergebruikt als achtergrond van de drie overlays.

- Tegel 7: Tafellamp (light.tafellamp_licht), tik = toggle,
  long-press = helderheidsslider.

- Tegel 8: Brievenbus reset (input_select.brievenbus_status). Licht op
  zodra de status "Vol" is, tik zet hem terug op "Leeg".

- TILE*_ACTIVE_STATE toegevoegd: een exacte HA-state die als "actief"
  telt, voor entiteiten die geen on/off gebruiken. Leeg = oud gedrag.

- do_tile_action kent nu param_key "option", voor
  input_select.select_option.

Tegels 7 en 8 abonneren alleen op de HA-entiteiten die ze echt lezen,
in plaats van op alle elf per tegel. Na flashen: 148 KB vrije heap,
grootste blok 94 KB.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
2026-09-01 11:38:39 +02:00