Implemented sensors for how many times the doors have been opened daily

This commit is contained in:
2022-12-10 16:53:58 -05:00
parent fd400e6326
commit ec26b1e85c

View File

@ -939,9 +939,7 @@
"0968727f2138ac62"
],
"x": 34,
"y": 779,
"w": 1432,
"h": 422
"y": 779
},
{
"id": "f55a52c40b8b8749",
@ -986,9 +984,7 @@
"318bee4424125dd5"
],
"x": 34,
"y": 19,
"w": 832,
"h": 742
"y": 19
},
{
"id": "208284848b13b85b",
@ -1056,9 +1052,7 @@
"4f330c52abf707de"
],
"x": 14,
"y": 599,
"w": 2212,
"h": 282
"y": 599
},
{
"id": "753e14252442d87d",
@ -9284,10 +9278,10 @@
"entityidfiltertype": "exact",
"outputinitially": false,
"state_type": "str",
"haltifstate": "",
"haltifstate": "on",
"halt_if_type": "str",
"halt_if_compare": "is",
"outputs": 1,
"outputs": 2,
"output_only_on_state_change": true,
"for": "0",
"forType": "num",
@ -9309,17 +9303,28 @@
"propertyType": "msg",
"value": "door",
"valueType": "str"
},
{
"property": "whichdoor",
"propertyType": "msg",
"value": "front",
"valueType": "str"
}
],
"x": 840,
"y": 60,
"wires": [
[
"26f15fc8d75a4020",
"5f8b61ddc9963e99"
],
[
"26f15fc8d75a4020"
]
],
"outputLabels": [
"Open"
"Open",
""
]
},
{
@ -9372,7 +9377,7 @@
}
],
"x": 860,
"y": 180,
"y": 240,
"wires": [
[
"26f15fc8d75a4020"
@ -9429,7 +9434,7 @@
}
],
"x": 840,
"y": 120,
"y": 180,
"wires": [
[
"26f15fc8d75a4020"
@ -9439,6 +9444,101 @@
"On"
]
},
{
"id": "ff44de8d65439a5f",
"type": "server-state-changed",
"z": "3abb5ae57afb4761",
"name": "Back Door Open",
"server": "9e87348d.9c1c48",
"version": 4,
"exposeToHomeAssistant": false,
"haConfig": [
{
"property": "name",
"value": ""
},
{
"property": "icon",
"value": ""
}
],
"entityidfilter": "binary_sensor.back_door",
"entityidfiltertype": "exact",
"outputinitially": false,
"state_type": "str",
"haltifstate": "on",
"halt_if_type": "str",
"halt_if_compare": "is",
"outputs": 2,
"output_only_on_state_change": true,
"for": "0",
"forType": "num",
"forUnits": "minutes",
"ignorePrevStateNull": false,
"ignorePrevStateUnknown": true,
"ignorePrevStateUnavailable": true,
"ignoreCurrentStateUnknown": true,
"ignoreCurrentStateUnavailable": true,
"outputProperties": [
{
"property": "payload",
"propertyType": "msg",
"value": "",
"valueType": "entityState"
},
{
"property": "detect",
"propertyType": "msg",
"value": "door",
"valueType": "str"
},
{
"property": "whichdoor",
"propertyType": "msg",
"value": "back",
"valueType": "str"
}
],
"x": 840,
"y": 120,
"wires": [
[
"5f8b61ddc9963e99"
],
[]
],
"outputLabels": [
"Open",
""
]
},
{
"id": "5f8b61ddc9963e99",
"type": "api-call-service",
"z": "3abb5ae57afb4761",
"name": "+1",
"server": "9e87348d.9c1c48",
"version": 5,
"debugenabled": false,
"domain": "input_number",
"service": "increment",
"areaId": [],
"deviceId": [],
"entityId": [
"input_number.{{whichdoor}}_door_opened_today"
],
"data": "",
"dataType": "jsonata",
"mergeContext": "",
"mustacheAltTags": false,
"outputProperties": [],
"queue": "none",
"x": 1070,
"y": 80,
"wires": [
[]
]
},
{
"id": "d95d9964546768a5",
"type": "server-state-changed",