Ich habe zum
Einschalten diese
Rule erstellt:
Code: Alles auswählen
triggers:
- id: "1"
configuration:
itemName: LichtKuche_Relay2_Output
state: ON
previousState: OFF
type: core.ItemStateChangeTrigger
conditions: []
actions:
- inputs: {}
id: "2"
configuration:
itemName: TPLinkHS100G_Betrieb
command: ON
type: core.ItemCommandAction
- inputs: {}
id: "3"
configuration:
type: application/javascript
script: >-
var HttpUtil = Java.type("org.openhab.core.io.net.http.HttpUtil")
var urlmessage = encodeURI("Lichtschalter ein")
HttpUtil.executeUrl("GET", "https://api.callmebot.com/whatsapp.php?phone=+49xxxxxxxx&text=This+is+a+test&apikey=xxxxxx&text=" + urlmessage , 2000)
type: script.ScriptAction
Das ist die
Rule zum
Ausschalten:
Code: Alles auswählen
triggers:
- id: "1"
configuration:
itemName: LichtKuche_Relay2_Output
state: OFF
previousState: ON
type: core.ItemStateChangeTrigger
conditions: []
actions:
- inputs: {}
id: "2"
configuration:
itemName: TPLinkHS100G_Betrieb
command: OFF
type: core.ItemCommandAction
- inputs: {}
id: "3"
configuration:
type: application/javascript
script: >
var HttpUtil = Java.type("org.openhab.core.io.net.http.HttpUtil")
var urlmessage = encodeURI("Lichtschalter aus")
HttpUtil.executeUrl("GET", "https://api.callmebot.com/whatsapp.php?phone=+49xxxxxx&text=This+is+a+test&apikey=xxxx&text=" + urlmessage , 2000)
type: script.ScriptAction
Die WhatsApp-Nachricht dient nur zur Fehlersuche.
Wenn ich direkt an der Weboberfläche den Schalter "LichtKuche_Relay2_Output" betätige wird die Regel sofort ausgeführt und das Licht sofort geschalten. Nur wenn ich den Schalter (Shelly 2.5) betätige dauert es über 10 Sec. Es scheint so, als ob der Shelly nur in sehr langen Zyklen abgefragt wird.
Der Shelly ist unter Things so konfiguriert:
Code: Alles auswählen
UID: shelly:shelly25-relay:7ab25d1a85
label: Licht Küche
thingTypeUID: shelly:shelly25-relay
configuration:
eventsCoIoT: true
deviceIp: 192.168.114.129
eventsSwitch: true
updateInterval: -60
eventsButton: true
eventsPush: false
Mit der Einstellung updateInterval: habe ich unterschiedliche Werte ausprobiert. Gefühlt verändert sich aber nichts.
Ich bin nun ratlos

.
Wie könnte ich denn weitersuchen?
Vielen Dank!
Tony