Hallo liebes Forum,
ich habe eine Markise, die ich bei zu starkem Wind einfahren möchte. Ich möchte aber nur den Fahrbefehl senden, wenn die Markise ausgefahren ist.
Ich sehe zwei Möglichkeiten, weiß aber nicht wie.
- Es gibt das Attribut “cover.markise.attribut.current_position”
- Es gibt den Zustand "cover.mark.original_state: “open”
Die Markise hat den State: open, bis diese vollständig geschlossen/ausgefahren ist, somit fällt das heraus.
Ich bekomme es aber nicht hin, dass ich als Ergebnis die “cover.markise.attribut.current_position” als Zahlenwert 100 für komplett eingefahren bzw. einen anderen erhalte:
[
{
"id": "45d34181a9f9c49a",
"type": "api-current-state",
"z": "22530f6a046f733c",
"name": "Prüfung, ob Markise Position 100 ist?",
"server": "9a63205d.785ca",
"version": 3,
"outputs": 2,
"halt_if": "$number($entities('cover.markise.current_position').state)",
"halt_if_type": "jsonata",
"halt_if_compare": "lt",
"entity_id": "cover.markise",
"state_type": "num",
"blockInputOverrides": false,
"outputProperties": [
{
"property": "payload",
"propertyType": "msg",
"value": "",
"valueType": "entityState"
},
{
"property": "data",
"propertyType": "msg",
"value": "",
"valueType": "entity"
},
{
"property": "a",
"propertyType": "global",
"value": "cover.markise.attributes.current_position'",
"valueType": "jsonata"
}
],
"for": "0",
"forType": "num",
"forUnits": "minutes",
"override_topic": false,
"state_location": "payload",
"override_payload": "msg",
"entity_location": "data",
"override_data": "msg",
"x": 370,
"y": 140,
"wires": [
[
"69fab9246a541cee"
],
[
"fecd2877a7ab505b"
]
]
},
{
"id": "9a63205d.785ca",
"type": "server",
"name": "Home Assistant",
"addon": true
}
]
Vielen Dank für Eure Hilfe