Qolsys IQ Panel 2 and 3rd party integration

I’m sure you can :smiley:. I thought about writing a python script for it, but decided to use node red for its easy HA integration. I don’t do a lot in node red but this was easier in node red than other options (IMO).

I use the node red add-on so the HA plugin is built in.

Alright, I’m going to try to make this work with your code and Node Red. I curled my panel and can see that it is outputting device status information. My panel has a combination of 13 contact and motion sensors mostly. Each device corresponds to a zone_ID 1-13.

So in your node red code I’m looking to see what I need to modify.

I’m looking at “put entity_ids in msg.” What does case 1, 2, 3 correspond to? Are you only pulling in status information about lights? I’m thinking I need to create binary sensors for all my devices rather than switches. How are your generating entities in HomeAssistant for all the devices connected to your IQ2 Panel?

I got the Node-Red flow to fetch data, but my panel seems to be flaky about keeping that web socket service running if several different systems hitting it. Alternatively, is there some throttling or blocking mechanism that kicks in when messing around over the network? Anyone else experience that and/or have a fix?

{As a note… many thanks to everyone above for finding this and getting this far with it! I’m happy to test things on my IQ2 system as I have time, so feel free to ask.}

Yes, they have iptables running on the panel that limits the connections. I’ll update this post soon with their settings so you can see what they’re doing.

I just ordered this panel so I’m following.

This is the iptables settings on the Qolsys panel. Some good clues here! You will also notice they have set rate limiting.

I found it in the firmware under:
/system/etc/init.qolsys.iptables.sh

IPTABLES="/system/bin/iptables -w"
IP6TABLES="/system/bin/ip6tables -w"

#definitions
LINKLOCAL_INF="lo"
DEF_WAN_INF="wlan0"
DEF_LAN_INF="p2p0"
DEF_ETH_INF="eth0"


# Protocol to Port Definition
HTTP="80"
HTTP_ALT="8080"
HTTP_SERV="8448"
HTTPS="443"
HTTPS_CUSTOM="8443"
DNS="53" #TCP and UDP
PHIGH="2000:65535"
NTP="123" #TCP and udp
SSDP="1900" #TCP and UDP
RIP="520" #UDP
DHCP="67:68" #TCP and UDP
ISAKMP1="500" #TCP and UDP
ISAKMP2="2500" #TCP and UDP
ESP_IP_PROTO="50" # ip protocol number for ESP
AH_IP_PROTO="51" # ip protocol number for AH
IDENT="123" #TCP only
L2TP="1701" # TCP and UDP
PPTP="1723" # TCP and UDP
OPENVPN="1194" # TCP and UDP
GRE_IP_PROTO="47" # ip protocol number for GRE
SYSLOG="514" #UDP
MQTT1="1883" #TCP and UDP
MQTT2="8883" #TCP
MQTT3="8884" #TCP
MQTT4="8081" #TCP
DTLS="4433"  #UDP
STUN_ON_DTLS="5349"  #UDP
RDP="" #Remote Desktop Protocol
ADB="5554:5557" #Android Debugging
FTP="20:21" #TCP #FTP for upgrade
SNMP="161:162" #TCP and UDP
SNMP_S="10161:10162" #TCP
SIP="5060:5070" #TCP and UDP. SIP and RTP
RTSP="554" #TCP and UDP
DTLS_1="59595"
LSOCK="21239"
SRF="9910,9920,9930,9940,9950,9990"
ZWAVE="1900"

#table shortcuts
RAW_TABLE="-t raw"
MANGLE_TABLE="-t mangle"
NAT_TABLE="-t nat"

#the below are commented out since they delete android rules
#======================================================
# Cleanup and Initialization of Tables and Chains
#$IPTABLES -F
#$IPTABLES -t mangle -F
#$IPTABLES -t nat -F
#$IPTABLES -t raw -F

#Deleting user defined chains
#$IPTABLES -X
#$IPTABLES -t mangle -X
#$IPTABLES -t nat -X
#$IPTABLES -t raw -X
#========================================================

# Policy Setup for system chains

$IPTABLES -P FORWARD ACCEPT 
$IPTABLES -P OUTPUT ACCEPT

#ADC Rules in the beginning
$IPTABLES -N ADC_CELL_OUT #this is expected to fail on second creation since not allowed to cleanup in non-boot time
$IPTABLES -I OUTPUT 1 -o rmnet+ -j ADC_CELL_OUT #putting this in top of output chain as requested 
$IP6TABLES -N ADC_CELL_OUT #this is expected to fail on second creation since not allowed to cleanup in non-boot time
$IP6TABLES -I OUTPUT 1 -o rmnet+ -j ADC_CELL_OUT #putting this in top of output chain



$IPTABLES -t mangle -P PREROUTING ACCEPT
$IPTABLES -t mangle -P INPUT ACCEPT
$IPTABLES -t mangle -P FORWARD ACCEPT
$IPTABLES -t mangle -P OUTPUT ACCEPT
$IPTABLES -t mangle -P POSTROUTING ACCEPT

$IPTABLES -t nat -P PREROUTING ACCEPT
$IPTABLES -t nat -P POSTROUTING ACCEPT
$IPTABLES -t nat -P OUTPUT ACCEPT
$IPTABLES -t nat -P INPUT ACCEPT

#Creating User-Defined Chains

$IPTABLES -N IANA_IPs
$IPTABLES -N SYN_FLOOD
$IPTABLES -N HTTP_S_IN
$IPTABLES -N HTTP_S_OUT
$IPTABLES -N ICMP_ALLOWED
$IPTABLES -N ICMP_FLOOD_DROP
$IPTABLES -N ICMP_ECHO_DROP
$IPTABLES -N UNPREV_PORTS
$IPTABLES -N UDP_FLOOD
$IPTABLES -N TCP_ATTACKS_FILTER
$IPTABLES -N TCP_ALLOWED_IN
$IPTABLES -N UDP_ALLOWED_IN
$IPTABLES -N TCP_HANDLE_IN_FILTER
$IPTABLES -N UDP_HANDLE_IN_FILTER
$IPTABLES -N ICMP_HANDLE_IN_FILTER
$IPTABLES -N MOBILE_DATA_OUT
$IPTABLES -N LAN_ZONE_INPUT
$IPTABLES -N WAN_ZONE_FORWARD
$IPTABLES -N INPUT_CONTROL
$IPTABLES -N IF_SPEC_DROP
$IPTABLES -N RMNET_OUT_FILTER

$IPTABLES -t raw -N TCP_ATTACKS_RAW
$IPTABLES -t raw -N CHARGEN_ATTACK

#Populating user Defined chains with static rules


