From b4b85fdb1751c2510402452bbc701fed093ad57a Mon Sep 17 00:00:00 2001 From: Ranlvor Date: Thu, 13 May 2021 18:44:09 +0200 Subject: [PATCH] uwap-home: add toggle for projector auto off --- config/uwap-home/index.js | 22 +++++++++++++++++++++- 1 file changed, 21 insertions(+), 1 deletion(-) diff --git a/config/uwap-home/index.js b/config/uwap-home/index.js index a023f5f..6aa466e 100644 --- a/config/uwap-home/index.js +++ b/config/uwap-home/index.js @@ -373,7 +373,21 @@ const config: Config = { type: types.string }, defaultValue: "0" - } + }, + tasmotaProjectorAutoOff: { + state: { + name: "tele/tasmota-projector/auto-off", + type: types.option({ OFF: "off", ON: "on" }) + }, + command: { + name: "cmnd/tasmota-projector/backlog", + type: types.option({ + off: "Rule2 off; RuleTimer1 0; Publish2 tele/tasmota-projector/auto-off OFF;", + on: "Rule2 on; Publish2 tele/tasmota-projector/auto-off ON;" + }) + }, + defaultValue: "on" + }, } ], controls: { @@ -860,6 +874,12 @@ const config: Config = { topic: "tasmotaProjectorState", text: "Ein/Ausschalten", icon: svg(icons.mdiPower) + }, + { + type: "toggle", + topic: "tasmotaProjectorAutoOff", + text: "Automatik", + icon: svg(icons.mdiAutoDownload) } ] },