homebridge-easy-mqtt 1.4.0-beta.8 → 1.4.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 +20 -6
- package/README.md +237 -22
- package/config.schema.json +1523 -71
- package/dist/accessory/abstract/base.js +5 -5
- package/dist/accessory/abstract/base.js.map +1 -1
- package/dist/accessory/abstract/common.d.ts +43 -0
- package/dist/accessory/abstract/common.js +172 -0
- package/dist/accessory/abstract/common.js.map +1 -0
- package/dist/accessory/abstract/helper.d.ts +1 -0
- package/dist/accessory/abstract/helper.js +21 -2
- package/dist/accessory/abstract/helper.js.map +1 -1
- package/dist/accessory/abstract/mqtt.d.ts +15 -26
- package/dist/accessory/abstract/mqtt.js +26 -143
- package/dist/accessory/abstract/mqtt.js.map +1 -1
- package/dist/accessory/addons/addon.d.ts +24 -0
- package/dist/accessory/addons/addon.js +52 -0
- package/dist/accessory/addons/addon.js.map +1 -0
- package/dist/accessory/addons/filter.d.ts +11 -0
- package/dist/accessory/addons/filter.js +37 -0
- package/dist/accessory/addons/filter.js.map +1 -0
- package/dist/accessory/button.d.ts +10 -0
- package/dist/accessory/button.js +43 -0
- package/dist/accessory/button.js.map +1 -0
- package/dist/accessory/climate/active.js +14 -8
- package/dist/accessory/climate/active.js.map +1 -1
- package/dist/accessory/climate/fan2.d.ts +20 -0
- package/dist/accessory/climate/fan2.js +122 -0
- package/dist/accessory/climate/fan2.js.map +1 -0
- package/dist/accessory/climate/heaterCooler.js +4 -2
- package/dist/accessory/climate/heaterCooler.js.map +1 -1
- package/dist/accessory/climate/purifier.js +5 -3
- package/dist/accessory/climate/purifier.js.map +1 -1
- package/dist/accessory/climate/temperatureControl.d.ts +1 -1
- package/dist/accessory/climate/temperatureControl.js +10 -8
- package/dist/accessory/climate/temperatureControl.js.map +1 -1
- package/dist/accessory/climate/thermostat.js +8 -8
- package/dist/accessory/climate/thermostat.js.map +1 -1
- package/dist/accessory/garage.d.ts +17 -0
- package/dist/accessory/garage.js +110 -0
- package/dist/accessory/garage.js.map +1 -0
- package/dist/accessory/lock.d.ts +2 -2
- package/dist/accessory/lock.js +3 -3
- package/dist/accessory/lock.js.map +1 -1
- package/dist/accessory/onoff/lightbulb.js +9 -4
- package/dist/accessory/onoff/lightbulb.js.map +1 -1
- package/dist/accessory/onoff/onoff.js +1 -1
- package/dist/accessory/onoff/onoff.js.map +1 -1
- package/dist/accessory/onoff/outlet.js +1 -1
- package/dist/accessory/onoff/outlet.js.map +1 -1
- package/dist/accessory/position/blind.d.ts +10 -0
- package/dist/accessory/position/blind.js +22 -0
- package/dist/accessory/position/blind.js.map +1 -0
- package/dist/accessory/position/position.d.ts +14 -0
- package/dist/accessory/position/position.js +88 -0
- package/dist/accessory/position/position.js.map +1 -0
- package/dist/accessory/security.js +4 -4
- package/dist/accessory/security.js.map +1 -1
- package/dist/accessory/sensor/air.d.ts +14 -0
- package/dist/accessory/sensor/air.js +96 -0
- package/dist/accessory/sensor/air.js.map +1 -0
- package/dist/accessory/sensor/carbonDioxide.js +3 -3
- package/dist/accessory/sensor/carbonDioxide.js.map +1 -1
- package/dist/accessory/sensor/carbonMonoxide.js +3 -3
- package/dist/accessory/sensor/carbonMonoxide.js.map +1 -1
- package/dist/accessory/sensor/contact.js +1 -1
- package/dist/accessory/sensor/contact.js.map +1 -1
- package/dist/accessory/sensor/humidity.js +1 -1
- package/dist/accessory/sensor/humidity.js.map +1 -1
- package/dist/accessory/sensor/leak.js +1 -1
- package/dist/accessory/sensor/leak.js.map +1 -1
- package/dist/accessory/sensor/light.js +1 -1
- package/dist/accessory/sensor/light.js.map +1 -1
- package/dist/accessory/sensor/motion.js +1 -1
- package/dist/accessory/sensor/motion.js.map +1 -1
- package/dist/accessory/sensor/occupancy.js +1 -1
- package/dist/accessory/sensor/occupancy.js.map +1 -1
- package/dist/accessory/sensor/sensor.js +4 -4
- package/dist/accessory/sensor/sensor.js.map +1 -1
- package/dist/accessory/sensor/smoke.js +1 -1
- package/dist/accessory/sensor/smoke.js.map +1 -1
- package/dist/accessory/sensor/temperature.js +1 -1
- package/dist/accessory/sensor/temperature.js.map +1 -1
- package/dist/accessory/valve.js +7 -7
- package/dist/accessory/valve.js.map +1 -1
- package/dist/homebridge/platform.js +4 -2
- package/dist/homebridge/platform.js.map +1 -1
- package/dist/homebridge-ui/public/index.html +1 -1
- package/dist/homebridge-ui/public/ui.js +1 -1
- package/dist/i18n/en.d.ts +183 -16
- package/dist/i18n/en.js +236 -69
- package/dist/i18n/en.js.map +1 -1
- package/dist/i18n/fr.d.ts +452 -18
- package/dist/i18n/fr.js +269 -2
- package/dist/i18n/fr.js.map +1 -1
- package/dist/i18n/i18n.d.ts +185 -17
- package/dist/i18n/i18n.js +6 -0
- package/dist/i18n/i18n.js.map +1 -1
- package/dist/i18n/ro.d.ts +347 -33
- package/dist/i18n/ro.js +164 -17
- package/dist/i18n/ro.js.map +1 -1
- package/dist/i18n/template.d.ts +183 -16
- package/dist/i18n/template.js +1 -1
- package/dist/i18n/vi.d.ts +1059 -0
- package/dist/i18n/vi.js +528 -0
- package/dist/i18n/vi.js.map +1 -0
- package/dist/model/enums.d.ts +35 -6
- package/dist/model/enums.js +34 -5
- package/dist/model/enums.js.map +1 -1
- package/dist/model/mqtt.d.ts +4 -3
- package/dist/model/mqtt.js +31 -12
- package/dist/model/mqtt.js.map +1 -1
- package/dist/model/types.d.ts +97 -4
- package/dist/tools/log.d.ts +7 -5
- package/dist/tools/log.js.map +1 -1
- package/dist/tools/properties.d.ts +11 -0
- package/dist/tools/properties.js +73 -0
- package/dist/tools/properties.js.map +1 -0
- package/dist/tools/temperature.d.ts +7 -3
- package/dist/tools/temperature.js +20 -9
- package/dist/tools/temperature.js.map +1 -1
- package/dist/tools/validation.d.ts +2 -0
- package/dist/tools/validation.js +11 -0
- package/dist/tools/validation.js.map +1 -1
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -2,20 +2,34 @@
|
|
|
2
2
|
|
|
3
3
|
All notable changes to homebridge-dummy will be documented in this file.
|
|
4
4
|
|
|
5
|
-
## 1.4.0
|
|
5
|
+
## 1.4.0 (2025-10-08)
|
|
6
6
|
|
|
7
7
|
### Added
|
|
8
|
-
-
|
|
8
|
+
- New accessory types:
|
|
9
|
+
- `Air Purifier`
|
|
10
|
+
- `Air Quality Sensor`
|
|
11
|
+
- `Fanv2`
|
|
12
|
+
- `GarageDoorOpener`
|
|
13
|
+
- `HeaterCooler`
|
|
14
|
+
- `LightSensor`
|
|
15
|
+
- `StatelessProgrammableSwitch`
|
|
16
|
+
- `Valve`
|
|
17
|
+
- `Window Covering`
|
|
9
18
|
- Broker, username, and password can be set via environment variables ([documentation](https://github.com/mpatfield/homebridge-easy-mqtt#environment-variables))
|
|
19
|
+
- Publish arbitrary MQTT messages on connect ([documentation] (https://github.com/mpatfield/homebridge-easy-mqtt#mqtt-onconnect))
|
|
20
|
+
- Lightbulb `maximumBrightness` to use values (i.e. 1, 2, 3) rather than a percentage for lightbulb brightness
|
|
10
21
|
- Traduceri în limba română. Mulțumesc, [@rursache](https://github.com/sponsors/rursache)!
|
|
22
|
+
- Bản dịch tiếng Việt. Cảm ơn [@khanhnd88](https://github.com/sponsors/khanhnd88)!
|
|
11
23
|
|
|
12
24
|
### Changed
|
|
25
|
+
- ⚠️ Accessory states are now saved across plugin/Homebridge restarts
|
|
26
|
+
- If you want to keep the old behavior, select the `Reset on Restart` option for each accessory you want to reset
|
|
27
|
+
- MQTT `options` JSON can now also include both client and publish options, such as `retain`
|
|
13
28
|
- Optimized MQTT connections by sharing across multiple accessories when possible
|
|
14
|
-
- Previously, every accessory had its own connection
|
|
29
|
+
- Previously, every accessory always had its own dedicated connection
|
|
15
30
|
- Better field validation in config UI (Thank you, [@justjam2013](https://github.com/sponsors/justjam2013) for teaching me this!)
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
- Config UI rendering issue when migrating deprecated fields
|
|
31
|
+
- Significant under-the-hood cleanup to speed future development
|
|
32
|
+
- Traductions françaises mises à jour. Merci, [@7ute](https://github.com/sponsors/7ute)!
|
|
19
33
|
|
|
20
34
|
### Notes
|
|
21
35
|
Would you like to see Homebridge Easy MQTT in your language? Please consider [getting involved](https://github.com/mpatfield/homebridge-easy-mqtt/issues/4). No coding experience required!
|
package/README.md
CHANGED
|
@@ -25,21 +25,30 @@ This plugin is designed to be a simple replacement for the fantastic [homebridge
|
|
|
25
25
|
|
|
26
26
|
**HomebridgeEasyMQTT** currently supports the following accessory types but will be expanded over time as more use cases are requested. If there is an accessory type you'd like to see supported, please [create an issue in GitHub](https://github.com/mpatfield/homebridge-easy-mqtt/issues/new/choose).
|
|
27
27
|
|
|
28
|
+
- `AirPurifier`
|
|
29
|
+
- `AirQualitySensor`
|
|
28
30
|
- `CarbonDioxideSensor`
|
|
29
31
|
- `CarbonMonoxideSensor`
|
|
30
32
|
- `ContactSensor`
|
|
33
|
+
- `Fanv2`
|
|
34
|
+
- `GarageDoorOpener`
|
|
35
|
+
- `HeaterCooler`
|
|
31
36
|
- `HumiditySensor`
|
|
32
37
|
- `LeakSensor`
|
|
33
38
|
- `Lightbulb`
|
|
39
|
+
- `LightSensor`
|
|
34
40
|
- `LockMechanism`
|
|
35
41
|
- `MotionSensor`
|
|
36
42
|
- `OccupancySensor`
|
|
37
43
|
- `Outlet`
|
|
38
44
|
- `SecuritySystem`
|
|
39
45
|
- `SmokeSensor`
|
|
46
|
+
- `StatelessProgrammableSwitch`
|
|
40
47
|
- `Switch`
|
|
41
48
|
- `TemperatureSensor`
|
|
42
49
|
- `Thermostat`
|
|
50
|
+
- `Valve`
|
|
51
|
+
- `WindowCovering`
|
|
43
52
|
|
|
44
53
|
## Configuration
|
|
45
54
|
|
|
@@ -64,7 +73,14 @@ Using the Homebridge Config UI is the easiest way to set up this plugin. However
|
|
|
64
73
|
"broker": "string",
|
|
65
74
|
"username": "string",
|
|
66
75
|
"password": "string",
|
|
67
|
-
"options": "string"
|
|
76
|
+
"options": "string",
|
|
77
|
+
"onConnect": [
|
|
78
|
+
{
|
|
79
|
+
"topic": "string",
|
|
80
|
+
"message": "string",
|
|
81
|
+
}
|
|
82
|
+
…
|
|
83
|
+
]
|
|
68
84
|
},
|
|
69
85
|
"customCharacteristics": [
|
|
70
86
|
{
|
|
@@ -75,6 +91,7 @@ Using the Homebridge Config UI is the easiest way to set up this plugin. However
|
|
|
75
91
|
}
|
|
76
92
|
…
|
|
77
93
|
],
|
|
94
|
+
"resetOnRestart": false,
|
|
78
95
|
"disableLogging": false,
|
|
79
96
|
… // See Topics & Values below for additional attributes for each accessory type
|
|
80
97
|
],
|
|
@@ -88,7 +105,7 @@ Required fields are marked with an asterisk (*)
|
|
|
88
105
|
### Info
|
|
89
106
|
- `id*` - A unique ID to identify this accessory. Changing this value will result in a new accessory.
|
|
90
107
|
- `name*` - The display name for the accessory in HomeKit
|
|
91
|
-
- `type*` - The type of accessory
|
|
108
|
+
- `type*` - The type of accessory. See list of currently supported types above.
|
|
92
109
|
- `group` - Items sharing the same group name will be grouped together in the Home app UI
|
|
93
110
|
- ⚠️ Changing the group name will require you to reconfigure any HomeKit scenes/automations for those accessories
|
|
94
111
|
- `manufacturer` - The accessory manufacturer which will display in HomeKit device details
|
|
@@ -101,6 +118,7 @@ Required fields are marked with an asterisk (*)
|
|
|
101
118
|
- `username` - Username
|
|
102
119
|
- `password` - Password
|
|
103
120
|
- `options` - See [MQTT Options](#mqtt-options) below
|
|
121
|
+
- `onConnect` - See [MQTT OnConnect](#mqtt-onconnect) below
|
|
104
122
|
|
|
105
123
|
#### Environment Variables
|
|
106
124
|
|
|
@@ -120,6 +138,8 @@ You may define topics using a JSONPath dot notation to assist the parser in find
|
|
|
120
138
|
|
|
121
139
|
As with topics, you will also need to populate the appropriate values based on the type. Note that while they are defined as strings, they will be auto-converted to the appropriate primitives (e.g. boolean or number) where appropriate.
|
|
122
140
|
|
|
141
|
+
These values are used for both determining current state and, where appropriate, publishing the new state to MQTT
|
|
142
|
+
|
|
123
143
|
### General Purpose
|
|
124
144
|
- `topicGetStatusActive` - Whether or not the accessory is connected/reachable
|
|
125
145
|
- `topicGetBatteryLow` - Wether or not the accessory has a low battery
|
|
@@ -128,12 +148,13 @@ As with topics, you will also need to populate the appropriate values based on t
|
|
|
128
148
|
- `valueBatteryLow` - Accessory has a low battery level
|
|
129
149
|
|
|
130
150
|
### On/Off Accessories
|
|
151
|
+
|
|
152
|
+
#### Lightbulb
|
|
153
|
+
- `maximumBrightness` - Set a maximum to use values (i.e. 1, 2, 3) rather than a percentage for brightness
|
|
131
154
|
- `topicGetOn*` - The current state of the outlet, i.e. on/off
|
|
132
155
|
- `topicSetOn*` - For setting the state of the outlet
|
|
133
156
|
- `valueOn*` - Turned on, e.g. "true", or "1", or "On"
|
|
134
157
|
- `valueOff*` - Turned off, e.g. "false", or "0", or "Off"
|
|
135
|
-
|
|
136
|
-
#### Lightbulb
|
|
137
158
|
- `topicGetBrightness` - The current brightness as a percent
|
|
138
159
|
- `topicSetBrightness` - For setting the brightness
|
|
139
160
|
- `topicGetColorTemperature` - The current color temperature of the lightbulb
|
|
@@ -144,15 +165,60 @@ As with topics, you will also need to populate the appropriate values based on t
|
|
|
144
165
|
- `topicSetSaturation` - For setting the saturation setting of the lightbulb
|
|
145
166
|
|
|
146
167
|
#### Outlet
|
|
168
|
+
- `topicGetOn*` - The current state of the outlet, i.e. on/off
|
|
169
|
+
- `topicSetOn*` - For setting the state of the outlet
|
|
170
|
+
- `valueOn*` - Turned on, e.g. "true", or "1", or "On"
|
|
171
|
+
- `valueOff*` - Turned off, e.g. "false", or "0", or "Off"
|
|
147
172
|
- `topicGetOutletInUse` - Whether or not the outlet is currently being used
|
|
148
173
|
- `valueOutletInUse` - Currently being used, e.g. "true", or "1", or "On"
|
|
149
174
|
|
|
150
175
|
#### Switch
|
|
151
|
-
-
|
|
176
|
+
- `topicGetOn*` - The current state of the outlet, i.e. on/off
|
|
177
|
+
- `topicSetOn*` - For setting the state of the outlet
|
|
178
|
+
- `valueOn*` - Turned on, e.g. "true", or "1", or "On"
|
|
179
|
+
- `valueOff*` - Turned off, e.g. "false", or "0", or "Off"
|
|
180
|
+
|
|
181
|
+
### Position Accessories
|
|
182
|
+
|
|
183
|
+
#### WindowCovering
|
|
184
|
+
- `maximumPosition` - Set a maximum to use values (i.e. 1, 2, 3) rather than a percentage for position
|
|
185
|
+
- `topicGetPositionState*` - Get position state (Decreasing, Increasing, Stopped)
|
|
186
|
+
- `topicGetCurrentPosition*` - Get current position percent
|
|
187
|
+
- `topicGetTargetPosition*` - Get target position percent
|
|
188
|
+
- `topicSetTargetPosition*` - Set target position percent
|
|
189
|
+
- `topicGetCurrentHorizontalTiltAngle` - Get current horizontal angle (-90° to 90°)
|
|
190
|
+
- `topicGetTargetHorizontalTiltAngle` - Get target horizontal angle (-90° to 90°)
|
|
191
|
+
- `topicSetTargetHorizontalTiltAngle` - Set target horizontal angle (-90° to 90°)
|
|
192
|
+
- `topicGetCurrentVerticalTiltAngle` - Get current vertical angle (-90° to 90°)
|
|
193
|
+
- `topicGetTargetVerticalTiltAngle` - Get target vertical angle (-90° to 90°)
|
|
194
|
+
- `topicSetTargetVerticalTiltAngle` - Set target vertical angle (-90° to 90°)
|
|
195
|
+
- `topicSetHoldPosition` - Set hold (true/false)
|
|
196
|
+
- `topicGetObstructionDetected` - Get obstruction detected
|
|
197
|
+
- `valuePositionDecreasing` - Closing
|
|
198
|
+
- `valuePositionIncreasing` - Opening
|
|
199
|
+
- `valuePositionStopped` - Stopped
|
|
200
|
+
- `valuePositionHold` - Hold
|
|
201
|
+
- `valuePositionResume` - Resume
|
|
202
|
+
- `valuePositionObstructed` - Obstruction detected
|
|
152
203
|
|
|
153
204
|
### Sensors
|
|
205
|
+
|
|
206
|
+
#### AirQualitySensor
|
|
207
|
+
- `topicGetAirQuality*` - Get air quality
|
|
208
|
+
- `topicGetNitrogenDioxideDensity` - Get nitrogen dioxide density in µg/m³
|
|
209
|
+
- `topicGetOzoneDensity` - Get ozone density in µg/m³
|
|
210
|
+
- `topicGetPM2_5Density` - Get PM2.5 density in µg/m³
|
|
211
|
+
- `topicGetPM10Density` - Get PM10 density in µg/m³
|
|
212
|
+
- `topicGetSulphurDioxideDensity` - Get sulphur dioxide density in µg/m³
|
|
213
|
+
- `topicGetVOCDensity` - Get VOC density in µg/m³
|
|
154
214
|
- `topicGetStatusFault` - Whether or not the sensor has a generic fault
|
|
155
215
|
- `topicGetStatusTampered` - Whether or not the sensor has been tampered with
|
|
216
|
+
- `valueAQExcellent` - Air quality excellent
|
|
217
|
+
- `valueAQGood` - Air quality good
|
|
218
|
+
- `valueAQFair` - Air quality fair
|
|
219
|
+
- `valueAQInferior` - Air quality inferior
|
|
220
|
+
- `valueAQPoor` - Air quality poor
|
|
221
|
+
- `valueAQUnknown` - Air quality unknown
|
|
156
222
|
- `valueFault` - Accessory has a fault
|
|
157
223
|
- `valueTampered` - Accessory has been tampered with
|
|
158
224
|
|
|
@@ -160,105 +226,223 @@ As with topics, you will also need to populate the appropriate values based on t
|
|
|
160
226
|
- `topicGetCarbonDioxideDetected*` - Whether or not the sensor has detected carbon dioxide
|
|
161
227
|
- `topicGetCarbonDioxideLevel` - The current carbon dioxide level
|
|
162
228
|
- `topicGetCarbonDioxidePeakLevel` - The peak carbon dioxide level
|
|
229
|
+
- `topicGetStatusFault` - Whether or not the sensor has a generic fault
|
|
230
|
+
- `topicGetStatusTampered` - Whether or not the sensor has been tampered with
|
|
163
231
|
- `valueCarbonDioxideDetected*` - Accessory has detected carbon dioxide
|
|
232
|
+
- `valueFault` - Accessory has a fault
|
|
233
|
+
- `valueTampered` - Accessory has been tampered with
|
|
164
234
|
|
|
165
235
|
#### CarbonMonoxideSensor
|
|
166
236
|
- `topicGetCarbonMonoxideDetected*` - Whether or not the sensor has detected carbon monoxide
|
|
167
237
|
- `topicGetCarbonMonoxideLevel` - The current carbon monoxide level
|
|
168
238
|
- `topicGetCarbonMonoxidePeakLevel` - The peak carbon monoxide level
|
|
239
|
+
- `topicGetStatusFault` - Whether or not the sensor has a generic fault
|
|
240
|
+
- `topicGetStatusTampered` - Whether or not the sensor has been tampered with
|
|
169
241
|
- `valueCarbonMonoxideDetected*` - Accessory has detected carbon monoxide
|
|
242
|
+
- `valueFault` - Accessory has a fault
|
|
243
|
+
- `valueTampered` - Accessory has been tampered with
|
|
170
244
|
|
|
171
245
|
#### ContactSensor
|
|
172
246
|
- `topicGetContactSensorState*` - Whether or not sensor has detected contact
|
|
247
|
+
- `topicGetStatusFault` - Whether or not the sensor has a generic fault
|
|
248
|
+
- `topicGetStatusTampered` - Whether or not the sensor has been tampered with
|
|
173
249
|
- `valueContactDetected*` - Accessory has detected contact
|
|
250
|
+
- `valueFault` - Accessory has a fault
|
|
251
|
+
- `valueTampered` - Accessory has been tampered with
|
|
174
252
|
|
|
175
253
|
### HumiditySensor
|
|
176
254
|
- `topicGetCurrentRelativeHumidity*` - The current relatively humidity
|
|
255
|
+
- `topicGetStatusFault` - Whether or not the sensor has a generic fault
|
|
256
|
+
- `topicGetStatusTampered` - Whether or not the sensor has been tampered with
|
|
257
|
+
- `valueFault` - Accessory has a fault
|
|
258
|
+
- `valueTampered` - Accessory has been tampered with
|
|
177
259
|
|
|
178
260
|
#### LeakSensor
|
|
179
261
|
- `topicGetLeakDetected*` - Whether or not sensor has detected a leak
|
|
262
|
+
- `topicGetStatusFault` - Whether or not the sensor has a generic fault
|
|
263
|
+
- `topicGetStatusTampered` - Whether or not the sensor has been tampered with
|
|
180
264
|
- `valueLeakDetected*` - Accessory has detected a leak
|
|
265
|
+
- `valueFault` - Accessory has a fault
|
|
266
|
+
- `valueTampered` - Accessory has been tampered with
|
|
181
267
|
|
|
182
268
|
#### LightSensor
|
|
183
269
|
- `topicGetCurrentAmbientLightLevel*` - The current light level in lux units
|
|
270
|
+
- `topicGetStatusFault` - Whether or not the sensor has a generic fault
|
|
271
|
+
- `topicGetStatusTampered` - Whether or not the sensor has been tampered with
|
|
272
|
+
- `valueFault` - Accessory has a fault
|
|
273
|
+
- `valueTampered` - Accessory has been tampered with
|
|
184
274
|
|
|
185
275
|
#### MotionSensor
|
|
186
276
|
- `topicGetMotionDetected*` - Whether or not sensor has detected motion
|
|
277
|
+
- `topicGetStatusFault` - Whether or not the sensor has a generic fault
|
|
278
|
+
- `topicGetStatusTampered` - Whether or not the sensor has been tampered with
|
|
187
279
|
- `valueMotionDetected*` - Accessory has detected motion
|
|
280
|
+
- `valueFault` - Accessory has a fault
|
|
281
|
+
- `valueTampered` - Accessory has been tampered with
|
|
188
282
|
|
|
189
283
|
#### OccupancySensor
|
|
190
284
|
- `topicGetOccupancyDetected*` - Whether or not sensor has detected occupancy
|
|
285
|
+
- `topicGetStatusFault` - Whether or not the sensor has a generic fault
|
|
286
|
+
- `topicGetStatusTampered` - Whether or not the sensor has been tampered with
|
|
191
287
|
- `valueOccupancyDetected*` - Accessory has detected occupancy
|
|
288
|
+
- `valueFault` - Accessory has a fault
|
|
289
|
+
- `valueTampered` - Accessory has been tampered with
|
|
192
290
|
|
|
193
291
|
#### SmokeSensor
|
|
194
292
|
- `topicGetSmokeDetected*` - Whether or not sensor has detected smoke
|
|
293
|
+
- `topicGetStatusFault` - Whether or not the sensor has a generic fault
|
|
294
|
+
- `topicGetStatusTampered` - Whether or not the sensor has been tampered with
|
|
195
295
|
- `valueSmokeDetected*` - Accessory has detected smoke
|
|
296
|
+
- `valueFault` - Accessory has a fault
|
|
297
|
+
- `valueTampered` - Accessory has been tampered with
|
|
196
298
|
|
|
197
299
|
#### TemperatureSensor
|
|
198
300
|
- `topicGetCurrentTemperature*` - The current temperature of the sensor
|
|
199
301
|
- `temperatureUnits` - The temperature units of the incoming value supplied by the sensor, `C` for Celsius (default) `F` for Fahrenheit
|
|
302
|
+
- `topicGetStatusFault` - Whether or not the sensor has a generic fault
|
|
303
|
+
- `topicGetStatusTampered` - Whether or not the sensor has been tampered with
|
|
304
|
+
- `valueFault` - Accessory has a fault
|
|
305
|
+
- `valueTampered` - Accessory has been tampered with
|
|
200
306
|
|
|
201
|
-
###
|
|
202
|
-
- `temperatureUnits` - The temperature units of the incoming value supplied by the thermostat, `C` for Celsius (default) `F` for Fahrenheit
|
|
203
|
-
- `topicGetCurrentTemperature*` - Get the current temperature
|
|
204
|
-
- `topicGetCoolingThresholdTemperature` - Get the cooling threshold temperature
|
|
205
|
-
- `topicSetCoolingThresholdTemperature` - Set the cooling threshold temparture
|
|
206
|
-
- `topicGetHeatingThresholdTemperature` - Get the heating threshold temperature
|
|
207
|
-
- `topicSetHeatingThresholdTemperature` - Set the heating threshold temperature
|
|
307
|
+
### Climate Controllers
|
|
208
308
|
|
|
209
309
|
#### Thermostat
|
|
310
|
+
- `temperatureUnits` - The temperature units of the incoming value supplied by the thermostat, `C` for Celsius (default) `F` for Fahrenheit
|
|
311
|
+
- `topicGetCurrentTemperature*` - Get the current temperature
|
|
210
312
|
- `topicGetCurrentHeatingCoolingState*` - Get the current mode (i.e. cooling, heating, off)
|
|
211
313
|
- `topicGetTargetHeatingCoolingState*` - Get the target mode (i.e. auto, cooling, heating, off)
|
|
212
314
|
- `topicSetTargetHeatingCoolingState*` - Set the target mode (i.e. auto, cooling, heating, off)
|
|
213
315
|
- `topicGetTargetTemperature*` - Get the target temperature
|
|
214
316
|
- `topicSetTargetTemperature*` - Set the target temperature
|
|
317
|
+
- `topicGetCoolingThresholdTemperature` - Get the cooling threshold temperature
|
|
318
|
+
- `topicSetCoolingThresholdTemperature` - Set the cooling threshold temparture
|
|
319
|
+
- `topicGetHeatingThresholdTemperature` - Get the heating threshold temperature
|
|
320
|
+
- `topicSetHeatingThresholdTemperature` - Set the heating threshold temperature
|
|
215
321
|
- `topicGetCurrentRelativeHumidity` - Get the current humidity
|
|
216
322
|
- `topicGetTargetRelativeHumidity` - Get the target humidity
|
|
217
323
|
- `topicSetTargetRelativeHumidity` - Set the target humidity
|
|
324
|
+
- `topicGetFilterChangeIndication` - Whether or not the filter needs to be changed. *Required if other filter topics are defined.
|
|
325
|
+
- `topicGetFilterLifeLevel` - Filter life remaining as a percentage
|
|
326
|
+
- `topicResetFilterIndication` - Used to reset the filter
|
|
218
327
|
- `valueModeAuto` - Auto mode
|
|
219
328
|
- `valueModeCool` - Cool mode
|
|
220
329
|
- `valueModeHeat` - Heat mode
|
|
221
330
|
- `valueModeOff` - Thermostat off
|
|
331
|
+
- `valueFilterChange` - Indicates that the filter needs to be changed. *Required if `topicGetFilterChangeIndication` is defined.
|
|
222
332
|
|
|
223
|
-
|
|
224
|
-
|
|
333
|
+
#### AirPurifier
|
|
334
|
+
- `maximumRotationSpeed` - Set a maximum to use values (i.e. 1, 2, 3) rather than a percentage for rotation speed
|
|
225
335
|
- `topicGetActive*` - Get whether or not the accessory is currently active
|
|
226
336
|
- `topicSetActive*` - Set whether or not the accessory is currently active
|
|
337
|
+
- `topicGetCurrentPurifierState*` - Get the current mode (i.e. inactive, idle, purifying)
|
|
338
|
+
- `topicGetTargetPurifierState*` - Get the target mode (i.e. auto, manual)
|
|
339
|
+
- `topicSetTargetPurifierState*` - Set the target mode (i.e. auto, manual)
|
|
227
340
|
- `topicGetLockPhysicalControls` - Get whether or not the physical controls are locked
|
|
228
341
|
- `topicSetLockPhysicalControls` - Set whether or not the physical controls are locked
|
|
229
342
|
- `topicGetRotationSpeed` - Get the rotation speed as a percentage
|
|
230
343
|
- `topicSetRotationSpeed` - Set the rotation speed as a percentage
|
|
231
344
|
- `topicGetSwingMode` - Get whether or not accessory is oscillating
|
|
232
345
|
- `topicSetSwingMode` - Set whether or not accessory is oscillating
|
|
346
|
+
- `topicGetFilterChangeIndication` - Whether or not the filter needs to be changed. *Required if other filter topics are defined.
|
|
347
|
+
- `topicGetFilterLifeLevel` - Filter life remaining as a percentage
|
|
348
|
+
- `topicResetFilterIndication` - Used to reset the filter
|
|
233
349
|
- `valueStateActive*` - Accessory is currently active
|
|
234
350
|
- `valueStateInactive*` - Accessory is currently inactive
|
|
351
|
+
- `valueModeAuto` - Auto target mode
|
|
352
|
+
- `valueModeIdle` - Idle mode
|
|
353
|
+
- `valueModeInactive` - Inactive mode
|
|
354
|
+
- `valueModeManual` - Manual target mode
|
|
355
|
+
- `valueModePurifying` - Purifying mode
|
|
235
356
|
- `valueControlLock` - Physical controls are locked
|
|
236
357
|
- `valueControlUnlock` - Physical controls are unlocked
|
|
237
358
|
- `valueSwingEnabled` - Accessory is oscillating
|
|
238
359
|
- `valueSwingDisabled` - Accessory is not oscillating
|
|
360
|
+
- `valueFilterChange` - Indicates that the filter needs to be changed. *Required if `topicGetFilterChangeIndication` is defined.
|
|
239
361
|
|
|
240
|
-
####
|
|
241
|
-
- `
|
|
242
|
-
- `
|
|
243
|
-
- `
|
|
244
|
-
- `
|
|
362
|
+
#### Fanv2
|
|
363
|
+
- `maximumRotationSpeed` - Set a maximum to use values (i.e. 1, 2, 3) rather than a percentage for rotation speed
|
|
364
|
+
- `topicGetActive*` - Get whether or not the accessory is currently active
|
|
365
|
+
- `topicSetActive*` - Set whether or not the accessory is currently active
|
|
366
|
+
- `topicGetCurrentFanState` - Get current fan mode (blowing, idle, inactive)
|
|
367
|
+
- `topicGetTargetFanState` - Get target fan mode (auto, manual)
|
|
368
|
+
- `topicSetTargetFanState` - Set target fan mode (auto, manual)
|
|
369
|
+
- `topicGetLockPhysicalControls` - Get whether or not the physical controls are locked
|
|
370
|
+
- `topicSetLockPhysicalControls` - Set whether or not the physical controls are locked
|
|
371
|
+
- `topicGetRotationDirection` - Get the fan rotation direction (clockwise, counter clockwise)
|
|
372
|
+
- `topicSetRotationDirection` - Set the fan rotation direction (clockwise, counter clockwise)
|
|
373
|
+
- `topicGetRotationSpeed` - Get the rotation speed as a percentage
|
|
374
|
+
- `topicSetRotationSpeed` - Set the rotation speed as a percentage
|
|
375
|
+
- `topicGetSwingMode` - Get whether or not accessory is oscillating
|
|
376
|
+
- `topicSetSwingMode` - Set whether or not accessory is oscillating
|
|
377
|
+
- `valueStateActive*` - Accessory is currently active
|
|
378
|
+
- `valueStateInactive*` - Accessory is currently inactive
|
|
379
|
+
- `valueModeBlowing` - Air blowing mode
|
|
245
380
|
- `valueModeIdle` - Idle mode
|
|
246
381
|
- `valueModeInactive` - Inactive mode
|
|
382
|
+
- `valueModeAuto` - Auto target mode
|
|
247
383
|
- `valueModeManual` - Manual target mode
|
|
248
|
-
- `
|
|
384
|
+
- `valueDirectionClockwise` - Rotating clockwise
|
|
385
|
+
- `valueDirectionCounterClockwise` - Rotating counter clockwise
|
|
386
|
+
- `valueControlLock` - Physical controls are locked
|
|
387
|
+
- `valueControlUnlock` - Physical controls are unlocked
|
|
388
|
+
- `valueSwingEnabled` - Accessory is oscillating
|
|
389
|
+
- `valueSwingDisabled` - Accessory is not oscillating
|
|
249
390
|
|
|
250
391
|
#### HeaterCooler
|
|
392
|
+
- `maximumRotationSpeed` - Set a maximum to use values (i.e. 1, 2, 3) rather than a percentage for rotation speed
|
|
393
|
+
- `temperatureUnits` - The temperature units of the incoming value supplied by the thermostat, `C` for Celsius (default) `F` for Fahrenheit
|
|
394
|
+
- `topicGetActive*` - Get whether or not the accessory is currently active
|
|
395
|
+
- `topicSetActive*` - Set whether or not the accessory is currently active
|
|
396
|
+
- `topicGetCurrentTemperature*` - Get the current temperature
|
|
251
397
|
- `topicGetCurrentHeaterCoolerState*` - Get the current mode (i.e. inactive, idle, heating, cooling)
|
|
252
398
|
- `topicGetTargetHeaterCoolerState*` - Get the target mode (i.e. auto, heat, cool)
|
|
253
399
|
- `topicSetTargetHeaterCoolerState*` - Set the target mode (i.e. auto, heat, cool)
|
|
400
|
+
- `topicGetCoolingThresholdTemperature` - Get the cooling threshold temperature
|
|
401
|
+
- `topicSetCoolingThresholdTemperature` - Set the cooling threshold temparture
|
|
402
|
+
- `topicGetHeatingThresholdTemperature` - Get the heating threshold temperature
|
|
403
|
+
- `topicSetHeatingThresholdTemperature` - Set the heating threshold temperature
|
|
404
|
+
- `topicGetLockPhysicalControls` - Get whether or not the physical controls are locked
|
|
405
|
+
- `topicSetLockPhysicalControls` - Set whether or not the physical controls are locked
|
|
406
|
+
- `topicGetRotationSpeed` - Get the rotation speed as a percentage
|
|
407
|
+
- `topicSetRotationSpeed` - Set the rotation speed as a percentage
|
|
408
|
+
- `topicGetSwingMode` - Get whether or not accessory is oscillating
|
|
409
|
+
- `topicSetSwingMode` - Set whether or not accessory is oscillating
|
|
410
|
+
- `topicGetFilterChangeIndication` - Whether or not the filter needs to be changed. *Required if other filter topics are defined.
|
|
411
|
+
- `topicGetFilterLifeLevel` - Filter life remaining as a percentage
|
|
412
|
+
- `topicResetFilterIndication` - Used to reset the filter
|
|
413
|
+
- `valueStateActive*` - Accessory is currently active
|
|
414
|
+
- `valueStateInactive*` - Accessory is currently inactive
|
|
254
415
|
- `valueModeAuto` - Mode is auto
|
|
255
416
|
- `valueModeCool` - Mode is cool/cooling
|
|
256
417
|
- `valueModeHeat` - Mode is heat/heating
|
|
257
418
|
- `valueModeIdle` - Mode is idle
|
|
258
419
|
- `valueModeInactive` - Mode is inactive
|
|
420
|
+
- `valueControlLock` - Physical controls are locked
|
|
421
|
+
- `valueControlUnlock` - Physical controls are unlocked
|
|
422
|
+
- `valueSwingEnabled` - Accessory is oscillating
|
|
423
|
+
- `valueSwingDisabled` - Accessory is not oscillating
|
|
424
|
+
- `valueFilterChange` - Indicates that the filter needs to be changed. *Required if `topicGetFilterChangeIndication` is defined.
|
|
259
425
|
|
|
260
426
|
### Others
|
|
261
427
|
|
|
428
|
+
#### GarageDoorOpener
|
|
429
|
+
- `topicGetCurrentDoorState*` - Current state of the garage door, i.e. open/opening/closed/closing/stopped
|
|
430
|
+
- `topicGetTargetDoorState*` - Target state of the garage door, i.e. open/closed
|
|
431
|
+
- `topicSetTargetDoorState*` - Set the target door state, i.e. open/closed
|
|
432
|
+
- `topicGetObstructionDetected*` - Whether or not the garage door is obstructed
|
|
433
|
+
- `topicGetCurrentLockState` - The current state of the garage lock, i.e. locked/unlocked
|
|
434
|
+
- `topicGetTargetLockState` - The target (i.e. desired) state of the garage lock
|
|
435
|
+
- `topicSetTargetLockState` - For setting the target (i.e. desired) state of the garage lock
|
|
436
|
+
- `valueDoorObstructed*` - Door is obstructed
|
|
437
|
+
- `valueDoorStateClosed` - Door is closed
|
|
438
|
+
- `valueDoorStateClosing` - Door is closing
|
|
439
|
+
- `valueDoorStateOpen` - Door is open
|
|
440
|
+
- `valueDoorStateOpening` - Door is opening
|
|
441
|
+
- `valueDoorStateStopped` - Door is stopped
|
|
442
|
+
- `valueLockStateJammed` - Door lock is jammed
|
|
443
|
+
- `valueLockStateSecured` - Door is locked
|
|
444
|
+
- `valueLockStateUnsecured` - Door is unlocked
|
|
445
|
+
|
|
262
446
|
#### LockMechanism
|
|
263
447
|
- `topicGetCurrentLockState*` - The current state of the lock, i.e. locked/unlocked
|
|
264
448
|
- `topicGetTargetLockState*` - The target (i.e. desired) state of the lock
|
|
@@ -281,6 +465,12 @@ As with topics, you will also need to populate the appropriate values based on t
|
|
|
281
465
|
- `valueFault` - Accessory has a fault
|
|
282
466
|
- `valueTampered` - Accessory has been tampered with
|
|
283
467
|
|
|
468
|
+
#### StatelessProgrammableSwitch
|
|
469
|
+
- `topicEventButtonPress` - Event for button press event
|
|
470
|
+
- `valueSinglePress` - Single press event
|
|
471
|
+
- `valueDoublePress` - Double press event
|
|
472
|
+
- `valueLongPress` - Long press event
|
|
473
|
+
|
|
284
474
|
#### Valve
|
|
285
475
|
- `valveType` - One of `GENERIC_VALVE` (default), `IRRIGATION`, `SHOWER_HEAD`, or `WATER_FAUCET`
|
|
286
476
|
- `topicGetValveActive*` - For getting whether or not the valve is active
|
|
@@ -313,10 +503,29 @@ You may also turn on additional logging if you'd like to see the MQTT messages p
|
|
|
313
503
|
|
|
314
504
|
## MQTT Options
|
|
315
505
|
|
|
316
|
-
You are able to pass in any arbitrary MQTT options via `mqtt.options` in the config. This can
|
|
506
|
+
You are able to pass in any arbitrary MQTT options via `mqtt.options` in the config. This can be a combination of [client options](https://github.com/mqttjs/MQTT.js?tab=readme-ov-file#mqttclientstreambuilder-options) and [publish options](https://github.com/mqttjs/MQTT.js?tab=readme-ov-file#mqttclientpublishtopic-message-options-callback). Just make sure the value provided is valid JSON. For example:
|
|
317
507
|
|
|
318
508
|
```
|
|
319
|
-
"options": "{ \"protocolVersion\": \"4\", \"clientId\": \"my-client-id\", \"
|
|
509
|
+
"options": "{ \"protocolVersion\": \"4\", \"clientId\": \"my-client-id\", \"retain\": true }"
|
|
510
|
+
```
|
|
511
|
+
|
|
512
|
+
## MQTT OnConnect
|
|
513
|
+
|
|
514
|
+
Accessories can be configured to publish any number of arbitratry messages to the MQTT server on connect. This can be useful to invoke accessories to give updates on their current status.
|
|
515
|
+
|
|
516
|
+
Each entry should have a topic and a message:
|
|
517
|
+
|
|
518
|
+
```
|
|
519
|
+
"onConnect": [
|
|
520
|
+
{
|
|
521
|
+
"topic": "some/arbitrary/topic",
|
|
522
|
+
"message": "connected",
|
|
523
|
+
},
|
|
524
|
+
{
|
|
525
|
+
"topic": "another/arbitrary/topic",
|
|
526
|
+
"message": "{ \"value\": \"can also be json\" }",
|
|
527
|
+
}
|
|
528
|
+
]
|
|
320
529
|
```
|
|
321
530
|
|
|
322
531
|
## JSONPaths
|
|
@@ -415,6 +624,12 @@ Due to the complexity, this was intentionally left out of the plugin config UI,
|
|
|
415
624
|
|
|
416
625
|
Since `customCharacteristics` is an array, you may define as many custom characteristics as you wish.
|
|
417
626
|
|
|
627
|
+
## Persistance
|
|
628
|
+
|
|
629
|
+
By default, all accessory values are saved and reloaded when the plugin restarts. However, you may override this behavior by selecting `Reset on Restart` option and accessories will be reset to defaults whenever the plugin or Homebridge restarts.
|
|
630
|
+
|
|
631
|
+
- `"resetOnRestart": true`
|
|
632
|
+
|
|
418
633
|
## Credits
|
|
419
634
|
|
|
420
635
|
[@arachnetech](https://github.com/arachnetech) for the fantastic [homebridge-mqttthing](https://github.com/arachnetech/homebridge-mqttthing) plugin which serves as the main inspiration for this project
|