$IPTABLES -A IANA_IPs -s 0.0.0.0 -i wlan0 -p udp --dport 67:68 -m limit --limit 25/s --limit-burst 50 -j ACCEPT #p2p0 are accepted anyway. 
$IPTABLES -A IANA_IPs -s 0.0.0.0/7 -j DROP
$IPTABLES -A IANA_IPs -s 100.64.0.0/10 -j DROP
$IPTABLES -A IANA_IPs -s 127.0.0.0/8 -j DROP
$IPTABLES -A IANA_IPs -s 169.254.0.0/16 -j DROP
$IPTABLES -A IANA_IPs -s 192.0.0.0/29 -j DROP 
$IPTABLES -A IANA_IPs -s 192.0.2.0/24 -j DROP 
$IPTABLES -A IANA_IPs -s 192.88.99.0/24 -j DROP 
$IPTABLES -A IANA_IPs -s 198.18.0.0/15 -j DROP
$IPTABLES -A IANA_IPs -s 198.51.100.0/24 -j DROP 
$IPTABLES -A IANA_IPs -s 203.0.113.0/24 -j DROP 
$IPTABLES -A IANA_IPs -s 224.0.0.0/4 -j DROP 
$IPTABLES -A IANA_IPs -s 240.0.0.0/4 -j DROP 
$IPTABLES -A IANA_IPs -s 255.255.255.255/32 -j DROP

$IPTABLES -A SYN_FLOOD -m limit --limit 4/s --limit-burst 6 -j RETURN
$IPTABLES -A SYN_FLOOD -j DROP

$IPTABLES $RAW_TABLE -A TCP_ATTACKS_RAW -p tcp --tcp-flags ALL NONE -j DROP # No Flags set
$IPTABLES $RAW_TABLE -A TCP_ATTACKS_RAW -p tcp --tcp-flags ALL ALL -j DROP # ALL flags set
$IPTABLES $RAW_TABLE -A TCP_ATTACKS_RAW -p tcp --tcp-flags FIN,SYN FIN,SYN -j DROP # both SYN and FIN set
$IPTABLES $RAW_TABLE -A TCP_ATTACKS_RAW -p tcp --tcp-flags SYN,RST SYN,RST -j DROP # both SYN and RST set
$IPTABLES $RAW_TABLE -A TCP_ATTACKS_RAW -p tcp --tcp-flags FIN,RST FIN,RST -j DROP # both RST and FIN set
$IPTABLES $RAW_TABLE -A TCP_ATTACKS_RAW -p tcp --tcp-flags FIN,ACK FIN -j DROP # FIN is set without ACK
$IPTABLES $RAW_TABLE -A TCP_ATTACKS_RAW -p tcp --tcp-flags ACK,URG URG -j DROP # URG is set without ACK
$IPTABLES $RAW_TABLE -A TCP_ATTACKS_RAW -p tcp --tcp-flags ACK,PSH PSH -j DROP # PSH is set without ACK
$IPTABLES $RAW_TABLE -A TCP_ATTACKS_RAW -p tcp --tcp-flags ALL FIN,PSH,URG -j DROP # X-Mas attack
$IPTABLES $RAW_TABLE -A TCP_ATTACKS_RAW -p tcp --tcp-flags ALL SYN,FIN,URG,PSH -j DROP # Nmap OS fingerprinting
$IPTABLES $RAW_TABLE -A TCP_ATTACKS_RAW -p tcp --tcp-flags RST RST -m limit --limit 10/s --limit-burst 20 -j RETURN # Smurf RST flood
$IPTABLES $RAW_TABLE -A TCP_ATTACKS_RAW -p tcp --tcp-flags RST RST -j DROP # Smurf RST flood                                       
$IPTABLES $RAW_TABLE -A TCP_ATTACKS_RAW -p tcp --tcp-flags URG URG -m limit --limit 10/s --limit-burst 20 -j RETURN # Smurf RST flood
$IPTABLES $RAW_TABLE -A TCP_ATTACKS_RAW -p tcp --tcp-flags URG URG -j DROP # Smurf RST flood

$IPTABLES $RAW_TABLE -A CHARGEN_ATTACK -p udp --sport 19 -j DROP # CHARGEN ATTACK

$IPTABLES -A TCP_ATTACKS_FILTER -p tcp --tcp-flags SYN,ACK SYN,ACK -m state --state NEW -j DROP # Bad SYN Request
$IPTABLES -A TCP_ATTACKS_FILTER -p tcp ! --syn -m state --state NEW -j DROP # New Connection without SYN
$IPTABLES -A TCP_ATTACKS_FILTER -p tcp -f -m state --state NEW -j DROP # fragment attack

$IPTABLES -A HTTP_S_IN -p tcp --dport $HTTPS -m limit --limit 500/s --limit-burst 750 -j ACCEPT # HTTPS Flood
$IPTABLES -A HTTP_S_IN -p tcp --dport $HTTP -m limit --limit 50/s --limit-burst 100 -j ACCEPT # HTTP Flood
$IPTABLES -A HTTP_S_IN -p tcp --dport $HTTP_ALT -m limit --limit 50/s --limit-burst 100 -j ACCEPT # HTTP Flood
$IPTABLES -A HTTP_S_IN -p tcp --syn --dport $HTTP_SERV -m connlimit --connlimit-above 15 -j DROP # Slowloris
$IPTABLES -A HTTP_S_IN -p tcp --dport $HTTP_SERV -m limit --limit 50/s --limit-burst 100 -j ACCEPT # HTTP Flood
$IPTABLES -A HTTP_S_IN -p tcp --syn --dport $MQTT2 -m connlimit --connlimit-above 15 -j DROP # Slowloris

$IPTABLES -A HTTP_S_OUT -p tcp --dport $HTTPS -j ACCEPT
$IPTABLES -A HTTP_S_OUT -p tcp --dport $HTTP -j ACCEPT
$IPTABLES -A HTTP_S_OUT -p tcp --dport $HTTP_ALT -j ACCEPT

$IPTABLES -A ICMP_ALLOWED -p icmp -m icmp --icmp-type 0 -j ACCEPT
$IPTABLES -A ICMP_ALLOWED -p icmp -m icmp --icmp-type 3 -j ACCEPT
$IPTABLES -A ICMP_ALLOWED -p icmp -m icmp --icmp-type 11 -j ACCEPT
$IPTABLES -A ICMP_ALLOWED -p icmp -m icmp --icmp-type 4 -j ACCEPT
$IPTABLES -A ICMP_ALLOWED -p icmp -m icmp --icmp-type 12 -j ACCEPT

$IPTABLES -A ICMP_FLOOD_DROP -p icmp -f -j DROP #icmp fragment attack
$IPTABLES -A ICMP_FLOOD_DROP -p icmp -m icmp --icmp-type 13 -j DROP #smurf attack protection
$IPTABLES -A ICMP_FLOOD_DROP -p icmp -m icmp --icmp-type 17 -j DROP #smurf attack protection
$IPTABLES -A ICMP_FLOOD_DROP -p icmp -m limit --limit 5/s --limit-burst 10 -j RETURN
$IPTABLES -A ICMP_FLOOD_DROP -p icmp -m limit --limit 5/s --limit-burst 10 -j LOG --log-prefix 'ICMP-FLOOD-DROP:'
#$IPTABLES -A ICMP_FLOOD_DROP -p icmp -j DROP

$IPTABLES -A ICMP_ECHO_DROP -p icmp --icmp-type 8 -j DROP #ping drop initially disabled

