In case somebody finds this lokking for HomePilot integration: My solution with the latest Firmware for HP (5.0.xx). Thanks to @rossko57 for directing my nose to the working solution…
Items:
Rollershutter RollladenWZSL "Süd Links" (GRollAll,GRollWZ,GRollWZSL) {http="<[homepilotCache:20000:JSONPATH($.devices[?(@.did==10001)].statusesMap.Position)] "}
Rollershutter RollladenWZSR "Süd Rechts" (GRollAll,GRollWZ,GRollWZSR) {http="<[homepilotCache:20000:JSONPATH($.devices[?(@.did==10002)].statusesMap.Position)] "}
Rollershutter RollladenWZSML "Süd Mitte Links" (GRollAll,GRollWZ,GRollWZSL) {http="<[homepilotCache:20000:JSONPATH($.devices[?(@.did==10004)].statusesMap.Position)] "}
Rollershutter RollladenWZSMR "Süd Mitte Rechts" (GRollAll,GRollWZ,GRollWZSR) {http="<[homepilotCache:20000:JSONPATH($.devices[?(@.did==10005)].statusesMap.Position)] "}
Rollershutter RollladenWZWR "West Rechts" (GRollAll,GRollWZ,GRollWZW) {http="<[homepilotCache:20000:JSONPATH($.devices[?(@.did==10006)].statusesMap.Position)] "}
Rollershutter RollladenWZWL "West Links" (GRollAll,GRollWZ,GRollWZW) {http="<[homepilotCache:20000:JSONPATH($.devices[?(@.did==10007)].statusesMap.Position)] "}
Rollershutter RollladenSZR "Schlafzimmer Rechts" (GRollAll,GRollOG,GRollSZ) {http="<[homepilotCache:20000:JSONPATH($.devices[?(@.did==10008)].statusesMap.Position)] "}
Rollershutter RollladenSZL "Schlafzimmer Links" (GRollAll,GRollOG,GRollSZ) {http="<[homepilotCache:20000:JSONPATH($.devices[?(@.did==10009)].statusesMap.Position)] "}
Rollershutter RollladenSZA "Schlafzimmer Alex" (GRollAll,GRollOG) {http="<[homepilotCache:20000:JSONPATH($.devices[?(@.did==10010)].statusesMap.Position)] "}
Rule:
//send updates to Home Pilot
rule "GetRollershutterUpdate"
when
Member of GRollAll received command
then
logDebug("rolershutter","rolershutter " + triggeringItem.name + " recieved update" + receivedCommand )
var String myUrl = ""
switch(triggeringItem.name) {
case "RollladenWZSL": { myUrl = "http://homepilot/devices/10001"}
case "RollladenWZSR": { myUrl = "http://homepilot/devices/10002"}
case "RollladenWZSML": { myUrl = "http://homepilot/devices/10004"}
case "RollladenWZSMR": { myUrl = "http://homepilot/devices/10005"}
case "RollladenWZWR": { myUrl = "http://homepilot/devices/10006"}
case "RollladenWZWL": { myUrl = "http://homepilot/devices/10007"}
case "RollladenSZR": { myUrl = "http://homepilot/devices/10008"}
case "RollladenSZL": { myUrl = "http://homepilot/devices/10009"}
case "RollladenSZA": { myUrl = "http://homepilot/devices/10010"}
}
var String myData = '{"name":"GOTO_POS_CMD","value":"' + receivedCommand + '"}'
logDebug("rolershutter","Sending put "+ myData + " to " + myUrl)
sendHttpPutRequest(myUrl, "application/x-www-form-urlencoded", myData)
end
Service config in http.cfg
#Homepilot
homepilotCache.url=http://homepilot/v4/devices
homepilotCache.updateInterval=20000