homebridge-broadlink-rm-blaster 1.1.0 → 1.2.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +66 -0
- package/README.md +46 -33
- package/dist/accessories/temperatureHumiditySensorAccessory.d.ts +1 -0
- package/dist/accessories/temperatureHumiditySensorAccessory.js +13 -0
- package/dist/accessories/temperatureHumiditySensorAccessory.js.map +1 -1
- package/dist/platform.d.ts +2 -0
- package/dist/platform.js +3 -2
- package/dist/platform.js.map +1 -1
- package/package.json +5 -2
package/CHANGELOG.md
ADDED
|
@@ -0,0 +1,66 @@
|
|
|
1
|
+
# Changelog
|
|
2
|
+
All notable changes to this project will be documented in this file.
|
|
3
|
+
|
|
4
|
+
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/),
|
|
5
|
+
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
|
|
6
|
+
|
|
7
|
+
## Unreleased
|
|
8
|
+
|
|
9
|
+
## [1.2.0] - 2026-07-26
|
|
10
|
+
|
|
11
|
+
### Changed
|
|
12
|
+
- `package.json`'s `files` list now explicitly includes README, LICENSE and
|
|
13
|
+
CHANGELOG alongside the published `dist` output.
|
|
14
|
+
- README restructured: Requirements/Installation/Usage sections, version
|
|
15
|
+
number in the title, Features/Configuration/Debugging nested under Usage,
|
|
16
|
+
license/changelog links at the bottom.
|
|
17
|
+
|
|
18
|
+
## [1.1.1] - 2026-07-26
|
|
19
|
+
|
|
20
|
+
### Added
|
|
21
|
+
- Temperature/humidity sensor now shows "No Response" in Home and sends an
|
|
22
|
+
ntfy notification after 5 consecutive failed readings, instead of silently
|
|
23
|
+
keeping the last known value forever.
|
|
24
|
+
|
|
25
|
+
## [1.1.0] - 2026-07-25
|
|
26
|
+
|
|
27
|
+
### Added
|
|
28
|
+
- Optional `ntfyTopic` config field: sends a push notification via ntfy.sh
|
|
29
|
+
the first time an RM device fails to connect.
|
|
30
|
+
|
|
31
|
+
## [1.0.4] - 2026-07-23
|
|
32
|
+
|
|
33
|
+
### Changed
|
|
34
|
+
- Reverted the `.npmignore` added in 1.0.3 (inert; `package.json`'s `files`
|
|
35
|
+
field already controls what's published).
|
|
36
|
+
|
|
37
|
+
## [1.0.3] - 2026-07-23
|
|
38
|
+
|
|
39
|
+
### Added
|
|
40
|
+
- `.npmignore`.
|
|
41
|
+
|
|
42
|
+
## [1.0.2] - 2026-07-22
|
|
43
|
+
|
|
44
|
+
### Fixed
|
|
45
|
+
- Reverted 1.0.1's per-IP placeholder MAC (broke authentication with real
|
|
46
|
+
Broadlink hardware); fixed the underlying multi-device registry collision
|
|
47
|
+
with a private `Broadlink` instance per configured RM device instead.
|
|
48
|
+
|
|
49
|
+
## [1.0.1] - 2026-07-22
|
|
50
|
+
|
|
51
|
+
### Fixed
|
|
52
|
+
- Second configured RM device permanently failing to authenticate, and a
|
|
53
|
+
`MaxListenersExceededWarning` on repeated connection retries.
|
|
54
|
+
|
|
55
|
+
## [1.0.0] - 2026-07-20
|
|
56
|
+
|
|
57
|
+
### Added
|
|
58
|
+
- First public release: basic accessories (light/switch/outlet/fan), dimmer
|
|
59
|
+
lights with brightness levels, TV remote accessory, temperature/humidity
|
|
60
|
+
sensor, multi-RM-device support, CLI diagnostic tool.
|
|
61
|
+
|
|
62
|
+
## [0.9.1] - 2026-07-20
|
|
63
|
+
|
|
64
|
+
### Changed
|
|
65
|
+
- README restructured: configuration section now leads with Homebridge
|
|
66
|
+
Config UI X support, `config.json` example moved to its own subsection.
|
package/README.md
CHANGED
|
@@ -1,42 +1,30 @@
|
|
|
1
|
-
#
|
|
1
|
+
# Homebridge Broadlink RM Blaster Plugin 1.2.0
|
|
2
2
|
|
|
3
|
-
|
|
4
|
-
[homebridge-broadlink-rm](https://github.com/kiwi-cam/homebridge-broadlink-rm#readme),
|
|
5
|
-
built on [kiwicam-broadlinkjs-rm](https://www.npmjs.com/package/kiwicam-broadlinkjs-rm)
|
|
6
|
-
for the underlying device communication.
|
|
3
|
+
**This Homebridge plugin has been 100% vibe coded with Claude.**
|
|
7
4
|
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
remotes, see
|
|
5
|
+
Blast RF and IR signals from Broadlink RM devices using Homebridge. Sends
|
|
6
|
+
pre-recorded hex codes to a known device IP; does not learn signals or
|
|
7
|
+
autodiscover devices. To capture hex codes from your own remotes, see
|
|
8
|
+
[learn-broadlink-rm4-codes](https://github.com/LuudJacobs/learn-broadlink-rm4-codes).
|
|
11
9
|
|
|
12
|
-
|
|
10
|
+
## Requirements
|
|
13
11
|
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
-
|
|
17
|
-
|
|
18
|
-
- **Basic accessories** power on/off via a hex signal.
|
|
19
|
-
- **Dimmer lights** one hex signal per discrete brightness level
|
|
20
|
-
- **TVs** power on/off plus a usable remote (arrows, select, back, exit, info,
|
|
21
|
-
volume, mute) in the iOS Remote app
|
|
22
|
-
- **Temperature/humidity sensor** polls the RM every 60 seconds, on by default.
|
|
23
|
-
- **ntfy.sh notifications** optional push notification the first time an RM
|
|
24
|
-
device fails to connect.
|
|
25
|
-
- Fully configurable via the Homebridge Config UI X plugin settings form.
|
|
12
|
+
- A Broadlink RM device, unlocked using the official Broadlink app (new
|
|
13
|
+
devices ship locked, which blocks local API access).
|
|
14
|
+
- Node.js `^18.15.0 || ^20.7.0 || ^22 || ^24`
|
|
15
|
+
- Homebridge `^1.8.0 || ^2.0.0`
|
|
26
16
|
|
|
27
|
-
##
|
|
17
|
+
## Installation
|
|
28
18
|
|
|
29
19
|
```bash
|
|
30
20
|
npm install -g homebridge-broadlink-rm-blaster
|
|
31
21
|
```
|
|
32
22
|
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
Your Broadlink RM must be unlocked using the official Broadlink app before this
|
|
36
|
-
plugin (or any third-party integration) can control it: new devices ship locked,
|
|
37
|
-
which blocks local API access.
|
|
23
|
+
## Usage
|
|
38
24
|
|
|
39
|
-
|
|
25
|
+
This plugin can be fully configured from the Homebridge Config UI X plugin
|
|
26
|
+
settings form. See [Configuration](#configuration) below for the full field
|
|
27
|
+
reference and an example `config.json`.
|
|
40
28
|
|
|
41
29
|
**TVs don't appear automatically alongside your other accessories.** HomeKit
|
|
42
30
|
only shows a proper TV tile/remote when it's added as its own accessory, so
|
|
@@ -47,12 +35,25 @@ code, the same way you'd add any other HomeKit accessory. If you remove a
|
|
|
47
35
|
TV from your config later, it has to be removed from the Home app manually
|
|
48
36
|
too since Homebridge can't unpair it for you.
|
|
49
37
|
|
|
50
|
-
|
|
38
|
+
### Features
|
|
39
|
+
|
|
40
|
+
- **Multiple RM devices** configure several Broadlink RMs and assign each
|
|
41
|
+
accessory to whichever one it's actually near.
|
|
42
|
+
- **Basic accessories** power on/off via a hex signal.
|
|
43
|
+
- **Dimmer lights** one hex signal per discrete brightness level
|
|
44
|
+
- **TVs** power on/off plus a usable remote (arrows, select, back, exit, info,
|
|
45
|
+
volume, mute) in the iOS Remote app
|
|
46
|
+
- **Temperature/humidity sensor** polls the RM every 60 seconds, on by default.
|
|
47
|
+
- **ntfy.sh notifications** optional push notification the first time an RM
|
|
48
|
+
device fails to connect.
|
|
49
|
+
- Fully configurable via the Homebridge Config UI X plugin settings form.
|
|
50
|
+
|
|
51
|
+
### Configuration
|
|
51
52
|
|
|
52
53
|
This plugin can be fully configured from the Homebridge Config UI X plugin
|
|
53
54
|
settings form.
|
|
54
55
|
|
|
55
|
-
|
|
56
|
+
#### config.json
|
|
56
57
|
|
|
57
58
|
If you'd rather edit the config file directly, here's an example
|
|
58
59
|
`config.json` platform block:
|
|
@@ -127,10 +128,14 @@ If you'd rather edit the config file directly, here's an example
|
|
|
127
128
|
`https://ntfy.sh/<topic>` the first time a given RM device fails to
|
|
128
129
|
connect - subscribe to the same topic in the [ntfy](https://ntfy.sh) app to
|
|
129
130
|
receive it. Only fires once per outage; it resets once that device
|
|
130
|
-
connects successfully again.
|
|
131
|
+
connects successfully again. The temperature/humidity sensor also triggers
|
|
132
|
+
this after 5 consecutive failed readings (see below), reusing the same
|
|
133
|
+
once-per-outage behavior.
|
|
131
134
|
- `rmDevices`: at least one required. Each needs a unique `name` and `ip`;
|
|
132
135
|
`enableTemperatureHumidity` (defaults to `true`) adds a temperature/humidity
|
|
133
|
-
sensor accessory for that specific device.
|
|
136
|
+
sensor accessory for that specific device. If a reading fails 5 times in a
|
|
137
|
+
row, the sensor shows "No Response" in Home (rather than a frozen stale
|
|
138
|
+
value) and, if `ntfyTopic` is set, sends a notification.
|
|
134
139
|
- `rmDevice` on every accessory/dimmer/TV below is a plain text field that
|
|
135
140
|
must exactly match the `name` of one of the devices above. There's no
|
|
136
141
|
live dropdown, since Homebridge's config UI can't populate one from
|
|
@@ -158,7 +163,7 @@ If you'd rather edit the config file directly, here's an example
|
|
|
158
163
|
`muteCode` is sent as-is for both muting and unmuting, since most remotes
|
|
159
164
|
use a single toggle button rather than distinct on/off signals.
|
|
160
165
|
|
|
161
|
-
|
|
166
|
+
### Debugging
|
|
162
167
|
|
|
163
168
|
To send a single hex code straight to your RM, bypassing Homebridge/HomeKit
|
|
164
169
|
entirely (useful for isolating whether a signal behaves oddly on the device
|
|
@@ -170,3 +175,11 @@ broadlink-rm-blaster <ip> <hexCode>
|
|
|
170
175
|
```
|
|
171
176
|
|
|
172
177
|
Run `broadlink-rm-blaster --help` for usage details.
|
|
178
|
+
|
|
179
|
+
## Credits
|
|
180
|
+
|
|
181
|
+
Inspired by [homebridge-broadlink-rm](https://github.com/kiwi-cam/homebridge-broadlink-rm#readme),
|
|
182
|
+
built on [kiwicam-broadlinkjs-rm](https://www.npmjs.com/package/kiwicam-broadlinkjs-rm)
|
|
183
|
+
for the underlying device communication.
|
|
184
|
+
|
|
185
|
+
[LICENSE](https://github.com/LuudJacobs/homebridge-broadlink-rm-blaster/blob/main/LICENSE) · [CHANGELOG](https://github.com/LuudJacobs/homebridge-broadlink-rm-blaster/blob/main/CHANGELOG.md)
|
|
@@ -5,6 +5,7 @@ export declare class TemperatureHumiditySensorAccessory {
|
|
|
5
5
|
private readonly accessory;
|
|
6
6
|
private readonly ip;
|
|
7
7
|
private readonly name;
|
|
8
|
+
private consecutiveFailures;
|
|
8
9
|
constructor(platform: BroadlinkRMBlasterPlatform, accessory: PlatformAccessory, ip: string, name: string);
|
|
9
10
|
private getTemperature;
|
|
10
11
|
private getHumidity;
|
|
@@ -2,11 +2,16 @@
|
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.TemperatureHumiditySensorAccessory = void 0;
|
|
4
4
|
const POLL_INTERVAL_MS = 60_000;
|
|
5
|
+
// A single poll failure is normal RF/network noise. Only treat the sensor as
|
|
6
|
+
// actually unreachable (clear the cached reading, notify) after this many in
|
|
7
|
+
// a row - avoids flapping to "No Response" and a notification on one blip.
|
|
8
|
+
const MAX_CONSECUTIVE_FAILURES = 5;
|
|
5
9
|
class TemperatureHumiditySensorAccessory {
|
|
6
10
|
platform;
|
|
7
11
|
accessory;
|
|
8
12
|
ip;
|
|
9
13
|
name;
|
|
14
|
+
consecutiveFailures = 0;
|
|
10
15
|
constructor(platform, accessory, ip, name) {
|
|
11
16
|
this.platform = platform;
|
|
12
17
|
this.accessory = accessory;
|
|
@@ -50,6 +55,8 @@ class TemperatureHumiditySensorAccessory {
|
|
|
50
55
|
async poll() {
|
|
51
56
|
try {
|
|
52
57
|
const { temperature, humidity } = await this.platform.broadlinkClient.readTemperatureHumidity(this.ip);
|
|
58
|
+
this.consecutiveFailures = 0;
|
|
59
|
+
this.platform.notifier.notifyConnectionRecovered(this.ip);
|
|
53
60
|
this.accessory.context.temperature = temperature;
|
|
54
61
|
this.accessory.context.humidity = humidity;
|
|
55
62
|
this.accessory.getService(this.platform.Service.TemperatureSensor)
|
|
@@ -59,6 +66,12 @@ class TemperatureHumiditySensorAccessory {
|
|
|
59
66
|
}
|
|
60
67
|
catch (error) {
|
|
61
68
|
this.platform.log.warn(`Failed to read temperature/humidity from ${this.ip}: ${error.message}`);
|
|
69
|
+
this.consecutiveFailures++;
|
|
70
|
+
if (this.consecutiveFailures >= MAX_CONSECUTIVE_FAILURES) {
|
|
71
|
+
this.accessory.context.temperature = undefined;
|
|
72
|
+
this.accessory.context.humidity = undefined;
|
|
73
|
+
this.platform.notifier.notifyConnectionFailure(this.ip, error);
|
|
74
|
+
}
|
|
62
75
|
}
|
|
63
76
|
}
|
|
64
77
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"temperatureHumiditySensorAccessory.js","sourceRoot":"","sources":["../../src/accessories/temperatureHumiditySensorAccessory.ts"],"names":[],"mappings":";;;AAIA,MAAM,gBAAgB,GAAG,MAAM,CAAC;AAEhC,MAAa,kCAAkC;
|
|
1
|
+
{"version":3,"file":"temperatureHumiditySensorAccessory.js","sourceRoot":"","sources":["../../src/accessories/temperatureHumiditySensorAccessory.ts"],"names":[],"mappings":";;;AAIA,MAAM,gBAAgB,GAAG,MAAM,CAAC;AAEhC,6EAA6E;AAC7E,6EAA6E;AAC7E,2EAA2E;AAC3E,MAAM,wBAAwB,GAAG,CAAC,CAAC;AAEnC,MAAa,kCAAkC;IAI1B;IACA;IACA;IACA;IANX,mBAAmB,GAAG,CAAC,CAAC;IAEhC,YACmB,QAAoC,EACpC,SAA4B,EAC5B,EAAU,EACV,IAAY;QAHZ,aAAQ,GAAR,QAAQ,CAA4B;QACpC,cAAS,GAAT,SAAS,CAAmB;QAC5B,OAAE,GAAF,EAAE,CAAQ;QACV,SAAI,GAAJ,IAAI,CAAQ;QAE7B,MAAM,kBAAkB,GAAG,IAAI,CAAC,SAAS,CAAC,UAAU,CAAC,IAAI,CAAC,QAAQ,CAAC,OAAO,CAAC,iBAAiB,CAAC;eACxF,IAAI,CAAC,SAAS,CAAC,UAAU,CAAC,IAAI,CAAC,QAAQ,CAAC,OAAO,CAAC,iBAAiB,CAAC,CAAC;QACxE,kBAAkB,CAAC,iBAAiB,CAAC,IAAI,CAAC,QAAQ,CAAC,cAAc,CAAC,IAA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AAI,CAAC,mBAAmB,EAAE,CAAC;YAC3B,IAAI,IAAI,CAAC,mBAAmB,IAAI,wBAAwB,EAAE,CAAC;gBACzD,IAAI,CAAC,SAAS,CAAC,OAAO,CAAC,WAAW,GAAG,SAAS,CAAC;gBAC/C,IAAI,CAAC,SAAS,CAAC,OAAO,CAAC,QAAQ,GAAG,SAAS,CAAC;gBAC5C,IAAI,CAAC,QAAQ,CAAC,QAAQ,CAAC,uBAAuB,CAAC,IAAI,CAAC,EAAE,EAAE,KAAc,CAAC,CAAC;YAC1E,CAAC;QACH,CAAC;IACH,CAAC;CACF;AA3ED,gFA2EC"}
|
package/dist/platform.d.ts
CHANGED
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import type { API, Characteristic, DynamicPlatformPlugin, Logger, PlatformAccessory, PlatformConfig, Service } from 'homebridge';
|
|
2
2
|
import { BroadlinkClient } from './broadlinkClient';
|
|
3
|
+
import { NtfyNotifier } from './ntfyNotifier';
|
|
3
4
|
export declare class BroadlinkRMBlasterPlatform implements DynamicPlatformPlugin {
|
|
4
5
|
readonly log: Logger;
|
|
5
6
|
readonly config: PlatformConfig;
|
|
@@ -8,6 +9,7 @@ export declare class BroadlinkRMBlasterPlatform implements DynamicPlatformPlugin
|
|
|
8
9
|
readonly Characteristic: typeof Characteristic;
|
|
9
10
|
readonly accessories: PlatformAccessory[];
|
|
10
11
|
readonly broadlinkClient: BroadlinkClient;
|
|
12
|
+
readonly notifier: NtfyNotifier;
|
|
11
13
|
private readonly activeUuids;
|
|
12
14
|
constructor(log: Logger, config: PlatformConfig, api: API);
|
|
13
15
|
configureAccessory(accessory: PlatformAccessory): void;
|
package/dist/platform.js
CHANGED
|
@@ -16,6 +16,7 @@ class BroadlinkRMBlasterPlatform {
|
|
|
16
16
|
Characteristic;
|
|
17
17
|
accessories = [];
|
|
18
18
|
broadlinkClient;
|
|
19
|
+
notifier;
|
|
19
20
|
activeUuids = new Set();
|
|
20
21
|
constructor(log, config, api) {
|
|
21
22
|
this.log = log;
|
|
@@ -28,8 +29,8 @@ class BroadlinkRMBlasterPlatform {
|
|
|
28
29
|
for (const rmDevice of blasterConfig.rmDevices ?? []) {
|
|
29
30
|
deviceNames.set(rmDevice.ip, rmDevice.name);
|
|
30
31
|
}
|
|
31
|
-
|
|
32
|
-
this.broadlinkClient = new broadlinkClient_1.BroadlinkClient(this.log, notifier);
|
|
32
|
+
this.notifier = new ntfyNotifier_1.NtfyNotifier(this.log, blasterConfig.ntfyTopic, deviceNames);
|
|
33
|
+
this.broadlinkClient = new broadlinkClient_1.BroadlinkClient(this.log, this.notifier);
|
|
33
34
|
this.api.on('didFinishLaunching', () => {
|
|
34
35
|
this.discoverAccessories();
|
|
35
36
|
});
|
package/dist/platform.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"platform.js","sourceRoot":"","sources":["../src/platform.ts"],"names":[],"mappings":";;;AAUA,uDAAoD;AACpD,iDAA8C;AAC9C,yCAAwD;AAExD,iEAA8D;AAC9D,mEAAgE;AAChE,2DAAwD;AACxD,yGAAsG;AAEtG,MAAa,0BAA0B;
|
|
1
|
+
{"version":3,"file":"platform.js","sourceRoot":"","sources":["../src/platform.ts"],"names":[],"mappings":";;;AAUA,uDAAoD;AACpD,iDAA8C;AAC9C,yCAAwD;AAExD,iEAA8D;AAC9D,mEAAgE;AAChE,2DAAwD;AACxD,yGAAsG;AAEtG,MAAa,0BAA0B;IAWnB;IACA;IACA;IAZF,OAAO,CAAiB;IACxB,cAAc,CAAwB;IAEtC,WAAW,GAAwB,EAAE,CAAC;IACtC,eAAe,CAAkB;IACjC,QAAQ,CAAe;IAEtB,WAAW,GAAG,IAAI,GAAG,EAAU,CAAC;IAEjD,YACkB,GAAW,EACX,MAAsB,EACtB,GAAQ;QAFR,QAAG,GAAH,GAAG,CAAQ;QACX,WAAM,GAAN,MAAM,CAAgB;QACtB,QAAG,GAAH,GAAG,CAAK;QAExB,IAAI,CAAC,OAAO,GAAG,IAAI,CA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F,KAAK,MAAM,SAAS,IAAI,gBAAgB,EAAE,CAAC;YACzC,MAAM,KAAK,GAAG,IAAI,CAAC,WAAW,CAAC,OAAO,CAAC,SAAS,CAAC,CAAC;YAClD,IAAI,KAAK,KAAK,CAAC,CAAC,EAAE,CAAC;gBACjB,IAAI,CAAC,WAAW,CAAC,MAAM,CAAC,KAAK,EAAE,CAAC,CAAC,CAAC;YACpC,CAAC;QACH,CAAC;IACH,CAAC;CACF;AA1KD,gEA0KC"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "homebridge-broadlink-rm-blaster",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.2.0",
|
|
4
4
|
"description": "Blast RF and IR signals from Broadlink RM devices using Homebridge",
|
|
5
5
|
"author": "Luud Jacobs",
|
|
6
6
|
"license": "MIT",
|
|
@@ -22,7 +22,10 @@
|
|
|
22
22
|
},
|
|
23
23
|
"files": [
|
|
24
24
|
"dist",
|
|
25
|
-
"config.schema.json"
|
|
25
|
+
"config.schema.json",
|
|
26
|
+
"README.md",
|
|
27
|
+
"LICENSE",
|
|
28
|
+
"CHANGELOG.md"
|
|
26
29
|
],
|
|
27
30
|
"keywords": [
|
|
28
31
|
"homebridge",
|