$IPTABLES -A UDP_FLOOD -p udp -f -j DROP # UDP fragment attack
$IPTABLES -A UDP_FLOOD -p udp -m pkttype --pkt-type broadcast -j DROP # Fraggle attack #drops lot of packets
$IPTABLES -A UDP_FLOOD -p udp -m limit --limit 50/s --limit-burst 100 -j RETURN # limiting to 50 pps
#$IPTABLES -A UDP_FLOOD -p udp -m state --state NEW -m recent --update --seconds 1 --hitcount 10 -j RETURN #DDOS prep #unsupported
$IPTABLES -A UDP_FLOOD -m limit --limit 10/s --limit-burst 15 -j LOG --log-level 4 --log-prefix 'UDP-flood attempt: '
$IPTABLES -A UDP_FLOOD -j DROP


$IPTABLES -A TCP_ALLOWED_IN -p tcp -m tcp --dport $ADB -m limit --limit 200/s --limit-burst 250 -j ACCEPT
$IPTABLES -A TCP_ALLOWED_IN -p tcp -m tcp --dport $FTP -m limit --limit 200/s --limit-burst 250 -j ACCEPT
$IPTABLES -A TCP_ALLOWED_IN -p tcp -m tcp --dport $DNS -m limit --limit 25/s --limit-burst 50 -j ACCEPT
$IPTABLES -A TCP_ALLOWED_IN -p tcp -m tcp --dport $NTP -m limit --limit 25/s --limit-burst 50 -j ACCEPT
$IPTABLES -A TCP_ALLOWED_IN -p tcp -m tcp --dport $SSDP -m limit --limit 25/s --limit-burst 50 -j ACCEPT
$IPTABLES -A TCP_ALLOWED_IN -p tcp -m tcp --dport $SIP -m limit --limit 25/s --limit-burst 50 -j ACCEPT
$IPTABLES -A TCP_ALLOWED_IN -p tcp -m tcp --dport $RTSP -m limit --limit 25/s --limit-burst 50 -j ACCEPT
$IPTABLES -A TCP_ALLOWED_IN -p tcp -m tcp --dport $MQTT1 -m limit --limit 50/s --limit-burst 100 -j ACCEPT
$IPTABLES -A TCP_ALLOWED_IN -p tcp -m tcp --dport $MQTT2 -m limit --limit 50/s --limit-burst 100 -j ACCEPT
$IPTABLES -A TCP_ALLOWED_IN -p tcp -m tcp --dport $MQTT3 -m limit --limit 50/s --limit-burst 100 -j ACCEPT
$IPTABLES -A TCP_ALLOWED_IN -p tcp -m tcp --dport $MQTT4 -m limit --limit 50/s --limit-burst 100 -j ACCEPT



$IPTABLES -A UDP_ALLOWED_IN -i lo -p udp -m multiport --ports $SRF -j ACCEPT
$IPTABLES -A UDP_ALLOWED_IN -i lo -p udp -m multiport --ports $ZWAVE -j ACCEPT
$IPTABLES -A UDP_ALLOWED_IN -i lo -p udp -m multiport --ports $LSOCK -j ACCEPT
$IPTABLES -A UDP_ALLOWED_IN -p udp -m udp --dport $DHCP -m limit --limit 25/s --limit-burst 50 -j ACCEPT
$IPTABLES -A UDP_ALLOWED_IN -p udp -m udp --dport $DNS -m limit --limit 25/s --limit-burst 50 -j ACCEPT
$IPTABLES -A UDP_ALLOWED_IN -p udp -m udp --dport $NTP -m limit --limit 25/s --limit-burst 50 -j ACCEPT
$IPTABLES -A UDP_ALLOWED_IN -p udp -m udp --dport $SSDP -m limit --limit 25/s --limit-burst 50 -j ACCEPT
$IPTABLES -A UDP_ALLOWED_IN -p udp -m udp --dport $SIP -m limit --limit 25/s --limit-burst 50 -j ACCEPT
$IPTABLES -A UDP_ALLOWED_IN -p udp -m udp --dport $RTSP -m limit --limit 25/s --limit-burst 50 -j ACCEPT
$IPTABLES -A UDP_ALLOWED_IN -p udp -m udp --dport $MQTT1 -m limit --limit 50/s --limit-burst 100 -j ACCEPT
$IPTABLES -A UDP_ALLOWED_IN -p udp -m udp --dport $DTLS -m limit --limit 50/s --limit-burst 100 -j ACCEPT
$IPTABLES -A UDP_ALLOWED_IN -p udp -m udp --dport $STUN_ON_DTLS -m limit --limit 50/s --limit-burst 100 -j ACCEPT
$IPTABLES -A UDP_ALLOWED_IN -p udp -m udp --dport $RIP -m limit --limit 25/s --limit-burst 50 -j ACCEPT
$IPTABLES -A UDP_ALLOWED_IN -p udp -m udp --dport $DTLS_1 -m limit --limit 50/s --limit-burst 100 -j ACCEPT



$IPTABLES -A UNPREV_PORTS -p tcp -m tcp --dport $PHIGH -m limit --limit 200/s --limit-burst 250 -j ACCEPT
$IPTABLES -A UNPREV_PORTS -p udp -m udp --dport $PHIGH -m limit --limit 200/s --limit-burst 250 -j ACCEPT

$IPTABLES -A TCP_HANDLE_IN_FILTER -j TCP_ATTACKS_FILTER
$IPTABLES -A TCP_HANDLE_IN_FILTER -j HTTP_S_IN
$IPTABLES -A TCP_HANDLE_IN_FILTER -j TCP_ALLOWED_IN


#$IPTABLES -A UDP_HANDLE_IN_FILTER -j UDP_FLOOD
$IPTABLES -A UDP_HANDLE_IN_FILTER -j UDP_ALLOWED_IN

$IPTABLES -A ICMP_HANDLE_IN_FILTER -j ICMP_ALLOWED

# Not allowing qolsys traffic to be initiated from mobile data interfaces
$IPTABLES -A MOBILE_DATA_OUT -d 54.211.24.81 -j REJECT #iqms2 and iqcloud 
$IPTABLES -A MOBILE_DATA_OUT -d 52.2.96.56 -j REJECT   #myserver
$IPTABLES -A MOBILE_DATA_OUT -d 52.3.208.83 -j REJECT   #haproxy for logsupload
$IPTABLES -A MOBILE_DATA_OUT -d 224.0.0.0/4 -j DROP #Block multicast on lte radio
#$IPTABLES -A MOBILE_DATA_OUT -d 8.8.8.8 -j REJECT
#$IPTABLES -A MOBILE_DATA_OUT -d 8.8.4.4 -j REJECT

$IPTABLES -A RMNET_OUT_FILTER -d 224.0.0.0/4 -j DROP # drop multicast regardless of ports
$IPTABLES -A RMNET_OUT_FILTER -d 8.8.8.8 -j REJECT # No google dns on rmnet
$IPTABLES -A RMNET_OUT_FILTER -d 8.8.4.4 -j REJECT # No google dns on rmnet
$IPTABLES -A RMNET_OUT_FILTER -o rmnet7 -j ACCEPT
$IPTABLES -A RMNET_OUT_FILTER -o rmnet1 -j ACCEPT



#Adding default rules to ZONE chains

$IPTABLES -I WAN_ZONE_FORWARD -i $DEF_WAN_INF -p tcp --syn -j SYN_FLOOD
$IPTABLES -I WAN_ZONE_FORWARD -i $DEF_ETH_INF -p tcp --syn -j SYN_FLOOD
$IPTABLES -A LAN_ZONE_INPUT -i $DEF_LAN_INF -j ACCEPT


