Public Access
The hardcoded clock is now the built-in dynamic page "Clock". A dynamic page has a background bitmap per time of day and up to 8 elements (clock, date, Home Assistant value, text), each with position, alignment, font and overlay. Pages are drawn on the ESP32, also for the web previews. - Pages tab in the web UI: page editor with drag and drop, font upload (TTF/OTF converted in the browser to the FDF1 dot font format) - Built-in fonts Small, Normal, Large and Full height (generated by tools/make_builtin_fonts.py), built-in bitmaps Pikachu and Pikachu yawning - Home Assistant values over the REST API (URL and token in the HA tab) - Settings version 4: evening settings removed (now time slots of the Clock page), old records are converted - HA Mode dropdown lists the dynamic pages and bitmaps Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
24 lines
1.2 KiB
C
24 lines
1.2 KiB
C
#pragma once
|
|
|
|
#include "logic/display_controller.h"
|
|
#include "logic/settings.h"
|
|
|
|
// Home Assistant integration over MQTT (with discovery):
|
|
// FlipDot Display Power switch: off = draw the off image and switch the display off
|
|
// FlipDot Display Mode select: the page shown during the day (a dynamic page, e.g.
|
|
// the built-in "Clock", or a bitmap)
|
|
// FlipDot Display Off image select: left on the dots when the display switches off
|
|
// ("Blank" or a bitmap)
|
|
// FlipDot Display IP sensor: the IP address
|
|
// FlipDot Display Firmware sensor: version and health, e.g. "2.1.0, ok, 0 crashes, ..."
|
|
// FlipDot Display Recovery button: restart into the recovery app (for 10 minutes)
|
|
//
|
|
// The broker comes from the settings (web UI); an empty host means BROKER_ADDR, MQTT_USER
|
|
// and MQTT_PASSWORD from secrets.h. Changes need a restart.
|
|
void homeAssistantBegin(DisplayController &controller, const HomeAssistantSettings &settings);
|
|
void homeAssistantLoop();
|
|
bool homeAssistantConnected();
|
|
|
|
// Publish the firmware status (only sent when it changes, and again after a reconnect)
|
|
void homeAssistantSetFirmwareStatus(const char *status);
|