[
{
"id": "4637e5e.a99ef1c",
"type": "tab",
"label": "Aqara无线开关联动",
"disabled": false,
"info": ""
},
{
"id": "fdc37963.e87508",
"type": "server-state-changed",
"z": "4637e5e.a99ef1c",
"name": "Aaqara无线开关点击(卧室)",
"server": "f502d896.36dae8",
"version": 1,
"exposeToHomeAssistant": false,
"haConfig": [
{
"property": "name",
"value": ""
},
{
"property": "icon",
"value": ""
}
],
"entityidfilter": "sensor.0x158d00024b48c6_action",
"entityidfiltertype": "exact",
"outputinitially": false,
"state_type": "str",
"haltifstate": "single",
"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": false,
"ignorePrevStateUnavailable": false,
"ignoreCurrentStateUnknown": false,
"ignoreCurrentStateUnavailable": false,
"x": 450,
"y": 220,
"wires": [
[
"e6b26bee.d70fe8"
],
[]
]
},
{
"id": "3cccdf6c.d8115",
"type": "switch",
"z": "4637e5e.a99ef1c",
"name": "次数统计",
"property": "count",
"propertyType": "msg",
"rules": [
{
"t": "eq",
"v": "1",
"vt": "str"
},
{
"t": "eq",
"v": "2",
"vt": "str"
},
{
"t": "eq",
"v": "3",
"vt": "str"
}
],
"checkall": "true",
"repair": false,
"outputs": 3,
"x": 860,
"y": 220,
"wires": [
[
"6adfda86.51fd94"
],
[],
[]
],
"outputLabels": [
"1次",
"2次",
null
]
},
{
"id": "6adfda86.51fd94",
"type": "api-call-service",
"z": "4637e5e.a99ef1c",
"name": "卧室灯",
"server": "f502d896.36dae8",
"version": 1,
"debugenabled": false,
"service_domain": "switch",
"service": "toggle",
"entityId": "switch.0x158d000211801e_channel_2",
"data": "",
"dataType": "json",
"mergecontext": "",
"output_location": "",
"output_location_type": "none",
"mustacheAltTags": false,
"x": 1050,
"y": 220,
"wires": [
[]
]
},
{
"id": "be37648b.7b91d8",
"type": "server-state-changed",
"z": "4637e5e.a99ef1c",
"name": "Aaqara无线开关点击(书房)",
"server": "f502d896.36dae8",
"version": 1,
"exposeToHomeAssistant": false,
"haConfig": [
{
"property": "name",
"value": ""
},
{
"property": "icon",
"value": ""
}
],
"entityidfilter": "sensor.0x158d00025302a8_action",
"entityidfiltertype": "exact",
"outputinitially": false,
"state_type": "str",
"haltifstate": "single",
"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": false,
"ignorePrevStateUnavailable": false,
"ignoreCurrentStateUnknown": false,
"ignoreCurrentStateUnavailable": false,
"x": 450,
"y": 340,
"wires": [
[
"b66740.b10ad8c"
],
[]
]
},
{
"id": "ee8d42a0.29afb",
"type": "switch",
"z": "4637e5e.a99ef1c",
"name": "次数统计",
"property": "count",
"propertyType": "msg",
"rules": [
{
"t": "eq",
"v": "1",
"vt": "str"
},
{
"t": "eq",
"v": "2",
"vt": "str"
},
{
"t": "eq",
"v": "3",
"vt": "str"
}
],
"checkall": "true",
"repair": false,
"outputs": 3,
"x": 860,
"y": 340,
"wires": [
[
"82a44fa4.b9df8"
],
[],
[]
],
"outputLabels": [
"1次",
"2次",
null
]
},
{
"id": "82a44fa4.b9df8",
"type": "api-call-service",
"z": "4637e5e.a99ef1c",
"name": "书房灯",
"server": "f502d896.36dae8",
"version": 1,
"debugenabled": false,
"service_domain": "switch",
"service": "toggle",
"entityId": "switch.0x158d000211801e_channel_1",
"data": "",
"dataType": "json",
"mergecontext": "",
"output_location": "",
"output_location_type": "none",
"mustacheAltTags": false,
"x": 1050,
"y": 340,
"wires": [
[]
]
},
{
"id": "af947bd0.f2d968",
"type": "server-state-changed",
"z": "4637e5e.a99ef1c",
"name": "Aaqara无线开关点击(主卧)",
"server": "f502d896.36dae8",
"version": 1,
"exposeToHomeAssistant": false,
"haConfig": [
{
"property": "name",
"value": ""
},
{
"property": "icon",
"value": ""
}
],
"entityidfilter": "sensor.0x158d0002530462_action",
"entityidfiltertype": "exact",
"outputinitially": false,
"state_type": "str",
"haltifstate": "single",
"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": false,
"ignorePrevStateUnavailable": false,
"ignoreCurrentStateUnknown": false,
"ignoreCurrentStateUnavailable": false,
"x": 450,
"y": 460,
"wires": [
[
"c5612152.cad3a"
],
[]
]
},
{
"id": "19e2f8e7.154b67",
"type": "switch",
"z": "4637e5e.a99ef1c",
"name": "次数统计",
"property": "count",
"propertyType": "msg",
"rules": [
{
"t": "eq",
"v": "1",
"vt": "str"
},
{
"t": "eq",
"v": "2",
"vt": "str"
},
{
"t": "eq",
"v": "3",
"vt": "str"
}
],
"checkall": "true",
"repair": false,
"outputs": 3,
"x": 860,
"y": 460,
"wires": [
[
"aeb82431.ef4048"
],
[
"5683f44a.2cdd9c"
],
[
"48c76e99.305"
]
],
"outputLabels": [
"1次",
"2次",
null
]
},
{
"id": "aeb82431.ef4048",
"type": "api-call-service",
"z": "4637e5e.a99ef1c",
"name": "主卧A灯",
"server": "f502d896.36dae8",
"version": 1,
"debugenabled": false,
"service_domain": "switch",
"service": "toggle",
"entityId": "switch.0x158d0002422cc3_channel_1",
"data": "",
"dataType": "json",
"mergecontext": "",
"output_location": "",
"output_location_type": "none",
"mustacheAltTags": false,
"x": 1060,
"y": 420,
"wires": [
[]
]
},
{
"id": "d8d5ca.6696ea38",
"type": "server-state-changed",
"z": "4637e5e.a99ef1c",
"name": "Aaqara无线开关点击(客厅)",
"server": "f502d896.36dae8",
"version": 1,
"exposeToHomeAssistant": false,
"haConfig": [
{
"property": "name",
"value": ""
},
{
"property": "icon",
"value": ""
}
],
"entityidfilter": "sensor.0x158d00024b3a84_action",
"entityidfiltertype": "exact",
"outputinitially": false,
"state_type": "str",
"haltifstate": "single",
"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": false,
"ignorePrevStateUnavailable": false,
"ignoreCurrentStateUnknown": false,
"ignoreCurrentStateUnavailable": false,
"x": 450,
"y": 580,
"wires": [
[
"14ccec96.916943"
],
[]
]
},
{
"id": "43f890b0.954f6",
"type": "switch",
"z": "4637e5e.a99ef1c",
"name": "次数统计",
"property": "count",
"propertyType": "msg",
"rules": [
{
"t": "eq",
"v": "1",
"vt": "str"
},
{
"t": "eq",
"v": "2",
"vt": "str"
},
{
"t": "eq",
"v": "3",
"vt": "str"
}
],
"checkall": "true",
"repair": false,
"outputs": 3,
"x": 860,
"y": 580,
"wires": [
[
"84f6262d.00b5b8"
],
[
"28e13e59.c15d32"
],
[]
],
"outputLabels": [
"1次",
"2次",
null
]
},
{
"id": "5683f44a.2cdd9c",
"type": "api-call-service",
"z": "4637e5e.a99ef1c",
"name": "主卧B灯",
"server": "f502d896.36dae8",
"version": 1,
"debugenabled": false,
"service_domain": "switch",
"service": "toggle",
"entityId": "switch.0x158d0002422cc3_channel_2",
"data": "",
"dataType": "json",
"mergecontext": "",
"output_location": "",
"output_location_type": "none",
"mustacheAltTags": false,
"x": 1060,
"y": 460,
"wires": [
[]
]
},
{
"id": "48c76e99.305",
"type": "api-call-service",
"z": "4637e5e.a99ef1c",
"name": "主卧A-B灯",
"server": "f502d896.36dae8",
"version": 1,
"debugenabled": false,
"service_domain": "switch",
"service": "turn_off",
"entityId": "switch.0x158d0002422cc3_channel_1, switch.0x158d0002422cc3_channel_2",
"data": "",
"dataType": "json",
"mergecontext": "",
"output_location": "",
"output_location_type": "none",
"mustacheAltTags": false,
"x": 1070,
"y": 500,
"wires": [
[]
]
},
{
"id": "84f6262d.00b5b8",
"type": "api-call-service",
"z": "4637e5e.a99ef1c",
"name": "客厅程序",
"server": "f502d896.36dae8",
"version": 1,
"debugenabled": false,
"service_domain": "switch",
"service": "turn_off",
"entityId": "switch.0x158d0001f27004_switch, switch.0x158d0002403162_channel_1, switch.0x158d0002403162_channel_2, switch.0x158d0002450410_channel_1, switch.0x158d0002450410_channel_2, switch.0x158d0001f2720a_switch",
"data": "",
"dataType": "json",
"mergecontext": "",
"output_location": "",
"output_location_type": "none",
"mustacheAltTags": false,
"x": 1060,
"y": 560,
"wires": [
[
"26534fb4.72a12"
]
],
"info": "switch.0x00158d0001f27004, switch.0x00158d0002403162_right, switch.0x00158d0002450410_left, switch.0x00158d0002450410_right, switch.0x00158d0002403162_left, switch.0x00158d0001f2720a"
},
{
"id": "28e13e59.c15d32",
"type": "api-call-service",
"z": "4637e5e.a99ef1c",
"name": "客厅双击",
"server": "f502d896.36dae8",
"version": 1,
"debugenabled": false,
"service_domain": "switch",
"service": "turn_on",
"entityId": "switch.0x158d0002403162_channel_2",
"data": "",
"dataType": "json",
"mergecontext": "",
"output_location": "",
"output_location_type": "none",
"mustacheAltTags": false,
"x": 1060,
"y": 600,
"wires": [
[]
]
},
{
"id": "26534fb4.72a12",
"type": "delay",
"z": "4637e5e.a99ef1c",
"name": "",
"pauseType": "delay",
"timeout": "20",
"timeoutUnits": "seconds",
"rate": "1",
"nbRateUnits": "1",
"rateUnits": "second",
"randomFirst": "1",
"randomLast": "5",
"randomUnits": "seconds",
"drop": false,
"x": 1220,
"y": 560,
"wires": [
[
"26930c1b.c43174"
]
]
},
{
"id": "26930c1b.c43174",
"type": "api-call-service",
"z": "4637e5e.a99ef1c",
"name": "主卧A灯",
"server": "f502d896.36dae8",
"version": 1,
"debugenabled": false,
"service_domain": "switch",
"service": "turn_off",
"entityId": "switch.0x158d0002422cc3_channel_1",
"data": "",
"dataType": "json",
"mergecontext": "",
"output_location": "",
"output_location_type": "none",
"mustacheAltTags": false,
"x": 1380,
"y": 560,
"wires": [
[]
]
},
{
"id": "e6b26bee.d70fe8",
"type": "timed-counter",
"z": "4637e5e.a99ef1c",
"name": "固定计数",
"timelimit": "800",
"timeunit": "1",
"withhold": true,
"fixedtimeout": true,
"pertopic": true,
"x": 680,
"y": 220,
"wires": [
[
"3cccdf6c.d8115"
]
]
},
{
"id": "b66740.b10ad8c",
"type": "timed-counter",
"z": "4637e5e.a99ef1c",
"name": "固定计数",
"timelimit": "800",
"timeunit": "1",
"withhold": true,
"fixedtimeout": true,
"pertopic": true,
"x": 680,
"y": 340,
"wires": [
[
"ee8d42a0.29afb"
]
]
},
{
"id": "c5612152.cad3a",
"type": "timed-counter",
"z": "4637e5e.a99ef1c",
"name": "固定计数",
"timelimit": "800",
"timeunit": "1",
"withhold": true,
"fixedtimeout": true,
"pertopic": true,
"x": 680,
"y": 460,
"wires": [
[
"19e2f8e7.154b67"
]
]
},
{
"id": "14ccec96.916943",
"type": "timed-counter",
"z": "4637e5e.a99ef1c",
"name": "固定计数",
"timelimit": "800",
"timeunit": "1",
"withhold": true,
"fixedtimeout": true,
"pertopic": true,
"x": 680,
"y": 580,
"wires": [
[
"43f890b0.954f6"
]
]
},
{
"id": "f502d896.36dae8",
"type": "server",
"name": "Home Assistant",
"legacy": false,
"addon": true,
"rejectUnauthorizedCerts": true,
"ha_boolean": "y|yes|true|on|home|open",
"connectionDelay": true,
"cacheJson": true
}
]