$IPTABLES -A INPUT_CONTROL -i $LINKLOCAL_INF -j ACCEPT
$IPTABLES -A INPUT_CONTROL -j LAN_ZONE_INPUT
$IPTABLES -A INPUT_CONTROL -p tcp --syn -j SYN_FLOOD
$IPTABLES -A INPUT_CONTROL -p icmp -j ICMP_FLOOD_DROP
$IPTABLES -A INPUT_CONTROL -p icmp -j ICMP_ECHO_DROP
$IPTABLES -A INPUT_CONTROL -m conntrack --ctstate ESTABLISHED,RELATED -j ACCEPT
$IPTABLES -A INPUT_CONTROL -j IANA_IPs
$IPTABLES -A INPUT_CONTROL -p tcp -j TCP_HANDLE_IN_FILTER
$IPTABLES -A INPUT_CONTROL -p icmp -j ICMP_HANDLE_IN_FILTER
$IPTABLES -A INPUT_CONTROL -p udp -j UDP_HANDLE_IN_FILTER
$IPTABLES -A INPUT_CONTROL -j UNPREV_PORTS #Unprevilaged ports 2000 to 65535


$IPTABLES -A IF_SPEC_DROP -i $DEF_WAN_INF -m limit --limit 50/s --limit-burst 100 -j RETURN #not exceeding 50 limit since legit inputs form established connections
$IPTABLES -A IF_SPEC_DROP -i $DEF_WAN_INF -j DROP
$IPTABLES -A IF_SPEC_DROP -i $DEF_ETH_INF -m limit --limit 50/s --limit-burst 100 -j RETURN
$IPTABLES -A IF_SPEC_DROP -i $DEF_ETH_INF -j DROP

# Populating System chains

#FILTER Table:

#INPUT Chain:
#------------

$IPTABLES -I INPUT -j INPUT_CONTROL
$IPTABLES -A INPUT -i $LINKLOCAL_INF -j ACCEPT #just in case.
$IPTABLES -A INPUT ! -i lo -j IF_SPEC_DROP  #lo packets reaching here will be anyway accepted by default policy
#$IPTABLES -P INPUT DROP  #modifying policy only after chain addition

#Forward Chain:
#--------------
$IPTABLES -I FORWARD -j WAN_ZONE_FORWARD
#$IPTABLES -I FORWARD -i wlan0 -p tcp --syn -j SYN_FLOOD
#android chains here. masquarading happens in them.
$IPTABLES -A FORWARD -i $LINKLOCAL_INF -j ACCEPT
#UDP Flood may be handled here
#inter vlan routing policy may be handled here. Its prioritization must be done in Mangle table

#Output Chain
#-------------
#$IPTABLES -A OUTPUT -j HTTP_S_OUT
$IPTABLES -I  OUTPUT 2 -o rmnet+ -j MOBILE_DATA_OUT #matching all rmnet interfaces
$IPTABLES -I  OUTPUT 3 -o $LINKLOCAL_INF -j ACCEPT		 #putting this above everything in OUTPUT chain
#$IPTABLES -I OUTPUT -o rmnet+ -j RMNET_OUT_FILTER

#RAW Table :
#==================

#Prerouting Chain:
#-----------------
$IPTABLES $RAW_TABLE -I PREROUTING -p udp -j CHARGEN_ATTACK
$IPTABLES $RAW_TABLE -I PREROUTING -p tcp -j TCP_ATTACKS_RAW #this one is to be on top in the chain


$IP6TABLES -N MOBILE_DATA_OUT_V6
$IP6TABLES -I OUTPUT -o rmnet+ -j MOBILE_DATA_OUT_V6 #matching all rmnet interfaces
#$IP6TABLES -I MOBILE_DATA_OUT_V6 ! -o rmnet7 -d ff00::0/8 -j DROP #Block ipv6 multicast on lte radio
$IP6TABLES -A MOBILE_DATA_OUT_V6 -o rmnet+ -d ff00::0/8 -p udp --sport 5353 -j DROP # Block mdns on rmnet7 since not needed for verizon DM

$IP6TABLES -N RMNET_OUT_FILTER_V6
$IP6TABLES -A RMNET_OUT_FILTER_V6 -o rmnet+ -d ff00::0/8 -p udp --sport 5353 -j DROP
$IP6TABLES -A RMNET_OUT_FILTER_V6 -o rmnet7 -j ACCEPT
$IP6TABLES -A RMNET_OUT_FILTER_V6 -o rmnet1 -j ACCEPT
#$IP6TABLES -I OUTPUT -o rmnet+ -j RMNET_OUT_FILTER_V6 #matching all rmnet interfaces

Wait, my total lack of documentation wasn’t super clear? :laughing:

First off, I only focused on the open/close sensors. I don’t have any other sensors.

Secondly, I didn’t create a bunch of sensors in HA. Again, it went through my head (I even had a node in NR to make the sensors)… then I decided not to. As I said above, I’m not sure QolSys is long for my home. So I just have the events firing off the specific call-outs.

My use cases: When certain doors (e.g. a garage entry door) opens, I want to turn on the lights in the associated garage and the entry way in the house. I already have an HA automation that turns off the lights after 15 minutes (unless interrupted or reset… not to bog down here).

So I think you can get the same use case working (then modify from there) by

  1. changing the IP to your QolSys panel in the curl node
  2. specify what service(s) you want to call in the HA node
  3. specify which entities you want to send to HA in the “put entity_ids in msg” node

I hope this helps a bit… let me know!

Ah ok I follow what you are doing. So what you have so far is only being used as a trigger for some entities that aren’t associated with the panel, which you already have in HA.

Yeah my panel is pretty much all contact sensors and a couple motion sensors. Basically all binary sensors.

I keep feeling small burst’s of motivation to get this setup. I would like to setup binary sensors in HA for each of the devices connected to the panel and then feed the states into HA via Node Red.

I think I need to create individual binary sensors in my yamml and use Node Reds MQTT node to feed the states from the panel web socket to the sensors I created. But I’m struggling to figure out how to get that working.

Any chance you can set one sensor up this way with your configuration that I can use as a model to replicate for all my sensors?

After trying for hours to get MQTT to work in Node Red to update the status on a binary sensor I manually created in HA, someone pointed out to me that there is an integration that lets you create controllable sensors in Node Red that populate in HA :confused:

That makes things a lot easier. Now to figure out how to use that Node Red flow to update the sensors created within Node Red.

I just got my panel installed and I don’t have the option to enable 3rd party integration. Was this removed from the firmware? I’ve tried the master, installer, and dealer codes under advanced settings but don’t see the option anywhere.

@JasonLee One thing to be careful of when using those HA nodes: if you create a sensor in a loop (e.g. through an array), that node loses track of the previous sensor created. So unless you’ve cached the name of the sensor, you won’t be able to easily update it.

My description probably doesn’t make sense but I banged my head on this wall many months ago and decided not to manage (create) HA entities in node red.

@ahigginbotham it’s not where you’d expect it to be. I know you had to use the dealer code and go to advanced settings and i think it was buried in wifi settings or something weird. googled and found this.

