UNPKG

homebridge-tahoma

Version:

Sample Platform plugin for TaHoma and Cozytouch services (Somfy,Atlantic,Thermor,Sauter): https://github.com/dubocr/homebridge-tahoma

37 lines 1.42 kB
"use strict"; var __importDefault = (this && this.__importDefault) || function (mod) { return (mod && mod.__esModule) ? mod : { "default": mod }; }; Object.defineProperty(exports, "__esModule", { value: true }); const overkiz_client_1 = require("overkiz-client"); const HeatingSystem_1 = __importDefault(require("../HeatingSystem")); class AtlanticPassAPCBoiler extends HeatingSystem_1.default { registerMainService() { return this.registerSwitchService(); } getOnCommands(value) { return new overkiz_client_1.Command('setPassAPCOperatingMode', value ? 'heating' : 'stop'); } onStateChanged(name, value) { var _a, _b; switch (name) { case 'io:PassAPCOperatingModeState': switch (value) { case 'stop': (_a = this.on) === null || _a === void 0 ? void 0 : _a.updateValue(false); break; case 'heating': case 'drying': case 'cooling': (_b = this.on) === null || _b === void 0 ? void 0 : _b.updateValue(true); break; } break; default: super.onStateChanged(name, value); break; } } } exports.default = AtlanticPassAPCBoiler; //# sourceMappingURL=AtlanticPassAPCBoiler.js.map