homebridge-tasmota-control 0.4.9 → 0.4.10
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 +5 -0
- package/README.md +3 -1
- package/config.schema.json +48 -38
- package/index.js +10 -7
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -4,6 +4,11 @@ All notable changes to this project will be documented in this file.
|
|
|
4
4
|
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
|
|
5
5
|
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
|
|
6
6
|
|
|
7
|
+
## [0.4.10] - (23.08.2022)
|
|
8
|
+
## Changes
|
|
9
|
+
- added possibility to display log device info on every restart
|
|
10
|
+
- config schema updated
|
|
11
|
+
|
|
7
12
|
## [0.4.7] - (23.08.2022)
|
|
8
13
|
## Changes
|
|
9
14
|
- added display channel name instead device name
|
package/README.md
CHANGED
|
@@ -52,6 +52,7 @@ Homebridge plugin for Tasmota flashed devices.
|
|
|
52
52
|
| `passwd` | Here set the authorization *Password*. |
|
|
53
53
|
| `enableDebugMode` | This enable deep log in homebridge console. |
|
|
54
54
|
| `disableLogInfo` | This disable log info, all values and state will not be displayed in Homebridge log console. |
|
|
55
|
+
| `disableLogDeviceInfo` | If enabled, add ability to disable log device info by every connections device to the network. |
|
|
55
56
|
|
|
56
57
|
```json
|
|
57
58
|
{
|
|
@@ -65,7 +66,8 @@ Homebridge plugin for Tasmota flashed devices.
|
|
|
65
66
|
"passwd": "password",
|
|
66
67
|
"refreshInterval": 5,
|
|
67
68
|
"disableLogInfo": false,
|
|
68
|
-
"
|
|
69
|
+
"disableLogDeviceInfo": false,
|
|
70
|
+
"enableDebugMode": false
|
|
69
71
|
}
|
|
70
72
|
]
|
|
71
73
|
}
|
package/config.schema.json
CHANGED
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
"pluginType": "platform",
|
|
4
4
|
"singular": true,
|
|
5
5
|
"headerDisplay": "This plugin works with deevices flashed with Tasmota firmware. Devices are exposed to HomeKit as separate accessories and each needs to be manually paired.\n\n1. Open the Home <img src='https://user-images.githubusercontent.com/3979615/78010622-4ea1d380-738e-11ea-8a17-e6a465eeec35.png' height='16.42px'> app on your device.\n2. Tap the <img src='https://user-images.githubusercontent.com/3979615/78010869-9aed1380-738e-11ea-9644-9f46b3633026.png' height='16.42px'>.\n3. Tap *Add Accessory*, and select *I Don't Have a Code or Cannot Scan* or *More Options*.\n4. Select Your accessory and press add anyway.\n5. Enter the PIN or scan the QR code, this can be found in Homebridge UI or Homebridge logs.\n6. Complete the accessory setup.",
|
|
6
|
-
|
|
6
|
+
"footerDisplay": "For documentation please see [GitHub repository](https://github.com/grzegorz914/homebridge-tasmota-control).",
|
|
7
7
|
"schema": {
|
|
8
8
|
"type": "object",
|
|
9
9
|
"properties": {
|
|
@@ -20,7 +20,7 @@
|
|
|
20
20
|
"required": true
|
|
21
21
|
},
|
|
22
22
|
"host": {
|
|
23
|
-
"title": "IP
|
|
23
|
+
"title": "IP address",
|
|
24
24
|
"type": "string",
|
|
25
25
|
"default": "192.168.1.61",
|
|
26
26
|
"required": true,
|
|
@@ -53,7 +53,7 @@
|
|
|
53
53
|
"required": true
|
|
54
54
|
},
|
|
55
55
|
"enableDebugMode": {
|
|
56
|
-
"title": "Enable
|
|
56
|
+
"title": "Enable debug mode",
|
|
57
57
|
"type": "boolean",
|
|
58
58
|
"default": false,
|
|
59
59
|
"description": "This enable debug mode.",
|
|
@@ -65,46 +65,56 @@
|
|
|
65
65
|
"default": false,
|
|
66
66
|
"description": "This disable log info, all values and state will not be displayed in Homebridge log console.",
|
|
67
67
|
"required": false
|
|
68
|
+
},
|
|
69
|
+
"disableLogDeviceInfo": {
|
|
70
|
+
"title": "Disable log device info",
|
|
71
|
+
"type": "boolean",
|
|
72
|
+
"default": false,
|
|
73
|
+
"description": "This disable log device info by every connections device to the network.",
|
|
74
|
+
"required": false
|
|
68
75
|
}
|
|
69
76
|
}
|
|
70
77
|
}
|
|
71
78
|
}
|
|
72
79
|
}
|
|
73
80
|
},
|
|
74
|
-
"layout": [
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
"
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
"
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
"
|
|
81
|
+
"layout": [
|
|
82
|
+
{
|
|
83
|
+
"key": "devices",
|
|
84
|
+
"type": "tabarray",
|
|
85
|
+
"title": "{{ value.name || 'new device' }}",
|
|
86
|
+
"items": [
|
|
87
|
+
"devices[].name",
|
|
88
|
+
"devices[].host",
|
|
89
|
+
"devices[].auth",
|
|
90
|
+
{
|
|
91
|
+
"key": "devices[]",
|
|
92
|
+
"type": "section",
|
|
93
|
+
"title": "Authorization",
|
|
94
|
+
"expandable": true,
|
|
95
|
+
"expanded": false,
|
|
96
|
+
"items": [
|
|
97
|
+
"devices[].user",
|
|
98
|
+
"devices[].passwd"
|
|
99
|
+
],
|
|
100
|
+
"condition": {
|
|
101
|
+
"functionBody": "return model.devices[arrayIndices].auth === true;"
|
|
102
|
+
}
|
|
103
|
+
},
|
|
104
|
+
{
|
|
105
|
+
"key": "devices[]",
|
|
106
|
+
"type": "section",
|
|
107
|
+
"title": "Advanced Settings",
|
|
108
|
+
"expandable": true,
|
|
109
|
+
"expanded": false,
|
|
110
|
+
"items": [
|
|
111
|
+
"devices[].enableDebugMode",
|
|
112
|
+
"devices[].disableLogInfo",
|
|
113
|
+
"devices[].disableLogDeviceInfo",
|
|
114
|
+
"devices[].refreshInterval"
|
|
115
|
+
]
|
|
94
116
|
}
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
"type": "section",
|
|
99
|
-
"title": "Advanced Settings",
|
|
100
|
-
"expandable": true,
|
|
101
|
-
"expanded": false,
|
|
102
|
-
"items": [
|
|
103
|
-
"devices[].enableDebugMode",
|
|
104
|
-
"devices[].disableLogInfo",
|
|
105
|
-
"devices[].refreshInterval"
|
|
106
|
-
]
|
|
107
|
-
}
|
|
108
|
-
]
|
|
109
|
-
}]
|
|
117
|
+
]
|
|
118
|
+
}
|
|
119
|
+
]
|
|
110
120
|
}
|
package/index.js
CHANGED
|
@@ -80,6 +80,7 @@ class tasmotaDevice {
|
|
|
80
80
|
this.refreshInterval = config.refreshInterval || 5;
|
|
81
81
|
this.enableDebugMode = config.enableDebugMode || false;
|
|
82
82
|
this.disableLogInfo = config.disableLogInfo || false;
|
|
83
|
+
this.disableLogDeviceInfo = config.disableLogDeviceInfo || false;
|
|
83
84
|
|
|
84
85
|
//get Device info
|
|
85
86
|
this.manufacturer = 'Tasmota';
|
|
@@ -133,13 +134,15 @@ class tasmotaDevice {
|
|
|
133
134
|
const addressMac = deviceInfo.data.StatusNET.Mac;
|
|
134
135
|
const firmwareRevision = deviceInfo.data.StatusFWR.Version;
|
|
135
136
|
|
|
136
|
-
this.
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
137
|
+
if (!this.disableLogDeviceInfo) {
|
|
138
|
+
this.log(`----- ${this.name} -----`);
|
|
139
|
+
this.log(`Manufacturer: ${this.manufacturer}`);
|
|
140
|
+
this.log(`Hardware: ${modelName}`);
|
|
141
|
+
this.log(`Serialnr: ${addressMac}`);
|
|
142
|
+
this.log(`Firmware: ${firmwareRevision}`);
|
|
143
|
+
this.log(`Channels: ${friendlyNameCount}`);
|
|
144
|
+
this.log(`----------------------------------`);
|
|
145
|
+
};
|
|
143
146
|
|
|
144
147
|
this.modelName = modelName;
|
|
145
148
|
this.serialNumber = addressMac;
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"displayName": "Tasmota Control",
|
|
3
3
|
"name": "homebridge-tasmota-control",
|
|
4
|
-
"version": "0.4.
|
|
4
|
+
"version": "0.4.10",
|
|
5
5
|
"description": "Homebridge plugin (https://github.com/homebridge/homebridge) to control Tasmota flashed devices.",
|
|
6
6
|
"license": "MIT",
|
|
7
7
|
"author": "grzegorz914",
|