From the main screen, click the small grey bar at the top. Choose Settings > Advanced Settings > enter Dealer Code (default 2222) > Installation > Devices > WIFI Devices > 3rd Party Connections > enable Remote Device Access > OK. The panel will then reboot to apply the changes.
Read more: Control4 Integration for Qolsys IQ Panel 2 Plus - Alarm Grid

It’s also not a feature in the factory firmware. I don’t know exactly what OS version in which it was introduced, but run an update cycle or two should get you current and make that feature available.

I wasn’t thinking of anything complicated, I have zero programming experience. I thought I could create the binary sensors manually in Node Red rather that try to have them dynamically created. I may just need to keep any eye on this thread until someone can post a working solution, I don’t feel like I’m getting anywhere.

@phunkymonkey does your Node Red flow include binary sensors that update in HA? Do you mind sharing what you have so far?

I had a terrible time with the autoblocking on the panel itself (thus the request for the iptables config), and set it aside for a few days to see if it would clear itself up. Seems like NodeRed can be a little too aggressive in reestablishing the connection, and will get itself blocked sometimes. Rebooting the panel seems to clear it up, so long as you stop NR and wait for the panel to be ready before starting again.

Anywho… my first use case is to populate status where I don’t have coverage from other HA sensors. From there, I’ll build some automations based on those status changes, but wanted to get that first part of the chain working before getting any more complicated.

That said, I set up a series of input booleans to use as the raw devices to represent the doors and windows that my alarm system cover. Because I needed to turn them on and off, I also parse the zone status and map to the turn_on and turn_off services for the HA json.

Going forward, I will likely streamline this by removing some of the looping, since everything will have a 1:1 mapping to entities in HA.

