mirror of
https://github.com/Koenkk/zigbee2mqtt.git
synced 2026-08-24 19:50:12 +00:00
Add option to enable livolo code. #592
This commit is contained in:
+8
-3
@@ -22,7 +22,7 @@ const ExtensionAvailability = require('./extension/availability');
|
||||
const ExtensionBind = require('./extension/bind');
|
||||
const ExtensionCoordinatorGroup = require('./extension/coordinatorGroup');
|
||||
const ExtensionReporting = require('./extension/reporting');
|
||||
// const ExtensionPollLivoloSwitch = require('./extension/pollLivoloSwitch');
|
||||
const ExtensionPollLivoloSwitch = require('./extension/pollLivoloSwitch');
|
||||
|
||||
class Controller {
|
||||
constructor() {
|
||||
@@ -49,8 +49,6 @@ class Controller {
|
||||
new ExtensionBind(this.zigbee, this.mqtt, this.state, this.publishEntityState),
|
||||
new ExtensionCoordinatorGroup(this.zigbee, this.mqtt, this.state, this.publishEntityState),
|
||||
new ExtensionReporting(this.zigbee, this.mqtt, this.state, this.publishEntityState),
|
||||
// https://github.com/Koenkk/zigbee2mqtt/issues/592
|
||||
// new ExtensionPollLivoloSwitch(this.zigbee, this.mqtt, this.state, this.publishEntityState),
|
||||
];
|
||||
|
||||
if (settings.get().homeassistant) {
|
||||
@@ -70,6 +68,13 @@ class Controller {
|
||||
this.zigbee, this.mqtt, this.state, this.publishEntityState
|
||||
));
|
||||
}
|
||||
|
||||
if (settings.get().experimental.livolo) {
|
||||
// https://github.com/Koenkk/zigbee2mqtt/issues/592
|
||||
this.extensions.push(new ExtensionPollLivoloSwitch(
|
||||
this.zigbee, this.mqtt, this.state, this.publishEntityState
|
||||
));
|
||||
}
|
||||
}
|
||||
|
||||
onMQTTConnected() {
|
||||
|
||||
@@ -12,6 +12,9 @@ const defaults = {
|
||||
},
|
||||
groups: {},
|
||||
device_options: {},
|
||||
experimental: {
|
||||
livolo: false,
|
||||
},
|
||||
advanced: {
|
||||
log_directory: path.join(data.getPath(), 'log', '%TIMESTAMP%'),
|
||||
log_level: process.env.DEBUG ? 'debug' : 'info',
|
||||
|
||||
Reference in New Issue
Block a user