160 Commits

Author SHA1 Message Date
Adrian Jagielak
b892e20920 Expose battery maintenance status (e.g. replace_now) as a sensor
Some battery devices report a full battery level while still signalling that
the battery must be replaced (the customer's log shows devices at lvl 100 with
state "replace_now"). That maintenance state was not surfaced anywhere.

When the battery service supports the replace_* events (per its `sup_events`
property), expose the hub-reported `state` attribute as a diagnostic
"Battery status" sensor.
2026-07-01 23:38:16 +02:00
Jagi ᯅ
93a036c4f7 Add Futurehome house mode support (Modeswitch) + scene event entities (#33)
* Add Futurehome house mode support (Modeswitch) + scene event entities

The Futurehome Modeswitch (Modusbryter) is a house-mode switch: its buttons
change the hub's mode (Home/Away/Sleep/Vacation), which is a hub-level Vinculum
concept broadcast via `evt.pd7.notify` (component "mode") — not a device
`scene_ctrl` event. That is why tapping it produced nothing in the device
message stream and the mapped scene sensor was stuck on `unknown`.

The add-on had no house-mode support at all. This adds it:

- Expose the current house mode as a `Mode` select on the Smarthub device.
  It reflects the current mode, updates in real time via `evt.pd7.notify`
  (with a 30s house-poll fallback), and can change the mode from Home Assistant
  via `cmd.pd7.request {cmd:"set", component:"mode", id:<mode>}` (matching the
  reference primefimp `ChangeMode`).
- Always publish the Smarthub hub device so the Mode select is available even
  without Thingsplex credentials; inclusion/exclusion tooling stays gated.
- Discover available modes from the Vinculum `mode` component, falling back to
  home/away/sleep/vacation.

Also improve genuine scene controllers: `scene_ctrl` now additionally exposes a
Home Assistant `event` entity so momentary button presses can drive automations
(the previous `Scene` sensor latched and could not react to repeated presses).
The sensor is kept for backwards compatibility (renamed "Scene (last value)").

Includes demo-mode support, README/CHANGELOG updates, and a version bump to
1.7.0.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01FuQAyPde4K57P2XMCKbFek

* Fix real-time house-mode updates: hub-mode notify uses component "hub"

A house-mode-change evt.pd7.notify is broadcast on the hub component
(component "hub", id "mode"), not component "mode". The previous guard
`notify.component !== 'mode'` discarded every real mode-change notification, so
the Mode select only updated via the 30s poll fallback instead of in real time.

Gate on component "hub" (and, defensively, "mode") and extract the new mode
from either param.mode.current (primefimp Hub/HubMode) or param.current
(edge-iqcontrols/tpflow references), publishing only when a mode string is
found.
2026-07-01 23:36:36 +02:00
Adrian Jagielak
36168c1101 v1.6.2 2026-05-16 23:59:35 +02:00
Jagi ᯅ
1a8a7c2e2c Fix invalid device_class + unit_of_measurement combinations for HA 2026.5 (#32)
HA 2026.5 enforces strict validation of device_class/unit_of_measurement
pairs in MQTT discovery payloads. Four categories were broken:

- power_factor: unit was sent as "power_factor" (the FIMP field name); HA
  requires the field to be omitted or empty for this device class. Fixed by
  normalising the display unit separately from the FIMP data-path key.

- illuminance: unit "Lux" is rejected; normalise to "lx". When a sensor
  reports luminance as "%" (some Z-Wave devices), the illuminance device
  class is dropped so the entity becomes a generic sensor rather than
  triggering a validation error.

- reactive_power (regular/export meter): unit "VAr" is rejected; HA requires
  lowercase "var".

- reactive_power (extended meter values, e.g. p_import_react): the unit
  determination logic fell through to the generic power branch and sent "W";
  reactive power extended values now emit "var", apparent power values emit
  "VA", and reactive energy values emit "kvarh".

Fixes #31

Co-authored-by: Claude <noreply@anthropic.com>
2026-05-16 23:58:19 +02:00
Adrian Jagielak
ce36669587 v1.6.1 2025-10-16 20:50:41 +02:00
Adrian Jagielak
dac16b0fd4 Tweak 'Ignore Availability Reports' setting 2025-10-16 20:50:03 +02:00
Adrian Jagielak
45182a6416 v1.6.0 2025-10-16 20:16:11 +02:00
Adrian Jagielak
9f2feea8c1 Add setting to always treat all devices as up 2025-10-16 20:15:31 +02:00
Adrian Jagielak
a38e441c9b v1.5.0 2025-10-16 02:07:11 +02:00
Adrian Jagielak
afbfd1d1c7 Revert "Add ability to specify a custom MQTT broker"
This reverts commit b937f90340.
2025-10-16 02:06:06 +02:00
Adrian Jagielak
729c6c839f v1.4.0 2025-10-13 19:03:53 +02:00
Adrian Jagielak
b937f90340 Add ability to specify a custom MQTT broker 2025-10-13 19:03:52 +02:00
Adrian Jagielak
4a3eb07464 v1.3.1 2025-09-28 15:49:27 +02:00
Adrian Jagielak
5732c70d4e Revert "Upgrade dependencies"
This reverts commit 91c33b33cd.
2025-09-28 15:48:40 +02:00
Adrian Jagielak
16a4fb3181 v1.3.0 2025-09-28 14:59:18 +02:00
Adrian Jagielak
fdc65a0bd5 Use light entity for out_lvl_switch if the device type is "light" 2025-09-28 14:57:37 +02:00
Adrian Jagielak
91c33b33cd Upgrade dependencies 2025-09-28 14:54:14 +02:00
Adrian Jagielak
6ca05e95b9 v1.2.1 - update version in config.yaml 2025-09-28 12:25:43 +02:00
Adrian Jagielak
7e3d56cec1 v1.2.1 2025-09-27 02:26:33 +02:00
Adrian Jagielak
a8c61c4658 Revert "Use light entity for out_lvl_switch if the device type is "light""
This reverts commit 50500e97be.
2025-09-27 02:25:52 +02:00
Adrian Jagielak
653df93807 v1.2.0 2025-09-26 20:00:52 +02:00
Adrian Jagielak
50500e97be Use light entity for out_lvl_switch if the device type is "light" 2025-09-26 20:00:11 +02:00
Adrian Jagielak
f216f4b719 v1.1.2 2025-09-25 00:41:48 +02:00
dependabot[bot]
e7cab97142 Bump home-assistant/builder from 2025.03.0 to 2025.09.0 (#6) 2025-09-25 00:41:47 +02:00
dependabot[bot]
e39bfbcde8 Bump actions/checkout from 4.2.2 to 5.0.0 (#2) 2025-09-25 00:41:47 +02:00
dependabot[bot]
060ae593f8 Bump docker/login-action from 3.4.0 to 3.5.0 (#1) 2025-09-25 00:41:47 +02:00
Adrian Jagielak
383980d5f8 v1.1.1 2025-09-25 00:41:47 +02:00
Adrian Jagielak
41cd550225 Add error handling for invalid FIMP messages 2025-09-25 00:41:47 +02:00
Andreas
060947e06b Update installation.md (#7)
Clarify that users must select the MQTT Integration instead of the hub’s MQTT server, with step-by-step guidance provided.
2025-09-25 00:41:47 +02:00
Adrian Jagielak
a05e96bae0 v1.1.0 2025-09-25 00:41:47 +02:00
Adrian Jagielak
000537585d Stop inclusion/exclusion after the first report 2025-09-25 00:41:47 +02:00
Adrian Jagielak
351274f56e Allow empty Thingsplex credentials (#3) 2025-09-25 00:41:47 +02:00
Andreas
a8e5b00275 Improve GUI security by hiding passwords by default (#5)
Replaced 'str?' with 'password?' for fh_password and tp_password
2025-09-25 00:41:47 +02:00
Adrian Jagielak
0bb82f6d95 Add logging the initial devices response 2025-09-16 12:44:38 +02:00
Jagi ᯅ
2be8bf34bf Update README.md 2025-08-02 11:10:17 +02:00
Jagi ᯅ
22456658bc Update README.md 2025-08-02 11:07:30 +02:00
Jagi ᯅ
3c09f02e0e Update README.md 2025-08-02 11:06:37 +02:00
Jagi ᯅ
f8ea167478 Update README.md 2025-08-02 11:05:46 +02:00
Jagi ᯅ
0a171bbb9f Update README.md 2025-08-02 10:26:43 +02:00
Jagi ᯅ
f0bd75e5b8 Update README.md 2025-08-02 10:25:25 +02:00
Jagi ᯅ
215a3e61e0 Update installation.md 2025-07-29 14:34:10 +02:00
Adrian Jagielak
a41c599686 Update README.md 2025-07-29 00:48:24 +02:00
Adrian Jagielak
69c2d7de4b Update README.md 2025-07-29 00:46:35 +02:00
Adrian Jagielak
e17a4eaec7 v1.0.0 2025-07-29 00:40:32 +02:00
Adrian Jagielak
9e2aa6999a Add Installation Guide 2025-07-29 00:38:10 +02:00
Adrian Jagielak
986c85c0bf Lint fixes 2025-07-28 23:31:14 +02:00
Adrian Jagielak
c56b9c6fbe Allow unpairing devices using any adapter 2025-07-28 22:38:00 +02:00
Adrian Jagielak
361eaaf1bc Add icon 2025-07-28 17:34:41 +02:00
Adrian Jagielak
57d7773a27 Update README.md 2025-07-28 17:34:23 +02:00
Adrian Jagielak
4d599a5e1a Update README.md 2025-07-28 17:32:28 +02:00