[
    {
        "id": "cbfaf013.0e5e",
        "type": "tab",
        "label": "Monitor QolSys Panel",
        "disabled": false,
        "info": ""
    },
    {
        "id": "9d021c07.d9795",
        "type": "server",
        "name": "Home Assistant",
        "addon": true
    },
    {
        "id": "8ab3acad.bd0fb",
        "type": "server",
        "name": "Home Assistant",
        "legacy": false,
        "addon": true,
        "rejectUnauthorizedCerts": true,
        "ha_boolean": "y|yes|true|on|home|open",
        "connectionDelay": false,
        "cacheJson": true
    },
    {
        "id": "40b27fca.5057",
        "type": "ui_base",
        "theme": {
            "name": "theme-light",
            "lightTheme": {
                "default": "#0094CE",
                "baseColor": "#0094CE",
                "baseFont": "-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Oxygen-Sans,Ubuntu,Cantarell,Helvetica Neue,sans-serif",
                "edited": true,
                "reset": false
            },
            "darkTheme": {
                "default": "#097479",
                "baseColor": "#097479",
                "baseFont": "-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Oxygen-Sans,Ubuntu,Cantarell,Helvetica Neue,sans-serif",
                "edited": false
            },
            "customTheme": {
                "name": "Untitled Theme 1",
                "default": "#4B7930",
                "baseColor": "#4B7930",
                "baseFont": "-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Oxygen-Sans,Ubuntu,Cantarell,Helvetica Neue,sans-serif"
            },
            "themeState": {
                "base-color": {
                    "default": "#0094CE",
                    "value": "#0094CE",
                    "edited": false
                },
                "page-titlebar-backgroundColor": {
                    "value": "#0094CE",
                    "edited": false
                },
                "page-backgroundColor": {
                    "value": "#fafafa",
                    "edited": false
                },
                "page-sidebar-backgroundColor": {
                    "value": "#ffffff",
                    "edited": false
                },
                "group-textColor": {
                    "value": "#1bbfff",
                    "edited": false
                },
                "group-borderColor": {
                    "value": "#ffffff",
                    "edited": false
                },
                "group-backgroundColor": {
                    "value": "#ffffff",
                    "edited": false
                },
                "widget-textColor": {
                    "value": "#111111",
                    "edited": false
                },
                "widget-backgroundColor": {
                    "value": "#0094ce",
                    "edited": false
                },
                "widget-borderColor": {
                    "value": "#ffffff",
                    "edited": false
                },
                "base-font": {
                    "value": "-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Oxygen-Sans,Ubuntu,Cantarell,Helvetica Neue,sans-serif"
                }
            },
            "angularTheme": {
                "primary": "indigo",
                "accents": "blue",
                "warn": "red",
                "background": "grey"
            }
        },
        "site": {
            "name": "Node-RED Dashboard",
            "hideToolbar": "false",
            "allowSwipe": "false",
            "lockMenu": "false",
            "allowTempTheme": "true",
            "dateFormat": "DD/MM/YYYY",
            "sizes": {
                "sx": 48,
                "sy": 48,
                "gx": 6,
                "gy": 6,
                "cx": 6,
                "cy": 6,
                "px": 0,
                "py": 0
            }
        }
    },
    {
        "id": "a92cf1.8c434b1",
        "type": "inject",
        "z": "cbfaf013.0e5e",
        "name": "go",
        "props": [],
        "repeat": "",
        "crontab": "",
        "once": true,
        "onceDelay": 0.1,
        "topic": "",
        "x": 90,
        "y": 100,
        "wires": [
            [
                "df1b46c2.dc0748"
            ]
        ]
    },
    {
        "id": "df1b46c2.dc0748",
        "type": "exec",
        "z": "cbfaf013.0e5e",
        "command": "curl -kN --http0.9 https://192.168.99.99:12345",
        "addpay": true,
        "append": "",
        "useSpawn": "true",
        "timer": "",
        "oldrc": false,
        "name": "curl",
        "x": 110,
        "y": 180,
        "wires": [
            [
                "1f5ac981.6ccdde",
                "1edaf367.8f44ed"
            ],
            [
                "f17d89c8.de8bf"
            ],
            [
                "cf10d274.0242e"
            ]
        ]
    },
    {
        "id": "cf10d274.0242e",
        "type": "debug",
        "z": "cbfaf013.0e5e",
        "name": "return (exit) codes",
        "active": false,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "true",
        "targetType": "full",
        "statusVal": "",
        "statusType": "auto",
        "x": 690,
        "y": 120,
        "wires": []
    },
    {
        "id": "1f5ac981.6ccdde",
        "type": "debug",
        "z": "cbfaf013.0e5e",
        "name": "activity events and updates",
        "active": false,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "true",
        "targetType": "full",
        "statusVal": "",
        "statusType": "auto",
        "x": 720,
        "y": 32,
        "wires": []
    },
    {
        "id": "f17d89c8.de8bf",
        "type": "debug",
        "z": "cbfaf013.0e5e",
        "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": 800,
        "y": 76,
        "wires": []
    },
    {
        "id": "1edaf367.8f44ed",
        "type": "switch",
        "z": "cbfaf013.0e5e",
        "name": "Ignore ACK",
        "property": "payload",
        "propertyType": "msg",
        "rules": [
            {
                "t": "cont",
                "v": "ACK",
                "vt": "str"
            },
            {
                "t": "else"
            }
        ],
        "checkall": "true",
        "repair": false,
        "outputs": 2,
        "x": 230,
        "y": 240,
        "wires": [
            [],
            [
                "9a07870e.d047d8"
            ]
        ]
    },
    {
        "id": "9a07870e.d047d8",
        "type": "json",
        "z": "cbfaf013.0e5e",
        "name": "convert update to json",
        "property": "payload",
        "action": "",
        "pretty": true,
        "x": 420,
        "y": 240,
        "wires": [
            [
                "9c24717d.c5031",
                "6d8421cd.eae33"
            ]
        ]
    },
    {
        "id": "9c24717d.c5031",
        "type": "debug",
        "z": "cbfaf013.0e5e",
        "name": "converted json",
        "active": false,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "true",
        "targetType": "full",
        "statusVal": "",
        "statusType": "auto",
        "x": 640,
        "y": 160,
        "wires": []
    },
    {
        "id": "e535c607.f893f8",
        "type": "api-call-service",
        "z": "cbfaf013.0e5e",
        "name": "",
        "server": "8ab3acad.bd0fb",
        "version": 1,
        "debugenabled": true,
        "service_domain": "",
        "service": "",
        "entityId": "",
        "data": "",
        "dataType": "json",
        "mergecontext": "",
        "output_location": "",
        "output_location_type": "none",
        "mustacheAltTags": false,
        "x": 550,
        "y": 540,
        "wires": [
            []
        ]
    },
    {
        "id": "6d8421cd.eae33",
        "type": "function",
        "z": "cbfaf013.0e5e",
        "name": "put entity_ids in msg",
        "func": "zid = msg.payload[\"zone\"][\"zone_id\"]\nzstatus = msg.payload[\"zone\"][\"status\"]\nentity_ids = []\nswitch (zid) {\n    case 5:\n        entity_ids = [\n            \"input_boolean.alarm_craft_room_window\"\n            ]\n        break\n    case 16:\n        entity_ids = [\n            \"input_boolean.alarm_front_door\"\n            ]\n        break\n    case 21:\n        entity_ids = [\n            \"input_boolean.alarm_big_garage_door\"\n            ]\n        break\n    case 22:\n        entity_ids = [\n            \"input_boolean.alarm_back_door\"\n            ]\n        break\n    case 13:\n        entity_ids = [\n            \"input_boolean.alarm_car_port_door\"\n            ]\n        break\n}\n\n//node.warn(\"zid: \" + zid + \", status: \" + zstatus + \", entities: \" + entity_ids)\n\nmsg.entity_ids = entity_ids\nmsg.zstatus = zstatus\n//node.warn(msg)\n\nreturn msg;",
        "outputs": 1,
        "noerr": 0,
        "initialize": "",
        "finalize": "",
        "x": 660,
        "y": 240,
        "wires": [
            [
                "929374ec.595c48",
                "ed36d599.984728"
            ]
        ]
    },
    {
        "id": "7b5ce640.877ee8",
        "type": "template",
        "z": "cbfaf013.0e5e",
        "name": "json for HA",
        "field": "payload",
        "fieldType": "msg",
        "format": "json",
        "syntax": "mustache",
        "template": "{\n    \"domain\":\"input_boolean\",\n    \"service\":\"{{zstatus}}\",\n    \"data\":\n        {\n            \"entity_id\":\"{{payload}}\"\n        }\n}",
        "output": "json",
        "x": 310,
        "y": 440,
        "wires": [
            [
                "e535c607.f893f8",
                "aad1aaf7.b1c3e8",
                "929374ec.595c48"
            ]
        ]
    },
    {
        "id": "929374ec.595c48",
        "type": "array-loop",
        "z": "cbfaf013.0e5e",
        "name": "loop entity_ids",
        "key": "al929374ec595c48",
        "keyType": "msg",
        "reset": true,
        "resetValue": "value-null",
        "array": "entity_ids",
        "arrayType": "msg",
        "x": 220,
        "y": 300,
        "wires": [
            [
                "1a32f917.444eb7"
            ],
            [
                "c2a3cc7c.d5ef1",
                "14e1993f.3790f7"
            ]
        ]
    },
    {
        "id": "aad1aaf7.b1c3e8",
        "type": "debug",
        "z": "cbfaf013.0e5e",
        "name": "json for HA",
        "active": true,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "true",
        "targetType": "full",
        "statusVal": "",
        "statusType": "auto",
        "x": 590,
        "y": 440,
        "wires": []
    },
    {
        "id": "c2a3cc7c.d5ef1",
        "type": "debug",
        "z": "cbfaf013.0e5e",
        "name": "looped payload",
        "active": false,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "true",
        "targetType": "full",
        "statusVal": "",
        "statusType": "auto",
        "x": 620,
        "y": 400,
        "wires": []
    },
    {
        "id": "1a32f917.444eb7",
        "type": "debug",
        "z": "cbfaf013.0e5e",
        "name": "end of loop payload",
        "active": false,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "true",
        "targetType": "full",
        "statusVal": "",
        "statusType": "auto",
        "x": 660,
        "y": 340,
        "wires": []
    },
    {
        "id": "ed36d599.984728",
        "type": "debug",
        "z": "cbfaf013.0e5e",
        "name": "added entity ids",
        "active": false,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "true",
        "targetType": "full",
        "statusVal": "",
        "statusType": "auto",
        "x": 930,
        "y": 320,
        "wires": []
    },
    {
        "id": "14e1993f.3790f7",
        "type": "change",
        "z": "cbfaf013.0e5e",
        "name": "",
        "rules": [
            {
                "t": "change",
                "p": "zstatus",
                "pt": "msg",
                "from": "Open",
                "fromt": "str",
                "to": "turn_on",
                "tot": "str"
            },
            {
                "t": "change",
                "p": "zstatus",
                "pt": "msg",
                "from": "Closed",
                "fromt": "str",
                "to": "turn_off",
                "tot": "str"
            }
        ],
        "action": "",
        "property": "",
        "from": "",
        "to": "",
        "reg": false,
        "x": 200,
        "y": 500,
        "wires": [
            [
                "7b5ce640.877ee8",
                "d4ac3aed.e67338"
            ]
        ]
    },
    {
        "id": "d4ac3aed.e67338",
        "type": "debug",
        "z": "cbfaf013.0e5e",
        "name": "",
        "active": false,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "false",
        "statusVal": "",
        "statusType": "auto",
        "x": 520,
        "y": 620,
        "wires": []
    }
]

Well… I guess I’m just impatient :wink:.

image

Made the NR flow more linear, only handling one entity per update, but able to set status to both on and off.

