lisa-box
Version:
Home automation system L.I.S.A.
18 lines • 564 B
JavaScript
;
Object.defineProperty(exports, "__esModule", { value: true });
const common_1 = require("@fabrix/fabrix/dist/common");
const LIRC = require('lisa-lirc');
class IRService extends common_1.FabrixService {
init() {
return LIRC.init().catch(err => this.log.error(err));
}
send(remote, action) {
return new Promise((resolve, reject) => {
LIRC.irsend.send_once(remote, action, () => {
resolve();
});
});
}
}
exports.IRService = IRService;
//# sourceMappingURL=IRService.js.map