node-red-contrib-homebridge-automation 0.3.0-beta.14 → 0.3.0-beta.16

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/README.md CHANGED
@@ -9,59 +9,59 @@ The above Node-RED Flow, turns on my 'Outside Office' light when the powder room
9
9
  # Table of Contents
10
10
 
11
11
  <!--ts-->
12
- * [Homebridge Automation powered by Node-RED](#homebridge-automation-powered-by-node-red)
13
- * [Table of Contents](#table-of-contents)
14
- * [Introduction](#introduction)
15
- * [Caveats](#caveats)
16
- * [Changes](#changes)
17
- * [Mar 18, 2019 - Version 0.0.39](#mar-18-2019---version-0039)
18
- * [Mar 19, 2019 - Version 0.0.42](#mar-19-2019---version-0042)
19
- * [Mar 31, 2019 - Version 0.0.](#mar-31-2019---version-00)
20
- * [May 9, 2019 - Version 0.0.43](#may-9-2019---version-0043)
21
- * [May 15, 2019 - Version 0.0.44](#may-15-2019---version-0044)
22
- * [May 29, 2019 - Version 0.0.45](#may-29-2019---version-0045)
23
- * [July 27, 2019 - Version 0.0.50](#july-27-2019---version-0050)
24
- * [Feb 24, 2020 - Version 0.0.56](#feb-24-2020---version-0056)
25
- * [Mar 18, 2020 - Version 0.0.59](#mar-18-2020---version-0059)
26
- * [Oct 13, 2020 - Version 0.0.71](#oct-13-2020---version-0071)
27
- * [Oct 24, 2020 - Version 0.0.71](#oct-24-2020---version-0071)
28
- * [Nov 1, 2020 - Version 0.0.73](#nov-1-2020---version-0073)
29
- * [Nov 13, 2020 - Version 0.0.76](#nov-13-2020---version-0076)
30
- * [Feb 2, 2021 - Version 0.0.78](#feb-2-2021---version-0078)
31
- * [Mar 9, 2021 - Version 0.0.80](#mar-9-2021---version-0080)
32
- * [April 23, 2021 - Version 0.0.82](#april-23-2021---version-0082)
33
- * [Dec 31, 2022 - Version 0.1.3](#dec-31-2022---version-013)
34
- * [Jan 6, 2023 - Version 0.1.5](#jan-6-2023---version-015)
35
- * [Jan 11, 2023 - Version 0.1.7](#jan-11-2023---version-017)
36
- * [Jan 15, 2023 - Version 0.1.8](#jan-15-2023---version-018)
37
- * [Dec 15, 2024 - Version 0.2.0](#dec-15-2024---version-020)
38
- * [April 15, 2025 - Version 0.3.0](#april-15-2025---version-030)
39
- * [Breaking Change](#breaking-change)
40
- * [Fixes](#fixes)
41
- * [Backlog / Roadmap](#backlog--roadmap)
42
- * [Dropped items](#dropped-items)
43
- * [Installation Steps](#installation-steps)
44
- * [1 - Install Node-RED and Homebridge](#1---install-node-red-and-homebridge)
45
- * [2 - Prepare Homebridge for integration with Homebridge-Automation](#2---prepare-homebridge-for-integration-with-homebridge-automation)
46
- * [3 - Install Homebridge-Automation into Node-Red](#3---install-homebridge-automation-into-node-red)
47
- * [4 - Start Node-Red](#4---start-node-red)
48
- * [5 - Initial setup and configuration inside Node-Red](#5---initial-setup-and-configuration-inside-node-red)
49
- * [6 - Configure 'hb event' to receive updates from your Accessories](#6---configure-hb-event-to-receive-updates-from-your-accessories)
50
- * [Node-RED Homebridge-Automation Message Structure](#node-red-homebridge-automation-message-structure)
51
- * [hb event](#hb-event)
52
- * [Output](#output)
53
- * [hb resume](#hb-resume)
54
- * [input](#input)
55
- * [output](#output-1)
56
- * [hb status](#hb-status)
57
- * [input](#input-1)
58
- * [output](#output-2)
59
- * [hb control](#hb-control)
60
- * [Input](#input-2)
61
- * [Flows Shared from Community](#flows-shared-from-community)
62
- * [Donations](#donations)
63
- * [Troubleshooting / DEBUG MODE](#troubleshooting--debug-mode)
64
- * [To start Node-RED in DEBUG mode, and output Homebridge-Automation debug logs start Node-RED like this.](#to-start-node-red-in-debug-mode-and-output-homebridge-automation-debug-logs-start-node-red-like-this)
12
+ - [Homebridge Automation powered by Node-RED](#homebridge-automation-powered-by-node-red)
13
+ - [Table of Contents](#table-of-contents)
14
+ - [Introduction](#introduction)
15
+ - [Caveats](#caveats)
16
+ - [Changes](#changes)
17
+ - [Mar 18, 2019 - Version 0.0.39](#mar-18-2019---version-0039)
18
+ - [Mar 19, 2019 - Version 0.0.42](#mar-19-2019---version-0042)
19
+ - [Mar 31, 2019 - Version 0.0.](#mar-31-2019---version-00)
20
+ - [May 9, 2019 - Version 0.0.43](#may-9-2019---version-0043)
21
+ - [May 15, 2019 - Version 0.0.44](#may-15-2019---version-0044)
22
+ - [May 29, 2019 - Version 0.0.45](#may-29-2019---version-0045)
23
+ - [July 27, 2019 - Version 0.0.50](#july-27-2019---version-0050)
24
+ - [Feb 24, 2020 - Version 0.0.56](#feb-24-2020---version-0056)
25
+ - [Mar 18, 2020 - Version 0.0.59](#mar-18-2020---version-0059)
26
+ - [Oct 13, 2020 - Version 0.0.71](#oct-13-2020---version-0071)
27
+ - [Oct 24, 2020 - Version 0.0.71](#oct-24-2020---version-0071)
28
+ - [Nov 1, 2020 - Version 0.0.73](#nov-1-2020---version-0073)
29
+ - [Nov 13, 2020 - Version 0.0.76](#nov-13-2020---version-0076)
30
+ - [Feb 2, 2021 - Version 0.0.78](#feb-2-2021---version-0078)
31
+ - [Mar 9, 2021 - Version 0.0.80](#mar-9-2021---version-0080)
32
+ - [April 23, 2021 - Version 0.0.82](#april-23-2021---version-0082)
33
+ - [Dec 31, 2022 - Version 0.1.3](#dec-31-2022---version-013)
34
+ - [Jan 6, 2023 - Version 0.1.5](#jan-6-2023---version-015)
35
+ - [Jan 11, 2023 - Version 0.1.7](#jan-11-2023---version-017)
36
+ - [Jan 15, 2023 - Version 0.1.8](#jan-15-2023---version-018)
37
+ - [Dec 15, 2024 - Version 0.2.0](#dec-15-2024---version-020)
38
+ - [April 15, 2025 - Version 0.3.0](#april-15-2025---version-030)
39
+ - [Breaking Change](#breaking-change)
40
+ - [Fixes](#fixes)
41
+ - [Backlog / Roadmap](#backlog--roadmap)
42
+ - [Dropped items](#dropped-items)
43
+ - [Installation Steps](#installation-steps)
44
+ - [1 - Install Node-RED and Homebridge](#1---install-node-red-and-homebridge)
45
+ - [2 - Prepare Homebridge for integration with Homebridge-Automation](#2---prepare-homebridge-for-integration-with-homebridge-automation)
46
+ - [3 - Install Homebridge-Automation into Node-Red](#3---install-homebridge-automation-into-node-red)
47
+ - [4 - Start Node-Red](#4---start-node-red)
48
+ - [5 - Initial setup and configuration inside Node-Red](#5---initial-setup-and-configuration-inside-node-red)
49
+ - [6 - Configure 'hb event' to receive updates from your Accessories](#6---configure-hb-event-to-receive-updates-from-your-accessories)
50
+ - [Node-RED Homebridge-Automation Message Structure](#node-red-homebridge-automation-message-structure)
51
+ - [hb event](#hb-event)
52
+ - [Output](#output)
53
+ - [hb resume](#hb-resume)
54
+ - [input](#input)
55
+ - [output](#output-1)
56
+ - [hb status](#hb-status)
57
+ - [input](#input-1)
58
+ - [output](#output-2)
59
+ - [hb control](#hb-control)
60
+ - [Input](#input-2)
61
+ - [Flows Shared from Community](#flows-shared-from-community)
62
+ - [Donations](#donations)
63
+ - [Troubleshooting / DEBUG MODE](#troubleshooting--debug-mode)
64
+ - [To start Node-RED in DEBUG mode, and output Homebridge-Automation debug logs start Node-RED like this.](#to-start-node-red-in-debug-mode-and-output-homebridge-automation-debug-logs-start-node-red-like-this)
65
65
  <!--te-->
66
66
 
67
67
  # Introduction
@@ -200,6 +200,7 @@ With a plugin, you can see if it supports Real Time events, by opening the Home
200
200
  - Add common supported types Window, Window Covering, Light Sensor #151, tks @HDeKnop
201
201
  - HB-Control Node Turns Off then On when this message is received #152
202
202
  - Added `Debug logging` configuration option that creates a file `homebridge-automation-endpoints.json`, which contains all the homebridge devices discovered. It can be used as part of troubleshooting device issues.
203
+ - Fix for some camara devices not outputing events
203
204
 
204
205
  # Backlog / Roadmap
205
206
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "node-red-contrib-homebridge-automation",
3
- "version": "0.3.0-beta.14",
3
+ "version": "0.3.0-beta.16",
4
4
  "description": "NodeRED Automation for HomeBridge",
5
5
  "main": "src/HAP-NodeRed.js",
6
6
  "scripts": {
@@ -41,8 +41,8 @@
41
41
  },
42
42
  "dependencies": {
43
43
  "better-queue": ">=3.8.12",
44
- "debug": "^4.3.7",
45
- "@homebridge/hap-client": "^2.1.0"
44
+ "debug": "^4.4.1",
45
+ "@homebridge/hap-client": "^3.1.1"
46
46
  },
47
47
  "author": "NorthernMan54",
48
48
  "license": "ISC",
@@ -174,8 +174,11 @@ class HBConfigNode {
174
174
  this.monitor = await this.hapClient.monitorCharacteristics(monitorNodes);
175
175
  this.monitor.on('service-update', (services) => {
176
176
  services.forEach(service => {
177
- const eventNodes = Object.values(this.clientNodes).filter(clientNode =>
178
- clientNode.config.device === `${service.instance.name}${service.instance.username}${service.accessoryInformation.Manufacturer}${service.serviceName}${service.uuid.slice(0, 8)}`
177
+ const eventNodes = Object.values(this.clientNodes).filter(clientNode => {
178
+ const deviceIdentifier = `${service.instance.name}${service.instance.username}${service.accessoryInformation.Manufacturer}${(service.accessoryInformation.Name ? service.accessoryInformation.Name : service.serviceName)}${service.uuid.slice(0, 8)}`;
179
+ // debug('service-update: compare', clientNode.config.device, deviceIdentifier);
180
+ return clientNode.config.device === deviceIdentifier;
181
+ }
179
182
  );
180
183
  // debug('service-update', service.serviceName, eventNodes);
181
184
  eventNodes.forEach(eventNode => eventNode.emit('hbEvent', service));
@@ -35,7 +35,7 @@
35
35
  "id": "4138921fd7b9a926",
36
36
  "type": "tab",
37
37
  "label": "Flow 5",
38
- "disabled": false,
38
+ "disabled": true,
39
39
  "info": "",
40
40
  "env": []
41
41
  },
@@ -43,7 +43,7 @@
43
43
  "id": "92f59d974b9c8a86",
44
44
  "type": "tab",
45
45
  "label": "Camera Test",
46
- "disabled": true,
46
+ "disabled": false,
47
47
  "info": "",
48
48
  "env": []
49
49
  },
@@ -2883,14 +2883,14 @@
2883
2883
  "id": "6df154716efd4949",
2884
2884
  "type": "hb-event",
2885
2885
  "z": "92f59d974b9c8a86",
2886
- "name": "Side door",
2887
- "Homebridge": "homebridge",
2888
- "Manufacturer": "Eufy",
2886
+ "name": "North Sidewalk 6EED",
2887
+ "Homebridge": "ECI-T24F2",
2888
+ "Manufacturer": "HikVision",
2889
2889
  "Service": "MotionSensor",
2890
- "device": "homebridge0E:89:A7:DA:D3:21EufySide door00000085",
2890
+ "device": "ECI-T24F28E:88:AB:7A:D0:54HikVisionNorth Sidewalk 6EED00000085",
2891
2891
  "conf": "7e647d67.f33acc",
2892
2892
  "sendInitialState": true,
2893
- "x": 100,
2893
+ "x": 140,
2894
2894
  "y": 220,
2895
2895
  "wires": [
2896
2896
  [
@@ -2916,7 +2916,7 @@
2916
2916
  "checkall": "true",
2917
2917
  "repair": false,
2918
2918
  "outputs": 1,
2919
- "x": 270,
2919
+ "x": 370,
2920
2920
  "y": 220,
2921
2921
  "wires": [
2922
2922
  [
@@ -2943,7 +2943,7 @@
2943
2943
  "from": "",
2944
2944
  "to": "",
2945
2945
  "reg": false,
2946
- "x": 460,
2946
+ "x": 540,
2947
2947
  "y": 220,
2948
2948
  "wires": [
2949
2949
  [
@@ -2955,14 +2955,14 @@
2955
2955
  "id": "769d2de2c6bd3544",
2956
2956
  "type": "hb-control",
2957
2957
  "z": "92f59d974b9c8a86",
2958
- "name": "Side door",
2959
- "Homebridge": "homebridge",
2960
- "Manufacturer": "Eufy",
2958
+ "name": "North Sidewalk 6EED",
2959
+ "Homebridge": "ECI-T24F2",
2960
+ "Manufacturer": "HikVision",
2961
2961
  "Service": "CameraRTPStreamManagement",
2962
- "device": "homebridge0E:89:A7:DA:D3:21EufySide door00000110",
2962
+ "device": "ECI-T24F28E:88:AB:7A:D0:54HikVisionNorth Sidewalk 6EED00000110",
2963
2963
  "conf": "7e647d67.f33acc",
2964
2964
  "outputs": 1,
2965
- "x": 660,
2965
+ "x": 760,
2966
2966
  "y": 220,
2967
2967
  "wires": [
2968
2968
  [
@@ -2977,13 +2977,13 @@
2977
2977
  "name": "debug 21",
2978
2978
  "active": true,
2979
2979
  "tosidebar": true,
2980
- "console": false,
2980
+ "console": true,
2981
2981
  "tostatus": true,
2982
2982
  "complete": "payload",
2983
2983
  "targetType": "msg",
2984
2984
  "statusVal": "payload",
2985
2985
  "statusType": "auto",
2986
- "x": 840,
2986
+ "x": 850,
2987
2987
  "y": 280,
2988
2988
  "wires": []
2989
2989
  },
@@ -3024,7 +3024,7 @@
3024
3024
  "checkall": "true",
3025
3025
  "repair": false,
3026
3026
  "outputs": 1,
3027
- "x": 270,
3027
+ "x": 330,
3028
3028
  "y": 340,
3029
3029
  "wires": [
3030
3030
  [
@@ -3051,7 +3051,7 @@
3051
3051
  "from": "",
3052
3052
  "to": "",
3053
3053
  "reg": false,
3054
- "x": 460,
3054
+ "x": 540,
3055
3055
  "y": 340,
3056
3056
  "wires": [
3057
3057
  [
@@ -3070,7 +3070,7 @@
3070
3070
  "device": "ECI-T24F2CB:6F:94:DD:43:77HikVisionDriveway 8E5200000110",
3071
3071
  "conf": "7e647d67.f33acc",
3072
3072
  "outputs": 1,
3073
- "x": 680,
3073
+ "x": 740,
3074
3074
  "y": 340,
3075
3075
  "wires": [
3076
3076
  [
@@ -3114,13 +3114,13 @@
3114
3114
  "name": "debug 22",
3115
3115
  "active": true,
3116
3116
  "tosidebar": true,
3117
- "console": false,
3117
+ "console": true,
3118
3118
  "tostatus": true,
3119
3119
  "complete": "payload",
3120
3120
  "targetType": "msg",
3121
3121
  "statusVal": "payload",
3122
3122
  "statusType": "auto",
3123
- "x": 700,
3123
+ "x": 710,
3124
3124
  "y": 500,
3125
3125
  "wires": []
3126
3126
  },
@@ -3152,5 +3152,115 @@
3152
3152
  "d376945f7d6314f9"
3153
3153
  ]
3154
3154
  ]
3155
+ },
3156
+ {
3157
+ "id": "448a23fd99b4e52a",
3158
+ "type": "hb-event",
3159
+ "z": "92f59d974b9c8a86",
3160
+ "name": "Side door",
3161
+ "Homebridge": "homebridge",
3162
+ "Manufacturer": "Eufy",
3163
+ "Service": "MotionSensor",
3164
+ "device": "homebridge0E:89:A7:DA:D3:21EufySide door00000085",
3165
+ "conf": "7e647d67.f33acc",
3166
+ "sendInitialState": true,
3167
+ "x": 100,
3168
+ "y": 420,
3169
+ "wires": [
3170
+ [
3171
+ "943911317b27b4bc",
3172
+ "5b0570544efae122"
3173
+ ]
3174
+ ]
3175
+ },
3176
+ {
3177
+ "id": "5b0570544efae122",
3178
+ "type": "switch",
3179
+ "z": "92f59d974b9c8a86",
3180
+ "name": "",
3181
+ "property": "payload.MotionDetected",
3182
+ "propertyType": "msg",
3183
+ "rules": [
3184
+ {
3185
+ "t": "eq",
3186
+ "v": "1",
3187
+ "vt": "num"
3188
+ }
3189
+ ],
3190
+ "checkall": "true",
3191
+ "repair": false,
3192
+ "outputs": 1,
3193
+ "x": 330,
3194
+ "y": 420,
3195
+ "wires": [
3196
+ [
3197
+ "7840c24c88d831cc"
3198
+ ]
3199
+ ]
3200
+ },
3201
+ {
3202
+ "id": "7840c24c88d831cc",
3203
+ "type": "change",
3204
+ "z": "92f59d974b9c8a86",
3205
+ "name": "",
3206
+ "rules": [
3207
+ {
3208
+ "t": "set",
3209
+ "p": "payload",
3210
+ "pt": "msg",
3211
+ "to": "",
3212
+ "tot": "date"
3213
+ }
3214
+ ],
3215
+ "action": "",
3216
+ "property": "",
3217
+ "from": "",
3218
+ "to": "",
3219
+ "reg": false,
3220
+ "x": 540,
3221
+ "y": 420,
3222
+ "wires": [
3223
+ [
3224
+ "389516e4379cfcc8"
3225
+ ]
3226
+ ]
3227
+ },
3228
+ {
3229
+ "id": "389516e4379cfcc8",
3230
+ "type": "hb-control",
3231
+ "z": "92f59d974b9c8a86",
3232
+ "name": "Side door",
3233
+ "Homebridge": "homebridge",
3234
+ "Manufacturer": "Eufy",
3235
+ "Service": "CameraRTPStreamManagement",
3236
+ "device": "homebridge0E:89:A7:DA:D3:21EufySide door00000110",
3237
+ "conf": "7e647d67.f33acc",
3238
+ "outputs": 1,
3239
+ "x": 720,
3240
+ "y": 420,
3241
+ "wires": [
3242
+ [
3243
+ "1c18c4d5c4cd94db"
3244
+ ]
3245
+ ]
3246
+ },
3247
+ {
3248
+ "id": "2802a70d3cd5570b",
3249
+ "type": "hb-event",
3250
+ "z": "92f59d974b9c8a86",
3251
+ "name": "Canoe 5036",
3252
+ "Homebridge": "ECI-T24F2",
3253
+ "Manufacturer": "HikVision",
3254
+ "Service": "MotionSensor",
3255
+ "device": "ECI-T24F25C:EE:FE:4D:64:B4HikVisionCanoe 503600000085",
3256
+ "conf": "7e647d67.f33acc",
3257
+ "sendInitialState": true,
3258
+ "x": 130,
3259
+ "y": 600,
3260
+ "wires": [
3261
+ [
3262
+ "943911317b27b4bc"
3263
+ ]
3264
+ ]
3155
3265
  }
3156
3266
  ]