homebridge-lgwebos-tv 4.2.3 → 4.2.5
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 +6 -0
- package/config.schema.json +11 -6
- package/package.json +2 -2
- package/src/lgwebossocket.js +7 -4
package/CHANGELOG.md
CHANGED
|
@@ -15,6 +15,12 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/)
|
|
|
15
15
|
- For plugin < v4.1.0 use Homebridge UI <= v5.5.0
|
|
16
16
|
- For plugin >= v4.1.0 use Homebridge UI >= v5.13.0
|
|
17
17
|
|
|
18
|
+
## [4.2.4] - (26.01.2026)
|
|
19
|
+
|
|
20
|
+
## Changes
|
|
21
|
+
|
|
22
|
+
- fix [#301](https://github.com/grzegorz914/homebridge-lgwebos-tv/pull/301)
|
|
23
|
+
|
|
18
24
|
## [4.2.3] - (23.01.2026)
|
|
19
25
|
|
|
20
26
|
## Changes
|
package/config.schema.json
CHANGED
|
@@ -1676,32 +1676,37 @@
|
|
|
1676
1676
|
"title": "Device Info",
|
|
1677
1677
|
"type": "boolean",
|
|
1678
1678
|
"default": true,
|
|
1679
|
-
"description": "This enable
|
|
1679
|
+
"description": "This enable log level device info, will display overall device info by every plugin restart"
|
|
1680
1680
|
},
|
|
1681
1681
|
"success": {
|
|
1682
1682
|
"title": "Success",
|
|
1683
1683
|
"type": "boolean",
|
|
1684
|
-
"default": true
|
|
1684
|
+
"default": true,
|
|
1685
|
+
"description": "This enable log level success"
|
|
1685
1686
|
},
|
|
1686
1687
|
"info": {
|
|
1687
1688
|
"title": "Info",
|
|
1688
1689
|
"type": "boolean",
|
|
1689
|
-
"default": false
|
|
1690
|
+
"default": false,
|
|
1691
|
+
"description": "This enable log level info"
|
|
1690
1692
|
},
|
|
1691
1693
|
"warn": {
|
|
1692
1694
|
"title": "Warn",
|
|
1693
1695
|
"type": "boolean",
|
|
1694
|
-
"default": true
|
|
1696
|
+
"default": true,
|
|
1697
|
+
"description": "This enable log level warn"
|
|
1695
1698
|
},
|
|
1696
1699
|
"error": {
|
|
1697
1700
|
"title": "Error",
|
|
1698
1701
|
"type": "boolean",
|
|
1699
|
-
"default": true
|
|
1702
|
+
"default": true,
|
|
1703
|
+
"description": "This enable log level error"
|
|
1700
1704
|
},
|
|
1701
1705
|
"debug": {
|
|
1702
1706
|
"title": "Debug",
|
|
1703
1707
|
"type": "boolean",
|
|
1704
|
-
"default": false
|
|
1708
|
+
"default": false,
|
|
1709
|
+
"description": "This enable log level debug"
|
|
1705
1710
|
}
|
|
1706
1711
|
}
|
|
1707
1712
|
},
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"displayName": "LG webOS TV",
|
|
3
3
|
"name": "homebridge-lgwebos-tv",
|
|
4
|
-
"version": "4.2.
|
|
4
|
+
"version": "4.2.5",
|
|
5
5
|
"description": "Homebridge plugin to control LG webOS TV.",
|
|
6
6
|
"license": "MIT",
|
|
7
7
|
"author": "grzegorz914",
|
|
@@ -34,7 +34,7 @@
|
|
|
34
34
|
"node": "^20 || ^22 || ^24 || ^25"
|
|
35
35
|
},
|
|
36
36
|
"dependencies": {
|
|
37
|
-
"mqtt": "^5.
|
|
37
|
+
"mqtt": "^5.15.0",
|
|
38
38
|
"ws": "^8.19.0",
|
|
39
39
|
"express": "^5.2.1"
|
|
40
40
|
},
|
package/src/lgwebossocket.js
CHANGED
|
@@ -94,6 +94,7 @@ class LgWebOsSocket extends EventEmitter {
|
|
|
94
94
|
}
|
|
95
95
|
this.socket = null;
|
|
96
96
|
this.socketConnected = false;
|
|
97
|
+
this.specializedSocketConnected = false;
|
|
97
98
|
this.cidCount = 0;
|
|
98
99
|
this.power = false;
|
|
99
100
|
this.screenState = 'Suspend';
|
|
@@ -365,8 +366,10 @@ class LgWebOsSocket extends EventEmitter {
|
|
|
365
366
|
}
|
|
366
367
|
|
|
367
368
|
//Request specjalized socket
|
|
368
|
-
|
|
369
|
-
|
|
369
|
+
if (!this.specializedSocketConnected) {
|
|
370
|
+
this.specializedSocketId = await this.getCid();
|
|
371
|
+
await this.send('request', ApiUrls.SocketUrl, undefined, this.specializedSocketId);
|
|
372
|
+
}
|
|
370
373
|
|
|
371
374
|
//Send initial power state
|
|
372
375
|
if (!this.power) {
|
|
@@ -468,7 +471,7 @@ class LgWebOsSocket extends EventEmitter {
|
|
|
468
471
|
this.tvInfo.productName = messageData.product_name;
|
|
469
472
|
this.tvInfo.deviceId = messageData.device_id;
|
|
470
473
|
this.tvInfo.firmwareRevision = `${messageData.major_ver}.${messageData.minor_ver}`;
|
|
471
|
-
this.tvInfo.webOS = Number(messageData.product_name.match(/\d+(\.\d+)?/)[0])
|
|
474
|
+
this.tvInfo.webOS = Number.isFinite(Number(messageData.product_name?.match(/\d+(\.\d+)?/)?.[0])) ? Number(messageData.product_name.match(/\d+(\.\d+)?/)[0]) : this.tvInfo.webOS;
|
|
472
475
|
|
|
473
476
|
await this.functions.saveData(this.devInfoFile, this.tvInfo);
|
|
474
477
|
|
|
@@ -949,4 +952,4 @@ class LgWebOsSocket extends EventEmitter {
|
|
|
949
952
|
}
|
|
950
953
|
}
|
|
951
954
|
}
|
|
952
|
-
export default LgWebOsSocket;
|
|
955
|
+
export default LgWebOsSocket;
|