homebridge-elero-stick
Version:
Elero funkstick for homebridge: https://github.com/ma-ku/homebridge-elero-stick
35 lines • 1.54 kB
JavaScript
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.EleroAccessory = void 0;
class EleroAccessory {
constructor(hap, log, platformConfig, motorConfig, uuid, stick, channel) {
this.services = [];
// This is a marker if we are moving the shutter ourselves. If not, it might have been
// controlled by a local switch and we will not interfere with that manual control
this.isMonitoring = false;
this.reportingInterval = 5000;
this.log = log;
this.hap = hap;
this.platformConfig = platformConfig;
this.name = motorConfig.name;
this.displayName = motorConfig.displayName || motorConfig.name;
this.uuid = uuid;
this.stick = stick;
this.channel = channel;
this.reportingInterval = platformConfig.defaultUpdateInterval;
this.informationService = new hap.Service.AccessoryInformation()
.setCharacteristic(hap.Characteristic.Manufacturer, "Elero")
.setCharacteristic(hap.Characteristic.Model, "Channel " + channel)
.setCharacteristic(hap.Characteristic.SerialNumber, stick.port + ":" + channel);
this.services.push(this.informationService);
}
/**
* This method is called directly after creation of this instance.
* It should return all services which should be added to the accessory.
*/
getServices() {
return this.services;
}
}
exports.EleroAccessory = EleroAccessory;
//# sourceMappingURL=elero-accessory.js.map