I just realized my motion sensor wasn’t even communicating with the panel. My motion sensor source was set to use S-line instead of SecurityRF-319.
Settings / Advanced Settings / Installation / Devices / Security Sensors / Edit Sensors / Find your motion sensor tap edit, and change source.
You can turn on the chime just to verify that the motion senor is activating and notifying the panel
So the motion sensor status remains “closed”. Instead it looks like the panel is reporting motion with zone_event_type, as ZONE_ACTIVE (motion) and ZONE_UPDATE (clear).
So I updated my flow with a second function for devices using that information. I only have one motion sensor, but I’ve grouped in the panel motion sensor. The panel motion sensor zone_event_type is always zone_active and status is always ‘closed’, so I’m not sure how or if it’s possible to get that working
[
{
"id": "ba898990.4dd3e8",
"type": "tab",
"label": "Monitor QolSys Panel",
"disabled": false,
"info": ""
},
{
"id": "fd3d1b3a.4d0928",
"type": "inject",
"z": "ba898990.4dd3e8",
"name": "go",
"props": [],
"repeat": "",
"crontab": "",
"once": true,
"onceDelay": 0.1,
"topic": "",
"x": 90,
"y": 20,
"wires": [
[
"7796cc60.cd6384"
]
]
},
{
"id": "7796cc60.cd6384",
"type": "exec",
"z": "ba898990.4dd3e8",
"command": "curl -kN --http0.9 https://192.168.2.35:12345",
"addpay": true,
"append": "",
"useSpawn": "true",
"timer": "",
"oldrc": false,
"name": "curl",
"x": 130,
"y": 80,
"wires": [
[
"ba649a6f.3d0cf8"
],
[
"6ca13117.4beca"
],
[
"643511a.cb42bf"
]
]
},
{
"id": "643511a.cb42bf",
"type": "debug",
"z": "ba898990.4dd3e8",
"name": "return (exit) codes",
"active": false,
"tosidebar": true,
"console": false,
"tostatus": false,
"complete": "true",
"targetType": "full",
"statusVal": "",
"statusType": "auto",
"x": 430,
"y": 60,
"wires": []
},
{
"id": "6ca13117.4beca",
"type": "debug",
"z": "ba898990.4dd3e8",
"name": "Just outputs the curl progress, not the actual output",
"active": false,
"tosidebar": true,
"console": false,
"tostatus": false,
"complete": "true",
"targetType": "full",
"statusVal": "",
"statusType": "auto",
"x": 490,
"y": 20,
"wires": []
},
{
"id": "ba649a6f.3d0cf8",
"type": "switch",
"z": "ba898990.4dd3e8",
"name": "Ignore ACK",
"property": "payload",
"propertyType": "msg",
"rules": [
{
"t": "cont",
"v": "ACK",
"vt": "str"
},
{
"t": "else"
}
],
"checkall": "true",
"repair": false,
"outputs": 2,
"x": 190,
"y": 140,
"wires": [
[
"6c645525.266eec"
],
[
"fe4c2051.1574a"
]
]
},
{
"id": "fe4c2051.1574a",
"type": "json",
"z": "ba898990.4dd3e8",
"name": "convert update to json",
"property": "payload",
"action": "",
"pretty": true,
"x": 260,
"y": 200,
"wires": [
[
"98d001ba.58635",
"d0a2b915.6f1ad8",
"2915e436.c4c6bc"
]
]
},
{
"id": "98d001ba.58635",
"type": "debug",
"z": "ba898990.4dd3e8",
"name": "converted json",
"active": true,
"tosidebar": true,
"console": false,
"tostatus": false,
"complete": "true",
"targetType": "full",
"statusVal": "",
"statusType": "auto",
"x": 480,
"y": 100,
"wires": []
},
{
"id": "d0a2b915.6f1ad8",
"type": "function",
"z": "ba898990.4dd3e8",
"name": "Find Open/Closed Status \\n Doors + Windows ",
"func": "zid = msg.payload[\"zone\"][\"zone_id\"];\nzstatus = msg.payload[\"zone\"][\"status\"];\n//entity_id = \"\";\nmsg.zstatus = zstatus;\n\nswitch (zid) {\n case 1:\n return [msg,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null]\n case 2:\n return [null,msg,null,null,null,null,null,null,null,null,null,null,null,null,null,null]\n case 3:\n return [null,null,msg,null,null,null,null,null,null,null,null,null,null,null,null,null]\n case 4:\n return [null,null,null,msg,null,null,null,null,null,null,null,null,null,null,null,null]\n case 5:\n return [null,null,null,null,msg,null,null,null,null,null,null,null,null,null,null,null]\n case 6:\n return [null,null,null,null,null,msg,null,null,null,null,null,null,null,null,null,null]\n case 7:\n return [null,null,null,null,null,null,msg,null,null,null,null,null,null,null,null,null] \n case 8:\n return [null,null,null,null,null,null,null,msg,null,null,null,null,null,null,null,null] \n case 9:\n return [null,null,null,null,null,null,null,null,msg,null,null,null,null,null,null,null]\n case 10:\n return [null,null,null,null,null,null,null,null,null,msg,null,null,null,null,null,null]\n case 11:\n return [null,null,null,null,null,null,null,null,null,null,msg,null,null,null,null,null]\n case 12:\n return [null,null,null,null,null,null,null,null,null,null,null,msg,null,null,null,null]\n case 13:\n return [null,null,null,null,null,null,null,null,null,null,null,null,msg,null,null,null]\n case 14:\n return [null,null,null,null,null,null,null,null,null,null,null,null,null,msg,null,null]\n case 15:\n return [null,null,null,null,null,null,null,null,null,null,null,null,null,null,msg,null] \n case 16:\n return [null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,msg]\n}\n\n//node.warn(\"zid: \" + zid + \", status: \" + zstatus + \", entities: \" + entity_ids)",
"outputs": 16,
"noerr": 0,
"initialize": "",
"finalize": "",
"x": 270,
"y": 540,
"wires": [
[
"9022a5b8.478c58",
"4aa7a1bc.426c9"
],
[
"a35218ae.d18e28"
],
[
"60ca2505.845d1c"
],
[
"df396c28.eef64"
],
[
"19770ba8.11c6d4"
],
[
"d8ba25f6.efce58"
],
[
"dcc747aa.a378b8"
],
[
"1722acaa.485883"
],
[
"35d56d5d.bd9c62"
],
[],
[
"71d87ba9.be99e4"
],
[
"d1b097c8.d89308"
],
[
"964b0753.0aa248"
],
[
"83bc1403.532158"
],
[],
[
"5e02e726.7dddb8"
]
]
},
{
"id": "9022a5b8.478c58",
"type": "debug",
"z": "ba898990.4dd3e8",
"name": "added entity ids",
"active": false,
"tosidebar": true,
"console": false,
"tostatus": false,
"complete": "true",
"targetType": "full",
"statusVal": "",
"statusType": "auto",
"x": 600,
"y": 140,
"wires": []
},
{
"id": "60ca2505.845d1c",
"type": "ha-entity",
"z": "ba898990.4dd3e8",
"name": "Garage Door",
"server": "934a7469.f8dfc8",
"version": 1,
"debugenabled": false,
"outputs": 1,
"entityType": "binary_sensor",
"config": [
{
"property": "name",
"value": "Garage Door"
},
{
"property": "device_class",
"value": "door"
},
{
"property": "icon",
"value": ""
},
{
"property": "unit_of_measurement",
"value": ""
}
],
"state": "zstatus",
"stateType": "msg",
"attributes": [],
"resend": true,
"outputLocation": "",
"outputLocationType": "none",
"inputOverride": "allow",
"x": 550,
"y": 360,
"wires": [
[]
]
},
{
"id": "6c645525.266eec",
"type": "debug",
"z": "ba898990.4dd3e8",
"name": "",
"active": false,
"tosidebar": true,
"console": false,
"tostatus": false,
"complete": "payload",
"targetType": "msg",
"statusVal": "",
"statusType": "auto",
"x": 630,
"y": 180,
"wires": []
},
{
"id": "4aa7a1bc.426c9",
"type": "ha-entity",
"z": "ba898990.4dd3e8",
"name": "Front Door",
"server": "934a7469.f8dfc8",
"version": 1,
"debugenabled": false,
"outputs": 1,
"entityType": "binary_sensor",
"config": [
{
"property": "name",
"value": "Front Door"
},
{
"property": "device_class",
"value": "door"
},
{
"property": "icon",
"value": ""
},
{
"property": "unit_of_measurement",
"value": ""
}
],
"state": "zstatus",
"stateType": "msg",
"attributes": [],
"resend": true,
"outputLocation": "",
"outputLocationType": "none",
"inputOverride": "allow",
"x": 550,
"y": 240,
"wires": [
[]
]
},
{
"id": "a35218ae.d18e28",
"type": "ha-entity",
"z": "ba898990.4dd3e8",
"name": "Sliding Door",
"server": "934a7469.f8dfc8",
"version": 1,
"debugenabled": false,
"outputs": 1,
"entityType": "binary_sensor",
"config": [
{
"property": "name",
"value": "Sliding Door"
},
{
"property": "device_class",
"value": "door"
},
{
"property": "icon",
"value": ""
},
{
"property": "unit_of_measurement",
"value": ""
}
],
"state": "zstatus",
"stateType": "msg",
"attributes": [],
"resend": true,
"outputLocation": "",
"outputLocationType": "none",
"inputOverride": "allow",
"x": 550,
"y": 300,
"wires": [
[]
]
},
{
"id": "df396c28.eef64",
"type": "ha-entity",
"z": "ba898990.4dd3e8",
"name": "Master Bedroom Left Window",
"server": "934a7469.f8dfc8",
"version": 1,
"debugenabled": false,
"outputs": 1,
"entityType": "binary_sensor",
"config": [
{
"property": "name",
"value": "Master Bedroom Left Window"
},
{
"property": "device_class",
"value": "window"
},
{
"property": "icon",
"value": ""
},
{
"property": "unit_of_measurement",
"value": ""
}
],
"state": "zstatus",
"stateType": "msg",
"attributes": [],
"resend": true,
"outputLocation": "",
"outputLocationType": "none",
"inputOverride": "allow",
"x": 610,
"y": 420,
"wires": [
[]
]
},
{
"id": "19770ba8.11c6d4",
"type": "ha-entity",
"z": "ba898990.4dd3e8",
"name": "Master Bedroom Right Window",
"server": "934a7469.f8dfc8",
"version": 1,
"debugenabled": false,
"outputs": 1,
"entityType": "binary_sensor",
"config": [
{
"property": "name",
"value": "Master Bedroom Right Window"
},
{
"property": "device_class",
"value": "window"
},
{
"property": "icon",
"value": ""
},
{
"property": "unit_of_measurement",
"value": ""
}
],
"state": "zstatus",
"stateType": "msg",
"attributes": [],
"resend": true,
"outputLocation": "",
"outputLocationType": "none",
"inputOverride": "allow",
"x": 610,
"y": 480,
"wires": [
[]
]
},
{
"id": "d8ba25f6.efce58",
"type": "ha-entity",
"z": "ba898990.4dd3e8",
"name": "Livingroom Left Window",
"server": "934a7469.f8dfc8",
"version": 1,
"debugenabled": false,
"outputs": 1,
"entityType": "binary_sensor",
"config": [
{
"property": "name",
"value": "Livingroom Left Window"
},
{
"property": "device_class",
"value": "window"
},
{
"property": "icon",
"value": ""
},
{
"property": "unit_of_measurement",
"value": ""
}
],
"state": "zstatus",
"stateType": "msg",
"attributes": [],
"resend": true,
"outputLocation": "",
"outputLocationType": "none",
"inputOverride": "allow",
"x": 590,
"y": 540,
"wires": [
[]
]
},
{
"id": "dcc747aa.a378b8",
"type": "ha-entity",
"z": "ba898990.4dd3e8",
"name": "Livingroom Right Window",
"server": "934a7469.f8dfc8",
"version": 1,
"debugenabled": false,
"outputs": 1,
"entityType": "binary_sensor",
"config": [
{
"property": "name",
"value": "Livingroom Right Window"
},
{
"property": "device_class",
"value": "window"
},
{
"property": "icon",
"value": ""
},
{
"property": "unit_of_measurement",
"value": ""
}
],
"state": "zstatus",
"stateType": "msg",
"attributes": [],
"resend": true,
"outputLocation": "",
"outputLocationType": "none",
"inputOverride": "allow",
"x": 590,
"y": 600,
"wires": [
[]
]
},
{
"id": "1722acaa.485883",
"type": "ha-entity",
"z": "ba898990.4dd3e8",
"name": "Dining Room Left Window",
"server": "934a7469.f8dfc8",
"version": 1,
"debugenabled": false,
"outputs": 1,
"entityType": "binary_sensor",
"config": [
{
"property": "name",
"value": "Dining Room Left Window"
},
{
"property": "device_class",
"value": "window"
},
{
"property": "icon",
"value": ""
},
{
"property": "unit_of_measurement",
"value": ""
}
],
"state": "zstatus",
"stateType": "msg",
"attributes": [],
"resend": true,
"outputLocation": "",
"outputLocationType": "none",
"inputOverride": "allow",
"x": 590,
"y": 660,
"wires": [
[]
]
},
{
"id": "35d56d5d.bd9c62",
"type": "ha-entity",
"z": "ba898990.4dd3e8",
"name": "Dining Room Right Window",
"server": "934a7469.f8dfc8",
"version": 1,
"debugenabled": false,
"outputs": 1,
"entityType": "binary_sensor",
"config": [
{
"property": "name",
"value": "Dining Room Right Window"
},
{
"property": "device_class",
"value": "window"
},
{
"property": "icon",
"value": ""
},
{
"property": "unit_of_measurement",
"value": ""
}
],
"state": "zstatus",
"stateType": "msg",
"attributes": [],
"resend": true,
"outputLocation": "",
"outputLocationType": "none",
"inputOverride": "allow",
"x": 600,
"y": 720,
"wires": [
[]
]
},
{
"id": "fac1a046.e2162",
"type": "ha-entity",
"z": "ba898990.4dd3e8",
"name": "Motion Detector",
"server": "934a7469.f8dfc8",
"version": 1,
"debugenabled": false,
"outputs": 1,
"entityType": "binary_sensor",
"config": [
{
"property": "name",
"value": "Hallway Motion Detector"
},
{
"property": "device_class",
"value": "motion"
},
{
"property": "icon",
"value": ""
},
{
"property": "unit_of_measurement",
"value": ""
}
],
"state": "zstatus",
"stateType": "msg",
"attributes": [],
"resend": true,
"outputLocation": "",
"outputLocationType": "none",
"inputOverride": "allow",
"x": 740,
"y": 780,
"wires": [
[]
]
},
{
"id": "71d87ba9.be99e4",
"type": "ha-entity",
"z": "ba898990.4dd3e8",
"name": "Smoke Detector",
"server": "934a7469.f8dfc8",
"version": 1,
"debugenabled": false,
"outputs": 1,
"entityType": "binary_sensor",
"config": [
{
"property": "name",
"value": "Smoke Detector"
},
{
"property": "device_class",
"value": "smoke"
},
{
"property": "icon",
"value": "mdi:fire-truck"
},
{
"property": "unit_of_measurement",
"value": ""
}
],
"state": "zstatus",
"stateType": "msg",
"attributes": [],
"resend": true,
"outputLocation": "",
"outputLocationType": "none",
"inputOverride": "allow",
"x": 560,
"y": 840,
"wires": [
[]
]
},
{
"id": "d1b097c8.d89308",
"type": "ha-entity",
"z": "ba898990.4dd3e8",
"name": "Auxilary Pendant",
"server": "934a7469.f8dfc8",
"version": 1,
"debugenabled": false,
"outputs": 1,
"entityType": "binary_sensor",
"config": [
{
"property": "name",
"value": "Auxilary Pendant"
},
{
"property": "device_class",
"value": "safety"
},
{
"property": "icon",
"value": "mdi:shield-home"
},
{
"property": "unit_of_measurement",
"value": ""
}
],
"state": "zstatus",
"stateType": "msg",
"attributes": [],
"resend": true,
"outputLocation": "",
"outputLocationType": "none",
"inputOverride": "allow",
"x": 570,
"y": 900,
"wires": [
[]
]
},
{
"id": "964b0753.0aa248",
"type": "ha-entity",
"z": "ba898990.4dd3e8",
"name": "Key FOB",
"server": "934a7469.f8dfc8",
"version": 1,
"debugenabled": false,
"outputs": 1,
"entityType": "binary_sensor",
"config": [
{
"property": "name",
"value": "Key FOB"
},
{
"property": "device_class",
"value": "safety"
},
{
"property": "icon",
"value": "mdi:shield-home-outline"
},
{
"property": "unit_of_measurement",
"value": ""
}
],
"state": "zstatus",
"stateType": "msg",
"attributes": [],
"resend": true,
"outputLocation": "",
"outputLocationType": "none",
"inputOverride": "allow",
"x": 540,
"y": 960,
"wires": [
[]
]
},
{
"id": "83bc1403.532158",
"type": "ha-entity",
"z": "ba898990.4dd3e8",
"name": "Key FOB2",
"server": "934a7469.f8dfc8",
"version": 1,
"debugenabled": false,
"outputs": 1,
"entityType": "binary_sensor",
"config": [
{
"property": "name",
"value": "Key FOB2"
},
{
"property": "device_class",
"value": "safety"
},
{
"property": "icon",
"value": "mdi:shield-home-outline"
},
{
"property": "unit_of_measurement",
"value": ""
}
],
"state": "zstatus",
"stateType": "msg",
"attributes": [],
"resend": true,
"outputLocation": "",
"outputLocationType": "none",
"inputOverride": "allow",
"x": 550,
"y": 1020,
"wires": [
[]
]
},
{
"id": "df4d7e82.5323b",
"type": "ha-entity",
"z": "ba898990.4dd3e8",
"name": "Panel Motion",
"server": "934a7469.f8dfc8",
"version": 1,
"debugenabled": false,
"outputs": 1,
"entityType": "binary_sensor",
"config": [
{
"property": "name",
"value": "IQ2 Panel Motion"
},
{
"property": "device_class",
"value": "motion"
},
{
"property": "icon",
"value": ""
},
{
"property": "unit_of_measurement",
"value": ""
}
],
"state": "zstatus",
"stateType": "msg",
"attributes": [],
"resend": true,
"outputLocation": "",
"outputLocationType": "none",
"inputOverride": "allow",
"x": 730,
"y": 1080,
"wires": [
[]
]
},
{
"id": "5e02e726.7dddb8",
"type": "ha-entity",
"z": "ba898990.4dd3e8",
"name": "Panel Glass Break",
"server": "934a7469.f8dfc8",
"version": 1,
"debugenabled": false,
"outputs": 1,
"entityType": "binary_sensor",
"config": [
{
"property": "name",
"value": "IQ2 Panel Glass Break"
},
{
"property": "device_class",
"value": "sound"
},
{
"property": "icon",
"value": ""
},
{
"property": "unit_of_measurement",
"value": ""
}
],
"state": "zstatus",
"stateType": "msg",
"attributes": [],
"resend": true,
"outputLocation": "",
"outputLocationType": "none",
"inputOverride": "allow",
"x": 570,
"y": 1140,
"wires": [
[]
]
},
{
"id": "2915e436.c4c6bc",
"type": "function",
"z": "ba898990.4dd3e8",
"name": "Find Active Status \\n Motion Sensors",
"func": "zid = msg.payload[\"zone\"][\"zone_id\"];\nzstatus = msg.payload[\"zone_event_type\"];\n\nmsg.zstatus = zstatus;\n\nswitch (zid) {\n case 10:\n return [msg,null]\n case 15:\n return [null,msg]\n}\n\n//node.warn(\"zid: \" + zid + \", status: \" + zstatus + \", entities: \" + entity_ids)",
"outputs": 2,
"noerr": 0,
"initialize": "",
"finalize": "",
"x": 250,
"y": 700,
"wires": [
[
"5dad6e1b.6c2d4"
],
[
"6d25094d.78fd58"
]
]
},
{
"id": "5dad6e1b.6c2d4",
"type": "change",
"z": "ba898990.4dd3e8",
"name": "Define on/off",
"rules": [
{
"t": "change",
"p": "zstatus",
"pt": "msg",
"from": "ZONE_ACTIVE",
"fromt": "str",
"to": "on",
"tot": "str"
},
{
"t": "change",
"p": "zstatus",
"pt": "msg",
"from": "ZONE_UPDATE",
"fromt": "str",
"to": "off",
"tot": "str"
}
],
"action": "",
"property": "",
"from": "",
"to": "",
"reg": false,
"x": 550,
"y": 780,
"wires": [
[
"fac1a046.e2162"
]
]
},
{
"id": "6d25094d.78fd58",
"type": "change",
"z": "ba898990.4dd3e8",
"name": "Define on/off",
"rules": [
{
"t": "change",
"p": "zstatus",
"pt": "msg",
"from": "ZONE_ACTIVE",
"fromt": "str",
"to": "on",
"tot": "str"
},
{
"t": "change",
"p": "zstatus",
"pt": "msg",
"from": "ZONE_UPDATE",
"fromt": "str",
"to": "off",
"tot": "str"
}
],
"action": "",
"property": "",
"from": "",
"to": "",
"reg": false,
"x": 550,
"y": 1080,
"wires": [
[
"df4d7e82.5323b"
]
]
},
{
"id": "934a7469.f8dfc8",
"type": "server",
"name": "Home Assistant",
"addon": true
}
]
EDIT: One problem I’ve noticed with the motion sensor is that it will report Zone_Active/Zone_update every ~64 minutes on it’s own. The JSON the IQ2 panel spits out seems to be indistinguishable between these regular updates and an actual motion detected event.
I’m not sure if it’s a problem with that specific motion sensor model? Having a false motion event every 64mins might mean I can’t rely on it for any automations.
The other useful bit of information that shows up in the JSON is the disarmed/armed away/armed stay status. That should be easy to pull, I just need to figure out how to make a sensory with 3 states.