[
    {
        "id": "cbfaf013.0e5e",
        "type": "tab",
        "label": "Monitor QolSys Panel",
        "disabled": false,
        "info": ""
    },
    {
        "id": "a92cf1.8c434b1",
        "type": "inject",
        "z": "cbfaf013.0e5e",
        "name": "go",
        "props": [],
        "repeat": "",
        "crontab": "",
        "once": true,
        "onceDelay": 0.1,
        "topic": "",
        "x": 90,
        "y": 100,
        "wires": [
            [
                "df1b46c2.dc0748"
            ]
        ]
    },
    {
        "id": "df1b46c2.dc0748",
        "type": "exec",
        "z": "cbfaf013.0e5e",
        "command": "curl -kN --http0.9 https://192.168.99.99:12345",
        "addpay": true,
        "append": "",
        "useSpawn": "true",
        "timer": "",
        "oldrc": false,
        "name": "curl",
        "x": 110,
        "y": 180,
        "wires": [
            [
                "1f5ac981.6ccdde",
                "1edaf367.8f44ed"
            ],
            [
                "f17d89c8.de8bf"
            ],
            [
                "cf10d274.0242e"
            ]
        ]
    },
    {
        "id": "cf10d274.0242e",
        "type": "debug",
        "z": "cbfaf013.0e5e",
        "name": "return (exit) codes",
        "active": false,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "true",
        "targetType": "full",
        "statusVal": "",
        "statusType": "auto",
        "x": 430,
        "y": 148,
        "wires": []
    },
    {
        "id": "1f5ac981.6ccdde",
        "type": "debug",
        "z": "cbfaf013.0e5e",
        "name": "activity events and updates",
        "active": false,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "true",
        "targetType": "full",
        "statusVal": "",
        "statusType": "auto",
        "x": 460,
        "y": 60,
        "wires": []
    },
    {
        "id": "f17d89c8.de8bf",
        "type": "debug",
        "z": "cbfaf013.0e5e",
        "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": 540,
        "y": 104,
        "wires": []
    },
    {
        "id": "1edaf367.8f44ed",
        "type": "switch",
        "z": "cbfaf013.0e5e",
        "name": "Ignore ACK",
        "property": "payload",
        "propertyType": "msg",
        "rules": [
            {
                "t": "cont",
                "v": "ACK",
                "vt": "str"
            },
            {
                "t": "else"
            }
        ],
        "checkall": "true",
        "repair": false,
        "outputs": 2,
        "x": 230,
        "y": 240,
        "wires": [
            [],
            [
                "9a07870e.d047d8"
            ]
        ]
    },
    {
        "id": "9a07870e.d047d8",
        "type": "json",
        "z": "cbfaf013.0e5e",
        "name": "convert update to json",
        "property": "payload",
        "action": "",
        "pretty": true,
        "x": 300,
        "y": 300,
        "wires": [
            [
                "9c24717d.c5031",
                "6d8421cd.eae33"
            ]
        ]
    },
    {
        "id": "9c24717d.c5031",
        "type": "debug",
        "z": "cbfaf013.0e5e",
        "name": "converted json",
        "active": false,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "true",
        "targetType": "full",
        "statusVal": "",
        "statusType": "auto",
        "x": 600,
        "y": 200,
        "wires": []
    },
    {
        "id": "e535c607.f893f8",
        "type": "api-call-service",
        "z": "cbfaf013.0e5e",
        "name": "",
        "server": "8ab3acad.bd0fb",
        "version": 1,
        "debugenabled": true,
        "service_domain": "",
        "service": "",
        "entityId": "",
        "data": "",
        "dataType": "json",
        "mergecontext": "",
        "output_location": "",
        "output_location_type": "none",
        "mustacheAltTags": false,
        "x": 670,
        "y": 600,
        "wires": [
            []
        ]
    },
    {
        "id": "6d8421cd.eae33",
        "type": "function",
        "z": "cbfaf013.0e5e",
        "name": "put entity_ids in msg",
        "func": "zid = msg.payload[\"zone\"][\"zone_id\"]\nzstatus = msg.payload[\"zone\"][\"status\"]\nentity_id = \"\"\nswitch (zid) {\n    case 5:\n        entity_id = \"input_boolean.alarm_craft_room_window\"\n        break\n    case 16:\n        entity_id = \"input_boolean.alarm_front_door\"\n        break\n    case 21:\n        entity_id = \"input_boolean.alarm_big_garage_door\"\n        break\n    case 22:\n        entity_id = \"input_boolean.alarm_back_door\"\n        break\n    case 13:\n        entity_id = \"input_boolean.alarm_car_port_door\"\n        break\n}\n\n//node.warn(\"zid: \" + zid + \", status: \" + zstatus + \", entities: \" + entity_ids)\n\nmsg.entity_id = entity_id\nmsg.zstatus = zstatus\n\nreturn msg;",
        "outputs": 1,
        "noerr": 0,
        "initialize": "",
        "finalize": "",
        "x": 380,
        "y": 360,
        "wires": [
            [
                "ed36d599.984728",
                "14e1993f.3790f7"
            ]
        ]
    },
    {
        "id": "7b5ce640.877ee8",
        "type": "template",
        "z": "cbfaf013.0e5e",
        "name": "json for HA",
        "field": "payload",
        "fieldType": "msg",
        "format": "json",
        "syntax": "mustache",
        "template": "{\n    \"domain\":\"input_boolean\",\n    \"service\":\"{{zstatus}}\",\n    \"data\":\n        {\n            \"entity_id\":\"{{entity_id}}\"\n        }\n}",
        "output": "json",
        "x": 550,
        "y": 480,
        "wires": [
            [
                "63206646.c523d8"
            ]
        ]
    },
    {
        "id": "aad1aaf7.b1c3e8",
        "type": "debug",
        "z": "cbfaf013.0e5e",
        "name": "json for HA",
        "active": false,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "true",
        "targetType": "full",
        "statusVal": "",
        "statusType": "auto",
        "x": 770,
        "y": 520,
        "wires": []
    },
    {
        "id": "ed36d599.984728",
        "type": "debug",
        "z": "cbfaf013.0e5e",
        "name": "added entity ids",
        "active": false,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "true",
        "targetType": "full",
        "statusVal": "",
        "statusType": "auto",
        "x": 640,
        "y": 260,
        "wires": []
    },
    {
        "id": "14e1993f.3790f7",
        "type": "change",
        "z": "cbfaf013.0e5e",
        "name": "",
        "rules": [
            {
                "t": "change",
                "p": "zstatus",
                "pt": "msg",
                "from": "Open",
                "fromt": "str",
                "to": "turn_on",
                "tot": "str"
            },
            {
                "t": "change",
                "p": "zstatus",
                "pt": "msg",
                "from": "Closed",
                "fromt": "str",
                "to": "turn_off",
                "tot": "str"
            }
        ],
        "action": "",
        "property": "",
        "from": "",
        "to": "",
        "reg": false,
        "x": 480,
        "y": 420,
        "wires": [
            [
                "7b5ce640.877ee8",
                "d4ac3aed.e67338"
            ]
        ]
    },
    {
        "id": "d4ac3aed.e67338",
        "type": "debug",
        "z": "cbfaf013.0e5e",
        "name": "",
        "active": false,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "false",
        "statusVal": "",
        "statusType": "auto",
        "x": 670,
        "y": 360,
        "wires": []
    },
    {
        "id": "63206646.c523d8",
        "type": "switch",
        "z": "cbfaf013.0e5e",
        "name": "",
        "property": "entity_id",
        "propertyType": "msg",
        "rules": [
            {
                "t": "nempty"
            }
        ],
        "checkall": "true",
        "repair": false,
        "outputs": 1,
        "x": 590,
        "y": 540,
        "wires": [
            [
                "e535c607.f893f8",
                "aad1aaf7.b1c3e8"
            ]
        ]
    },
    {
        "id": "8ab3acad.bd0fb",
        "type": "server",
        "name": "Home Assistant",
        "legacy": false,
        "addon": true,
        "rejectUnauthorizedCerts": true,
        "ha_boolean": "y|yes|true|on|home|open",
        "connectionDelay": false,
        "cacheJson": true
    }
]

