Closed lespatots closed 3 years ago
You can do it in a couple of ways. The first is just hook up homekit nodes to listen to the eve sensors and all push to a "sensor" for node-red-contrib-alarm.
Another is hook them all to one sensor for node-red-contrib-alarm.
Or use another mechanism outside of node red to aggregate them into one signal to node-red and send that to a single alarm sensor for node-red-contrib-alarm.
The reason to potentially keep them separate is to later make use of displaying which "sensor" was tripped, though not sure when node-red-contrib-alarm will have that feature.
Thanks for the rapid reply. When you say hook up Homekit Nodes, which nodes are we talking about. All the nodes seem to be for Homekit simulation and are the opposite of what I need? I do this type of monitoring for Hue Battery states using HueMagic but there is no similar capability for Eve. Surely the Alarm Panel main use would be to monitor door/window states, which is why I though an example would be good.
In the doco (also here: https://github.com/Anamico/node-red-contrib-alarm/) there is an example for a nest smoke detector as an example, this template can be used for any sensor trigger, even triggering on receipt of an email, facebook post or tweet.
There are 3 nodes in that standard approach:
Specific to step 1 is how do you get the message from the eve sensor (or email or whatever it is) to actually arrive in node red? Well that is very specific to the type of sensor. I haven't done research into eve specifically (as there are tons of options, so that's why node-red-contrib-alarm is very generic, you just get the message to it). From a quick google search for node-red and eve, it appears to always list node-red-homekit (and bridged). So given it is homekit capable, I would think that is an option. In that case you set up a homekit node, get it to emit on changes in state of that sensor and use that message as stage 1 in that alarm chain.
Alternately, if you choose a different way (like openhab or direct http MQTT, whatever, for Node-Red to talk to the eve sensor and detect a change, then use that message as stage 1 and fee it in to the alarm sensor).
In the "Garage Door" example in that same doco, you will see it only has stage 1 and stage 3, there was no logic required for the Wemo node-red node to make it drive the state of the alarm sensor, so stage 2 was a basic passthrough and not required.
Many of the examples given are directly from my production home alarm system using exactly those configurations, so for instance, I am using Z-Wave and Zigbee as well as TCP style interface components for a buch of things. My door sensors are zigbee and I use openhab to interface them with the node-red-contrib openhab nodes. Like the "Kitchen" sensor example, which is a Z-Wave door sensor reed switch that triggers an alarm if the alarm is "Armed" and the Kitchen door is opened.
The first step to getting it hooked up is to get the signal into node red, if you can get a debug node that echos "open"/"close" data when you open and close the sensor (door/window) then that is your stage 1, use stage 2 and 3 to hook it up to get node-red-contrib-alarm to detect the door opening and trigger the alarm.
Does that help?
Closing due to no response
This is probably a very stupid question but! I have a large number of the Eve sensors that are connected into Homekit. I would very much like to aggregate these into a simple alarm that is activated if any door /window is opened. Could an example be created that would demonstrate how to do this?