homebridge-texecom-full 4.2.6-beta.2 → 4.2.6
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 +0 -8
- package/config.schema.json +1 -3
- package/index.js +24 -7
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -2,14 +2,6 @@
|
|
|
2
2
|
|
|
3
3
|
This change log documents all release versions of homebridge-texecom
|
|
4
4
|
|
|
5
|
-
### 4.2.6-beta.2 (2025-01-22)
|
|
6
|
-
|
|
7
|
-
- **FIX** - Removed carbondioxide
|
|
8
|
-
|
|
9
|
-
### 4.2.6-beta.0 (2025-01-21)
|
|
10
|
-
|
|
11
|
-
- **TWEAK** - House keeping.
|
|
12
|
-
- **FIX** - Added carbonmonoxide and dioxide to config.schema.
|
|
13
5
|
|
|
14
6
|
### 4.2.5 (2025-01-03)
|
|
15
7
|
|
package/config.schema.json
CHANGED
package/index.js
CHANGED
|
@@ -13,6 +13,7 @@ class ResponseEmitter extends EventEmitter { }
|
|
|
13
13
|
const responseEmitter = new ResponseEmitter();
|
|
14
14
|
|
|
15
15
|
const LogUtil = require('./util/logutil');
|
|
16
|
+
const { platform } = require("os");
|
|
16
17
|
|
|
17
18
|
var areas_armed = []; // Creates an empty array, which can later grow dynamically
|
|
18
19
|
|
|
@@ -234,19 +235,35 @@ TexecomPlatform.prototype = {
|
|
|
234
235
|
responseEmitter.emit('data', data);
|
|
235
236
|
processData(data);
|
|
236
237
|
});
|
|
238
|
+
|
|
239
|
+
connection.on('timeout', () => {
|
|
240
|
+
platform.log.error('Connection attempt timed out.');
|
|
241
|
+
connection.destroy(); // prevent crash
|
|
242
|
+
});
|
|
243
|
+
|
|
244
|
+
connection.on('error', (err) => {
|
|
245
|
+
platform.log.error(`Socket error: ${err.message}`);
|
|
246
|
+
});
|
|
247
|
+
|
|
237
248
|
connection.on('end', function () {
|
|
238
249
|
platform.log.log('IP connection ended');
|
|
239
250
|
});
|
|
240
251
|
|
|
241
252
|
connection.on('close', function () {
|
|
242
253
|
platform.log.log('IP connection closed');
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
|
|
246
|
-
|
|
247
|
-
|
|
248
|
-
|
|
249
|
-
|
|
254
|
+
|
|
255
|
+
setTimeout(() => {
|
|
256
|
+
platform.log.log('Attempting reconnect...');
|
|
257
|
+
|
|
258
|
+
try {
|
|
259
|
+
connection = net.createConnection(platform.ip_port, platform.ip_address, function () {
|
|
260
|
+
platform.log.log('Re-connected after loss of connection');
|
|
261
|
+
});
|
|
262
|
+
} catch (err) {
|
|
263
|
+
platform.log.error(err);
|
|
264
|
+
}
|
|
265
|
+
}, 10000);
|
|
266
|
+
|
|
250
267
|
});
|
|
251
268
|
this.texecomConnection = connection;
|
|
252
269
|
} else {
|
package/package.json
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
"displayName": "Homebridge Texecom",
|
|
3
3
|
"name": "homebridge-texecom-full",
|
|
4
4
|
"description": "A plugin for homebridge to integrate Texecom Premier Elite alarm systems into HomeKit",
|
|
5
|
-
"version": "4.2.6
|
|
5
|
+
"version": "4.2.6",
|
|
6
6
|
"author": {
|
|
7
7
|
"name": "Chris Posthumus",
|
|
8
8
|
"email": "chris.posthumus@gmail.com"
|