Also, here’s my config for the input boolean entities from the tail end of my configuration.yaml:

# sensors from alarm system via node-red
input_boolean:
  alarm_car_port_door:
    name: Car Port Door (wired)
    icon: mdi:door-closed
  alarm_front_door:
    name: Front Door (wired)
    icon: mdi:door-closed
  alarm_small_garage_door:
    name: Small Garage Door (wired)
    icon: mdi:door-closed
  alarm_back_door:
    name: Back Door (wired)
    icon: mdi:door-closed

This is pretty awesome. I bought that panel for the alarm.com integration and then they deprecated that. I just installed Node Red add-on today and have never used it. Is the code in the top what the graphical node-red produces? Then the sensors are in your YAML?

Also did the flakiness go away with the connection? All I want to do is be able to use my door and motion statuses to automate things in HA. This is a better solution for me than alarm.com would be anyway. I just want to make sure I understand what you did here.

I got this working following your example. Thanks so much. The only issue I have is with motion sensors. They just flash on/off in less than a second. Are you using motion sensors and if so are you doing something different than the binary switch to utilize them. This was my primary goal to turn on a light when someone entered a room based off the motion.

I got some help and modified the Node Red Flow to use the HA Node Red integration. This simplifies things a little by having Node Red create the binary sensors and populate/update them in HA automatically.

To get this working you will need to install the Node Red companion component through HACs:

  1. Import Flow

  2. Modify “Curl” node with your panel IP address

  3. Modify “put entity_ids in msg” node. Change the outputs to however many panel connected sensors you want to monitor. In my example 16. The panel has a list of all the connected devices. Go into the setting and write them down. The list order will determine the number ID (zid) of each device. The device ID # is = case #. List all your devices and their case # (zid # aka device ID #). Modify the array so that the number of ‘null’ s is equal to number of devices - 1.

  4. add a binary senor node for each device and connect them in the right order to ‘put entity_ids in msg’ node. As soon as you deploy the Flow the Node Red integration will create corresponding entities in HA, so make sure you rename, and delete any of mine so that you don’t create unwanted entities.

My flow:

[
    {
        "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.50: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"
            ]
        ]
    },
    {
        "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": "put entity_ids in msg",
        "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": 220,
        "y": 700,
        "wires": [
            [
                "9022a5b8.478c58",
                "4aa7a1bc.426c9"
            ],
            [
                "a35218ae.d18e28"
            ],
            [
                "60ca2505.845d1c"
            ],
            [
                "df396c28.eef64"
            ],
            [
                "19770ba8.11c6d4"
            ],
            [
                "d8ba25f6.efce58"
            ],
            [
                "dcc747aa.a378b8"
            ],
            [
                "1722acaa.485883"
            ],
            [
                "35d56d5d.bd9c62"
            ],
            [
                "fac1a046.e2162"
            ],
            [
                "71d87ba9.be99e4"
            ],
            [
                "d1b097c8.d89308"
            ],
            [
                "964b0753.0aa248"
            ],
            [
                "83bc1403.532158"
            ],
            [
                "df4d7e82.5323b"
            ],
            [
                "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": 540,
        "y": 180,
        "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": [
            {
                "property": "payload_on",
                "value": "Open",
                "valueType": "str"
            },
            {
                "property": "payload_off",
                "value": "Closed",
                "valueType": "str"
            }
        ],
        "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": 510,
        "y": 140,
        "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": [
            {
                "property": "payload_on",
                "value": "Open",
                "valueType": "str"
            },
            {
                "property": "payload_off",
                "value": "Closed",
                "valueType": "str"
            }
        ],
        "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": [
            {
                "property": "payload_on",
                "value": "Open",
                "valueType": "str"
            },
            {
                "property": "payload_off",
                "value": "Closed",
                "valueType": "str"
            }
        ],
        "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": [
            {
                "property": "payload_on",
                "value": "Open",
                "valueType": "str"
            },
            {
                "property": "payload_off",
                "value": "Closed",
                "valueType": "str"
            }
        ],
        "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": [
            {
                "property": "payload_on",
                "value": "Open",
                "valueType": "str"
            },
            {
                "property": "payload_off",
                "value": "Closed",
                "valueType": "str"
            }
        ],
        "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": [
            {
                "property": "payload_on",
                "value": "Open",
                "valueType": "str"
            },
            {
                "property": "payload_off",
                "value": "Closed",
                "valueType": "str"
            }
        ],
        "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": [
            {
                "property": "payload_on",
                "value": "Open",
                "valueType": "str"
            },
            {
                "property": "payload_off",
                "value": "Closed",
                "valueType": "str"
            }
        ],
        "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": [
            {
                "property": "payload_on",
                "value": "Open",
                "valueType": "str"
            },
            {
                "property": "payload_off",
                "value": "Closed",
                "valueType": "str"
            }
        ],
        "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": [
            {
                "property": "payload_on",
                "value": "Open",
                "valueType": "str"
            },
            {
                "property": "payload_off",
                "value": "Closed",
                "valueType": "str"
            }
        ],
        "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": [
            {
                "property": "payload_on",
                "value": "Open",
                "valueType": "str"
            },
            {
                "property": "payload_off",
                "value": "Closed",
                "valueType": "str"
            }
        ],
        "resend": true,
        "outputLocation": "",
        "outputLocationType": "none",
        "inputOverride": "allow",
        "x": 560,
        "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": [
            {
                "property": "payload_on",
                "value": "Open",
                "valueType": "str"
            },
            {
                "property": "payload_off",
                "value": "Closed",
                "valueType": "str"
            }
        ],
        "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": [
            {
                "property": "payload_on",
                "value": "Open",
                "valueType": "str"
            },
            {
                "property": "payload_off",
                "value": "Closed",
                "valueType": "str"
            }
        ],
        "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": [
            {
                "property": "payload_on",
                "value": "Open",
                "valueType": "str"
            },
            {
                "property": "payload_off",
                "value": "Closed",
                "valueType": "str"
            }
        ],
        "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": [
            {
                "property": "payload_on",
                "value": "Open",
                "valueType": "str"
            },
            {
                "property": "payload_off",
                "value": "Closed",
                "valueType": "str"
            }
        ],
        "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": [
            {
                "property": "payload_on",
                "value": "Open",
                "valueType": "str"
            },
            {
                "property": "payload_off",
                "value": "Closed",
                "valueType": "str"
            }
        ],
        "resend": true,
        "outputLocation": "",
        "outputLocationType": "none",
        "inputOverride": "allow",
        "x": 550,
        "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": [
            {
                "property": "payload_on",
                "value": "Open",
                "valueType": "str"
            },
            {
                "property": "payload_off",
                "value": "Closed",
                "valueType": "str"
            }
        ],
        "resend": true,
        "outputLocation": "",
        "outputLocationType": "none",
        "inputOverride": "allow",
        "x": 570,
        "y": 1140,
        "wires": [
            []
        ]
    },
    {
        "id": "934a7469.f8dfc8",
        "type": "server",
        "name": "Home Assistant",
        "addon": true
    }
]

Huge thanks to Xtacy over on the HA Discord for the help on this

1 Like

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.

1 Like